diff options
author | Christian Neukirchen <chneukirchen@gmail.com> | 2015-03-25 14:26:08 +0100 |
---|---|---|
committer | Christian Neukirchen <chneukirchen@gmail.com> | 2015-03-25 14:26:08 +0100 |
commit | 3d339ac6d6bbabbe79b266149ea0e153757c9ec7 (patch) | |
tree | b7f9e923dcb075acf09981710959b5853ca7182e /xbump | |
parent | 6bc8e434bf988029c63c26c94e633278e96261b2 (diff) | |
download | xtools-3d339ac6d6bbabbe79b266149ea0e153757c9ec7.tar.gz xtools-3d339ac6d6bbabbe79b266149ea0e153757c9ec7.tar.xz xtools-3d339ac6d6bbabbe79b266149ea0e153757c9ec7.zip |
xbump: better detection of new packages.
Diffstat (limited to 'xbump')
-rwxr-xr-x | xbump | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/xbump b/xbump index 8276fb2..df96c31 100755 --- a/xbump +++ b/xbump @@ -12,12 +12,6 @@ if [ -z "$version" ]; then exit 1 fi -if [ -n "$(git ls-files srcpkgs/"$pkg"/template)" ]; then - msg="$pkg: update to $version." -else - msg="New package: $pkg-$version" -fi - spkpattern=$(xsubpkg "$pkg" | tr '\n' '|' | sed 's/\(.*\)|/^(\1)$/') shlibs=$(git diff common/shlibs | grep "^+[^+]" | \ sed "s/^+[^ ]\+ \(.*\)-[^-]\+_[0-9]\+$/\1/") @@ -32,4 +26,11 @@ dirs=$(./xbps-src show "$pkg" | sed -n '/^\(pkgname\|subpackage\)/s/[^:]*:[\t]*/srcpkgs\//p') git add $dirs + +if git diff --quiet --cached --diff-filter=A -- srcpkgs/"$pkg"/template; then + msg="$pkg: update to $version." +else + msg="New package: $pkg-$version" +fi + git commit -m "$msg" "$@" $dirs |