Skip to content

Instantly share code, notes, and snippets.

@timsonner
timsonner / vim-python-themes.md
Last active March 9, 2026 08:41
Vim Python syntax highlighting themes

Vim Python syntax highlighting themes

Source theme files

set t_Co=256
source /path/to/<theme-file>.vim

IDLE

@timsonner
timsonner / pdb.md
Last active March 9, 2026 01:46
PDB - Python Debugger Reference

PDB - Python Debugger Reference

Import statement

import pdb; pdb.set_trace()
Command Action Brief Explanation
l (list) Show Code Shows 11 lines of code around your current position.
@timsonner
timsonner / vim.md
Last active March 9, 2026 05:28
Vim Reference

Vim Reference

Category Command Action
Movement gg / G Top / Bottom of file
Movement 0 / $ Start / End of line
Movement ^ First non-space character of line
Movement f / F + <char> Find character forward / backward
Movement t / T + <char> Till character forward / backward
Movement ; Repeat last f or t jump
@timsonner
timsonner / tmux.md
Created March 8, 2026 17:25
Tmux cheatsheet

Tmux Cheatsheet

Category Shortcut / Command Action
Sessions tmux new -s <name> Start a new named session
Sessions tmux ls List all active sessions
Sessions tmux rename-session -t <name> <new name> Rename a session
Sessions tmux attach-session -t <name> Connect/Re-attach to a session
Sessions Ctrl + b, then d Detach (Keep everything running in background)
Windows Ctrl + b, then c Create a new full-screen window
@timsonner
timsonner / arch-setup.md
Last active March 8, 2026 02:29
Arch setup notes

Arch setup

Set timezone

timedatectl set-timezone America/<City>

list disks

lsblk
@timsonner
timsonner / find-fastest-mirror.sh
Created March 7, 2026 20:21
Find fastest download server / mirror.
#!/usr/bin/env bash
# Find the fastest mirror from a list of servers
# Tests HTTP(S) response time using curl's time_connect + time_starttransfer
TIMEOUT=5
PARALLEL=8 # max concurrent jobs
SERVERS=(
adectra.com
akane.network
@timsonner
timsonner / network+.md
Created March 5, 2026 16:36
Study sheet for Network+

Network+ Study Sheet


Network+ Cable Standards

A consolidated reference for copper, fiber, and coax cable types, including speeds, distances, and optical standards (SX, LX, EX, ZX, SR, LR, ER, ZR).

Twisted‑Pair Copper (Ethernet)

@timsonner
timsonner / gnome-debloat.md
Last active February 23, 2026 02:21
Gnome debloat script / after fresh install

Remove bloat from Gnome/Debian Trixie

sudo apt purge --autoremove -y \
  gnome-software gnome-software-plugin-deb gnome-software-plugin-fwupd \
  "libreoffice*" "mythes-*" "hyphen-*" "hunspell-*" \
  "fcitx*" "mozc*" "anthy*" ibus-anthy "hdate*" \
  "dict-*" "goldendict*" \
  "mlterm*" xiterm+thai \
  thunderbird yelp \
  gnome-calendar gnome-weather gnome-contacts gnome-maps gnome-dictionary \
@timsonner
timsonner / exploit.py
Last active January 2, 2026 05:00
CVE-2024-25600 (Bricks Builder RCE)
# CVE-2024-25600 (Bricks Builder RCE)
import requests
import sys
import urllib3
import re
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
def fetch_nonce(target_url):
@timsonner
timsonner / misc-bash.md
Last active March 7, 2026 20:49
Miscellaneous bash commands

Copy 1st line from file, insert into first line of another file

awk 'NR==1' test.py | xargs -I{} sed -i '1s/.*/{}/' slice.py

Setup Python debugger pdb in file

echo "import pdb; pdb.set_trace()" > test.py