lapis
lapis copied to clipboard
add a --config option
~~This is my last issue for today. I promise.~~ I am so, so sorry!
One of the first things I tend to do when creating a new project is making a config.lua
file, which requires me to open the lapis reference and copy the template file. Since this is such a common task, why not add a --config
option to lapis to automatically generate an empty config file (pretty much like --git
and --tup
work)
-- I don't do moonscript, but by the magic of Ctrl+C Ctrl+V this code should™ be OK
if flags.config
if flags.lua
@write_file_safe "config.lua", require("lapis.cmd.templates.config_lua") flags
else
@write_file_safe "config.moon", require("lapis.cmd.templates.config_moon") flags
Something like this? https://github.com/CriztianiX/lapis/commit/b9667ee49e54301bb73b909f12541630801035bd
I agree we should have new
create a config file. I'm fine with it being on by default too
https://github.com/leafo/lapis/pull/505
Any thoughts / progress on this?