linux support
This commit is contained in:
parent
246cdbb8d2
commit
994fb34dbd
2 changed files with 12 additions and 1 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "asajs",
|
"name": "asajs",
|
||||||
"version": "4.0.5-indev",
|
"version": "4.0.6-indev",
|
||||||
"description": "Create your Minecraft JSON-UI resource packs using JavaScript",
|
"description": "Create your Minecraft JSON-UI resource packs using JavaScript",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"Minecraft",
|
"Minecraft",
|
||||||
|
|
|
||||||
|
|
@ -173,6 +173,17 @@ export function getGamedataPath() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case "linux": {
|
||||||
|
const gamedata = path.join(process.env.HOME!, "\\.local\\share\\mcpelauncher\\games\\com.mojang")
|
||||||
|
if (fs.existsSync(gamedata)) return (pathinfo.gamepath = gamedata)
|
||||||
|
else {
|
||||||
|
return (pathinfo.gamepath = path.join(
|
||||||
|
process.env.HOME!,
|
||||||
|
"\\.var\\app\\io.mrarm.mcpelauncher\\data\\mcpelauncher\\games\\com.mojang",
|
||||||
|
))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
default: {
|
default: {
|
||||||
console.warn(`Your platform is not supported the install feature yet! \nYour OS version: ${os.version()}`)
|
console.warn(`Your platform is not supported the install feature yet! \nYour OS version: ${os.version()}`)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Reference in a new issue