Closed haydenbleasel closed 8 years ago
Sorry about the multiple commits - my linter is wrecked at the moment and doesn't pick up on undefined variables or naming conflicts.
Sorry for the late response. Nice catch :+1:. It is true that something should be done about creating the directories that the files are written into. I'm not sure about the implementation though.
The easiest way I think this could be done is by adding a step in here that creates the directories, so that it isn't necessary to implement this for each stylesheet generator and compositor.
Let me know wether you want to adapt your PR or want me to take a look at this. If you want to create a PR, please add tests for the functionality.
@selaux Heya, I'm not sure how to write unit tests and the code changes are only small, so perhaps it would be more useful for you to adapt the PR. Sorry about that :/
No worries, thanks for the bug-report :+1: . I will close this in favor of https://github.com/selaux/node-sprite-generator/pull/46.
Handling this common I/O issue would be helpful for a lot of users, especially when we’re writing an image to a new folder.