This is an automated email from the ASF dual-hosted git repository.
shanedell pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/daffodil-vscode.git
The following commit(s) were added to refs/heads/main by this push:
new ea58dd3 Remove temporary files on debug instance termination
ea58dd3 is described below
commit ea58dd3c1135355baf5f4813a41bcd94131824f6
Author: Michael Hoke <[email protected]>
AuthorDate: Fri Apr 29 14:26:28 2022 -0400
Remove temporary files on debug instance termination
Address review comments
Closes #102
---
src/infoset.ts | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/infoset.ts b/src/infoset.ts
index b8c739b..9505e2b 100644
--- a/src/infoset.ts
+++ b/src/infoset.ts
@@ -68,6 +68,11 @@ export async function activate(ctx: vscode.ExtensionContext)
{
)
ctx.subscriptions.push(
vscode.debug.onDidTerminateDebugSession(async (s) => {
+ if (sid !== undefined) {
+ let path = tmp(sid)
+ fs.rmSync(`${path}`, { force: true })
+ fs.rmSync(`${path}.prev`, { force: true })
+ }
sid = undefined
await openInfosetFilePrompt()
})