Page MenuHomePhabricator

Run ls-files from the root of the directory
ClosedPublic

Authored by ptarjan on Mar 25 2020, 8:45 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Dec 19, 1:00 AM
Unknown Object (File)
Tue, Dec 17, 10:15 AM
Unknown Object (File)
Tue, Dec 17, 5:03 AM
Unknown Object (File)
Fri, Dec 6, 8:56 PM
Unknown Object (File)
Fri, Dec 6, 5:05 PM
Unknown Object (File)
Wed, Dec 4, 7:09 AM
Unknown Object (File)
Mon, Nov 25, 12:35 AM
Unknown Object (File)
Nov 21 2024, 6:18 PM
Subscribers

Details

Summary

One of our users ran into an issue where they were running arc diff in
a subdirectory and it so happened that in that directoy there wasn't any lfs
files so the repo was marked as $is_lfs == false. Lets allow arc to be run
from anywhere.

Test Plan

Internally this patch worked

Diff Detail

Repository
rARC Arcanist
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Try something like this:

list($stdout) = $repository_api->execxLocal(
  'ls-files ...',
  ':(attr...)');

That should set the CWD correctly and avoid a bunch of other issues (see T13479). We also likely can't $(...) on Windows.

This revision now requires changes to proceed.Mar 25 2020, 8:49 PM

(Actual change makes perfect sense.)

If that doesn't immediately work, yell at me and I can grab this and figure out what's up.

ptarjan edited the summary of this revision. (Show Details)
ptarjan edited the summary of this revision. (Show Details)
This revision is now accepted and ready to land.Mar 25 2020, 9:13 PM