Module: Terraspace::Compiler::Dsl::Syntax::Helpers::Common
- Extended by:
- Memoist
- Defined in:
- lib/terraspace/compiler/dsl/syntax/helpers/common.rb
Constant Summary collapse
- Meta =
Terraspace::Compiler::Dsl::Meta
Instance Method Summary collapse
- #local ⇒ Object
-
#terraspace_command(separator = ' ') ⇒ Object
Only show the first 2 args and now the options.
- #var ⇒ Object
Instance Method Details
#local ⇒ Object
12 13 14 |
# File 'lib/terraspace/compiler/dsl/syntax/helpers/common.rb', line 12 def local Meta::Local.new end |
#terraspace_command(separator = ' ') ⇒ Object
Only show the first 2 args and now the options. Examples:
terraspace_command => "terraspace up demo"
terraspace_command('-') => "terraspace-up-demo"
22 23 24 25 26 |
# File 'lib/terraspace/compiler/dsl/syntax/helpers/common.rb', line 22 def terraspace_command(separator=' ') args = ARGV[0..1] || [] command = ["terraspace"] + args command.join(separator) end |
#var ⇒ Object
7 8 9 |
# File 'lib/terraspace/compiler/dsl/syntax/helpers/common.rb', line 7 def var Meta::Var.new end |