diff options
Diffstat (limited to 'gen-perl-pkg')
-rwxr-xr-x | gen-perl-pkg | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/gen-perl-pkg b/gen-perl-pkg index 46e5d18..d5a02a8 100755 --- a/gen-perl-pkg +++ b/gen-perl-pkg @@ -2,30 +2,29 @@ set -e for pkg in "$@"; do - export MAINTAINER="Florian Pritz <bluewind@xinu.at>" - targets=(~/arch/{community,extra}) - target_new=~/arch/community + export MAINTAINER="Florian Pritz <bluewind@archlinux.org>" + targets=(~/arch/pkgs) + target_new=~/arch/pkgs found_pkg=0 genpkg "$pkg" for target in "${targets[@]}"; do - if [[ -f "$target/$pkg/trunk/PKGBUILD" ]]; then + if [[ -f "$target/$pkg/PKGBUILD" ]]; then found_pkg=1 - vimdiff "$target/$pkg/trunk/PKGBUILD" "$HOME/pkg/dest/$pkg/PKGBUILD" + vimdiff "$target/$pkg/PKGBUILD" "$HOME/pkg/dest/$pkg/PKGBUILD" fi done if ((!found_pkg)); then - if [[ $PWD =~ ($HOME/arch/(community|extra)).* ]]; then + if [[ $PWD =~ ($HOME/arch/pkgs).* ]]; then target_new="${BASH_REMATCH[1]}" echo "Found target directory $target_new" fi - echo "Package not found, creating new in '$target_new/$pkg/trunk'" - mkdir -p "$target_new/$pkg/"{trunk,repos} - cp "$HOME/pkg/dest/$pkg/PKGBUILD" "$target_new/$pkg/trunk/" + echo "Package not found, creating new in '$target_new/$pkg/'" + cp "$HOME/pkg/dest/$pkg/PKGBUILD" "$target_new/$pkg/" cd "$target_new" - svn add "$pkg" + git add "$pkg" fi done |