fix: add package script to check for empty string

This commit is contained in:
2025-03-05 19:41:47 +00:00
parent 8c40103753
commit 419687c4c8

View File

@ -1,6 +1,11 @@
#!/usr/bin/env bash
cd ~/Code/dotfiles
if [ -z $@ ]; then
echo "You must provide a package name."
exit 1
fi
echo "metapac add --backend arch --package $@"
metapac add --backend arch --package $@
@ -8,6 +13,8 @@ rsync -av ~/.config/metapac .config --delete
metapac sync
echo "Adding package to git..."
git add .config/metapac
git commit -m "add-package: $@"
git push