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(git-spawn): Set GIT_SSH_VARIANT to get plink working with custom port #4806

Merged
merged 1 commit into from
Oct 31, 2017

Conversation

neonowy
Copy link
Contributor

@neonowy neonowy commented Oct 30, 2017

Summary

Fixes #4729.
Previous version in #4805.

Manually specify GIT_SSH_VARIANT in order to get package download via git+ssh with non-standard port when using plink.exe working.

Without GIT_SSH_VARIANT set properly, Git won't convert -p into -P and plink.exe will throw an error about unknown -p parameter.

Test plan

Before:

virtualbox_msedge_-_win10_30_10_2017_16_35_24

After:

virtualbox_msedge_-_win10_30_10_2017_19_07_15

Also got git-spawn.js test suite updated for testing GIT_SSH_VARIANT.

Fixes yarnpkg#4729. Manually specify `GIT_SSH_VARIANT` in order to get package download via git+ssh with
non-standard port when using plink.exe working.
Copy link
Member

@BYK BYK left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@BYK BYK merged commit 4f41887 into yarnpkg:master Oct 31, 2017
@arcanis
Copy link
Member

arcanis commented Oct 31, 2017

For reference, GIT_SSH_VARIANT seems to have been added in Git 2.13.0, released on May 10.

calvinhuang pushed a commit to calvinhuang/yarn that referenced this pull request Nov 9, 2017
**Summary**

Fixes yarnpkg#4729.
Previous version in yarnpkg#4805.

Manually specify `GIT_SSH_VARIANT` in order to get package download via `git+ssh` with a non-standard port when using `plink.exe` working.

Without `GIT_SSH_VARIANT` set properly, Git won't convert `-p` into `-P` and `plink.exe` will throw an error about unknown `-p` parameter.

**Test plan**

*Before:*
![virtualbox_msedge_-_win10_30_10_2017_16_35_24](https://user-images.githubusercontent.com/5042328/32179804-9a87c676-bd90-11e7-86d0-09380d61eadf.png)

*After:*
![virtualbox_msedge_-_win10_30_10_2017_19_07_15](https://user-images.githubusercontent.com/5042328/32187512-9bcb980e-bda5-11e7-96ea-27a513837d6e.png)

Also got `git-spawn.js` test suite updated for testing `GIT_SSH_VARIANT`.
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.

3 participants