Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

1 2 3 4
A |---|-O-|---|---|
E |---|---|-O-|---|
C |---|-O-|---|---|
G |---|---|---|---|
w/ same shape:
~~~~~~~~~~~~[ C ]~~~~~~~~~~~~~
4 5 6 7 8 9
starenka /tmp % time lein -v
Leiningen 2.3.4 on Java 1.8.0_05 Java HotSpot(TM) 64-Bit Server VM
lein -v 1.95s user 0.09s system 130% cpu 1.566 total
starenka /tmp % time lein -v
Leiningen 2.3.4 on Java 1.8.0_05 Java HotSpot(TM) 64-Bit Server VM
lein -v 1.99s user 0.06s system 130% cpu 1.574 total
starenka /tmp % time lein -v
Leiningen 2.3.4 on Java 1.8.0_05 Java HotSpot(TM) 64-Bit Server VM
lein -v 1.98s user 0.08s system 125% cpu 1.641 total
starenka /tmp % time lein -v
starenka /tmp % cat ~/.config/terminator/config
[global_config]
geometry_hinting = False
enabled_plugins = ,
tab_position = hidden
borderless = True
[keybindings]
scaled_zoom = <Shift><Control>u
go_up = <Shift>Up
next_tab = <Shift>Right
#!/usr/bin/env python
# coding=utf-8
import argparse
from selenium import webdriver
BROWSERS = dict(phantom=webdriver.PhantomJS,
opera=webdriver.Opera,
firefox=webdriver.Firefox,
chrome=webdriver.Chrome
#!/usr/bin/env python
# coding=utf-8
import sys, operator, re
OPMAP = {'+': operator.add, '-': operator.sub, '/': operator.div, '*': operator.mul}
RE_PARSE = re.compile(r'(?P<op>[+\-/\*])\s+(?P<num>\d+)')
def apply(line, prev):
op, num = re.match(RE_PARSE, line.strip('\n')).groups()
starenka /tmp % grep '^z.*l$' /data/slovniky/Czech.3-0-8utf8u.dic
zabal
zabalil
zabarikádoval
zabarvil
zabavil
zabavoval
zabejčil
zabezpečil
zabezpečoval
@starenka
starenka / gist:9466644
Last active August 29, 2015 13:57
ph what p?
'''
<?php
$array = array_fill(0,10000, "ahoj");
$count = 0;
$length = 0;
foreach($array as $item) {
class ModuleAdmin(admin.ModelAdmin):
class ParentFilter(SimpleListFilter):
title = _('Parent')
parameter_name = 'parent'
def lookups(self, request, model_admin):
return [(m.id, m.name) for m in Module.objects.filter(parent__isnull=True).order_by('name')] + [('Null', 'Null')]
def queryset(self, request, queryset):
if self.value():
#tady je priklad jednoho projektu:
# [-]luft_vagrant
# [+].hg
# .hgignore
# [+].vagrant
# README.md
# Vagrantfile
# [-]provisioning
# ansible_hosts
cvt 1680 1050 #get xorg-like line for this resolution
xrandr --newmode "flatronw2242s" 146.25 1680 1784 1960 2240 1050 1053 1059 1089 -hsync +vsync #make the mode
xrandr --addmode VGA1 "flatronw2242s" #add it to xrandr