Cube-Solutions / composer-dist-installer

Install template files (.dist) automatically on project setup with Composer. Framework-agnostic.
MIT License
2 stars 3 forks source link

Two missing features #3

Open dstollie opened 8 years ago

dstollie commented 8 years ago

I Really love this package and though it contains alot I need im still missing two important features

  1. If I have multiple dist files and I already installed them. Composer asks me if I want to override my current config file and back it up as an old one. The only problem here is that the message does not tell me about which file it's talking about. I know its chronological in my composer.json but this would be a simple fix and clears it somewhat up.
  2. Sometimes I want to reuse some variables I define in my dist file. Is there a possiblity to add this?

What are your ideas for these two features have you already thought about it or are you already working on it? SOO much questions ;p

Thanks

Dennis

gsomoza commented 8 years ago

Thanks for the suggestions, they're very reasonable. And we're glad you like the package!

  1. Like you said this should be a relatively easy fix and would indeed make things clearer.
  2. I agree this would be great, but I think it escapes a bit the scope of the "Generic" processor we have in place, which is really just meant for simple replacements. So this feature might find a better home as part of a new processor, for example a Twig processor would have variable support built-in as part of the Twig language (see docs on the set tag).

There's currently no development going on for these features. Would you like to get involved with that?

dstollie commented 8 years ago

I Created a new processor which supports Twig like you suggested. The working example is still on my local machine but this is the gist:

https://gist.github.com/dstollie/6ebd46721d31ed009314

Can you take a look at it and give some feedback? If ur okay with it I will create a pr somewhere these days

gsomoza commented 8 years ago

This is awesome, having a Twig processor will take this library to a whole new level! :+1:

Left some feedback on the gist. Looking forward to your PR!