Skip to content

Instantly share code, notes, and snippets.

View girst's full-sized avatar

girst

View GitHub Profile
@girst
girst / load-balance.sh
Last active March 8, 2024 13:26
Simple Linux Load Balancing with `iproute2`
#!/bin/bash
# Load balance multiple internet connections. Requires iproute2, awk and grep.
# (C) 2016 Tobias Girstmair, isticktoit.net, GPLv2
# Also useful: speedometer -l -r eth1 -t eth1 -m $(( 1024 * 1024 * 3 / 2 ))
# Not much user error checking is done - only pass working network connections
# script needs root to work and at least two interfaces to be useful
[ $EUID -eq 0 -a $# -ge 2 ] || {
echo "Usage (as root): $0 iface1[:weight1] iface2[:weight2] ..." >&2
#!/bin/bash
# run this script form the vt220 to set up terminal width, keyboard shortcuts and other stuff.
stty rows 24 cols 132
export TERM=vt220
export LANG=en_GB.iso88591
# vim: `:set termencoding=iso88591`
echo -en "\eP1;1|17/5B\e\\" # Shift+F6 = [
@girst
girst / pizero.php
Created March 2, 2016 13:50
Pi Zero Availability Checker (Webserver Version)
<html>
<head>
<meta http-equiv="refresh" content="60">
</head>
<body>
<pre><?php
$ctx = stream_context_create(array('http'=>
array(
'timeout' => 10, //10 Seconds
)
@girst
girst / asciiplayer
Last active February 10, 2022 07:37
PornHub ASCII Player
#!/bin/bash
#PornHub ASCII player 1.0
#Copyright Tobias Girstmair
#Licenced under GPLv3 (GNU Public Licence)
#iSticktoit.net
#Do not remove this notice
progName="PornHub / YouPorn ASCII Player v1.0"
playMode=0 # 0=vlc, 1=vlc new window, 2=mplayer, 3=mplayer new window
logFile=/dev/null
// ==UserScript==
// @name Epaper Downloader
// @author Tobias Girstmair
// @namespace net.isticktoit.epaperdl-v1.1
// @description Prepare the download of the currently opended issue
// @include https://epaper.derstandard.at/issue.act?issueId=*
// @version 1.2
// @grant none
// ==/UserScript==
@girst
girst / README.md
Last active April 5, 2019 19:46
`jj` - i3 tool for various tasks

i3tool by github.com/girst

Blog: iStickToIt.net

This is a simple program that lets you start programs / perform common tasks with very little key strokes.

Released under the GNU GPLv2. You can download a copy of the license from GNU.org

Setup