Skip to content

Instantly share code, notes, and snippets.

View szelga's full-sized avatar

Wasil Siargiejczyk szelga

  • Russia, Chelyabinsk
View GitHub Profile
@Tenderfeel
Tenderfeel / _css-speech-bubble.styl
Last active January 1, 2016 12:19
CSS Speech Bubble Mixin for Stylus
//--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--
// CSS Speech Bubble Mixin (for stylus)
// _bubble.scss
//
// http://jsdo.it/Tenderfeel/ApPq
// http://cssdeck.com/labs/x0v5zniy
//--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--
// Bubble-tail
//
@benjaoming
benjaoming / custom_user_auth_south_refactor.py
Last active August 1, 2020 17:04
Refactor South migration directory to respect custom User models. Backwards compatible with <django 1.5
# -*- coding: utf-8 -*-
"""Refactor South migrations to use settings.AUTH_USER_MODEL.
Inserts a backwards-compatible code-snippet in all
your schema migration files and uses a possibly customized user
model as introduced in Django 1.5.
Please note that this has nothing to do with changing
settings.AUTH_USER_MODEL to a new model. If you do this, stuff
will very likely break in reusable apps that have their own
migration trees.
anonymous
anonymous / rec.sh
Created October 21, 2012 14:06
record using ffmpeg
#!/bin/sh
INFO=$(xwininfo -frame)
WIN_GEO=$(echo $INFO | grep -oEe 'geometry [0-9]+x[0-9]+' |\
grep -oEe '[0-9]+x[0-9]+')
WIN_XY=$(echo $INFO | grep -oEe 'Corners:\s+\+[0-9]+\+[0-9]+' |\
grep -oEe '[0-9]+\+[0-9]+' | sed -e 's/+/,/' )
ffmpeg -f x11grab -y -r 15 -s $WIN_GEO -i :0.0+$WIN_XY -vcodec ffv1 -sameq -f alsa -ac 2\