Page MenuHomePhabricator

In Git, fall back across versions more cleanly when trying to get the URI for a remote
ClosedPublic

Authored by epriestley on Jan 23 2020, 11:17 PM.
Tags
None
Referenced Files
F15541806: D20950.diff
Fri, Apr 25, 1:38 PM
F15507137: D20950.id.diff
Tue, Apr 15, 4:41 PM
F15504156: D20950.id49913.diff
Mon, Apr 14, 4:19 PM
F15475422: D20950.diff
Sun, Apr 6, 7:44 PM
F15451769: D20950.id.diff
Fri, Mar 28, 11:42 PM
F15451627: D20950.diff
Fri, Mar 28, 11:03 PM
F15426160: D20950.diff
Mar 23 2025, 7:30 AM
F15390107: D20950.id49913.diff
Mar 15 2025, 5:54 AM
Subscribers
None

Details

Summary

Fixes T13481. When identifying the URI for a remote, fall back from "git remote get-url" to "git ls-remote --get-url" to "git config remote.<name>.url" based on command output and version tests.

Test Plan

Ran arc land --hold, rigged the subcommands to fail to try all three fallbacks, ran arc land --hold --remote asdfasdf to get an explicit failure.

Diff Detail

Repository
rARC Arcanist
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision was not accepted when it landed; it landed in state Needs Review.Jan 23 2020, 11:18 PM
epriestley requested review of this revision.
This revision was automatically updated to reflect the committed changes.