Changeset 1094

Show
Ignore:
Timestamp:
12/13/07 22:36:30 (1 year ago)
Author:
e.@brainspl.at
Message:

spit out error and help message if you call merb with no args and you are not in the root of a merb app. closes #352

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/lib/merb/server.rb

    r1087 r1094  
    180180        end 
    181181         
     182        # If we run merb with no arguments and we are not inside a merb root 
     183        # show the help message 
     184        if (argv.size == 0) && !File.exists?("#{options[:merb_root] || Merb::Config.defaults[:merb_root]}/config/merb_init.rb")  
     185          puts "You are not in the root of a merb application...\n" 
     186          puts opts  
     187          exit  
     188        end 
    182189        # Load up the configuration from file, but keep the command line 
    183190        # options that may have been chosen. Also, pass-through if we have