Skip to content

Instantly share code, notes, and snippets.

@cmpute
Last active February 1, 2021 22:54
Show Gist options
  • Save cmpute/27eaacaad739993b4edd44b54f7b7184 to your computer and use it in GitHub Desktop.
Save cmpute/27eaacaad739993b4edd44b54f7b7184 to your computer and use it in GitHub Desktop.
My linux command cheatsheet
# git: remove all remote branches except for master/main
git branch -r | grep -Eo 'cmpute/.*' | cut -c 8- - | xargs -n 10 git push cmpute --delete
# tar: unzip multiple tarballs in a row
find <INPUT_DIR> -name "*.tgz" | xargs tar -xz -C <OUTPUT_DIR> --checkpoint=10000 -f
# wavpack: compress DSD files
wavpack <INPUT_FILES> <OUTPUT_FILES> -h -m -v –-import-id3
# slurm: Run a slurm interactive session with gpu on Greatlakes
srun --partition=gpu --account=hpeng1 --gpus=1 --mem-per-cpu=1000m --cpus-per-task=16 --pty /bin/bash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment