Page MenuHomeSoftware Heritage

cherry-py-repo-from-template
No OneTemporary

cherry-py-repo-from-template

#!/usr/bin/env bash
TEMPLATE_DIR="swh-py-template"
usage () {
echo "Usage: cherry-py-repo-from-template GIT_REVISION [REPO_NAME]"
echo
echo "Apply the GIT_REVISION change of the swh-py-template repository to either"
echo "REPO_NAME, or all Python repositories"
exit 1
}
if [ -z "$1" ] ; then
usage
fi
gitrev="$1"
shift 1
apply_to_repo () {
repo="$1"
echo "* Applying to repo $1..."
(cd "$TEMPLATE_DIR" && git show "$gitrev") | (cd "$repo" ; git apply)
}
if [ -n "$1" ] ; then
repo="$1"
apply_to_repo "$repo"
else
for repo in `bin/ls-py-modules` ; do
apply_to_repo "$repo"
done
echo "All done."
fi

File Metadata

Mime Type
text/x-shellscript
Expires
Fri, Jul 4, 2:17 PM (2 d, 6 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3287444

Event Timeline