about to test the package fetching..

This commit is contained in:
brent s 2016-06-24 20:32:39 -04:00
parent b225b1a609
commit e8f5d6d0d9
2 changed files with 31 additions and 11 deletions

0
_bin/sign.pkg.sh Normal file → Executable file
View File

30
_bin/submodule.update.sh Normal file → Executable file
View File

@ -34,19 +34,39 @@ function freshenrepo () {
REPO="${1}" REPO="${1}"


# Check to see if it exists. https://stackoverflow.com/questions/12641469/list-submodules-in-a-git-repository # Check to see if it exists. https://stackoverflow.com/questions/12641469/list-submodules-in-a-git-repository
git config --file .gitmodules --get-regexp path | awk '{ print $2 }' | egrep -Eq "^${REPO}" # We COULD use 'if git submodule status "${REPO}"' but we don't because regexes are cooler. so there. deal with it. /me puts on cool guy sunglasses.
git config --file .gitmodules --get-regexp path | awk '{ print $2 }' | egrep -Eq "^${REPO}$"
if [[ "${?}" -eq '0' ]]; if [[ "${?}" -eq '0' ]];
then then
# We remove it so we can grab a fresh copy directly from the AUR. # We remove it so we can grab a fresh copy directly from the AUR.
#https://stackoverflow.com/questions/1260748/how-do-i-remove-a-submodule #https://stackoverflow.com/questions/1260748/how-do-i-remove-a-submodule and others
git rm --cached ${REPO} git submodule deinit -f "${REPO}"
git submodule deinit ${REPO} git rm -f "${REPO}"
git config -f .gitmodules --remove-section "submodule.${REPO}" > /dev/null 2>&1 # probably not necessary,...
rm -rf .git/modules/${REPO}
fi
touch .gitmodules
git add .gitmodules
git submodule add ${URI}:${REPO}
cat >> .git/modules/${REPO}/hooks/pre-commit << EOF
#!/bin/bash
/usr/bin/mksrcinfo


git add .SRCINFO
EOF
chmod 700 .git/modules/${REPO}/hooks/pre-commit


} }


if if [[ "${PKGNAME}" =~ [Aa][Ll]{2} ]];
then
for i in $(ssh aur@aur.archlinux.org list-repos | sed -e 's/[[:space:]]*//g' | sort); for i in $(ssh aur@aur.archlinux.org list-repos | sed -e 's/[[:space:]]*//g' | sort);
do do
freshenrepo ${i} freshenrepo ${i}
done done
elif [ -n "${PKGNAME}" ];
then
freshenrepo ${PKGNAME}
fi

git submodule update