Sha256: e113482072e86fdf1e563b7440dd1e0bd4dce342d9b8031be467c61457d38b4f

Contents?: true

Size: 1.19 KB

Versions: 2

Compression:

Stored size: 1.19 KB

Contents

#!/usr/bin/env ruby
require 'qedproject'

require 'optparse'

banner = "QEDProject #{QEDProject::VERSION} (C) 2011 Brian P. Hogan\n"
banner << "-" * banner.length
puts banner

options = {}
LIBRARIES = QEDProject::Libraries::Base.libs.keys
OptionParser.new do |opts|
  opts.banner = "Usage: qedproject <projectname> [options]"


  opts.on('-s', '--sass', "Use SASS") do
    options[:sass] = true
  end

  opts.on('-c', '--coffee', "Use Coffeescript") do
    options[:coffeescript] = true
  end
  
  opts.on('-a', '--assets', "Use Jammit to manage assets") do
    options[:jammit] = true
  end
    
  opts.on('-t', '--testing', "Set up testing with Jasmine") do
    options[:testing] = true
  end

  opts.on("-l", "--libs [LIBRARIES]", "comma-separated list of libraries to include.\nLibraries are: #{LIBRARIES.join(",")}") do |libs|
    options[:libs] = libs.split(",").collect{ |f| f.to_sym }
  end
end.parse!
options[:verbose] = true 
project = ARGV[0]

if project.nil?
  puts "Specify a project. Use qedproject -h for options."
else
  begin
    QEDProject::Project.create(project, options)
  rescue QEDProject::BadLibraryError => e
    puts e.message
    puts "QEDProject supports #{LIBRARIES.join(",")}"
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
qedproject-0.0.5 bin/qedproject
qedproject-0.0.4 bin/qedproject