===== misc bash terminal stuff ===== aliases and stuff ==== number files from start ==== i=29 # add 1 to last number in batch for f in *.png; do dest=$(printf "%02d" $i).png mv "$f" "$dest" i=$((i + 1)) done [[https://stackoverflow.com/questions/57860821/rename-files-with-incrementing-number-starting-at-certain-number|source]] ==== push to all git remotes ==== i'm lazy ok alias gitall="git remote | xargs -L1 git push --all" ==== youtube to MP3 === what the comment says # lazy ass way for me to get my idol mp3s from youtube # usage: ytmp3 url alias ytmp3="yt-dlp -f ba -x --audio-format mp3" ==== move nested files to top-level dir ==== (this will overwrite files with same names so rename with filebot beforehand if needed) i use this for counting icons usually, hence the alias name alias iconsubfol="find . -mindepth 2 -type f -print -exec mv {} . \;" ==== PDF to PNG ==== not used in a while gs -sDEVICE=pngalpha -o file-%03d.png -r144 zine.pdf