diff options
| author | Amos Wenger | 2013-08-15 21:50:13 +0200 |
|---|---|---|
| committer | Jack Nagel | 2013-08-19 13:35:44 -0500 |
| commit | 52ace99f14a9390f5bf71370d616f2ed6b98c034 (patch) | |
| tree | 48580569d443ddbebf2a06f99efb3a0ebe94208a /Library/Homebrew/test/testing_env.rb | |
| parent | 809a52a6a3e8b0899aa2697f767b8dcc22210bd8 (diff) | |
| download | brew-52ace99f14a9390f5bf71370d616f2ed6b98c034.tar.bz2 | |
Use File::PATH_SEPARATOR globally instead of ':'
On Unix, the path separator is ':', whereas on Windows,
it is ';'. This is the first of a series of patch to bring
macbrew's and winbrew's codebases closer together.
The main places the magic constant ':' was being used were:
- the $PATH environment variable
- CMAKE-related environment variables
- pkg-config related environment variables
Closes Homebrew/homebrew#21921.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Homebrew/test/testing_env.rb')
| -rw-r--r-- | Library/Homebrew/test/testing_env.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/test/testing_env.rb b/Library/Homebrew/test/testing_env.rb index 5c2efed73..9bc5d871f 100644 --- a/Library/Homebrew/test/testing_env.rb +++ b/Library/Homebrew/test/testing_env.rb @@ -33,7 +33,7 @@ MACOS = true MACOS_FULL_VERSION = `/usr/bin/sw_vers -productVersion`.chomp MACOS_VERSION = ENV.fetch('MACOS_VERSION') { MACOS_FULL_VERSION[/10\.\d+/] }.to_f -ORIGINAL_PATHS = ENV['PATH'].split(':').map{ |p| Pathname.new(p).expand_path rescue nil }.compact.freeze +ORIGINAL_PATHS = ENV['PATH'].split(File::PATH_SEPARATOR).map{ |p| Pathname.new(p).expand_path rescue nil }.compact.freeze module Homebrew extend self include FileUtils |
