valheim-oz-dsm 1.5.0 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -1
- package/dist/main.js +34 -41
- package/dist/main.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [1.5.1] - 2026-02-01
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
- Fixed Valheim server installing to wrong location (was installing directly to steamcmd Data folder instead of `steamapps/common/Valheim dedicated server`)
|
|
14
|
+
- Removed unnecessary custom path from `steamcmd.install()` call to use SteamCMD's default installation directory structure
|
|
15
|
+
|
|
10
16
|
## [1.5.0] - 2026-02-01
|
|
11
17
|
|
|
12
18
|
### Added
|
|
@@ -140,7 +146,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
140
146
|
- Platform detection for Windows, Linux, macOS
|
|
141
147
|
- Basic TUI framework with Ink
|
|
142
148
|
|
|
143
|
-
[Unreleased]: https://github.com/caleb-collar/land-of-oz-dsm-valheim/compare/v1.5.
|
|
149
|
+
[Unreleased]: https://github.com/caleb-collar/land-of-oz-dsm-valheim/compare/v1.5.1...HEAD
|
|
150
|
+
[1.5.1]: https://github.com/caleb-collar/land-of-oz-dsm-valheim/compare/v1.5.0...v1.5.1
|
|
144
151
|
[1.5.0]: https://github.com/caleb-collar/land-of-oz-dsm-valheim/compare/v1.4.3...v1.5.0
|
|
145
152
|
[1.4.3]: https://github.com/caleb-collar/land-of-oz-dsm-valheim/compare/v1.0.9...v1.4.3
|
|
146
153
|
[1.0.9]: https://github.com/caleb-collar/land-of-oz-dsm-valheim/compare/v1.0.8...v1.0.9
|
package/dist/main.js
CHANGED
|
@@ -1690,7 +1690,7 @@ function parseValue(value) {
|
|
|
1690
1690
|
}
|
|
1691
1691
|
|
|
1692
1692
|
// src/cli/commands/doctor.ts
|
|
1693
|
-
import
|
|
1693
|
+
import fs3 from "fs/promises";
|
|
1694
1694
|
import net from "net";
|
|
1695
1695
|
import path4 from "path";
|
|
1696
1696
|
import steamcmd4 from "@caleb-collar/steamcmd";
|
|
@@ -1891,7 +1891,6 @@ async function verifyValheimInstallation() {
|
|
|
1891
1891
|
}
|
|
1892
1892
|
|
|
1893
1893
|
// src/steamcmd/updater.ts
|
|
1894
|
-
import fs3 from "fs/promises";
|
|
1895
1894
|
import steamcmd3 from "@caleb-collar/steamcmd";
|
|
1896
1895
|
var VALHEIM_APP_ID = 896660;
|
|
1897
1896
|
function mapPhaseToStage2(phase) {
|
|
@@ -1908,7 +1907,6 @@ function mapPhaseToStage2(phase) {
|
|
|
1908
1907
|
}
|
|
1909
1908
|
}
|
|
1910
1909
|
async function installValheim(onProgress) {
|
|
1911
|
-
const { steamcmdDir } = getSteamPaths();
|
|
1912
1910
|
const report = (status) => {
|
|
1913
1911
|
onProgress?.(status);
|
|
1914
1912
|
};
|
|
@@ -1921,10 +1919,6 @@ async function installValheim(onProgress) {
|
|
|
1921
1919
|
});
|
|
1922
1920
|
throw new Error("SteamCMD is not installed");
|
|
1923
1921
|
}
|
|
1924
|
-
try {
|
|
1925
|
-
await fs3.mkdir(steamcmdDir, { recursive: true });
|
|
1926
|
-
} catch {
|
|
1927
|
-
}
|
|
1928
1922
|
report({
|
|
1929
1923
|
stage: "downloading",
|
|
1930
1924
|
progress: 0,
|
|
@@ -1933,7 +1927,6 @@ async function installValheim(onProgress) {
|
|
|
1933
1927
|
try {
|
|
1934
1928
|
await steamcmd3.install({
|
|
1935
1929
|
applicationId: VALHEIM_APP_ID,
|
|
1936
|
-
path: steamcmdDir,
|
|
1937
1930
|
onProgress: (p) => {
|
|
1938
1931
|
const stage = mapPhaseToStage2(p.phase);
|
|
1939
1932
|
const progress = p.percent ?? 0;
|
|
@@ -2014,7 +2007,7 @@ async function getInstalledVersion() {
|
|
|
2014
2007
|
// src/cli/commands/doctor.ts
|
|
2015
2008
|
async function exists(filePath) {
|
|
2016
2009
|
try {
|
|
2017
|
-
await
|
|
2010
|
+
await fs3.access(filePath);
|
|
2018
2011
|
return true;
|
|
2019
2012
|
} catch {
|
|
2020
2013
|
return false;
|
|
@@ -2162,9 +2155,9 @@ async function checkPermissions() {
|
|
|
2162
2155
|
const steamCmdDir = info2.directory;
|
|
2163
2156
|
const testFile = path4.join(steamCmdDir, ".oz-test-write");
|
|
2164
2157
|
try {
|
|
2165
|
-
await
|
|
2166
|
-
await
|
|
2167
|
-
await
|
|
2158
|
+
await fs3.mkdir(steamCmdDir, { recursive: true });
|
|
2159
|
+
await fs3.writeFile(testFile, "test");
|
|
2160
|
+
await fs3.unlink(testFile);
|
|
2168
2161
|
return {
|
|
2169
2162
|
name: "Directory Permissions",
|
|
2170
2163
|
status: "pass",
|
|
@@ -2275,7 +2268,7 @@ Summary: ${passed} passed, ${warnings} warnings, ${failed} failed
|
|
|
2275
2268
|
}
|
|
2276
2269
|
|
|
2277
2270
|
// src/cli/commands/install.ts
|
|
2278
|
-
import * as
|
|
2271
|
+
import * as fs4 from "fs/promises";
|
|
2279
2272
|
async function installCommand(args) {
|
|
2280
2273
|
const steamInstalled = await isSteamCmdInstalled();
|
|
2281
2274
|
const valheimInstalled = await isValheimInstalled();
|
|
@@ -2338,7 +2331,7 @@ async function validateInstallation(steamInstalled, valheimInstalled, paths) {
|
|
|
2338
2331
|
console.log(" \u2713 Installed");
|
|
2339
2332
|
console.log(` Path: ${paths.steamcmd}`);
|
|
2340
2333
|
try {
|
|
2341
|
-
const stat3 = await
|
|
2334
|
+
const stat3 = await fs4.stat(paths.steamcmd);
|
|
2342
2335
|
if (stat3.isFile()) {
|
|
2343
2336
|
console.log(" \u2713 Executable found");
|
|
2344
2337
|
}
|
|
@@ -2357,7 +2350,7 @@ async function validateInstallation(steamInstalled, valheimInstalled, paths) {
|
|
|
2357
2350
|
console.log(` Path: ${paths.valheimDir}`);
|
|
2358
2351
|
const exePath = `${paths.valheimDir}/${paths.executable}`;
|
|
2359
2352
|
try {
|
|
2360
|
-
const stat3 = await
|
|
2353
|
+
const stat3 = await fs4.stat(exePath);
|
|
2361
2354
|
if (stat3.isFile()) {
|
|
2362
2355
|
console.log(" \u2713 Executable found");
|
|
2363
2356
|
}
|
|
@@ -2572,7 +2565,7 @@ async function interactiveRcon(args) {
|
|
|
2572
2565
|
}
|
|
2573
2566
|
|
|
2574
2567
|
// src/server/commands.ts
|
|
2575
|
-
import * as
|
|
2568
|
+
import * as fs5 from "fs/promises";
|
|
2576
2569
|
import { dirname, join } from "path";
|
|
2577
2570
|
|
|
2578
2571
|
// src/server/logs.ts
|
|
@@ -2623,7 +2616,7 @@ function parseEvent(line) {
|
|
|
2623
2616
|
}
|
|
2624
2617
|
|
|
2625
2618
|
// src/server/pidfile.ts
|
|
2626
|
-
import
|
|
2619
|
+
import fs6 from "fs/promises";
|
|
2627
2620
|
import path5 from "path";
|
|
2628
2621
|
function getPidFilePath() {
|
|
2629
2622
|
return path5.join(getConfigDir(), "oz-valheim", "server.pid");
|
|
@@ -2631,13 +2624,13 @@ function getPidFilePath() {
|
|
|
2631
2624
|
async function writePidFile(data) {
|
|
2632
2625
|
const pidPath = getPidFilePath();
|
|
2633
2626
|
const dir = path5.dirname(pidPath);
|
|
2634
|
-
await
|
|
2635
|
-
await
|
|
2627
|
+
await fs6.mkdir(dir, { recursive: true });
|
|
2628
|
+
await fs6.writeFile(pidPath, JSON.stringify(data, null, 2), "utf-8");
|
|
2636
2629
|
}
|
|
2637
2630
|
async function readPidFile() {
|
|
2638
2631
|
const pidPath = getPidFilePath();
|
|
2639
2632
|
try {
|
|
2640
|
-
const content = await
|
|
2633
|
+
const content = await fs6.readFile(pidPath, "utf-8");
|
|
2641
2634
|
return JSON.parse(content);
|
|
2642
2635
|
} catch {
|
|
2643
2636
|
return null;
|
|
@@ -2646,7 +2639,7 @@ async function readPidFile() {
|
|
|
2646
2639
|
async function removePidFile() {
|
|
2647
2640
|
const pidPath = getPidFilePath();
|
|
2648
2641
|
try {
|
|
2649
|
-
await
|
|
2642
|
+
await fs6.unlink(pidPath);
|
|
2650
2643
|
} catch {
|
|
2651
2644
|
}
|
|
2652
2645
|
}
|
|
@@ -3279,29 +3272,29 @@ Found running server:`);
|
|
|
3279
3272
|
}
|
|
3280
3273
|
|
|
3281
3274
|
// src/cli/commands/worlds.ts
|
|
3282
|
-
import * as
|
|
3275
|
+
import * as fs9 from "fs/promises";
|
|
3283
3276
|
|
|
3284
3277
|
// src/valheim/lists.ts
|
|
3285
|
-
import
|
|
3278
|
+
import fs7 from "fs/promises";
|
|
3286
3279
|
import path6 from "path";
|
|
3287
3280
|
|
|
3288
3281
|
// src/valheim/worlds.ts
|
|
3289
|
-
import
|
|
3282
|
+
import fs8 from "fs/promises";
|
|
3290
3283
|
import path7 from "path";
|
|
3291
3284
|
import process3 from "process";
|
|
3292
3285
|
async function exists2(filePath) {
|
|
3293
3286
|
try {
|
|
3294
|
-
await
|
|
3287
|
+
await fs8.access(filePath);
|
|
3295
3288
|
return true;
|
|
3296
3289
|
} catch {
|
|
3297
3290
|
return false;
|
|
3298
3291
|
}
|
|
3299
3292
|
}
|
|
3300
3293
|
async function ensureDir(dirPath) {
|
|
3301
|
-
await
|
|
3294
|
+
await fs8.mkdir(dirPath, { recursive: true });
|
|
3302
3295
|
}
|
|
3303
3296
|
async function copyFile(src, dest) {
|
|
3304
|
-
await
|
|
3297
|
+
await fs8.copyFile(src, dest);
|
|
3305
3298
|
}
|
|
3306
3299
|
function getValheimBaseDir() {
|
|
3307
3300
|
const platform = getPlatform();
|
|
@@ -3355,7 +3348,7 @@ async function listWorldsFromDir(dir, source) {
|
|
|
3355
3348
|
const worlds = [];
|
|
3356
3349
|
const foundNames = /* @__PURE__ */ new Set();
|
|
3357
3350
|
try {
|
|
3358
|
-
const entries = await
|
|
3351
|
+
const entries = await fs8.readdir(dir, { withFileTypes: true });
|
|
3359
3352
|
for (const entry of entries) {
|
|
3360
3353
|
if (entry.isFile() && entry.name.endsWith(".db")) {
|
|
3361
3354
|
if (entry.name.includes(".db.")) continue;
|
|
@@ -3363,7 +3356,7 @@ async function listWorldsFromDir(dir, source) {
|
|
|
3363
3356
|
const dbPath = path7.join(dir, entry.name);
|
|
3364
3357
|
const fwlPath = path7.join(dir, `${name}.fwl`);
|
|
3365
3358
|
if (!await exists2(fwlPath)) continue;
|
|
3366
|
-
const dbStat = await
|
|
3359
|
+
const dbStat = await fs8.stat(dbPath);
|
|
3367
3360
|
foundNames.add(name);
|
|
3368
3361
|
const backupInfo = parseBackupName(name);
|
|
3369
3362
|
worlds.push({
|
|
@@ -3388,7 +3381,7 @@ async function listWorldsFromDir(dir, source) {
|
|
|
3388
3381
|
if (foundNames.has(name)) continue;
|
|
3389
3382
|
const fwlPath = path7.join(dir, entry.name);
|
|
3390
3383
|
const dbPath = path7.join(dir, `${name}.db`);
|
|
3391
|
-
const fwlStat = await
|
|
3384
|
+
const fwlStat = await fs8.stat(fwlPath);
|
|
3392
3385
|
const backupInfo = parseBackupName(name);
|
|
3393
3386
|
worlds.push({
|
|
3394
3387
|
name,
|
|
@@ -3484,7 +3477,7 @@ async function importWorld(dbPath, fwlPath, targetDir) {
|
|
|
3484
3477
|
const targetFwl = path7.join(dir, `${name}.fwl`);
|
|
3485
3478
|
await copyFile(dbPath, targetDb);
|
|
3486
3479
|
await copyFile(fwlPath, targetFwl);
|
|
3487
|
-
const stat3 = await
|
|
3480
|
+
const stat3 = await fs8.stat(targetDb);
|
|
3488
3481
|
const serverDir = getDedicatedServerWorldsDir();
|
|
3489
3482
|
const cloudDir = getCloudWorldsDir();
|
|
3490
3483
|
const source = dir === serverDir ? "server" : dir === cloudDir ? "cloud" : "local";
|
|
@@ -3540,16 +3533,16 @@ async function deleteWorld(worldName, worldsDir) {
|
|
|
3540
3533
|
throw new Error(`World "${worldName}" not found`);
|
|
3541
3534
|
}
|
|
3542
3535
|
if (dbExists) {
|
|
3543
|
-
await
|
|
3536
|
+
await fs8.unlink(dbPath);
|
|
3544
3537
|
}
|
|
3545
3538
|
if (fwlExists) {
|
|
3546
|
-
await
|
|
3539
|
+
await fs8.unlink(fwlPath);
|
|
3547
3540
|
}
|
|
3548
3541
|
try {
|
|
3549
|
-
const entries = await
|
|
3542
|
+
const entries = await fs8.readdir(dir, { withFileTypes: true });
|
|
3550
3543
|
for (const entry of entries) {
|
|
3551
3544
|
if (entry.name.startsWith(`${worldName}.db.`) || entry.name.startsWith(`${worldName}.fwl.`)) {
|
|
3552
|
-
await
|
|
3545
|
+
await fs8.unlink(path7.join(dir, entry.name));
|
|
3553
3546
|
}
|
|
3554
3547
|
}
|
|
3555
3548
|
} catch {
|
|
@@ -3667,7 +3660,7 @@ World: ${world.name}`);
|
|
|
3667
3660
|
console.log(`Size: ${sizeMb} MB`);
|
|
3668
3661
|
console.log(`Last modified: ${world.modified.toLocaleString()}`);
|
|
3669
3662
|
try {
|
|
3670
|
-
const fwlContent = await
|
|
3663
|
+
const fwlContent = await fs9.readFile(world.fwlPath, "utf-8");
|
|
3671
3664
|
if (fwlContent.length > 0) {
|
|
3672
3665
|
console.log("");
|
|
3673
3666
|
console.log(
|
|
@@ -3699,8 +3692,8 @@ Importing world '${name}'...`);
|
|
|
3699
3692
|
console.log(` From: ${path9}`);
|
|
3700
3693
|
try {
|
|
3701
3694
|
try {
|
|
3702
|
-
await
|
|
3703
|
-
await
|
|
3695
|
+
await fs9.stat(dbPath);
|
|
3696
|
+
await fs9.stat(fwlPath);
|
|
3704
3697
|
} catch {
|
|
3705
3698
|
console.error("\nError: World files not found.");
|
|
3706
3699
|
console.log(` Expected: ${dbPath}`);
|
|
@@ -3800,7 +3793,7 @@ import { useEffect as useEffect3, useMemo as useMemo2, useRef as useRef2, useSta
|
|
|
3800
3793
|
// package.json
|
|
3801
3794
|
var package_default = {
|
|
3802
3795
|
name: "valheim-oz-dsm",
|
|
3803
|
-
version: "1.5.
|
|
3796
|
+
version: "1.5.1",
|
|
3804
3797
|
description: "Land of OZ - Valheim Dedicated Server Manager",
|
|
3805
3798
|
type: "module",
|
|
3806
3799
|
bin: {
|
|
@@ -45990,7 +45983,7 @@ var App = () => {
|
|
|
45990
45983
|
};
|
|
45991
45984
|
|
|
45992
45985
|
// src/tui/components/PathInput.tsx
|
|
45993
|
-
import
|
|
45986
|
+
import fs10 from "fs/promises";
|
|
45994
45987
|
import path8 from "path";
|
|
45995
45988
|
import { Box as Box18, Text as Text17, useInput as useInput11 } from "ink";
|
|
45996
45989
|
import { useEffect as useEffect13, useState as useState12 } from "react";
|
|
@@ -46013,7 +46006,7 @@ function launchTui() {
|
|
|
46013
46006
|
}
|
|
46014
46007
|
|
|
46015
46008
|
// src/mod.ts
|
|
46016
|
-
var VERSION2 = "1.5.
|
|
46009
|
+
var VERSION2 = "1.5.1";
|
|
46017
46010
|
var APP_NAME = "Land of OZ - Valheim DSM";
|
|
46018
46011
|
|
|
46019
46012
|
// main.ts
|