Add support for (optional) GITHUB_TOKEN env variable
This commit is contained in:
9
scripts/utils/dotenv.ts
Normal file
9
scripts/utils/dotenv.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
/*
|
||||
* SPDX-License-Identifier: GPL-3.0
|
||||
* Vencord Desktop, a desktop app aiming to give you a snappier Discord Experience
|
||||
* Copyright (c) 2023 Vendicated and Vencord contributors
|
||||
*/
|
||||
|
||||
import { config } from "dotenv";
|
||||
|
||||
config();
|
||||
18
scripts/utils/spawn.mts
Normal file
18
scripts/utils/spawn.mts
Normal file
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
* SPDX-License-Identifier: GPL-3.0
|
||||
* Vencord Desktop, a desktop app aiming to give you a snappier Discord Experience
|
||||
* Copyright (c) 2023 Vendicated and Vencord contributors
|
||||
*/
|
||||
|
||||
import { spawn as spaaawn, SpawnOptions } from "child_process";
|
||||
import { join } from "path";
|
||||
|
||||
const EXT = process.platform === "win32" ? ".cmd" : "";
|
||||
|
||||
const OPTS: SpawnOptions = {
|
||||
stdio: "inherit"
|
||||
};
|
||||
|
||||
export function spawnNodeModuleBin(bin: string, args: string[]) {
|
||||
spaaawn(join("node_modules", ".bin", bin + EXT), args, OPTS);
|
||||
}
|
||||
Reference in New Issue
Block a user