diff --git a/package.json b/package.json index 96e61b2b3..f483384c7 100644 --- a/package.json +++ b/package.json @@ -12,6 +12,7 @@ "linter-precommit": "eslint --fix --ext .js --ext .ts", "lint-staged": "lint-staged", "lint-ci": "eslint . --max-warnings=0 --ext .js --ext .ts", + "build-translation-templates": "lerna run build-translation-templates", "preinstall": "git config core.hookspath .githooks", "postinstall": "npm run build" }, diff --git a/packages/build-tool/src/main.ts b/packages/build-tool/src/main.ts index 38cdb13cf..876944a8a 100755 --- a/packages/build-tool/src/main.ts +++ b/packages/build-tool/src/main.ts @@ -8,7 +8,7 @@ import buildTranslationTemplates from './buildTranslationTemplates'; import { BuildConfig, BuildMode, BundledFileRecord, TranslationSourcePair } from './types'; import compileSCSS from './compileSCSS'; -type BuildCommand = BuildMode|'build-translation-template'; +type BuildCommand = BuildMode|'build-translation-templates'; // TODO: These currently assume that build-tool is private to js-draw. const scriptDir = realpathSync(path.resolve(__dirname)); @@ -20,7 +20,7 @@ const isBuildMode = (a: string): a is BuildMode => { }; const isBuildCommand = (a: string): a is BuildCommand => { - return isBuildMode(a) || a === 'build-translation-template'; + return isBuildMode(a) || a === 'build-translation-templates'; }; const printUsage = () => { @@ -217,7 +217,7 @@ const main = async () => { console.log('Done.'); } - if (buildMode === 'build-translation-template') { + if (buildMode === 'build-translation-templates') { console.log('Building translation templates...'); buildTranslationTemplates(config); } else { diff --git a/packages/js-draw/package.json b/packages/js-draw/package.json index 004c98bff..e79390bd9 100644 --- a/packages/js-draw/package.json +++ b/packages/js-draw/package.json @@ -59,7 +59,7 @@ "dist": "npm run build && npm run dist-test", "build": "rm -rf ./dist/* && mkdir -p dist && build-tool build", "watch": "rm -rf ./dist/* && mkdir -p dist && build-tool watch", - "build-translation-template": "build-tool build-translation-template", + "build-translation-templates": "build-tool build-translation-templates", "prepack": "npm run dist && cd ../../ && npm run test && cd packages/js-draw && ts-node tools/copyREADME.ts copy", "postpack": "ts-node tools/copyREADME.ts revert" },