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

Edits to package.json no longer work as of March 2022 #35

Open
willroberts opened this issue Sep 12, 2022 · 1 comment
Open

Edits to package.json no longer work as of March 2022 #35

willroberts opened this issue Sep 12, 2022 · 1 comment

Comments

@willroberts
Copy link

willroberts commented Sep 12, 2022

GitHub permanently removed support for the unauthenticated Git protocol in March 2022: https://github.blog/2021-09-01-improving-git-protocol-security-github/

bower-away adds dependencies to package.json like so:

"@bower_components/some-component": "git://github.com/some-github-org/some-component.git#1.2.3",

As mentioned in the article, the unauthenticated Git protocol is no longer supported. The URL can be modified to use HTTPS, but anchors and redirection are not supported, meaning we can't specify the dependency version:

% git clone https://github.com/some-github-org/some-component.git#1.2.3
Cloning into 'some-component.git#1.2.3'...
fatal: unable to update url base from redirection:
  asked for: https://github.com/some-github-org/some-component.git#1.2.3/info/refs?service=git-upload-pack
   redirect: https://github.com/some-github-org/some-component

Slightly different issue with git+ssh:

% git clone git+ssh://git@github.com/some-github-org/some-component.git#v1.0.0
Cloning into 'some-component.git#v1.0.0'...
fatal: remote error:
   is not a valid repository name

There doesn't seem to be an easy way to resolve this, so bower-away would need some modifications to continue working.

@willroberts
Copy link
Author

I actually just found a way to make this work in package.json: use some-github-org/some-component#1.2.3 without any protocol specification!

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

1 participant