Splint.rs
open-menu closeme
Home
Posts
Docs
Projects
About
codeberg gitlab mastodon rss
  • Bash tips

    1 min read · shell comfy bash

    This & That Refer to 'that last thing', and 'the first thing': 1fortune -l > file1 2cat !$ | tr -d u > file2 3cat file1 !$ 4diff !^ !$ NB: this can go wrong: 1ls -l file1 file2 2cat !^ NB: this only works when running bash interactively, never in scripts. Lists You can put a list inside any bash argument, and bash will …


    Read More
  • Easy Number Checks

    1 min read · shell comfy

    Number checks are too long. 1if [ "$x" -gt "$y" ]; then 2 echo "$x" 3else 4 echo "$y" 5fi Write a shorter number check like this: echo $(( x > y ? x : y )) Longer checks are possible: 1col(){ 2 n=$(( $1 % 2 == 0 ? $1 /2 : $1 * 3 + 1 )) 3 echo $n 4 [ $n -eq 1 ] || col $n 5} 6 7col 4 8col 5 9col 9 10col 27


    Read More
  • Edit gpg encrypted files with vim

    1 min read · vim data gpg comfy

    Requirements GPG Basics vim basics The vim-gnupg plug-in lets vim edit gpg-encrypted files as if they were unencrypted. It's probably in your package manager. If not, you'll need to endure the faff of following the instructions.


    Read More
  • Rundown: curl

    1 min read · writing comfy dict curl writing web html2markdown curl

    Request a definition from the terminal. 1word='abderian' 2curl -s dict://dict.org/define:${word}: Convert a web page to markdown 1curl -sL "${url}" | html2markdown > "${file}}".md The html2markdown and html2md programs works better than any other.


    Read More
  • Rundown: find

    1 min read · maintenance find comfy fzf find

    Find broken links find -L ${path} -type l Quickly find and open run-command files 1alias rrc='$PAGER "$(find . -maxdepth 2 -name "*rc" | fzf)"'


    Read More
  • Rundown: fzf

    1 min read · disk system boot blkid fzf comfy fzf find

    Find disk UUID 1blkid Quickly find and open run-command files 1alias rrc='$PAGER "$(find . -maxdepth 2 -name "*rc" | fzf)"' Quickly hunt and kill processes 1kill $(pgrep less | fzf -m --preview='ps {}') Select many with shift/tab.


    Read More
  • Rundown: git

    1 min read · size git email pr comfy maintenance data git

    Automatically select commits from the current branch during a merge git checkout "${master}" git merge "${branch}" git checkout --ours "${master}" These flags can be counterintuitive in other contexts. https://nitaym.github.io/ourstheirs/ Read the minimal size of a git repo 1git count-objects -vH | grep -Po 'size-pack: …


    Read More
  • Rundown: grep

    1 min read · writing comfy search grep

    Find repeating words in a text file 1grep -r --color=always -E '(\b\S+\b)\s+\b\1\b'"$1" Search for a short word 1grep "\b${word}\b" ${file} Extract words in quotes 1grep -o "\b${word}\b" ${file}


    Read More
  • Rundown: jobs

    1 min read · shell comfy jobs

    Run commands in background 1ls -Rilt ~ & 2jobs 3find ~/.cache/ -type d -exec du '{}' -h ';' | sort -h & 4jobs Stop background command having output 1disown The command will continue as it was. You can see it with top.


    Read More
  • Rundown: ncdu

    1 min read · maintenance disk TUI comfy ncdu

    Check what's using disk space 1ncdu Brighten up the interface in the config. Check a remote computer's disk space in the 'images' directory 1dir=images 2ssh ${host} ncdu -co- ${dir} | ncdu -f- Install ncdu on both computers.


    Read More
    • ««
    • «
    • 1
    • 2
    • »
    • »»

Featured Posts

  • Belgrade Protests

Recent Posts

  • The Point
  • The Untranslatable Sign
  • Put Your Project's Dependencies in Make
  • Remote Hardware
  • TOS as a Service
  • Review: Harvey
  • Nobody Passed the Turing Test
  • Review: Ghost Dog

Tags

