tsc-files
tsc-files copied to clipboard
File can be left over if process is terminated before cleanup happens
Problem: the process might be terminated before the temporary config cleanup is done
https://github.com/gustavopch/tsc-files/blob/27a82464f2c0ff26ccb5b5b152b589aa580bd5a6/lib/index.js#L54
When that happens - and I've had that happen multiple times e.g. when hitting Ctrl-C
(SIGINT
) on a parent process - the file will not be cleaned up properly.
Solution: attach listeners on termination signals for cleaning up the file when the process exits (https://nodejs.org/api/process.html#signal-events)
I plan to open a pull request for this soon
I have just stumbled on this issue. The possible PR is in my fork of your repo: https://github.com/gustavopch/tsc-files/pull/48
Could either https://github.com/gustavopch/tsc-files/pull/28 or https://github.com/gustavopch/tsc-files/pull/48 be checked and merged so this issue can be resolved?
Fixed in https://github.com/gustavopch/tsc-files/releases/tag/v1.1.4. Sorry for the long delay.