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

feat: add env var override for get-last-release use local strategy #82

Open
wants to merge 1 commit into
base: caribou
Choose a base branch
from

Conversation

junosuarez
Copy link

The underlying semantic-release get-last-release plugin has all sorts of problems in their issues tracker about working with private npm registries (and seems slow and non-responsive in merging PRs).

Thankfully, the strategy in lerna-semantic-release-get-last-release of looking at git tags works great! The problem is, with a private npm registry, the package.json doesn't have private: true, so this package fails to detect it, and falls back to the default (non-working) strategy.

This PR lets you force the local git tag-based get-last-release strategy by setting an env var GET_LAST_RELEASE_FROM_TAGS.

I didn't see any other convention already established in this project for setting config (or overriding plugins, which would let me make this change in my setup without needing to push it upstream into lerna-semantic-release), so I went with an env var as an easy default - but I'm more than willing to discuss an alternate implementation. What I'm trying to achieve is a way to force lerna-semantic-release to always use the local get-last-version strategy.

Thanks!

affects: lerna-semantic-release-get-last-release
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

Successfully merging this pull request may close these issues.

1 participant