Skip to content

Instantly share code, notes, and snippets.

View fliiiix's full-sized avatar
🎩
This is the year of ipv6 and python3!

Felix fliiiix

🎩
This is the year of ipv6 and python3!
View GitHub Profile
#!/bin/bash
Red='\e[0;31m';
# reset color
RCol='\e[0m'
cleanUp(){
# clean up
unset counter
unset PDFNAME
@fliiiix
fliiiix / backup_full.sh
Created February 26, 2015 18:50
FreeBSD with ZFS backup
DATE=`date "+%Y-%m-%d_%H-%M-%S"`
#snap teh shot .__.
zfs snapshot -r tank@$DATE
#send it
zfs send -R tank@$DATE | ssh -c arcfour travos "zfs receive -F tank"
echo "THE end"
@fliiiix
fliiiix / backup_incremental.sh
Last active August 29, 2015 14:16
FreeBSD with ZFS backup incremental
#!/usr/local/bin/zsh
PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin
DATE=$(date "+%Y-%m-%d_%H-%M-%S")
SCRIPTNAME=$(basename $0)
PIDFILE=/var/run/${SCRIPTNAME}.pid
if [ -f ${PIDFILE} ]; then
@fliiiix
fliiiix / create_mail_user
Created July 19, 2015 10:46
create_mail_user on freebsd run with ./create_mail_user user
#!/bin/sh
USERNAME=$1
pw user add $USERNAME -m -s /sbin/nologin -c "mail user ($USERNAME)" # create user account
passwd $USERNAME # change password
mkdir /home/$USERNAME/mbox # create mail directory
chown -R $USERNAME:$USERNAME /home/$USERNAME/mbox # own the directory to the right user
@fliiiix
fliiiix / tumbler-Theme
Created February 16, 2013 15:47
Tumblr Theme unter WTFPL bei fragen und/oder wünschen blog@l33tsource.com
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<!---->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>{Title}{block:SearchPage} | {SearchQuery}{/block:SearchPage}{block:PostSummary} | {PostSummary}{/block:PostSummary}</title>
<link rel="shortcut icon" href="{Favicon}">
<link rel="alternate" type="application/rss+xml" href="{RSS}">
{block:Description}<meta name="description" content="{MetaDescription}" />{/block:Description}
@fliiiix
fliiiix / t_stacktrace
Created February 23, 2013 21:14
stacktrace and system information for an issue
l33t@nas:~$ rvm -v
rvm 1.18.10 (stable) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/]
l33t@nas:~$ ruby -v
ruby 1.9.3p392 (2013-02-22 revision 39386) [x86_64-linux]
l33t@nas:~$ gem -v
1.8.25
l33t@nas:~$ t -v
1.7.1
@fliiiix
fliiiix / auth.py
Created April 21, 2013 18:26
easy twitter cli using tweepy in python under Do What The Fuck You Want To Public License
#!/usr/bin/env python
import tweepy
#use your one keys ;)
CONSUMER_KEY = ''
CONSUMER_SECRET = ''
auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)
@fliiiix
fliiiix / random.c
Last active December 16, 2015 11:58
Do What The Fuck You Want To Public License
/*******************************************************************************
*
*
* Beschreibung: Diese Programm kann zufällige zahlen Generieren.
*
* Benötigte Libraries:
* - stdlib.h
* - stdio.h
* - time.h
*
@fliiiix
fliiiix / lottozahlen.c
Last active December 16, 2015 11:58
Do What The Fuck You Want To Public License
/*******************************************************************************
*
*
* Beschreibung: Diese Programm kann zufällige zahlen Generieren.
*
* Benötigte Libraries:
* - stdlib.h
* - stdio.h
* - time.h
*