Skip to content

Instantly share code, notes, and snippets.

@parth-io
parth-io / sunfire-print.sh
Created July 17, 2021 15:31 — forked from AaronCQL/sunfire-print.sh
Cheatsheet for printing via Sunfire
# Login to Sunfire
ssh e0123456@sunfire.comp.nus.edu.sg
# Copy a local file to Sunfire
scp some_file.txt e0123456@sunfire.comp.nus.edu.sg:/home/e/e0123456/
# Copy a local directory to Sunfire
scp -r ./some_directory e0123456@sunfire.comp.nus.edu.sg:/home/e/e0123456/
# Convert PDF to PS file
@parth-io
parth-io / example.sh
Created September 22, 2020 12:25 — forked from shakefu/example.sh
Bash Script with Short and Long Options
# Option defaults
OPT="value"
# getopts string
# This string needs to be updated with the single character options (e.g. -f)
opts="fvo:"
# Gets the command name without path
cmd(){ echo `basename $0`; }