Enhance absolute version dependency to accept "1.0.0" #39
Conversation
Instead of relying only on a "=" prefix, this enhanced version works by making sure all "non-absolute" version rangs are not used, e.g. "~", "^". From the semver Backus-Naur grammar (https://www.npmjs.com/package/semver) is only missing that a "x" and "X" can be used instead of "*".
Nice work, @chr1shaefn3r! I really like this improvement. I'll get a new version packaged up this weekend. |
Hey @chr1shaefn3r v2.5.0 has been published! The documentation has been updated too. Let me know if you see any issues. prefer-absolute-version-dependencies |
Thank you very much on prefer-absolute-version-devDependencies is a small copy&paste error: the headline still says "dependencies" instead of "devDependencies". Other than it looks good :) |
Fixed! Good eye |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Instead of relying only on a "=" prefix, this enhanced version works by
making sure all "non-absolute" version rangs are not used, e.g. "~", "^".
From the semver Backus-Naur grammar
(https://www.npmjs.com/package/semver) is only missing that a "x" and
"X" can be used instead of "*".
This change is motivated by the experience over the last several days that a workflow which tries to make sure a "=" prefixed version ends up in the package.json and yarn.lock is to tedious.
Main reason is that one needs to manually look up the latest version to run e.g.:
yarn add winston@=2.3.1
With this pull request you just need to run:
yarn add -E winston
No need to manually check the version :)