electron-forge-maker-innosetup 0.3.1 → 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,9 +8,6 @@ export default class MakerInnosetup extends MakerBase<MakerInnosetupConfig> {
8
8
  name: string;
9
9
  defaultPlatforms: ForgePlatform[];
10
10
  private scriptGenerator;
11
- private buildDir;
12
- private projectDir;
13
- private assetsDir;
14
11
  /**
15
12
  * 获取项目根目录
16
13
  */
@@ -54,19 +54,19 @@ class MakerInnosetup extends maker_base_1.default {
54
54
  * 获取项目根目录
55
55
  */
56
56
  getProjectDir() {
57
- return this.projectDir || this.config?.paths?.projectDir || process.cwd();
57
+ return this.config?.paths?.projectDir || process.cwd();
58
58
  }
59
59
  /**
60
60
  * 获取构建目录
61
61
  */
62
62
  getBuildDir() {
63
- return this.buildDir || this.config?.paths?.buildDir;
63
+ return this.config?.paths?.buildDir;
64
64
  }
65
65
  /**
66
66
  * 获取资源目录
67
67
  */
68
68
  getAssetsDir() {
69
- return this.assetsDir || this.config?.paths?.assetsDir || "assets";
69
+ return this.config?.paths?.assetsDir || "assets";
70
70
  }
71
71
  constructor(config = {}, platforms) {
72
72
  // 默认启用相对路径解析
@@ -534,6 +534,11 @@ class MakerInnosetup extends maker_base_1.default {
534
534
  */
535
535
  async make(options) {
536
536
  const { appName, dir, makeDir, targetArch, packageJSON } = options;
537
+ this.config.paths = {
538
+ buildDir: dir,
539
+ ...this.config.config,
540
+ };
541
+ // 设置默认构建目录
537
542
  const appVersion = packageJSON.version || "1.0.0";
538
543
  const archId = this.getArchIdentifier(targetArch);
539
544
  console.log(`Creating Innosetup installer for ${appName} ${appVersion} (${targetArch})...`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "electron-forge-maker-innosetup",
3
- "version": "0.3.1",
3
+ "version": "0.3.3",
4
4
  "description": "An Electron Forge maker for creating Windows installers using Innosetup with full TypeScript support",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",