File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -92,17 +92,18 @@ + (NSString *) path;
92
92
93
93
+ (NSArray *) searchLocations
94
94
{
95
- if (locations)
96
- return locations;
97
-
98
- locations = [NSMutableArray arrayWithObjects: @" /opt/local/bin/git" ,
99
- @" /sw/bin/git" ,
100
- @" /opt/git/bin/git" ,
101
- @" /usr/local/bin/git" ,
102
- @" /usr/local/git/bin/git" ,
103
- nil ];
104
-
105
- [locations addObject: [@" ~/bin/git" stringByExpandingTildeInPath ]];
95
+ if (!locations)
96
+ {
97
+ locations = [[NSMutableArray alloc ] initWithObjects:
98
+ @" /opt/local/bin/git" ,
99
+ @" /sw/bin/git" ,
100
+ @" /opt/git/bin/git" ,
101
+ @" /usr/local/bin/git" ,
102
+ @" /usr/local/git/bin/git" ,
103
+ nil ];
104
+
105
+ [locations addObject: [@" ~/bin/git" stringByExpandingTildeInPath ]];
106
+ }
106
107
return locations;
107
108
}
108
109
You can’t perform that action at this time.
0 commit comments