Page MenuHomePhabricator

Examine upstream path instead of assuming "origin"
ClosedPublic

Authored by alexmv on Nov 20 2015, 6:50 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Mar 31, 8:13 PM
Unknown Object (File)
Fri, Mar 29, 11:09 AM
Unknown Object (File)
Mar 6 2024, 5:24 AM
Unknown Object (File)
Mar 6 2024, 5:24 AM
Unknown Object (File)
Feb 5 2024, 3:12 AM
Unknown Object (File)
Jan 30 2024, 6:28 PM
Unknown Object (File)
Dec 25 2023, 7:25 AM
Unknown Object (File)
Dec 17 2023, 8:10 PM

Details

Summary

Instead of blindly assuming that "origin" is the repository that
arcanist should communicate with, use the remote that is configured
for the branch in git.

Test Plan

Used arc which with a branch with no upstream, an
origin/master upstream, and an upstream/master upstream -- the last of
which is being used to create and land this diff.

Diff Detail

Repository
rARC Arcanist
Branch
to-upstream/uri-from-upstream-remote
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 8958
Build 10516: arc lint + arc unit

Event Timeline

alexmv retitled this revision from to Examine upstream path instead of assuming "origin".
alexmv updated this object.
alexmv edited the test plan for this revision. (Show Details)
alexmv added a reviewer: epriestley.
epriestley edited edge metadata.
epriestley added inline comments.
src/repository/api/ArcanistGitAPI.php
543

For consistency, prefer to write variables in strings as {$variable} instead of $variable:

"remote.{$remote}.url"

There's no behavioral difference, this syntax is just a little more explicit and consistent within the project.

548

We could maybe do this properly now, but whatever. I think the logic is fine as-is.

This revision is now accepted and ready to land.Nov 23 2015, 3:17 PM