Skip to content

Instantly share code, notes, and snippets.

View funnydman's full-sized avatar
😀
Chilling

funnydman

😀
Chilling
View GitHub Profile

Vim Script for Python Developers

A guide to Vim Script development for Python developers. Sample code for the various expressions, statements, functions and programming constructs is shown in both Python and Vim Script. This is not intended to be a tutorial for developing Vim scripts. It is assumed that the reader is familiar with programming in Python.

For an introduction to Vim Script development, refer to usr_41.txt, eval.txt and Learn Vimscript the Hard Way


Variables

@funnydman
funnydman / tokens.md
Created May 27, 2020 17:15 — forked from zmts/tokens.md
Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

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

Last major update: 20.04.2020

  • Что такое авторизация/аутентификация
  • Где хранить токены
  • Как ставить куки ?
  • Процесс логина
  • Процесс рефреш токенов
  • Кража токенов/Механизм контроля токенов
@funnydman
funnydman / vim_cheatsheet.md
Created November 4, 2020 17:23 — forked from awidegreen/vim_cheatsheet.md
Vim shortcuts

Introduction

  • C-a == Ctrl-a
  • M-a == Alt-a

General

:q        close
:w        write/saves
:wa[!]    write/save all windows [force]
:wq       write/save and close
@funnydman
funnydman / celerey-headless.pipeline
Last active November 25, 2020 09:07
Celery headless configuration for pipeline
sudo: required
language: python
python:
- "3.6"
# command to install dependencies
install:
- pip install -r requirements.txt
# command to run tests
script:
- python manage.py behave
@funnydman
funnydman / combined_expressions.py
Created December 1, 2020 12:56
combined expressions Django helper
# https://stackoverflow.com/questions/58877390/how-to-collect-results-into-array-from-annotation
"""
Some different ways:
"""
class CombinedExpressions(SQLiteNumericMixin, Expression):
def __init__(self, *expressions, connector, output_field=None):