From 486f541ada68648ea2a98c35e77139fe37b9eb02 Mon Sep 17 00:00:00 2001 From: Pierre Seznec Date: Fri, 10 Jan 2020 11:26:54 +0100 Subject: [PATCH] chore: exclude folders from being loaded as commands --- src/plugin.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugin.ts b/src/plugin.ts index 58126d8f..c894da14 100644 --- a/src/plugin.ts +++ b/src/plugin.ts @@ -225,7 +225,7 @@ export class Plugin implements IPlugin { this._debug(`loading IDs from ${this.commandsDir}`) const patterns = [ '**/*.+(js|ts)', - '!**/*.+(d.ts|test.ts|test.js|spec.ts|spec.js)', + '!**/(*.+(d.ts|test.ts|test.js|spec.ts|spec.js)|__*__/*)', ] const ids = globby.sync(patterns, {cwd: this.commandsDir}) .map(file => {