Sha256: de9579776b26f50928e891d946b797f6d38d85d09073bb1c12e02a29d045f6a2

Contents?: true

Size: 771 Bytes

Versions: 2

Compression:

Stored size: 771 Bytes

Contents

#!/usr/bin/env ruby

$:.unshift File.join(File.dirname(__FILE__), *%w[.. lib])

help = <<HELP
Gollum is a multi-format Wiki Engine/API/Frontend.

Basic Command Line Usage:
  gollum [OPTIONS] [PATH]

        PATH                         The path to the Gollum repository.

Options:
HELP

require 'optparse'

require 'rubygems'
require 'gollum/frontend/app'

exec = {}
options = {}
opts = OptionParser.new do |opts|
  opts.banner = help

  opts.on("--port [PORT]", "Bind port (default 4567).") do |port|
    options['port'] = port.to_i
  end

  opts.on("--version", "Display current version.") do
    puts "Gollum " + Gollum::VERSION
    exit 0
  end
end

# Read command line options into `options` hash
opts.parse!

$path = ARGV[0] || Dir.pwd

Precious::App.run!(options)

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
gollum-1.0.1 bin/gollum
gollum-1.0.0 bin/gollum