From a2fd6998eef33c84de2acf4a42fea82f7da2c33b Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Mon, 27 May 2019 16:11:10 +0200 Subject: [PATCH] fix(core): update --- ts/tsdoc.cli.ts | 7 +++++++ ts/tsdoc.paths.ts | 1 + 2 files changed, 8 insertions(+) diff --git a/ts/tsdoc.cli.ts b/ts/tsdoc.cli.ts index 5108c12..0376fea 100644 --- a/ts/tsdoc.cli.ts +++ b/ts/tsdoc.cli.ts @@ -32,5 +32,12 @@ export const run = async () => { } }); + tsdocCli.addCommand('test').subscribe(argvArg => { + tsdocCli.trigger('typedoc'); + process.on('exit', async () => { + await plugins.smartfile.fs.remove(paths.publicDir); + }); + }); + tsdocCli.startParse(); }; diff --git a/ts/tsdoc.paths.ts b/ts/tsdoc.paths.ts index 3a14a6d..43af5ee 100644 --- a/ts/tsdoc.paths.ts +++ b/ts/tsdoc.paths.ts @@ -3,3 +3,4 @@ import * as plugins from './tsdoc.plugins'; export const packageDir = plugins.path.join(__dirname, '../'); export const cwd = process.cwd(); export const binDir = plugins.path.join(packageDir, './node_modules/.bin'); +export const publicDir = plugins.path.join(packageDir, './public');