confi-emacs-actual/snippets/sh-mode/getopts

13 lines
277 B
Plaintext
Raw Normal View History

2022-03-30 01:21:13 +02:00
# -*- mode: snippet; require-final-newline: nil -*-
# name: getopts
# key: getopts
# uuid: getopts
# --
while getopts "${1:s:h:}" o; do
case "$o" in
${2:X}) `(doom-snippets-format "%n%s")`$0
;;
*) usage
;;
esac
done