How can I retrieve the
git add -A
eval $pkg_ver = getjson('./package.json', 'version')
git commit -a -m "$pkg_ver"
git push origin master
If your json file is more complex then I would suggest to use jq - link
pkg_ver=$(jq '.version' package.json)
However, if you have only this two items then maybe using sed, awk or tr would be easier.