mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-27 20:14:27 +01:00
common: factor out common opts to all scripts
This commit is contained in:
8
runtc
8
runtc
@@ -1,14 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
. "$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/common"
|
||||
while getopts a:gh OPT; do
|
||||
while getopts "h${common_getopts_flags}" OPT; do
|
||||
case "$OPT" in
|
||||
a)
|
||||
common_arch="$OPTARG"
|
||||
;;
|
||||
h)
|
||||
echo "https://github.com/cirosantilli/linux-kernel-module-cheat#runtc" 2>&1
|
||||
exit
|
||||
;;
|
||||
?)
|
||||
common_getopts_case "$OPT"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
shift "$(($OPTIND - 1))"
|
||||
|
||||
Reference in New Issue
Block a user