Skip to content

Commit

Permalink
fix: fix path error
Browse files Browse the repository at this point in the history
Signed-off-by: zxypro1 <1018995004@qq.com>
  • Loading branch information
zxypro1 committed Oct 16, 2024
1 parent f15fe6a commit 0696fbe
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion packages/engine/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@serverless-devs/engine",
"version": "0.1.5-beta.6",
"version": "0.1.5-beta.7",
"description": "a engine lib for serverless-devs",
"main": "lib/index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion packages/load-application/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@serverless-devs/load-application",
"version": "0.0.15-beta.3",
"version": "0.0.15-beta.4",
"description": "load application for serverless-devs",
"main": "lib/index.js",
"scripts": {
Expand Down
6 changes: 3 additions & 3 deletions packages/load-application/src/v3.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,19 +137,19 @@ class LoadApplication {
const newData = parse({ appName }, data);
fs.writeFileSync(this.spath, newData, 'utf-8');
} else {
const data = fs.readFileSync(this.getExtend(this.spath), 'utf-8');
const data = fs.readFileSync(path.join(this.filePath, this.getExtend(this.spath)), 'utf-8');
const { appName } = this.options;
if (isEmpty(appName)) return;
const newData = parse({ appName }, data);
fs.writeFileSync(this.getExtend(this.spath), newData, 'utf-8');
fs.writeFileSync(path.join(this.filePath, this.getExtend(this.spath)), newData, 'utf-8');
}
}

private async parseTemplateYaml(postData: Record<string, any>) {
if (isEmpty(this.publishData)) return;
this.publishData = { ...this.publishData, ...postData };
if (!isEmpty(this.getExtend(this.spath))) {
this.doArtTemplate(this.getExtend(this.spath));
this.doArtTemplate(path.join(this.filePath, this.getExtend(this.spath)));
}
return this.doArtTemplate(this.spath);
}
Expand Down

0 comments on commit 0696fbe

Please sign in to comment.