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

Fix authentication when @scope:registry does not specify trailing slash #2168

Merged
merged 1 commit into from
Dec 7, 2016

Conversation

KidkArolis
Copy link
Contributor

This PR was triggered by new discussion on #1666.

I'm not 100% sold on this yet, I'll try to read through the npm source code to see what they do.

Which one of these cases are valid (cause this PR would break some of these):

# Standard setup - works today, both entries have trailing slash
@scoped:registry=https://foo.com/
//foo.com/:_authToken=xyz

# This PR addresses this case - does this work in npm-cli?
@scoped:registry=https://foo.com
//foo.com/:_authToken=xyz

# Is this possible? No trailing slashes
@scoped:registry=https://foo.com
//foo.com:_authToken=xyz

# I keep referring to these as trailing slashes, but really - they're paths
@scoped:registry=https://foo.com/custom/path
//foo.com/custom/path:_authToken=xyz

# And this?
@scoped:registry=https://foo.com/custom/path/
//foo.com/custom/path/:_authToken=xyz

# And this?
@scoped:registry=https://foo.com/custom/path
//foo.com/custom/path/:_authToken=xyz

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.

2 participants