Blueno_Termux/myTermux/.local/bin/awesomeshot-old
2022-04-01 08:36:29 -04:00

81 lines
848 B
Bash
Executable File

#!/usr/bin/env bash
LIBRARY_PATH="${HOME}/.scripts/library"
LIBRARYS=(
animation signal cursor colors stat
)
for LIBRARY in ${LIBRARYS[@]}; do
source ${LIBRARY_PATH}/${LIBRARY}.sh
done
HELPER_PATH="${HOME}/.scripts/screenshot"
HELPERS=(
backup border footer rounded shadow
utility autorun manualrun output
)
for HELPER in ${HELPERS[@]}; do
source ${HELPER_PATH}/${HELPER}.sh
done
function main() {
trap "handleInterruptByUser 'Interrupt By User'" 2
setCursor off
${1} ${2}
}
case "${1}" in
-a|--auto )
main autorun
;;
-i|--info )
about
;;
-m|--manual )
if [ ${2} ]; then
main manualrun ${2}
else
stat "ERROR" "Danger" "Require file name"
help
exit 1
fi
;;
-h|--help )
help
;;
-v|--version )
version
;;
* )
help
;;
esac