17 lines
383 B
Bash
Executable File
17 lines
383 B
Bash
Executable File
#!/usr/bin/env zsh
|
|
|
|
local maim_args=("-f" "png")
|
|
local outfile="screenshot--$(date +'%F_%k-%M-%S').png"
|
|
local outpath="${HOME}/downloads/${outfile}"
|
|
|
|
case "${1}" in;
|
|
'-root')
|
|
maim ${maim_args} "${outpath}"
|
|
;;
|
|
'-select' | *)
|
|
maim ${maim_args} -s "${outpath}"
|
|
;;
|
|
esac
|
|
|
|
notify-send -t 5000 "Screenshot Taken" "Screenshot saved to \"${outfile}\""
|