mirror of
https://github.com/MercuryWorkshop/adrift.git
synced 2025-05-13 14:20:01 -04:00
recursive dirs
This commit is contained in:
parent
3f4362e330
commit
b87e3b2644
1 changed files with 1 additions and 1 deletions
|
@ -3,6 +3,6 @@ import fs from "fs";
|
|||
export function datadir(): string {
|
||||
let base = (process.env.APPDATA || (process.platform == 'darwin' ? process.env.HOME + '/Library/Preferences' : process.env.HOME + "/.config")) + "/adrift-server"
|
||||
if (!fs.existsSync(base))
|
||||
fs.mkdirSync(base);
|
||||
fs.mkdirSync(base, { recursive: true });
|
||||
return base;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue