Skip to content

Instantly share code, notes, and snippets.

@iamralch
iamralch / sshtunnel.go
Last active August 21, 2024 05:15
SSH tunnelling in Golang
package main
import (
"log"
"bufio"
"time"
"os"
"fmt"
"io"
"net"
@jonseymour
jonseymour / gist:908ea09f7d1ab6dbb9fd
Last active October 24, 2016 17:23
Factory reset message codes
ERR301: The specified '$file' does not exist.
ERR302: The specified '$file' does not have the specified checksum ('$checksum'). Actual checksum: ('$filesum').
ERR310: Failed to download '${imageurl}' to '${imagetar}'.
ERR320: The clock has a date in the past: $(date "+%Y-%m-%d %H:%M:%S").
ERR330: The download of the recovery script from '$(url url .sh)' to '$shname' has failed.
ERR331: Partition table checksum mismatch. Expected '${PARTITION_TABLE_SHA1SUM}' found '$check'.
ERR341: The required recovery archive '$tar' does not exist.
ERR401: usage: generate-env {image-name} [ {url-prefix} ]
ERR405: usage: format-partitions {confrmation-code} {block-device} p{partition#}
ERR406: The specified partition device '${partition_device}' does not exist.
@jonseymour
jonseymour / gist:03598f052376095713a3
Last active October 24, 2016 17:24
diff between 03_0813 and images 04_0214
M ubuntu_armhf_trusty_norelease_sphere-unstable/etc/ninja-release
M ubuntu_armhf_trusty_norelease_sphere-unstable/etc/popularity-contest.conf
M ubuntu_armhf_trusty_norelease_sphere-unstable/etc/shadow
M ubuntu_armhf_trusty_norelease_sphere-unstable/etc/shadow-
M ubuntu_armhf_trusty_norelease_sphere-unstable/opt/ninjablocks/bin/sphere-setup-assistant
M ubuntu_armhf_trusty_norelease_sphere-unstable/opt/ninjablocks/drivers/sphere-go-led-controller/sphere-go-led-controller
A ubuntu_armhf_trusty_norelease_sphere-unstable/opt/ninjablocks/factory-reset/bin/recovery.sh
M ubuntu_armhf_trusty_norelease_sphere-unstable/opt/ninjablocks/factory-reset/bin/reset-helper.sh
M ubuntu_armhf_trusty_norelease_sphere-unstable/opt/ninjablocks/factory-reset/bin/sphere-io
A ubuntu_armhf_trusty_norelease_sphere-unstable/opt/ninjablocks/factory-reset/bin/sphere-serial
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active October 27, 2025 12:21
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname