1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-12-21 09:38:01 +02:00

Tools: Allow the server clean command to run on Windows

This commit is contained in:
Laurent Cozic 2021-12-20 16:48:40 +01:00
parent 7f64fbfd9b
commit a7a2dfbbd0
2 changed files with 11 additions and 4 deletions

View File

@ -3,12 +3,19 @@ const utils = require('@joplin/tools/gulp/utils');
const compilePackageInfo = require('@joplin/tools/compilePackageInfo');
const fs = require('fs-extra');
const distDir = `${__dirname}/dist`;
const tasks = {
compilePackageInfo: {
fn: async () => {
const targetDir = `${__dirname}/dist`;
await fs.mkdirp(targetDir);
await compilePackageInfo(`${__dirname}/package.json`, `${targetDir}/packageInfo.js`);
await fs.mkdirp(distDir);
await compilePackageInfo(`${__dirname}/package.json`, `${distDir}/packageInfo.js`);
},
},
clean: {
fn: async () => {
await fs.remove(distDir);
},
},
};

View File

@ -16,7 +16,7 @@
"test": "jest --verbose=false",
"test-ci": "yarn test",
"test-debug": "node --inspect node_modules/.bin/jest -- --verbose=false",
"clean": "rm -rf dist/",
"clean": "gulp clean",
"stripeListen": "stripe listen --forward-to http://joplincloud.local:22300/stripe/webhook",
"watch": "tsc --watch --project tsconfig.json"
},