Added '-a <architecture>' flag to to bpm-package

This commit is contained in:
2024-05-30 15:55:47 +03:00
parent a3a97efd59
commit 3ea431b98d
2 changed files with 10 additions and 5 deletions
+4 -3
View File
@@ -5,9 +5,10 @@ then
exit 1
fi
while getopts "c" flag; do
while getopts "ca:" flag; do
case "$flag" in
c) CONVERT=true;;
a) ARCHITECTURE="${OPTARG}";;
*) exit 1;;
esac
done
@@ -75,6 +76,6 @@ echo "Creating $type package as $output"
tar -czf "$output" "${toCompress[@]}"
if "$CONVERT" && [[ "$type" == "source" ]]; then
bpm-convert "$output"
if [ ! -z "$CONVERT" ] && "$CONVERT" && [[ "$type" == "source" ]]; then
bpm-convert "$output" "$ARCHITECTURE"
fi