From 2acdc3966d3a4086e3ad3cf8a1db0ba372984537 Mon Sep 17 00:00:00 2001 From: nomad-mystic Date: Thu, 14 Sep 2023 15:25:56 -0700 Subject: [PATCH 1/2] kpm: Fix packageRootDir path after dist refacctor --- package.json | 2 +- src/bin/commander-cli.ts | 2 +- src/utils/package-root.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 41c3729..55046f9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@nomadmystic/wordpress-scaffold-cli", - "version": "0.8.4", + "version": "0.8.5", "description": "This project is created to speed up WordPress development", "main": "index.js", "type": "module", diff --git a/src/bin/commander-cli.ts b/src/bin/commander-cli.ts index ea77aaa..b141dc9 100644 --- a/src/bin/commander-cli.ts +++ b/src/bin/commander-cli.ts @@ -93,7 +93,7 @@ class CommanderCli { private static callCommand = async (command: string): Promise => { try { const path: string = CommanderOptions[command].path as string; - const fullPath: string = `${packageRootDir}dist/${path}`; + const fullPath: string = `${packageRootDir}/dist/${path}`; // Bail early if (!fs.existsSync(fullPath)) { diff --git a/src/utils/package-root.ts b/src/utils/package-root.ts index b88cd3f..77dfb32 100644 --- a/src/utils/package-root.ts +++ b/src/utils/package-root.ts @@ -7,7 +7,7 @@ const filename: string = fileURLToPath(import.meta.url); const dirname: string = path.dirname(filename); const config = { - packageRootDir: `${path.join(dirname, '../../../')}`, + packageRootDir: `${path.join(dirname, '../../')}`, }; export let packageRootDir: string = config.packageRootDir; From 94636aa16a3bd3e59b2d999e82e0704ebe0cfdea Mon Sep 17 00:00:00 2001 From: nomad-mystic Date: Thu, 14 Sep 2023 15:25:56 -0700 Subject: [PATCH 2/2] kpm: Fix packageRootDir path after dist refactor --- package.json | 2 +- src/bin/commander-cli.ts | 2 +- src/utils/package-root.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 41c3729..55046f9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@nomadmystic/wordpress-scaffold-cli", - "version": "0.8.4", + "version": "0.8.5", "description": "This project is created to speed up WordPress development", "main": "index.js", "type": "module", diff --git a/src/bin/commander-cli.ts b/src/bin/commander-cli.ts index ea77aaa..b141dc9 100644 --- a/src/bin/commander-cli.ts +++ b/src/bin/commander-cli.ts @@ -93,7 +93,7 @@ class CommanderCli { private static callCommand = async (command: string): Promise => { try { const path: string = CommanderOptions[command].path as string; - const fullPath: string = `${packageRootDir}dist/${path}`; + const fullPath: string = `${packageRootDir}/dist/${path}`; // Bail early if (!fs.existsSync(fullPath)) { diff --git a/src/utils/package-root.ts b/src/utils/package-root.ts index b88cd3f..77dfb32 100644 --- a/src/utils/package-root.ts +++ b/src/utils/package-root.ts @@ -7,7 +7,7 @@ const filename: string = fileURLToPath(import.meta.url); const dirname: string = path.dirname(filename); const config = { - packageRootDir: `${path.join(dirname, '../../../')}`, + packageRootDir: `${path.join(dirname, '../../')}`, }; export let packageRootDir: string = config.packageRootDir;