Description: Support invocation as "arcanist"
Author: Christoph Biedl <debian.axhn@manchmal.in-ulm.de>
Bug-Debian: https://bugs.debian.org/1020840
Forwarded: not-needed
Last-Update: 2022-10-07

    Followup to #919697: The arc program must not be installed at
    /usr/bin/arc, but using /usr/bin/arcanist triggers an error from the
    program as it doesn't know anything about this.

--- a/arcanist/src/runtime/ArcanistRuntime.php
+++ b/arcanist/src/runtime/ArcanistRuntime.php
@@ -514,6 +514,9 @@
 
   private function newToolset(array $argv) {
     $binary = basename($argv[0]);
+    if ($binary == 'arcanist') {
+      $binary = 'arc';
+    }
 
     $toolsets = ArcanistToolset::newToolsetMap();
     if (!isset($toolsets[$binary])) {
