Estimated Mr. Sakamoto,
many thanks for your excellent extension, just what I was looking for.
Unfortunately, when I change the script, it is not reloaded.
I have no previous experience with VSCode plugins, but I managed to resolve the problem by adding a call to "require.resolve" in two lines in "loadAndRunMacro":
// Load the macro module into NodeRequire
delete require.cache[require.resolve(loadedMacroModulePath)];
const macroMod = require(require.resolve(macroModPath));
But it was perplexity.ai that suggested the fix and I have no idea why it works, so you'll want to review it.
Again, thanks for your work. Coming from Emacs, I can't understand why just running a few lines of script is not built into VSCode.
T. Hansen
Estimated Mr. Sakamoto,
many thanks for your excellent extension, just what I was looking for.
Unfortunately, when I change the script, it is not reloaded.
I have no previous experience with VSCode plugins, but I managed to resolve the problem by adding a call to "require.resolve" in two lines in "loadAndRunMacro":
But it was perplexity.ai that suggested the fix and I have no idea why it works, so you'll want to review it.
Again, thanks for your work. Coming from Emacs, I can't understand why just running a few lines of script is not built into VSCode.
T. Hansen