Class: Fig::Package::Path
- Inherits:
-
Object
- Object
- Fig::Package::Path
- Includes:
- Statement
- Defined in:
- lib/fig/package/path.rb
Overview
A statement that specifies or modifies a path environment variable, e.g. “append”, “path”, “add” (though those are all synonyms).
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(name, value) ⇒ Path
constructor
A new instance of Path.
- #unparse(indent) ⇒ Object
Methods included from Statement
Constructor Details
#initialize(name, value) ⇒ Path
Returns a new instance of Path.
15 16 17 18 |
# File 'lib/fig/package/path.rb', line 15 def initialize(name, value) @name = name @value = value end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
13 14 15 |
# File 'lib/fig/package/path.rb', line 13 def name @name end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
13 14 15 |
# File 'lib/fig/package/path.rb', line 13 def value @value end |
Instance Method Details
#unparse(indent) ⇒ Object
20 21 22 |
# File 'lib/fig/package/path.rb', line 20 def unparse(indent) "#{indent}append #{name}=#{value}" end |