Skip to content

Commit

Permalink
- Allow import_gem to have no path and import all
Browse files Browse the repository at this point in the history
  • Loading branch information
DannyBen committed Jan 26, 2023
1 parent dc4106b commit 4f8c8e0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/runfile/concerns/dsl.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ def import(pathspec, context = nil)

def import_gem(pathspec, context = nil)
gem_name, glob = pathspec.split('/', 2)
glob ||= '*'
path = GemFinder.find gem_name, glob
imports[path] = context
end
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
title 'The New Runfile'
summary 'Testing the new Runfile'

import_gem 'sample_import_gem', 'docker', "error here, must be a hash"
import_gem 'sample_import_gem', image_name: 'my/image'

usage "say MESSAGE"
action 'say' do |args|
Expand Down

0 comments on commit 4f8c8e0

Please sign in to comment.