Class: GemBootstrap::GitUtils
- Inherits:
-
Object
- Object
- GemBootstrap::GitUtils
- Defined in:
- lib/gem_bootstrap/git_utils.rb
Class Method Summary collapse
-
.create_git_project(base_dir, gem_name) ⇒ Object
create new git repository from a given directory.
Class Method Details
.create_git_project(base_dir, gem_name) ⇒ Object
create new git repository from a given directory
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/gem_bootstrap/git_utils.rb', line 8 def create_git_project(base_dir, gem_name) base_dir = (base_dir) files = MiscUtils.files base_dir: base_dir, non_exts: %w(Gemfile Rakefile Guardfile LICENSE .rubocop.yml .yardopts .gitignore) << gem_name, exts: %w(md rb gemspec yml), recursive: true git_init(base_dir) git_add(base_dir, files) end |