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
11 12 13 |
# File 'lib/terraspace/compiler/dsl/syntax/helpers/common.rb', line 11 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"
21 22 23 24 25 |
# File 'lib/terraspace/compiler/dsl/syntax/helpers/common.rb', line 21 def terraspace_command(separator=' ') args = Terraspace.argv[0..1] || [] command = ["terraspace"] + args command.join(separator) end |
#var ⇒ Object
6 7 8 |
# File 'lib/terraspace/compiler/dsl/syntax/helpers/common.rb', line 6 def var Meta::Var.new end |