I am trying to "arc land" a change where the remote is not named "origin". (Why is not particularly important, but the short version is multiple remotes...).
The output of arc is:
$ arc land
Landing current branch 'FeatureX'.
Switched to branch develop. Updating branch...
Switched back to branch FeatureX.
Exception
Command failed with error #128!
COMMAND
git log 'origin/develop'..'develop'
STDOUT
(empty)
STDERR
fatal: ambiguous argument 'origin/develop..develop': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions
On the other hand, if I try to specify the remote with --onto, I get a different error:
$ arc land --onto myremote/develop
Landing current branch 'FeatureX'.
Switched to branch myremote/develop. Updating branch...
Switched back to branch FeatureX.
Exception
Command failed with error #1!
COMMAND
git pull --ff-only --no-stat
STDOUT
(empty)
STDERR
fatal: No remote repository specified. Please, specify either a URL or a
remote name from which new revisions should be fetched.
Is there a config setting that can specify the name of the default remote for arcanist to use?
Answer: There is no configuration option, but there is a command line option:
arc land --remote myremote
Or, the source can be modified to read it from the configuration:
ArcanistLandWorkflow.php:
$remote_default = $this->isGit ? 'origin' : '';
+ $remote_default = nonempty(
+ $this->getConfigFromAnySource('arc.land.remote.default'),
+ $remote_default);
+
$this->remote = $this->getArgument('remote', $remote_default);
https://github.com/bitblitz/arcanist/commit/618dea07c067a31385f20b46063956b6674035f0