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
#!/usr/bin/env python | |
from os import getcwd | |
from sys import argv | |
from subprocess import Popen | |
from pynotify import init, Notification | |
from sniffer.broadcasters import PynotifyEmitter | |
from sniffer.main import run | |
from sniffer.runner import Sniffer |
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
# Requires snakefood python module | |
all: data clusters graph | |
data: | |
@echo "Generating data" | |
@sfood tentd > /tmp/tentd.deps | |
clusters: data | |
@echo "Clustering data" |
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
def test_create_new_profile(self, entity): | |
schema = 'https://testprofile.example.com/' | |
data = {'data': 'test'} | |
response = PUT('entity.profile', data, secure=True, schema=schema) | |
profile = entity.profiles.get(schema=schema) | |
assert response.json() == profile.to_json() == data |
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
class PositiveInt(object): | |
__slots__ = 'value' | |
def __init__(self, value): | |
self.__set__(instance=None, value=value) | |
def __get__(self, instance, owner): | |
return self.value | |
def __set__(self, instance, value): |
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
class Attribute(object): | |
def __get__(self, instance, owner): | |
print("Getting x") | |
if not 'x' in instance.__dict__: | |
instance.__dict__['x'] = 1 | |
return instance.__dict__['x'] | |
def __set__(self, instance, value): | |
instance.__dict__['x'] = value |
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
eval $(echo "no:global default;fi:normal file;di:directory;ln:symbolic link;pi:named pipe;so:socket;do:door;bd:block device;cd:character device;or:orphan symlink;mi:missing file;su:set uid;sg:set gid;tw:sticky other writable;ow:other writable;st:sticky;ex:executable;"|sed -e 's/:/="/g; s/\;/"\n/g') | |
{ | |
IFS=: | |
for i in $LS_COLORS do | |
echo -e "\e[${i#*=}m$( x=${i%=*}; [ "${!x}" ] && echo "${!x}" || echo "$x" )\e[m" | |
done | |
} |
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
Linode configuration profile: | |
Kernel: pv-grub-x86_64 | |
Xenify: No | |
Required packages: | |
lxc | |
supervisor (optional) | |
Docker installation: | |
wget http://get.docker.io/builds/Linux/x86_64/docker-latest.tgz |
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
riemann 5555/udp | |
riemann 5555/tcp | |
riemann 5556/websockets | |
riemann-dash 4567/http |
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
❯ sudo aptitude install kate | |
The following NEW packages will be installed: | |
docbook-xml{a} docbook-xsl{a} fonts-freefont-ttf{a} kate kate-data{a} katepart{a} kde-runtime{a} kde-runtime-data{a} kdelibs-bin{a} kdelibs5-data{a} kdelibs5-plugins{a} kdoctools{a} liba52-0.7.4{a} libattica0{a} | |
libcanberra-gtk3-0{a} libcanberra-gtk3-module{a} libcddb2{a} libcdio13{a} libclucene0ldbl{a} libcrystalhd3{a} libdbusmenu-qt2{a} libdirac-decoder0{a} libdlrestrictions1{a} libdvbpsi7{a} libebml3{a} libexiv2-12{a} | |
libfile-basedir-perl{a} libfile-desktopentry-perl{a} libfile-mimeinfo-perl{a} libgif4{a} libilmbase6{a} libimobiledevice2{a} libiodbc2{a} libiso9660-8{a} libkateinterfaces4{a} libkatepartinterfaces4{a} libkcmutils4{a} | |
libkde3support4{a} libkdeclarative5{a} libkdecore5{a} libkdesu5{a} libkdeui5{a} libkdewebkit5{a} libkdnssd4{a} libkemoticons4{a} libkfile4{a} libkhtml5{a} libkidletime4{a} libkio5{a} libkjsapi4{a} libkjsembed4{a} libkmediaplayer4{a} | |
libknewstuff2-4{a} libknewstuff3-4{a} libknotifyconfig4{a} libk |
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
$ time sudo /opt/chef/embedded/bin/gem install librarian librarian-chef | |
Successfully installed librarian-0.1.1 | |
Fetching: librarian-chef-0.0.2.gem (100%) | |
Successfully installed librarian-chef-0.0.2 | |
2 gems installed | |
Installing ri documentation for librarian-0.1.1... | |
Installing ri documentation for librarian-chef-0.0.2... | |
Installing RDoc documentation for librarian-0.1.1... | |
Installing RDoc documentation for librarian-chef-0.0.2... | |
sudo /opt/chef/embedded/bin/gem install librarian librarian-chef |