Closed Aankhen closed 2 months ago
Whoops! It looks like I missed this. (I’m used to creating PRs, but not receiving them.) Sorry about that.
.Trash
” function because I accidentally resolved the wrong directory one time and deleted the entire test
folder! 🤦🏽♂️ I am still feeling a bit over-cautious about using rmdir*()
until this project becomes more mature.
.Trash
hack. If you come up with something that works for Windows—bonus points for linux!—I will gladly accept..gitignore
change in a separate PR.
No problem, it happens. I’ve opened #4 for the .gitignore addition.
I wrote my hack-y “move to
.Trash
” function because I accidentally resolved the wrong directory one time and deleted the entiretest
folder! 🤦🏽♂️ I am still feeling a bit over-cautious about usingrmdir*()
until this project becomes more mature.
How about using the tmp package to generate output directories, then? It can automatically remove them when the process exits.
The data file needed to export a function that returns a function.
I replaced the macOS-specific TRASH code with
rmdirSync
and added the output directories to .gitignore. I think there’s still something wrong with how I’m running the tests, though, because running npx eleventy in the stub directories shows me the right results but the tests for those stubs always say Eleventy produced no files, which I confirmed afterwards.I wasn’t able to get the Eleventy output by passing
ndjson
toexecuteBuild
, either.P.S.: Would you consider adding a .prettierrc.yaml? I had the devil of a time forcing tabs instead of spaces, not to mention maintaining the rest of your style, and I think that might be because Prettier has its own defaults. 😅