OLD | NEW |
1 // Copyright 2015 The LUCI Authors. All rights reserved. | 1 // Copyright 2015 The LUCI Authors. All rights reserved. |
2 // Use of this source code is governed under the Apache License, Version 2.0 | 2 // Use of this source code is governed under the Apache License, Version 2.0 |
3 // that can be found in the LICENSE file. | 3 // that can be found in the LICENSE file. |
4 | 4 |
5 package isolate | 5 package isolate |
6 | 6 |
7 import ( | 7 import ( |
8 "fmt" | 8 "fmt" |
9 "log" | 9 "log" |
10 "path" | 10 "path" |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 buf[n] = '/' | 130 buf[n] = '/' |
131 copy(buf[n+1:], targ[t0:]) | 131 copy(buf[n+1:], targ[t0:]) |
132 } | 132 } |
133 return string(buf), nil | 133 return string(buf), nil |
134 } | 134 } |
135 return targ[t0:], nil | 135 return targ[t0:], nil |
136 } | 136 } |
137 | 137 |
138 // IsWindows returns True when running on the best OS there is. | 138 // IsWindows returns True when running on the best OS there is. |
139 func IsWindows() bool { | 139 func IsWindows() bool { |
| 140 // TODO(mcgreevy): once there is a top-level isolate directory with cmd |
| 141 // and cli subdirs, move IsWindows into an isolate/internal package. |
140 return runtime.GOOS == "windows" | 142 return runtime.GOOS == "windows" |
141 } | 143 } |
OLD | NEW |