RFR: Parse .ssh/config in git-pr if needed
Erik Duveblad via github.com
duke at openjdk.java.net
Tue Aug 27 13:28:42 UTC 2019
Hi all,
`git-pr` needs to find the `URI` for a remote and that can be a bit tricky if an SSH "alias" (set up in `~/.ssh/config`) is involved. This patch adds a little `ssh` module with a `SSHConfig` class that can parse most fields out of an `ssh_config` file (most crucially the `Hostname` field). This way `git-pr` can be a little smarter about figure out the hostname of the forge.
## Testing
- [x] `sh gradlew test` passes
- [x] Added an additional unit test
Thanks,
Erik
----------------
Commits:
- af597194: Remove tabs
- c03bd2f7: Remove stray debug printing
- 1ef6a56a: Parse .ssh/config in git-pr if needed
Pull request:
https://git.openjdk.java.net/skara/pull/88
Webrev:
https://webrevs.openjdk.java.net/skara/88/webrev.00
Patch:
https://git.openjdk.java.net/skara/pull/88.diff
Fetch command:
git fetch https://git.openjdk.java.net/skara pull/88/head:pull/88
More information about the skara-dev
mailing list