diff options
Diffstat (limited to 'src/ipcMain')
-rw-r--r-- | src/ipcMain/constants.ts | 2 | ||||
-rw-r--r-- | src/ipcMain/extensions.ts | 9 | ||||
-rw-r--r-- | src/ipcMain/index.ts | 9 | ||||
-rw-r--r-- | src/ipcMain/updater.ts | 9 |
4 files changed, 16 insertions, 13 deletions
diff --git a/src/ipcMain/constants.ts b/src/ipcMain/constants.ts index 18726fc..7133757 100644 --- a/src/ipcMain/constants.ts +++ b/src/ipcMain/constants.ts @@ -16,8 +16,8 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ -import { join } from "path"; import { app } from "electron"; +import { join } from "path"; export const DATA_DIR = process.env.VENCORD_USER_DATA_DIR ?? ( process.env.DISCORD_USER_DATA_DIR diff --git a/src/ipcMain/extensions.ts b/src/ipcMain/extensions.ts index 9bebdaf..d676f22 100644 --- a/src/ipcMain/extensions.ts +++ b/src/ipcMain/extensions.ts @@ -16,13 +16,14 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ -import https from "https"; -import { mkdir, rm, writeFile, access } from "fs/promises"; +import { session } from "electron"; +import { unzip } from "fflate"; import { constants as fsConstants } from "fs"; +import { access,mkdir, rm, writeFile } from "fs/promises"; +import https from "https"; import { join } from "path"; + import { DATA_DIR } from "./constants"; -import { unzip } from "fflate"; -import { session } from "electron"; import { crxToZip } from "./crxToZip"; const extensionCacheDir = join(DATA_DIR, "ExtensionCache"); diff --git a/src/ipcMain/index.ts b/src/ipcMain/index.ts index d815142..958728a 100644 --- a/src/ipcMain/index.ts +++ b/src/ipcMain/index.ts @@ -16,17 +16,18 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ +import "./updater"; + +import monacoHtml from "@fileContent/../components/monacoWin.html;base64"; import { app, BrowserWindow, desktopCapturer, ipcMain, shell } from "electron"; import { mkdirSync, readFileSync, watch } from "fs"; import { open, readFile, writeFile } from "fs/promises"; import { join } from "path"; + import { debounce } from "../utils/debounce"; import IpcEvents from "../utils/IpcEvents"; -import monacoHtml from "@fileContent/../components/monacoWin.html;base64"; - -import "./updater"; import { Queue } from "../utils/Queue"; -import { QUICKCSS_PATH, ALLOWED_PROTOCOLS, SETTINGS_DIR, SETTINGS_FILE } from "./constants"; +import { ALLOWED_PROTOCOLS, QUICKCSS_PATH, SETTINGS_DIR, SETTINGS_FILE } from "./constants"; diff --git a/src/ipcMain/updater.ts b/src/ipcMain/updater.ts index a1da8a7..6987916 100644 --- a/src/ipcMain/updater.ts +++ b/src/ipcMain/updater.ts @@ -16,13 +16,14 @@ * along with this program. If not, see <https://www.gnu.org/licenses/>. */ +import { execFile as cpExecFile } from "child_process"; +import { createHash } from "crypto"; import { ipcMain } from "electron"; +import { createReadStream } from "fs"; +import { join } from "path"; import { promisify } from "util"; + import IpcEvents from "../utils/IpcEvents"; -import { execFile as cpExecFile } from "child_process"; -import { join } from "path"; -import { createReadStream } from "fs"; -import { createHash } from "crypto"; const VENCORD_SRC_DIR = join(__dirname, ".."); |