Sha256: 5ab1e4ffd4308239298b3510ace9702b5a9c56e5f1bb2f3160c430db0d56fcbd

Contents?: true

Size: 917 Bytes

Versions: 1

Compression:

Stored size: 917 Bytes

Contents

#!/usr/bin/env ruby

require "bundler/setup"
require 'seeit'
require "json"
require 'optparse'

options = {}
OptionParser.new do |opts|
  opts.banner = "Usage: seeit_build_version"

  opts.on("-pPROJECT_DIR", "--project-dir=PROJECT_DIR", "Project directory with settings.json") do |project_dir|
    options[:project_dir] = project_dir
  end
  opts.on("-nVERSION_NAME", "--version-name=VERSION_NAME", "Mark the version of your screenshots (defaults to today's date)") do |build_version|
    options[:build_version] = build_version
  end
  opts.on("-h", "--help", "Prints this help") do
    puts opts
    exit
  end

end.parse!

# raise required items
raise OptionParser::MissingArgument if options[:project_dir].nil?

build_version = options[:build_version]
build_version = Date.today.strftime("%Y-%m-%d") if options[:build_version].nil?

b = Seeit::Builder.new(options[:project_dir], options[:build_version])
b.build

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
seeit-0.1.0 bin/seeit_build_version