Skip to content

Instantly share code, notes, and snippets.

Raphi raphiz

Block or report user

Report or block raphiz

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@raphiz
raphiz / synchronize_ftp.sh
Created Nov 12, 2014
Synchronize FTP server with a local directory (Linux)
View synchronize_ftp.sh
#!/usr/bin/env bash
# Requires: curlftpfs, unison and fuse.
# Configuration:
MOUNTPOINT=/mnt/my_ftp_share/
LOCAL="/home/user/directory"
FTP_HOST="example.com"
FTP_USER="user"
FTP_PASS="secrit"
@raphiz
raphiz / android-backup-extractor.sh
Created Dec 28, 2014
Converts the contents of a .ab android backup file into a .tar archive
View android-backup-extractor.sh
#!/usr/bin/env bash
#
# Converts the contents of a .ab android backup file into a .tar archive
#
# Usage: android-backup-extractor.sh SOURCE <DESTINATION>
#
# Requirements: dd, openssl
# License: MIT
# Autor: Raphael Zimmermann (http://raphael.li)
#
@raphiz
raphiz / deploy.sh
Created Dec 28, 2014
Easily deploy Composer Apps to a remote FTP server using curlftpfs, rsync and git
View deploy.sh
#!/usr/bin/env bash
# Requires: fuse, curlftpfs, rsync, git and composer
set -u
REPOSITORY="https://github.com/raphiz/php-raphael.li.git"
FTP_HOST="myhost.com"
FTP_USER="user"
FTP_PASS="secrit"
FTP_SUBFOLDER="httpdocs"
@raphiz
raphiz / deploy.sh
Last active Aug 29, 2015
FTP Deplozment Script
View deploy.sh
#!/usr/bin/env bash
# Abort if a command fails!
set -e
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
if [ ! -n "$HOST" ];then
echo "missing option \"HOST\", aborting"
exit 1
@raphiz
raphiz / euklid.py
Created Jan 24, 2016
A quick & dirty implementation of the Euclidean algorithm in python
View euklid.py
#!/usr/bin/env python
# coding=utf-8
from tabulate import tabulate
a = 180
b = 101
def euklid(x_p, y_p, q_p=None, r_p=None, u_p=None, s_p=None, v_p=None, t_p=None, result=None):
@raphiz
raphiz / README.md
Last active Jan 26, 2016
Moodle HSR Autologin Raw
View README.md

Autologin for https://moodle.hsr.ch/ with the power of userscripts.

Please note that you should from a security point of view store the username and password using the browsers built-in password manager! To do so, store the before installing these scripts and remove the highlighted two lines from moodle_autologin_2.js. Otherwise, replace the and values with your credentials.

@raphiz
raphiz / sync.sh
Last active Apr 5, 2016
HSR Skripteserver Sync-Skript
View sync.sh
#!/bin/bash
set -e
###################
## Konfiguration ##
###################
## Ersetze <your username> um nicht jedes mal nach deimem HSR Benutzername gefragt zu werden
# HSR_USERNAME="<your username>"
View gist:1a7921b66acecdcc3d2eb7f320d25cc2
### Keybase proof
I hereby claim:
* I am raphiz on github.
* I am raphiz (https://keybase.io/raphiz) on keybase.
* I have a public key whose fingerprint is E9C7 3898 CF7C 96D8 D321 37DF 522C C665 31B5 A199
To claim this, I am signing this object:
@raphiz
raphiz / us_umlauts
Created Jun 13, 2016
My custom xkb keyboard layout (/usr/share/X11/xkb/symbols/us_umlauts/us_umlauts)
View us_umlauts
default partial alphanumeric_keys modifier_keys
xkb_symbols "basic" {
name[Group1]= "English (German Umlauts)";
key <TLDE> { [ grave, asciitilde ] };
key <AE01> { [ 1, exclam ] };
key <AE02> { [ 2, at ] };
key <AE03> { [ 3, numbersign ] };
key <AE04> { [ 4, dollar ] };
View 00-keyboard.conf
Section "InputClass"
Identifier "system-keyboard"
MatchIsKeyboard "on"
Option "XkbLayout" "us_umlauts"
Option "XkbModel" "pc105"
Option "XkbVariant" ""
Option "XkbOptions" "terminate:ctrl_alt_bksp,grp:alt_shift_toggle"
EndSection
You can’t perform that action at this time.