aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorJack Nagel2012-06-17 17:59:30 -0500
committerJack Nagel2012-06-17 17:59:30 -0500
commit6a94df360a236acf23b025fdf3ca84f76f195c94 (patch)
tree5f62cf34e33feb9346264a57f5f45b75eed8c0b1 /Library
parent38a28285a6fdbeadbd6d7cc189af253fb446ee85 (diff)
downloadbrew-6a94df360a236acf23b025fdf3ca84f76f195c94.tar.bz2
audit: prefer modifying ENV to using env or export
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library')
-rwxr-xr-xLibrary/Homebrew/cmd/audit.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/Library/Homebrew/cmd/audit.rb b/Library/Homebrew/cmd/audit.rb
index 4ca541a75..cb7cb2510 100755
--- a/Library/Homebrew/cmd/audit.rb
+++ b/Library/Homebrew/cmd/audit.rb
@@ -129,6 +129,10 @@ def audit_formula_text name, text
problems << " * Use \"\#{ENV.cxx}\" instead of hard-coding \"#{$3}\""
end
+ if text =~ /system\s+['"](env|export)/
+ problems << " * Use ENV instead of invoking '#{$1}' to modify the environment"
+ end
+
return problems
end