Closed nietaki closed 5 years ago
I think the problem here is this line: https://github.com/CrowdHailer/raxx_kit/blob/master/lib/raxx/kit.ex#L152-L156
This means that empty files are not written. This is done for things like the docker file where an empty file is returned from the template in the case the docker flag is false.
I suggest this means that all .dummy
files will get removed unless we add some content to them.
A .gitignore
is a smart solution, but we might end up with quite a few once we switch all the .dummy files
There's two slightly different issues here:
Empty dummy files (that get stripped on project generation) take care of 1. but not of 2. The .gitignore
file with a comment content takes care of 2 as well.
Currently we only use dummy files for creating the deps
and _build
directories, which I think is alright: they get generated on the user's machine, so if they're new to elixir they can see what the directory structure is going to be, but won't be committed to git and the project is not going to break if the directories are not there - they will be created on demand.
Bottom line is I think it works correctly right now, but we can remove the dummy files if it causes any confusion on the raxx_kit
contributor side - they're not essential.
also, I like the logic in the lines you linked to https://github.com/CrowdHailer/raxx_kit/blob/master/lib/raxx/kit.ex#L152-L156 , it's pretty intuitive to me, unless there's a good reason for it, I wouldn't change it just yet.
I was about to say but what if deps
or _build
is empty. But raxx at least will always be a dependency so that's not happening.
See comment in the gitignore file.
What basically happened to me is I created a project on one machine, it ran well, but when I cloned it on another, I couldn't start it, because the
migrations
directory didn't get picked up by git.This will fix it.