|
1 | | -import type { ForgeConfig } from "@electron-forge/shared-types"; |
2 | | -import { MakerSquirrel } from "@electron-forge/maker-squirrel"; |
3 | | -import { MakerDMG } from "@electron-forge/maker-dmg"; |
4 | | -import { MakerZIP } from "@electron-forge/maker-zip"; |
5 | | -import { MakerDeb } from "@electron-forge/maker-deb"; |
6 | | -import { MakerRpm } from "@electron-forge/maker-rpm"; |
7 | | -import { VitePlugin } from "@electron-forge/plugin-vite"; |
8 | | -import { FusesPlugin } from "@electron-forge/plugin-fuses"; |
9 | | -import { FuseV1Options, FuseVersion } from "@electron/fuses"; |
10 | | -import { PublisherS3 } from "@electron-forge/publisher-s3"; |
| 1 | +/* eslint-disable @typescript-eslint/no-require-imports, @typescript-eslint/no-explicit-any */ |
| 2 | +const { MakerSquirrel } = require("@electron-forge/maker-squirrel"); |
| 3 | +const { MakerDMG } = require("@electron-forge/maker-dmg"); |
| 4 | +const { MakerZIP } = require("@electron-forge/maker-zip"); |
| 5 | +const { MakerDeb } = require("@electron-forge/maker-deb"); |
| 6 | +const { MakerRpm } = require("@electron-forge/maker-rpm"); |
| 7 | +const { VitePlugin } = require("@electron-forge/plugin-vite"); |
| 8 | +const { FusesPlugin } = require("@electron-forge/plugin-fuses"); |
| 9 | +const { FuseV1Options, FuseVersion } = require("@electron/fuses"); |
| 10 | +const { PublisherS3 } = require("@electron-forge/publisher-s3"); |
11 | 11 |
|
12 | | -import { type OsxSignOptions } from "@electron/packager/dist/types"; |
13 | | -import { type NotaryToolCredentials } from "@electron/notarize/lib/types"; |
14 | | - |
15 | | -import { execSync } from "child_process"; |
16 | | -import path from "path"; |
17 | | -import fs from "fs"; |
18 | | -import os from "os"; |
| 12 | +const { execSync } = require("child_process"); |
| 13 | +const path = require("path"); |
| 14 | +const fs = require("fs"); |
| 15 | +const os = require("os"); |
19 | 16 |
|
20 | 17 | // Make sure build path exists |
21 | 18 | const buildPath = path.join(__dirname, "build"); |
@@ -127,12 +124,12 @@ const mimeTypeScheme = |
127 | 124 | : "x-scheme-handler/cyd-dev"; |
128 | 125 |
|
129 | 126 | // macOS signing and notarization options |
130 | | -let osxSign: OsxSignOptions | undefined; |
131 | | -let osxNotarize: NotaryToolCredentials | undefined; |
| 127 | +let osxSign: any | undefined; |
| 128 | +let osxNotarize: any | undefined; |
132 | 129 | if (process.env.MACOS_RELEASE === "true") { |
133 | 130 | osxSign = { |
134 | 131 | identity: "Developer ID Application: Lockdown Systems LLC (G762K6CH36)", |
135 | | - optionsForFile: (filePath) => { |
| 132 | + optionsForFile: (filePath: string) => { |
136 | 133 | const entitlementDefault = path.join( |
137 | 134 | assetsPath, |
138 | 135 | "entitlements", |
@@ -178,7 +175,7 @@ if (process.env.MACOS_RELEASE === "true") { |
178 | 175 | }; |
179 | 176 | } |
180 | 177 |
|
181 | | -const config: ForgeConfig = { |
| 178 | +const config = { |
182 | 179 | packagerConfig: { |
183 | 180 | name: process.env.CYD_ENV == "prod" ? "Cyd" : "Cyd Dev", |
184 | 181 | executableName: |
@@ -368,4 +365,4 @@ const config: ForgeConfig = { |
368 | 365 | ], |
369 | 366 | }; |
370 | 367 |
|
371 | | -export default config; |
| 368 | +module.exports = config; |
0 commit comments