[!NOTE]
This package is ESM-only.
npm install roblox-studio-pathutil
import { getRobloxStudioPath } from 'roblox-studio-pathutil';
const robloxStudioPath = await getRobloxStudioPath();
On WSL, Roblox Studio root path is required since /mnt/c/...
cannot be automatically resolved
const robloxStudioPath = await getRobloxStudioPath(path.resolve(process.env.LOCALAPPDATA, 'Roblox'));
Or, set ROBLOX_STUDIO_PATH
enviroment variable.
The same enviroment name as roblox_install is used.
export ROBLOX_STUDIO_PATH="$LOCALAPPDATA/Roblox"
This env var is automatically checked so not need to pass it to getRobloxStudioPath
await getRobloxStudioPath();
// Is equivalent to
await getRobloxStudioPath(process.env.ROBLOX_STUDIO_PATH);
Put this into ~/.zshenv
or other shell equivalent for convinience (assuming LOCALAPPDATA is /mnt/c/Users/<user>/...
).
- Fix macOS paths