Sha256: cab46a0f274eb9b70a8e969a1b5b25d0e8a28c29bec215ac7f2c11041552afc5
Contents?: true
Size: 923 Bytes
Versions: 2
Compression:
Stored size: 923 Bytes
Contents
#!/usr/bin/env ruby require 'rubygems' require 'thor' require 'penchant' class PenchantCLI < Thor include Thor::Actions source_root File.expand_path('../..', __FILE__) desc "install", "Copy the common scripts to the project" method_options :dir => 'script' def install directory 'template/script', options[:dir] Dir[File.join(options[:dir], '**/*')].each { |file| File.chmod(0755, file) } end desc "convert", "Make an existing project Penchant-isized" method_options :dir => 'script' def convert install copy_file 'Gemfile', 'Gemfile.erb' remove_file 'Gemfile' gemfile(:remote) end desc "gemfile ENV", "Switch the gemfile environment" def gemfile(env) Penchant::Gemfile.do_full_env_switch!(env) end desc "gemfile-env", "Get the gemfile environment" def gemfile_env gemfile = Penchant::Gemfile.new puts gemfile.environment end end PenchantCLI.start
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
penchant-0.0.2 | bin/penchant |
penchant-0.0.1 | bin/penchant |