Closed craigmonson closed 7 years ago
I was looking at this as well and there are a couple implementation options.
1) have an array of acceptable names to look through on each search, instead of the one. While simple, it may not be the most efficient and the test case will have to be modified
2) use a glob to pull in the files. This works, though this would technically allow for weird options for extensions like .colonize.yasdfghjkml
3) change it to just be .colonize with no extension. No real downsides other than the format is not implied through extension. Alternatively, this could follow the git model where you have a .colonize directory and then a config file(s) inside of that.
4) Change implementation to actually read the available files and then use a pattern match to select a valid file. Downside is really just that it's just a reimplementation
@craigmonson do you have a preference or thought on another way to do this?
Note: in #4 above, it's also less efficient due to having to collect each file
I think #1 is probably the way to go.
As they're both respected file extensions, we should allow for both.