Summary:
Ref T13098. Depends on D19675. This change is headed to the `untamed-wilds` branch.
This change prevents `arc` from running `arc diff`, so I'm copy/pasting it.
This change also completely breaks `arc`, but I'm just generally trying to do this rewrite step-by-step so we have at least a bit of context to refer to in the future.
The major change here is to turn both `arc` and `phage` into scripts which start an `ArcanistRuntime`. This runtime then decides which workflows (like "diff", "patch", or "remote") are available based on `$argv[0]`. This turns `arc` into more of a CLI tools platform: we can build `phage` on it, third parties can build `my-companion-tool-thing`, etc. But all the different entry points can share a lot of infrastructure like: `help`, `alias`, shell-complete, configuration, Conduit, prompting, `--trace`, extension infrastructure, and so on.
`ArcanistRuntime` is roughly a slightly more modern version of `scripts/arcanist.php`. That will be removed eventually, but not everything has ported yet.
Test Plan: This code basically doesn't run yet, although the next patch runs at least a little bit.
Reviewers: amckinley
Reviewed By: amckinley
Maniphest Tasks: T13098
Differential Revision: https://secure.phabricator.com/D19677
Summary: This shell script needs more quotes.
Test Plan: Ran "arc" with `arcanist/` inside a directory called `s p a c e s`.
Reviewers: irinav, vrana
Reviewed By: vrana
CC: aran
Differential Revision: https://secure.phabricator.com/D5265
Summary: Using /usr/bin/env in #! to allow the arc script to run as is in every UNIX OSes, like FreeBSD where bash is installed in /usr/local/bin/bash.
Test Plan: Tested on Solaris, Ubuntu, kFreeBSD/Debian and FreeBSD.
Reviewers: epriestley
Reviewed By: epriestley
CC: aran, epriestley
Maniphest Tasks: T1440
Differential Revision: https://secure.phabricator.com/D2913
Summary:
The new wrapper shell script that is bin/arc does not correctly
handle arguments with spaces in them.
Test Plan:
added a print_r($argv) to scripts/arcanist.php and ran bin/arc -m
"testing something" to see that "testing something" got passed in as
one argument instead of two.
Reviewers: jungejason, epriestley
Reviewed By: epriestley
CC: aran
Differential Revision: https://secure.phabricator.com/D2066
Summary: Currently, we use a symlink. Under git bash, it tries to run the symlink. This is not a recipe for success. Instead, use a trivial wrapper script.
Test Plan: Ran "arc" from git bash.
Reviewers: Makinde, btrahan, Koolvin
Reviewed By: Koolvin
CC: aran, epriestley
Maniphest Tasks: T124
Differential Revision: https://secure.phabricator.com/D1939