]> git.pld-linux.org Git - packages/vim.git/commitdiff
sort patches by number, print to stderr auto/th/vim-7.3.1005-1
authorElan Ruusamäe <glen@delfi.ee>
Thu, 23 May 2013 18:20:17 +0000 (21:20 +0300)
committerElan Ruusamäe <glen@delfi.ee>
Thu, 23 May 2013 18:20:17 +0000 (21:20 +0300)
update-source.sh

index 8e85764ef4862b927bf3aba3db79c7b35bc07b06..f8c8aff903f9f1e0e826f8c896aee54edbabb850 100755 (executable)
@@ -37,10 +37,11 @@ if [ "$1" ]; then
        ver=$1
 else
        echo "Fetching latest patches list..."
-       wget -nv $sources -O sources.new 2>&1
+       wget -nv $sources -O sources.tmp 2>&1
+       sort -k 2 -V < sources.tmp > sources.new
        # exclude files already in git tree
        git ls-files "$basever.*" | sed -e 's/\./\\./g;s/$/$/'| grep -vf - sources.new > sources
-       rm sources.new
+       rm sources.new sources.tmp
        # also update patches README
        wget -nv $baseurl/README -O README.patches 2>&1
        ver=$(tail -n1 sources | awk '{print $NF}')
@@ -94,10 +95,11 @@ if [ "$curver" != "$ver" ]; then
                        --define "_builddir $outdir" \
                        --define "_rpmdir $rpmdir" \
                        $specfile || {
-                       echo "Package build failed"
+                       echo "Package build failed" >&2
                        tail -n 1000 $logfile >&2
                        exit 1
                }
+               echo >&2 "Package build OK"
 
                rpmdest=~/public_html/$dist/$arch/
                if [ "$publish_packages" ] && [ "$(ls $rpmdir/*.rpm 2>/dev/null)" ]; then
This page took 0.163183 seconds and 4 git commands to generate.