diff --git a/src/land/engine/ArcanistGitLandEngine.php b/src/land/engine/ArcanistGitLandEngine.php --- a/src/land/engine/ArcanistGitLandEngine.php +++ b/src/land/engine/ArcanistGitLandEngine.php @@ -885,6 +885,11 @@ $onto_ref)); } } + + // TODO: Check that these refs really exist in the remote? Checking the + // remote is expensive and users probably rarely specify "--onto" manually, + // but if "arc land" creates branches without prompting when you make typos + // that also seems questionable. } protected function selectOntoRefs(array $symbols) { @@ -1491,7 +1496,7 @@ foreach ($this->getOntoRefs() as $onto_ref) { $refspecs[] = sprintf( - '%s:%s', + '%s:refs/heads/%s', $this->getDisplayHash($into_commit), $onto_ref); } diff --git a/src/land/engine/ArcanistLandEngine.php b/src/land/engine/ArcanistLandEngine.php --- a/src/land/engine/ArcanistLandEngine.php +++ b/src/land/engine/ArcanistLandEngine.php @@ -1361,7 +1361,7 @@ } $into = $this->getIntoArgument(); - if ($into && ($into_empty !== null)) { + if ($into && $into_empty) { throw new PhutilArgumentUsageException( pht( 'Arguments "--into" and "--into-empty" are mutually exclusive.'));