View gist:77fe919c5e146628638c55cf7506bffc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am jonaspf on github. | |
* I am jonaspf (https://keybase.io/jonaspf) on keybase. | |
* I have a public key ASCr5nrf_TjnIu2pM823Scn45eCMa450-69e9rT5Od9BRQo | |
To claim this, I am signing this object: |
View gist:216a9b8457a16d472664093492081300
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Verifying my Blockstack ID is secured with the address 1GPb42kqRpLpUDG2kAtwzRXDsjFYVmTtGN https://explorer.blockstack.org/address/1GPb42kqRpLpUDG2kAtwzRXDsjFYVmTtGN |
View use_ansible.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import subprocess | |
import os | |
from collections import namedtuple | |
from tempfile import NamedTemporaryFile | |
from ansible.parsing.dataloader import DataLoader | |
from ansible.vars import VariableManager | |
from ansible.inventory import Inventory | |
from ansible.playbook.play import Play |
View hex2base58check.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import binascii | |
import base58 | |
import sys | |
string = sys.argv[1] | |
hex_values = binascii.unhexlify(string) | |
print(base58.b58encode_check(hex_values)) |
View list_backups.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import subprocess | |
import datetime | |
import re | |
import sys | |
backups = subprocess.check_output(['swift', 'list', sys.argv[1]]).splitlines() | |
width = None | |
total = 0 |
View writebmp.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
w = 500 | |
h = 300 | |
bmp = wx.EmptyBitmap(w, h) | |
dc = wx.MemoryDC() | |
dc.SelectObject(bmp) | |
dc.SetBackground(wx.Brush('black')) | |
dc.Clear() | |
dc.SetBrush(wx.Brush('green')) |
View customcontrol.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import wx | |
class CustomPanel(wx.PyPanel): | |
def __init__(self, parent): | |
wx.PyPanel.__init__(self, parent) | |
self.Bind(wx.EVT_PAINT, self.OnPaint) | |
self.Bind(wx.EVT_ERASE_BACKGROUND, self.OnEraseBackground) |
View gist:7bf2f1628aad57dbde56
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alert('I am evil'); |
View gist:9461819
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Creates a html page with a list of distinct looking colours for graphs, etc. | |
# Algorithm from: http://martin.ankerl.com/2009/12/09/how-to-create-random-colors-programmatically/ | |
# | |
# Jonas Pfannschmidt | |
from colorsys import hsv_to_rgb | |
golden_ratio_conjugate = 0.618033988749895 |
View automate.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import re | |
import sys | |
import zipfile | |
import shutil | |
import subprocess | |
import time | |
import threading | |
import Queue |
NewerOlder