Bash parse semver. The Rcpp package was used to provide R bindings.