I hereby claim:
- I am naufraghi on github.
- I am naufraghi (https://keybase.io/naufraghi) on keybase.
- I have a public key whose fingerprint is C01B A13F 5190 29A7 82E1 975A C4D1 A495 B316 6AF3
To claim this, I am signing this object:
# This is the "normal" way | |
class C(object): | |
def __init__(self): | |
self._x = None | |
@property | |
def x(self): | |
return self._x | |
@x.setter # will copy C.x and add the setter | |
def x(self, value): | |
self._x = value |
" naufraghi: move easily in tags | |
" tag->first, tselect->list, tjump->list-if-more-than-one | |
map <silent><C-Right> :exec("tjump ".expand("<cword>"))<CR> | |
map <silent><C-Left> :pop<CR> |
# ~/.bashrc: executed by bash(1) for non-login shells. | |
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) | |
# for examples | |
# If not running interactively, don't do anything | |
[ -z "$PS1" ] && return | |
# http://www.bradshawenterprises.com/blog/2008/5-ways-to-make-using-bash-more-productive/ | |
# erase old dups and skip commands starting with spaces | |
export HISTCONTROL="ignorespace:ignoredups" |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Scola la pasta</title> | |
<style type='text/css'> | |
@import url(http://fonts.googleapis.com/css?family=Krona+One); | |
h1 { | |
font-family: 'Krona One', sans-serif; | |
font-size: 8em; | |
font-size: 8vm; |
#!/usr/bin/env python3 | |
# Copyright 2014 Matteo Bertini [email protected] | |
# Released as Public Domain | |
# | |
# Latest version: | |
# wget http://slug.it/backup-google-authenticator.py | |
# | |
# Requirements | |
# ============ | |
# |
def retry(func, exception=Exception, num=3, wait=0.5): | |
""" | |
Example usage: | |
f = retry(open, IOError, num=3, wait=0.5)(file_path, 'w') | |
""" | |
def _retry(*args, **kwargs): | |
c = num | |
while True: | |
c = c-1 | |
try: |
--- | |
- hosts: local | |
sudo: yes | |
vars: | |
home: "{{ lookup('env','HOME') }}" | |
tasks: | |
- name: enable multiarch | |
command: dpkg --add-architecture i386 | |
- name: install deps | |
apt: name={{ item }} update_cache=yes cache_valid_time=3600 |
I hereby claim:
To claim this, I am signing this object:
from PyQt4.Qt import * | |
def teeSignal(*sig_args, **kwargs): | |
if "name" not in kwargs: | |
raise ValueError("Signal name required for old style emit compatibility") | |
class X(QObject): | |
signal = pyqtSignal(*sig_args, **kwargs) | |
x = X() | |
sig_name = kwargs["name"] | |
has_args = len(sig_args) > 0 |