I'd like to rewrite the entire dancer command line app. I'm thinking of something akin to App::Cmd (whether it's actually used or not in the end) with multiple possible commands, being able to manage a Dancer app instead of just scaffolding one.
I'd like to collect thoughts on what this might support. Obviously creating a new application, but what else? Stuff like sanity checks, adding modules, setting up various default configurations (dzil?), set up packaging (support via FatPacker or Carton) - these are some ideas.
What do you think?
It would be a good idea to make it easily extensible with plugins, allowing them to add new commands. I was thinking of this back when I was working on Dancer::Plugin::Auth::Basic and Dancer::Plugin::Auth::Htpasswd -- I thought it would be useful if the command line app allowed the user to generate an encrypted passphrase or create a .htpasswd file, without the use of other tools.
Ah, not a blog entry, an advent calendar entry: http://advent.perldancer.org/2012/10 :-)
@odyniec the way I want to write it (using App::Cmd) would allow for additional commands to be written as plugins very easily. I like the ideas you added.
@yanick so basically we're talking about the ability to create apps and to edit them.
@ikruglov has started work on it. It's essentially done but needs thorough review.
It's available in the master branch here: https://github.com/ikruglov/Dancer2/commits/master.
@ikruglov, please add any comments you may have here as well.
I should say that script/dancer2-cli rely on File::ShareDir::dist_dir to return folder where the installer copied all templates files to (share/skel). But i didn't actually test that part. So, if it fails, copy 'share/skel' into whetever path File::ShareDir::dist_dir returns in your case.
Rewrite dancer2 cli #371
rename dancer2-cli, add DANCER2_SHARE_DIR #371
include encoding fix from samitbadle #371
fix issue with broken templates in share/skel #371
This issue was fixed by PR #506 by @ikruglov.
Thank you! :)