Skip to content

Instantly share code, notes, and snippets.

View gandro's full-sized avatar

Sebastian Wicki gandro

View GitHub Profile
@gandro
gandro / rapidshare.sh
Created February 3, 2010 12:27
Rapidshare Free-User Download Shellscript
#!/bin/bash
# Version 4.1.0
#
# "THE COFFEE-WARE LICENSE" (Revision 12/2007):
#
# Sebastian Wicki <gandro@gmx.net> wrote this file. As long as you retain
# this notice you can do whatever you want with this stuff. If we meet some
# day, and you think this stuff is worth it, you can buy me a cup of coffee
# in return.
#
@gandro
gandro / Winhistory-Forum Regeln.txt
Last active July 13, 2020 18:40
Neue Regeln fürs MyBB-Update
[B]§ 1 Anwendung dieser Regeln[/B]
Diese Regeln gelten für alle Mitglieder des Forums, inklusive Gäste (Gästeboard) und der Verwaltung (Administratoren und Moderatoren).
[B]§ 2 Was ist verboten?[/B]
[list=1]
[*] Beleidigungen, Hetze, Mobbing und Diskriminierung jeglicher Art innerhalb wie ausserhalb des Forums.
[*] Menschenverachtende, rechtsradikale oder gesetzeswidrige Äußerungen innerhalb wie ausserhalb des Forums.
[*] Angebot oder Nachfrage von urheberrechtlich- oder lizenzgeschützten Inhalten.
#!/bin/bash
WIDTH=1280
HEIGHT=800
setterm -cursor off
mplayer -vo fbdev2 -quiet -zoom -screenw ${WIDTH} -screenh ${HEIGHT} -vf scale=${WIDTH}:-2 -sws 0 -fs ${@}
setterm -cursor on -clear
#!/bin/bash
# Version 10.8.12
URL="http://www.youtube.com/get_video"$(wget -q -O - "$1" | echo -e "$(sed 's/+/ /g; s/%/\\x/g')" | grep 'var swfHTML' | \
sed -re 's/.*fmt_url_map=([0-9]+)\|.*&t=([^&]+)&.*&video_id=([A-Za-z0-9_-]+).*/?video_id=\3\&t=\2\&asv=\&fmt=\1/')
echo "$URL"
// Version 10.8.12
var URL=unescape(
document.getElementById("movie_player").getAttributeNode("flashvars").value).
replace(/.*fmt_url_map=([0-9]+)\|.*&t=([^&]+).*&video_id=([A-Za-z0-9_-]+).*/,
"http://www.youtube.com/get_video?video_id=$3&t=$2&asv=&fmt=$1");
alert(URL);
#---------------------------------------------
# TINT2 CONFIG FILE
#---------------------------------------------
# For more information about tint2, see:
# http://code.google.com/p/tint2/wiki/Welcome
#
# For more config file examples, see:
# http://crunchbanglinux.org/forums/topic/3232/my-tint2-config/
#---------------------------------------------
# BACKGROUND AND BORDER
#!/bin/bash
function get_property() {
cat /sys/devices/platform/smapi/BAT0/$1
}
PREFIX="/usr/share/icons/gnome/24x24/status/"
while true ; do
PERCENT=$(get_property remaining_percent)
#!/bin/bash
set +o posix
BASEDIR="$(dirname "$(realpath "$0")")"
##############################################################################
# path to text file with line separted list of feed urls
FEED_FILE="${BASEDIR}/feeds.txt"
@gandro
gandro / lixbiblio.py
Created November 25, 2014 23:18
Script to generate wiki page based on ISBN
import json, sys
from urllib.request import urlopen
API='http://xisbn.worldcat.org/webservices/xid/isbn/{isbn}?method=getMetadata&format=json&fl=*'
OPT_KEYS = ['author', 'city', 'ed', 'form', 'lang', 'lccn',
'originalLang', 'publisher', 'year']
def get_metadata(isbn):
rawjson = urlopen(API.format(isbn=isbn)).readall().decode('utf-8')
response = json.loads(rawjson)
#ifndef __fat32_ebpb_DEV_H
#define __fat32_ebpb_DEV_H 1
/*
* DEVICE DEFINITION: FAT32 Extended BIOS Parameter Block (EBPB)
*
* Copyright (c) 2010, ETH Zurich.
* All rights reserved.
*
* This file is distributed under the terms in the attached LICENSE
* file. If you do not find this file, copies can be found by