Skip to content
Snippets Groups Projects
Commit ad71eca8 authored by Jacob Vosmaer's avatar Jacob Vosmaer
Browse files

Catch missing commands in rake tasks with ''

parent 322a8f1d
No related branches found
No related tags found
No related merge requests found
Loading
@@ -82,6 +82,8 @@ namespace :gitlab do
Loading
@@ -82,6 +82,8 @@ namespace :gitlab do
def run(command) def run(command)
output, _ = Gitlab::Popen.popen(command) output, _ = Gitlab::Popen.popen(command)
output output
rescue Errno::ENOENT
'' # if the command does not exist, return an empty string
end end
   
def uid_for(user_name) def uid_for(user_name)
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment