Module: Jarbs::ManifestHelpers
- Included in:
- FunctionGenerator, ProjectGenerator
- Defined in:
- lib/jarbs/manifest_helpers.rb
Instance Method Summary collapse
Instance Method Details
#repo_url ⇒ Object
14 15 16 |
# File 'lib/jarbs/manifest_helpers.rb', line 14 def repo_url @repo_url ||= `git config --get remote.origin.url`.chomp end |
#whoami ⇒ Object
10 11 12 |
# File 'lib/jarbs/manifest_helpers.rb', line 10 def whoami @whoami ||= `whoami`.chomp end |
#write_package(manifest, path) ⇒ Object
4 5 6 7 8 |
# File 'lib/jarbs/manifest_helpers.rb', line 4 def write_package(manifest, path) File.open(File.join(path, 'package.json'), 'w') do |f| f.write JSON.pretty_generate(manifest) end end |