Skip to content

Commit

Permalink
Fix bug where blank lines in Procfile break Foreman.
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt Haynes committed Jul 28, 2011
1 parent a2ba079 commit 2042de7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lib/foreman/engine.rb
Expand Up @@ -25,7 +25,7 @@ def processes
@processes ||= begin
@order = []
procfile.split("\n").inject({}) do |hash, line|
next if line.strip == ""
next hash if line.strip == ""
name, command = line.split(/ *: +/, 2)
unless command
warn_deprecated_procfile!
Expand Down
1 change: 1 addition & 0 deletions spec/spec_helper.rb
Expand Up @@ -27,6 +27,7 @@ def write_foreman_config(app)
def write_procfile(procfile="Procfile")
File.open(procfile, "w") do |file|
file.puts "alpha: ./alpha"
file.puts "\n"
file.puts "bravo: ./bravo"
end
File.expand_path(procfile)
Expand Down

0 comments on commit 2042de7

Please sign in to comment.