diff --git a/lib/integration/Target.js b/lib/integration/Target.js index 1bea515..5bf271c 100644 --- a/lib/integration/Target.js +++ b/lib/integration/Target.js @@ -161,7 +161,7 @@ export default class Target extends Plugin { const pluginTypeFolder = await this.getTypeFolder() if (this.isLocalSource) { await fs.ensureDir(path.resolve(this.cwd, 'src', pluginTypeFolder)) - const pluginPath = path.resolve(this.cwd, 'src', pluginTypeFolder, this.name) + const pluginPath = path.resolve(this.cwd, 'src', pluginTypeFolder, this.packageName) await fs.rm(pluginPath, { recursive: true, force: true }) await fs.copy(this.sourcePath, pluginPath, { recursive: true }) const bowerJSON = await fs.readJSON(path.join(pluginPath, 'bower.json')) @@ -177,7 +177,7 @@ export default class Target extends Plugin { const repoDetails = await this.getRepositoryUrl() if (!repoDetails) throw new Error('Error: Plugin repository url could not be found.') await fs.ensureDir(path.resolve(this.cwd, 'src', pluginTypeFolder)) - const pluginPath = path.resolve(this.cwd, 'src', pluginTypeFolder, this.name) + const pluginPath = path.resolve(this.cwd, 'src', pluginTypeFolder, this.packageName) await fs.rm(pluginPath, { recursive: true, force: true }) const url = repoDetails.url.replace(/^git:\/\//, 'https://') try { @@ -206,7 +206,7 @@ export default class Target extends Plugin { } // bower install const outputPath = path.join(this.cwd, 'src', pluginTypeFolder) - const pluginPath = path.join(outputPath, this.name) + const pluginPath = path.join(outputPath, this.packageName) try { await fs.rm(pluginPath, { recursive: true, force: true }) } catch (err) {