PRATTLE 76 DATA 44 SYSTEM 38 FOSS 36 LINUX 25 NETWORKING 25 TUI 22 VIM 21
All Tags
2FA1 ANDROID1 ANSIBLE3 ARCH7 ARCHIVEMOUNT1 ARCHIVES1 AUTOLOGIN1 AWK1 BACKUP3 BACKUPS2 BAR2 BASH3 BASIC1 BASICS17 BLKID2 BLUETOOTH1 BOOT3 BROWSER1 BUGS1 BUILD1 CALENDAR1 CHAT3 CLI1 COLUMN1 COMFY13 COMPLETION1 COMPRESSION1 CONTAINERS1 CPU1 CREDENTIALS2 CSV7 CURL2 DATA44 DATABASE4 DEATH1 DEBIAN1 DEDUPLICATE1 DEFAULTS2 DICT1 DIG1 DISK5 DISTROS6 DNS1 DOCKER1 DOCUMENTATION14 ECONOMICS2 ED2 EDIT1 EMAIL2 ENCODING1 EPISTEMOLOGY2 ETHICS1 EXIFDATA1 FC-LIST1 FFMPEG1 FILE BROWSER1 FIND3 FLOWCHART1 FONT1 FORMAT2 FOSS36 FUN6 FZF3 GAMES4 GEMINI2 GHOST SCRIPT1 GIT11 GIT SERVER4 GPG2 GPU1 GRAPH2 GRAPHVIZ1 GREP1 GROFF3 GROUPS2 GS1 GUI1 GUIDE1 GUNZIP1 HARDWARE3 HELP1 HEX1 HOST1 HOSTS1 HTML4 HTML2MARKDOWN2 IFTOP1 IJQ1 INDEX1 INFO1 INPUTRC1 IP1 JLESS1 JOBS1 JOURNALCTL1 JQ2 JSON3 KEYBOARD3 KUBERNETES4 LANGUAGE16 LAPTOP2 LEARNING11 LFS2 LIES1 LINEWRAP1 LINKS3 LINUX25 LOCALE3 LOCATE1 LOGIC1 LOGS3 LOLCAT2 LOWDOWN3 MAGICK1 MAINTANCE1 MAINTENANCE8 MAKE4 MAKEFILES2 MAN3 MARKDOWN12 MEMES1 MEMETICS1 MEMOIRS6 MEMORY1 METADATA2 MIME TYPE1 MINIKUBE1 MLR1 MUSIC1 NAT1 NAVIGATION1 NCDU1 NETWORK5 NETWORKING25 NTPD1 NUMFMT1 OCR1 OMEMO2 ORCHESTRATION1 OTP1 PAGER2 PDF4 PDFTK1 PHILOSOPHY20 PHONE1 PIPEWIRE1 PLOCATE1 POLITICS19 PR1 PRATTLE76 PRINTF1 PROGNOSTICATION4 PYTHON2 PYTHON31 QR1 QRENCODE1 RAID1 READLINE1 RECFILES8 REPLACE4 RESET1 REVIEW14 RPI1 RSS2 SC-IM1 SCRAPING3 SCRIPT1 SEARCH3 SECRETS4 SECURITY7 SED2 SERVICE1 SERVICES1 SETUP9 SHARE3 SHELL9 SIZE2 SMTP1 SNAP1 SOUND4 SPREADSHEET1 SSH4 STDOUT1 STORAGE1 SUBSTITUTE1 SUBSTITUTION2 SUDO2 SWAY3 SYNCH2 SYSTEM38 SYSTEMD2 TAR1 TECHNOLOGY6 TEX2 TEXT1 TIME5 TIP4 TMPFS1 TORRENT3 TRANSMISSION1 TREE1 TRICKS1 TUI22 TYPOGRAPHY2 UBUNTU1 UNICODE1 USERS2 UTILITARIANISM1 VIDEO3 VIM21 VIPW2 VIRTUALENV1 VIRTUALIZATION7 VISION5 VOID12 VOLUME1 VPN1 WAYLAND1 WEB7 WIFI1 WIKIS4 WINDOWS1 WRITING15 WTFM1 XARGS1 XE1 XEN1 ZIP1
[A~Z][0~9]
to-top