tmrts / boilr

:zap: boilerplate template manager that generates files or directories from template repositories
Apache License 2.0
1.73k stars 119 forks source link

Conditional creation of directories #56

Open iancmcc opened 7 years ago

iancmcc commented 7 years ago

Is there a way to conditionally create a directory, based on a parameter? For example:

.
├── project.json
└── template
    └── LICENSE
    ├── README.md
    └── {{if eq ConditionalDir "conditional"}}

With a project.json of:

{
    "ConditionalDir": false
}

This of course wouldn't work, being an invalid template, but is there a way? I have a Go package I often don't want to include.

stefanwalther commented 7 years ago

In addition to this question, I am also very interested in conditionally creating files ... ;-)