Skip to content

Instantly share code, notes, and snippets.

View henri's full-sized avatar
💭
hacking the mainframe

henri henri

💭
hacking the mainframe
View GitHub Profile
@henri
henri / resolve_install_linux_mint_cheatsheet.txt
Last active June 27, 2025 22:22
Installing Resolve GNU/LINUX Mint
# URL with details for Linux Mint install instructions :
# https://forum.blackmagicdesign.com/viewtopic.php?f=38&t=200276
# Big thanks to : Christoph Schmid!
# Running the installer
# Install the dependiencies as suggested by installer. If you still have message regarding some items missing
# simply setup the skip :
export SKIP_PACKAGE_CHECK=1
# Once you have run the installer.
@henri
henri / yt-comments.bash
Created June 11, 2025 00:24
Youtube Comment Download Wrapper
#!/usr/bin/env bash
# (C) 2025 Henri Shustak
# simple script to download youtube comments from a single video in bulk
# usage : ./yt-comments.bash "youtube.video.url"
# requires : python package called youtube-comment-downlaoder
# dependcy install : pip install youtube-comment-downloader
# currently set to ues sublime text to view the file when download completes..(last line)
tempfile=$(mktemp /tmp/yt-comments.XXXXXX)
suffix="json"
# get link speeds of a 5 port device
interface ethernet monitor numbers=0,1,2,3,4
@henri
henri / 010.restic_cheatsheet.fish
Last active May 27, 2025 22:50
restic cheatsheet (specific to fish shell)
# update to latest version of restic
sudo restic self-update
# initilise restic backup repository + generate an initial key
restic init -r <repository-directory>
# configure enviroemnt varables (fish) / alter as needed
set -x RESTIC_REPOSITORY /path/to/repository
set -x RESTIC_PASSWORD_FILE /path/to/.restic_password
set -x RESTIC_PASSWORD my_AmZiNiNg_password
@henri
henri / handy_cli_tools.txt
Last active June 25, 2025 04:21
handy software tools : for which sometimes forget the names
# check disk usage : output is graphical and feed out to stout.
ncdu
# check a disk is saving things as it should - check flash disks, hdd's, memory sticks, raids and more :)
f3write /path/to/mount && f3read /path/to/mount
# network / wifi
nmcli # eg : nmcli device wifi connect "<ssid>" --ask
# check file type
#!/usr/bin/env python3
#
# Released Under GNU GPLv3
# Copyright 2025 Henri Shustak
#
# About :
# This script will print messages as they arrive from a meshtastic node connected via serial port USB.
# If you have multiple nodes attached, you will need to edit this script and specify the node to monitor.
#
# Requirements :
@henri
henri / curl_cheatsheet.txt
Last active May 12, 2025 00:08
curl cheatsheet
# check the total real page load time for a specific page load :
TIMEFORMAT='%E' ; time curl https://myserver.com 2> /dev/null >/dev/null
# get my current ip address :
curl wtfismyip.com/text
@henri
henri / ssh-multi.sh
Last active January 27, 2025 01:19 — forked from dmytro/ssh-multi.sh
Start multiple synchronized SSH connections with Tmux
#!/bin/bash
# ssh-multi
# Modified to check if the script is started within a TMUX session to avoid starting in a background TMUX session
# H.SHUSTAK
# Origional :
# D.Kovalov : https://gist.github.com/dmytro/3984680
# Based on http://linuxpixies.blogspot.jp/2011/06/tmux-copy-mode-and-how-to-control.html
@henri
henri / linux_swap_cheatsheet.txt
Last active January 23, 2025 23:09
linux swap cheatsheet
# NOTES
#
# - this approach has been tested on mint (will work on many other distributions as well - YMMV)
# - this approach uses swap files not partitions
#
# create a 5GB swap disk to use - run as root!
swapon --show
mkdir /swapfiles ; chmod 700 /swapfiles
@henri
henri / ping-stdin.bash
Last active October 23, 2024 20:21
ping from stdin
#!/usr/bin/env bash
#
# This super basic script boiler plate
# will ping each host passed into the
# via stdin. Pipe your hosts into this
# script to check if they are up.
#
# Modify as needed for your purposes
#
# (C)2024 Henri Shustak - Released Under the GNU GPL 3.0 or later.