Compare commits

...

2 Commits

Author SHA1 Message Date
f4149ccf2b read USER env var instead of static name 2020-10-24 21:48:18 -07:00
94c4647378 clone void-packages 2020-10-24 21:43:13 -07:00

23
repo.sh
View File

@@ -14,7 +14,22 @@ help_file(){
""" """
} }
get_void_pkgs(){
echo -n "Location to place void-packages?: "
read vpkgs_location
if [ -z "${vpkgs_location}" ];then
vpkgs_location="${HOME}/vur"
echo "Creating directory: ${vpkgs_location}"
mkdir -p "${vpkgs_location}"
git clone https://github.com/void-linux/void-packages.git "${vpkgs_location}"
elif [ -n "${vpkgs_location}" ];then
echo "Creating directory: ${vpkgs_location}"
git clone https://github.com/void-linux/void-packages.git "${vpkgs_location}"
fi
}
gen_conf(){ gen_conf(){
@@ -91,10 +106,10 @@ sign_pkgs(){
gen_key gen_key
echo "Signing xbps files in ${REPO_PATH}" echo "Signing xbps files in ${REPO_PATH}"
xbps-rindex --sign --signedby "mollusk" --privkey "${KEY_PATH}" "$REPO_PATH" xbps-rindex --sign --signedby "${USER}" --privkey "${KEY_PATH}" "$REPO_PATH"
else else
echo "Signing xbps files in ${REPO_PATH}" echo "Signing xbps files in ${REPO_PATH}"
xbps-rindex --sign --signedby "mollusk" --privkey "${KEY_PATH}" "$REPO_PATH" xbps-rindex --sign --signedby "${USER}" --privkey "${KEY_PATH}" "$REPO_PATH"
fi fi
} }
@@ -128,6 +143,10 @@ case "${1}" in
sign_pkgs sign_pkgs
;; ;;
-vp | --void-packages)
get_void_pkgs
;;
*) *)
help_file help_file
;; ;;