skx / marionette

Something like puppet, for the localhost only.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Values declared in include-files are not available.

skx opened this issue · comments

This is because we spawn a separate parser to process include-files.

Given this example file main.in:

include "temp.in"

shell {
    command => "echo ${value}",
}

And this include file, temp.in:

let value="Hello, world"

We'd expect:

$ marionette -verbose main.in
Hello, world
$

However we get nothing.

Solution:

  • Don't use a sub-parser. Keep all state in the same object (probably)?

Upon reflecton I think we'll move the variables out of the parser object, and create an environment package.

This will allow the CLI to define variables too, and will be cleaner.