Skip to content

Instantly share code, notes, and snippets.

@nxhack
Last active June 29, 2016 23:42
Show Gist options
  • Save nxhack/12bd7124a05eab1b526dc0fcd26c5a3d to your computer and use it in GitHub Desktop.
Save nxhack/12bd7124a05eab1b526dc0fcd26c5a3d to your computer and use it in GitHub Desktop.
#!/bin/sh
OLD_NODE_VERSION="4.4.6"
NEW_NODE_VERSION="4.4.7"
for file in `ls -1 node-*/Makefile`; do
sed -i -e s/^PKG_NODE_VERSION:=${OLD_NODE_VERSION}/PKG_NODE_VERSION:=${NEW_NODE_VERSION}/ ${file}
SED_PT_RELEASE=`egrep ^PKG_RELEASE ${file}|awk -F= '{printf("s/^PKG_RELEASE:=%s/PKG_RELEASE:=%s/",$2,$2+1)}'`
sed -i -e ${SED_PT_RELEASE} ${file}
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment