Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PROPOSAL: Support dynamic Node version #141

Closed
notmessenger opened this issue Mar 5, 2018 · 3 comments
Closed

PROPOSAL: Support dynamic Node version #141

notmessenger opened this issue Mar 5, 2018 · 3 comments

Comments

@notmessenger
Copy link
Contributor

Currently we look for a hard-coded Node version in various scripts, for example if [[ ! "${PUBLISH_NODE_VERSION:-8.1.2}" =~ ^$TRAVIS_NODE_VERSION ]] in https://github.com/ciena-blueplanet/pr-bumper/blob/master/.travis/maybe-bump-version.sh#L10

I propose that we support the ability for the Node version to be set via a property so that when present it will be used in the scripts and when it is not then a/the default value is used. A likely candidate for where this property could be set is in the .pr-bumper.json file.

This will reduce the need for having to update the version of pr-bumper used in order to get a version of Node only if pr-bumper was released against/for the version desired.

@job13er
Copy link
Contributor

job13er commented Mar 5, 2018

I'm a little confused, isn't that exactly what PUBLISH_NODE_VERSION lets you do? The 8.1.2 is only used if PUBLISH_NODE_VERSION isn't provided in the environment.

@job13er
Copy link
Contributor

job13er commented Mar 5, 2018

(node@8.1.2) ~
[ameadows@PEW-AMEADOWS-02]$ echo ${PUBLISH_NODE_VERSION:-8.1.2}
8.1.2
(node@8.1.2) ~
[ameadows@PEW-AMEADOWS-02]$ export PUBLISH_NODE_VERSION=1.2.3
(node@8.1.2) ~
[ameadows@PEW-AMEADOWS-02]$ echo ${PUBLISH_NODE_VERSION:-8.1.2}
1.2.3

@notmessenger
Copy link
Contributor Author

You are completely correct - I spaced on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants