Sha256: 8c393bf23ae977a074078f491412257e3168fa222f2c703cac6725e2c978c11c

Contents?: true

Size: 652 Bytes

Versions: 36

Compression:

Stored size: 652 Bytes

Contents

Dir.chdir(__dir__) do
    require './perus/options'
    require './perus/pinger'
    require './perus/server'
    require './perus/version'
end

if ARGV[0] == 'server'
    Perus::Server::Server.new.run

elsif ARGV[0] == 'pinger'
    Perus::Pinger::Pinger.new.run

elsif ARGV[0] == 'console'
    require 'irb'

    # start in the Server namespace
    include Perus::Server

    # console is used to access the database. initialise server options to find
    # the db path and start the database connection.
    Server.load_options
    DB.start

    # remove the arg otherwise irb will try to load a file named 'console'
    ARGV.shift
    IRB.start
end

Version data entries

36 entries across 36 versions & 1 rubygems

Version Path
perus-1.0.7 lib/perus.rb
perus-1.0.6 lib/perus.rb
perus-1.0.5 lib/perus.rb
perus-1.0.4 lib/perus.rb
perus-1.0.3 lib/perus.rb
perus-1.0.2 lib/perus.rb
perus-1.0.1 lib/perus.rb
perus-1.0.0 lib/perus.rb
perus-0.1.35 lib/perus.rb
perus-0.1.34 lib/perus.rb
perus-0.1.33 lib/perus.rb
perus-0.1.32 lib/perus.rb
perus-0.1.31 lib/perus.rb
perus-0.1.30 lib/perus.rb
perus-0.1.29 lib/perus.rb
perus-0.1.28 lib/perus.rb
perus-0.1.27 lib/perus.rb
perus-0.1.26 lib/perus.rb
perus-0.1.25 lib/perus.rb
perus-0.1.24 lib/perus.rb