Class: Gemsmith::Builders::Git::Ignore

Inherits:
Rubysmith::Builders::Git::Ignore
  • Object
show all
Defined in:
lib/gemsmith/builders/git/ignore.rb

Overview

Builds project skeleton Git ignore.

Instance Method Summary collapse

Instance Method Details

#callObject



12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# File 'lib/gemsmith/builders/git/ignore.rb', line 12

def call
  super

  return false unless settings.build_git

  builder.call(settings.merge(template_path: "%project_name%/.gitignore.erb"))
         .touch
         .prepend("*.gem\n")
         .insert_before "tmp\n", <<~CONTENT
           Gemfile.lock
           pkg
         CONTENT

  true
end