public
Created

Increase the pkgrel of a PKGBUILD for ArchLinux

  • Download Gist
incpkgrel.sh
Shell
1 2 3 4 5 6 7 8 9
#! /bin/bash
 
ifile=$1; shift
ofile=$1; shift
 
awk '/^pkgrel/ { match( $0, /^pkgrel=([[:digit:]]+)/, Arr ); printf "pkgrel=%s\n", Arr[1]+1 }
! /^pkgrel/ { print }
' ${ifile} > ${ofile}.tmp
mv ${ofile}.tmp ${ofile}

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.