hotfix injector for ptb/canary/dev (#330)

This commit is contained in:
megumin
2022-12-14 22:35:02 +00:00
committed by GitHub
parent a67db11dc2
commit fea8c60a40
3 changed files with 124 additions and 5 deletions

View File

@ -21,6 +21,20 @@ const readline = require("readline");
const fs = require("fs");
const menu = require("console-menu");
function pathToBranch(dir) {
dir = dir.toLowerCase();
if (dir.endsWith("development")) {
return "development";
}
if (dir.endsWith("canary")) {
return "canary";
}
if (dir.endsWith("ptb")) {
return "ptb";
}
return "stable";
}
const BRANCH_NAMES = [
"Discord",
"DiscordPTB",
@ -329,6 +343,7 @@ function getLinuxDirs() {
}
module.exports = {
pathToBranch,
BRANCH_NAMES,
MACOS_DISCORD_DIRS,
LINUX_DISCORD_DIRS,