Add -v switch

And move VERSION to share/portzap/VERSION
This commit is contained in:
0x1eef 2024-04-18 20:19:54 -03:00
parent 6c594ee36e
commit 3c8697f186
2 changed files with 10 additions and 0 deletions

View file

@ -40,6 +40,16 @@ require_dependency() {
##
# main
i=1
while [ "${i}" -le "$#" ]; do
eval "_portzap_option=\$${i}"
if [ "${_portzap_option}" = "-v" ]; then
echo $(cat "${rootdir}"/../share/portzap/VERSION)
exit 0
fi
i=$(expr "${i}" + 1);
done
case $1 in
"clone")
require_dependency "git doas"