aboutsummaryrefslogtreecommitdiffstats
path: root/lib/alaveteli_external_command.rb
diff options
context:
space:
mode:
authorLouise Crow <louise.crow@gmail.com>2012-10-17 15:05:37 +0100
committerLouise Crow <louise.crow@gmail.com>2012-10-17 15:05:37 +0100
commitc8a203e221a55a5653596f5a8e092bd3877df9c4 (patch)
tree3de4ac1214eca2c12a357e5f338b0d3055e79721 /lib/alaveteli_external_command.rb
parente6dc0f6606b26e13cb0cd16124fdb2aad3c1b5a6 (diff)
parentcc7bc36d5748c9baa0cfd8e44395923cc5792f32 (diff)
Merge branch 'release/0.6.7'
Conflicts: locale/cs/app.po locale/ro_RO/app.po
Diffstat (limited to 'lib/alaveteli_external_command.rb')
-rw-r--r--lib/alaveteli_external_command.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/alaveteli_external_command.rb b/lib/alaveteli_external_command.rb
index 7d32be904..3bfc34e3a 100644
--- a/lib/alaveteli_external_command.rb
+++ b/lib/alaveteli_external_command.rb
@@ -14,16 +14,15 @@ module AlaveteliExternalCommand
if program_name =~ %r(^/)
program_path = program_name
else
- utility_search_path = MySociety::Config.get("UTILITY_SEARCH_PATH", ["/usr/bin", "/usr/local/bin"])
found = false
- utility_search_path.each do |d|
+ Configuration::utility_search_path.each do |d|
program_path = File.join(d, program_name)
if File.file? program_path and File.executable? program_path
found = true
break
end
end
- raise "Could not find #{program_name} in any of #{utility_search_path.join(', ')}" if !found
+ raise "Could not find #{program_name} in any of #{Configuration::utility_search_path.join(', ')}" if !found
end
xc = ExternalCommand.new(program_path, *args)