Skip to content

Instantly share code, notes, and snippets.

@danidiaz
danidiaz / netrw.txt
Created October 7, 2016 20:57
Vim's netrw commands.
--- ----------------- ----
Map Quick Explanation Link
--- ----------------- ----
< <F1> Causes Netrw to issue help
<cr> Netrw will enter the directory or read the file |netrw-cr|
<del> Netrw will attempt to remove the file/directory |netrw-del|
<c-h> Edit file hiding list |netrw-ctrl-h|
<c-l> Causes Netrw to refresh the directory listing |netrw-ctrl-l|
<c-r> Browse using a gvim server |netrw-ctrl-r|
<c-tab> Shrink/expand a netrw/explore window |netrw-c-tab|
@brunodles
brunodles / lima-agnoster.zsh-theme
Created October 22, 2016 01:53
A simple change on agnoster theme. This will add the time of the last command on the right size.
# vim:ft=zsh ts=2 sw=2 sts=2
#
# agnoster's Theme - https://gist.github.com/3712874
# A Powerline-inspired theme for ZSH
#
# # README
#
# In order for this theme to render correctly, you will need a
# [Powerline-patched font](https://github.com/Lokaltog/powerline-fonts).
# Make sure you have a recent version: the code points that Powerline
@zmts
zmts / tokens.md
Last active June 11, 2024 08:13
Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Last major update: 25.08.2020

  • Что такое авторизация/аутентификация
  • Где хранить токены
  • Как ставить куки ?
  • Процесс логина
  • Процесс рефреш токенов
  • Кража токенов/Механизм контроля токенов
@aynm142
aynm142 / api reg
Created October 20, 2017 17:34
api.php
/**
* @SWG\Post(
* path="/login/api",
* summary="Store new or update existing device",
* tags={"Login"},
* description="Store new or update existing device. <strong>Authorization header required</strong>",
* operationId="postDevice",
* consumes={"application/json", "application/x-www-form-urlencoded"},
* produces={"application/json"},
* @SWG\Parameter(
<?php
namespace PetstoreIO;
final class PetController
{
/**
* @SWG\Get(
* path="/pet/findByTags",
@chuckrincon
chuckrincon / ConfigServiceProvider.php
Last active October 10, 2023 14:13
Load all your lumen config files painless.
<?php
namespace App\Providers;
use Illuminate\Support\Facades\App;
use Illuminate\Support\ServiceProvider;
use Illuminate\Contracts\Filesystem\FileNotFoundException;
class ConfigServiceProvider extends ServiceProvider
{
@jthomaschewski
jthomaschewski / _directives.graphql
Created October 22, 2018 08:54
Lighthouse GraphQL Directives (WIP)
# Scalar directives
directive @scalar(class: String!) on SCALAR
# ENUM directives
directive @enum(value: ID!) on ENUM_VALUE
# Union directives
directive @union(resolver: String!) on UNION
@hipsterjazzbo
hipsterjazzbo / directives.graphql
Last active May 18, 2023 02:37
A list of all the directive definitions for version 3.7 of https://github.com/nuwave/lighthouse
directive @all(
"""
Specify the class name of the model to use.
This is only needed when the default model resolution does not work.
"""
model: String
"""
Apply scopes to the underlying query.
"""