Skip to content
This repository has been archived by the owner on Aug 16, 2022. It is now read-only.

Commit

Permalink
chore(tools): fix cannot find module ../loaders/env.cjs
Browse files Browse the repository at this point in the history
  • Loading branch information
unicornware committed Oct 10, 2021
1 parent 28ef66d commit edd1eb2
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions tools/cli/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,6 @@ const CWD: string = process.cwd()
/** @property {string[]} ENV_CHOICES - Build environment options */
const ENV_CHOICES: BuildOptions['env'][] = ['production', 'test', 'development']

/** @property {string} PWD - Root project working directory */
const PWD: string = process.env.PROJECT_CWD as string

/** @property {Argv<BuildOptions>} args - CLI arguments parser */
const args = yargs(hideBin(process.argv))
.usage('$0 [options]')
Expand Down Expand Up @@ -189,7 +186,7 @@ async function build(): Promise<void> {

try {
// Set environment variables
exec(`node ${PWD}/tools/cli/loadenv.cjs -c ${argv.env}`, argv.dryRun)
exec(`node ./tools/cli/loadenv.cjs -c ${argv.env}`, argv.dryRun)
logger(argv, `set ${argv.env} environment variables`)

// Build project, convert output extensions, create bundles
Expand Down

0 comments on commit edd1eb2

Please sign in to comment.