Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15539457
D14735.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D14735.diff
View Options
diff --git a/src/repository/api/ArcanistGitAPI.php b/src/repository/api/ArcanistGitAPI.php
--- a/src/repository/api/ArcanistGitAPI.php
+++ b/src/repository/api/ArcanistGitAPI.php
@@ -1216,8 +1216,20 @@
// Ideally, we would use something like "for-each-ref --contains"
// to get a filtered list of branches ready for script consumption.
// Instead, try to get predictable output from "branch --contains".
+
+ $flags = array();
+ $flags[] = '--no-color';
+
+ // NOTE: The "--no-column" flag was introduced in Git 1.7.11, so
+ // don't pass it if we're running an older version. See T9953.
+ $version = $this->getGitVersion();
+ if (version_compare($version, '1.7.11', '>=')) {
+ $flags[] = '--no-column';
+ }
+
list($branches) = $this->execxLocal(
- '-c column.ui=never -c color.ui=never branch --contains %s',
+ 'branch %Ls --contains %s',
+ $flags,
$commit);
$branches = array_filter(explode("\n", $branches));
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Apr 26, 1:39 AM (12 h, 41 m ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7713476
Default Alt Text
D14735.diff (1 KB)
Attached To
Mode
D14735: Don't use "-c" flag in "git:branch-unique()" revision range rule
Attached
Detach File
Event Timeline
Log In to Comment