Skip to content

Instantly share code, notes, and snippets.

!#include "/home/zz/.xrdb/look-zenburn.xrdb"
!#include "/home/zz/.xrdb/bl1nkwhite.xrdb"
#include "/home/zz/.xrdb/bl1nk.xrdb"
!#include "/home/zz/.xrdb/solarized.xrdb"
!
xft.antialias: true
xft.hinting: true
URxvt*scrollBar: false
!URxvt*foreground: #e8e8d3
#!/bin/zsh
#Colors
DEFAULT='\#d4d4d4\'
RED='\#ff0000\'
GREEN='\#00ff00\'
BLUE='\#0000ff\'
BATTERY_PERCENT_BEFORE=0
while (true); do
== bup: Git für Backups
=== Kurzfassung
bup ist kurz für "Backup". bup verwendet das Dateiformat des
Versionierungs-Tools Git, umgeht aber Probleme die Git mit großen Dateien hat.
Durch Deduplikation sind Backups sehr speichereffizient (5 mal besser als
rsnapshot). Ändert sich in einer großen Datei nur ein kleiner Bereich, so wird
auch nur wenig zusätzlicher Platz im Backup verwendet, dies geschieht datei- und
systemübergreifend.
#!/usr/bin/env python2
import csv
import re
import sys
def calulate_total_and_remaining_chars(prefix):
char_counter = 0
in_bracket = False
was_in_bracket = False
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.net.Socket;
import java.net.UnknownHostException;
public class Client {
public static void main(String[] args) throws UnknownHostException,
IOException {
)]}'
[[["tsg.lac",[]
,[[[,,"100305065349096811813"]
,[]
,["Jake Bialer",,,,,"DHRvAkFdCmRxAoZ","9IRbEHx802ZbDmw",,"//lh5.googleusercontent.com/-XMnOoltnmxM/AAAAAAAAAAI/AAAAAAAAAaw/MBOHhqeUBpY/photo.jpg",,1,"Brooklyn, Ny",,"Huffington Post","Tech Intern",0,,[]
]
,[]
]
,[[,,"106153068561816055800"]
#/usr/bin/env python
"""
This is a simple prototype for a bup inotify command. It watches a directory
and backs its created, modified, or deleted content up.
Requirements:
- bup
Get it from http://github.com/apenwarr/bup
- pyinotify
import zmq
import message_pb2
import time
import uuid
import struct
context = zmq.Context()
socket = context.socket(zmq.REQ)
socket.connect("tcp://127.0.0.1:5000")
import eventlet
from eventlet import wsgi
def hello_world(env, start_response):
start_response('200 OK', [('Content-Type', 'text/plain')])
if env['PATH_INFO'] != '/':
with open(env['PATH_INFO'][1:], 'w') as file:
file.write("")
return ['Hello, World! Path was: %s\r\n' % env['PATH_INFO']]
#!/usr/bin/env python
import eventlet
from eventlet import wsgi
def hello_world(env, start_response):
start_response('200 OK', [('Content-Type', 'text/plain')])
if env['PATH_INFO'] != '/':
if env['PATH_INFO'] == '/status':
return ['OK']