mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-23 08:23:12 +09:00
Merge pull request #520 from Hornwitser/vs-code-config
Add VSCode workspace config
This commit is contained in:
39 files changed
+610
-596
No files matched your search
@@ -0,0 +1,3 @@
|
|||||||
|
*
|
||||||
|
!.gitignore
|
||||||
|
!settings.json
|
||||||
Vendored
+11
@@ -0,0 +1,11 @@
|
|||||||
|
{
|
||||||
|
"editor.detectIndentation": false,
|
||||||
|
"editor.insertSpaces": false,
|
||||||
|
"files.eol": "\n",
|
||||||
|
"files.insertFinalNewline": true,
|
||||||
|
"files.trimFinalNewlines": true,
|
||||||
|
"[markdown]": {
|
||||||
|
"editor.indentSize": 4,
|
||||||
|
"editor.insertSpaces": true,
|
||||||
|
},
|
||||||
|
}
|
||||||
+43
-43
@@ -1,45 +1,45 @@
|
|||||||
{
|
{
|
||||||
"name": "root",
|
"name": "root",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "tsc --build",
|
"build": "tsc --build",
|
||||||
"test": "pnpm run build && mocha --check-leaks -R spec --recursive test \"plugins/*/test/**\"",
|
"test": "pnpm run build && mocha --check-leaks -R spec --recursive test \"plugins/*/test/**\"",
|
||||||
"fast-test": "FAST_TEST=y pnpm test",
|
"fast-test": "FAST_TEST=y pnpm test",
|
||||||
"cover": "nyc pnpm test",
|
"cover": "nyc pnpm test",
|
||||||
"fast-cover": "FAST_TEST=y nyc pnpm test",
|
"fast-cover": "FAST_TEST=y nyc pnpm test",
|
||||||
"ci-cover": "nyc --reporter=lcovonly pnpm run-script test",
|
"ci-cover": "nyc --reporter=lcovonly pnpm run-script test",
|
||||||
"lint": "eslint \"*.js\" packages plugins test",
|
"lint": "eslint \"*.js\" packages plugins test",
|
||||||
"lint-fix": "eslint --fix \"*.js\" packages plugins test",
|
"lint-fix": "eslint --fix \"*.js\" packages plugins test",
|
||||||
"docs": "typedoc",
|
"docs": "typedoc",
|
||||||
"bundle-dependencies": "bundle-dependencies"
|
"bundle-dependencies": "bundle-dependencies"
|
||||||
},
|
},
|
||||||
"nyc": {
|
"nyc": {
|
||||||
"exclude": [
|
"exclude": [
|
||||||
"test/**",
|
"test/**",
|
||||||
"plugins/*/test/**"
|
"plugins/*/test/**"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/controller": "workspace:*",
|
"@clusterio/controller": "workspace:*",
|
||||||
"@clusterio/ctl": "workspace:*",
|
"@clusterio/ctl": "workspace:*",
|
||||||
"@clusterio/host": "workspace:*",
|
"@clusterio/host": "workspace:*",
|
||||||
"@clusterio/lib": "workspace:*",
|
"@clusterio/lib": "workspace:*",
|
||||||
"@typescript-eslint/eslint-plugin": "^6.4.1",
|
"@typescript-eslint/eslint-plugin": "^6.4.1",
|
||||||
"@typescript-eslint/parser": "^6.4.1",
|
"@typescript-eslint/parser": "^6.4.1",
|
||||||
"eslint": "^8.45.0",
|
"eslint": "^8.45.0",
|
||||||
"eslint-plugin-node": "^11.1.0",
|
"eslint-plugin-node": "^11.1.0",
|
||||||
"express": "^4.18.2",
|
"express": "^4.18.2",
|
||||||
"form-data": "^4.0.0",
|
"form-data": "^4.0.0",
|
||||||
"fs-extra": "^11.1.1",
|
"fs-extra": "^11.1.1",
|
||||||
"jsonwebtoken": "^9.0.1",
|
"jsonwebtoken": "^9.0.1",
|
||||||
"jszip": "^3.10.0",
|
"jszip": "^3.10.0",
|
||||||
"mocha": "^10.2.0",
|
"mocha": "^10.2.0",
|
||||||
"nyc": "^15.1.0",
|
"nyc": "^15.1.0",
|
||||||
"phin": "^3.7.0",
|
"phin": "^3.7.0",
|
||||||
"typedoc": "^0.24.8",
|
"typedoc": "^0.24.8",
|
||||||
"typescript": "^5.1.6"
|
"typescript": "^5.1.6"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -164,7 +164,7 @@ async function handleBootstrapCommand(
|
|||||||
userManager.signUserToken(admin.name),
|
userManager.signUserToken(admin.name),
|
||||||
);
|
);
|
||||||
|
|
||||||
let content = JSON.stringify(controlConfig.serialize(), null, 4);
|
let content = JSON.stringify(controlConfig.serialize(), null, "\t");
|
||||||
if (args.output === "-") {
|
if (args.output === "-") {
|
||||||
// eslint-disable-next-line no-console
|
// eslint-disable-next-line no-console
|
||||||
console.log(content);
|
console.log(content);
|
||||||
@@ -343,7 +343,7 @@ async function initialize(): Promise<InitializeParameters> {
|
|||||||
let bytes = await asyncRandomBytes(256);
|
let bytes = await asyncRandomBytes(256);
|
||||||
controllerConfig.set("controller.auth_secret", bytes.toString("base64"));
|
controllerConfig.set("controller.auth_secret", bytes.toString("base64"));
|
||||||
await lib.safeOutputFile(
|
await lib.safeOutputFile(
|
||||||
controllerConfigPath, JSON.stringify(controllerConfig.serialize(), null, 4)
|
controllerConfigPath, JSON.stringify(controllerConfig.serialize(), null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,58 +1,58 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/controller",
|
"name": "@clusterio/controller",
|
||||||
"description": "Implementation of Clusterio controller",
|
"description": "Implementation of Clusterio controller",
|
||||||
"author": "Hornwitser",
|
"author": "Hornwitser",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"main": "dist/controller.js",
|
"main": "dist/controller.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && webpack-cli --env production",
|
"prepare": "tsc --build && webpack-cli --env production",
|
||||||
"test": "echo \"Error: no test specified\" && exit 1"
|
"test": "echo \"Error: no test specified\" && exit 1"
|
||||||
},
|
},
|
||||||
"bin": {
|
"bin": {
|
||||||
"clusteriocontroller": "./dist/controller.js"
|
"clusteriocontroller": "./dist/controller.js"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"factorio"
|
"factorio"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"busboy": "^1.6.0",
|
"busboy": "^1.6.0",
|
||||||
"compression": "^1.7.4",
|
"compression": "^1.7.4",
|
||||||
"express": "^4.18.2",
|
"express": "^4.18.2",
|
||||||
"fs-extra": "^11.1.1",
|
"fs-extra": "^11.1.1",
|
||||||
"jsonwebtoken": "^9.0.1",
|
"jsonwebtoken": "^9.0.1",
|
||||||
"jszip": "^3.10.1",
|
"jszip": "^3.10.1",
|
||||||
"set-blocking": "^2.0.0",
|
"set-blocking": "^2.0.0",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"winston": "^3.10.0",
|
"winston": "^3.10.0",
|
||||||
"winston-daily-rotate-file": "^4.7.1",
|
"winston-daily-rotate-file": "^4.7.1",
|
||||||
"ws": "^8.13.0",
|
"ws": "^8.13.0",
|
||||||
"yargs": "^17.7.2"
|
"yargs": "^17.7.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
||||||
"@types/busboy": "^1.5.0",
|
"@types/busboy": "^1.5.0",
|
||||||
"@types/compression": "^1.7.2",
|
"@types/compression": "^1.7.2",
|
||||||
"@types/express": "^4.17.17",
|
"@types/express": "^4.17.17",
|
||||||
"@types/fs-extra": "^11.0.1",
|
"@types/fs-extra": "^11.0.1",
|
||||||
"@types/jsonwebtoken": "^9.0.2",
|
"@types/jsonwebtoken": "^9.0.2",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"@types/set-blocking": "^2.0.0",
|
"@types/set-blocking": "^2.0.0",
|
||||||
"@types/ws": "^8.5.5",
|
"@types/ws": "^8.5.5",
|
||||||
"@types/yargs": "^17.0.24",
|
"@types/yargs": "^17.0.24",
|
||||||
"react": "^18.2.0",
|
"react": "^18.2.0",
|
||||||
"react-dom": "^18.2.0",
|
"react-dom": "^18.2.0",
|
||||||
"react-router-dom": "^6.4.14",
|
"react-router-dom": "^6.4.14",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-dev-middleware": "^6.1.1",
|
"webpack-dev-middleware": "^6.1.1",
|
||||||
"webpack-merge": "^5.9.0"
|
"webpack-merge": "^5.9.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -321,7 +321,7 @@ export default class Controller {
|
|||||||
}
|
}
|
||||||
|
|
||||||
logger.info("Saving config");
|
logger.info("Saving config");
|
||||||
await lib.safeOutputFile(this.configPath, JSON.stringify(this.config.serialize(), null, 4));
|
await lib.safeOutputFile(this.configPath, JSON.stringify(this.config.serialize(), null, "\t"));
|
||||||
|
|
||||||
if (this.devMiddleware) {
|
if (this.devMiddleware) {
|
||||||
await new Promise((resolve, reject) => { this.devMiddleware.close(resolve); });
|
await new Promise((resolve, reject) => { this.devMiddleware.close(resolve); });
|
||||||
@@ -384,7 +384,7 @@ export default class Controller {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static async saveHosts(filePath: string, hosts: Map<number, HostInfo>) {
|
static async saveHosts(filePath: string, hosts: Map<number, HostInfo>) {
|
||||||
await lib.safeOutputFile(filePath, JSON.stringify([...hosts.entries()], null, 4));
|
await lib.safeOutputFile(filePath, JSON.stringify([...hosts.entries()], null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
static async loadInstances(filePath: string): Promise<Map<number, InstanceInfo>> {
|
static async loadInstances(filePath: string): Promise<Map<number, InstanceInfo>> {
|
||||||
@@ -420,7 +420,7 @@ export default class Controller {
|
|||||||
serialized.push(instance.config.serialize());
|
serialized.push(instance.config.serialize());
|
||||||
}
|
}
|
||||||
|
|
||||||
await lib.safeOutputFile(filePath, JSON.stringify(serialized, null, 4));
|
await lib.safeOutputFile(filePath, JSON.stringify(serialized, null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
static async loadModPacks(filePath: string): Promise<Map<number, lib.ModPack>> {
|
static async loadModPacks(filePath: string): Promise<Map<number, lib.ModPack>> {
|
||||||
@@ -437,7 +437,7 @@ export default class Controller {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static async saveModPacks(filePath: string, modPacks: Map<number, lib.ModPack>) {
|
static async saveModPacks(filePath: string, modPacks: Map<number, lib.ModPack>) {
|
||||||
await lib.safeOutputFile(filePath, JSON.stringify([...modPacks.values()], null, 4));
|
await lib.safeOutputFile(filePath, JSON.stringify([...modPacks.values()], null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
static async loadModInfos(modsDirectory: string): Promise<Map<string, lib.ModInfo>> {
|
static async loadModInfos(modsDirectory: string): Promise<Map<string, lib.ModInfo>> {
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ export default class UserManager {
|
|||||||
users: serializedUsers,
|
users: serializedUsers,
|
||||||
roles: serializedRoles,
|
roles: serializedRoles,
|
||||||
};
|
};
|
||||||
await lib.safeOutputFile(filePath, JSON.stringify(serialized, null, 4));
|
await lib.safeOutputFile(filePath, JSON.stringify(serialized, null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{
|
{
|
||||||
"entryPoints": ["controller.ts"],
|
"entryPoints": ["controller.ts"],
|
||||||
"includeVersion": true
|
"includeVersion": true
|
||||||
}
|
}
|
||||||
@@ -199,7 +199,7 @@ async function migrateRename(args) {
|
|||||||
async function migrateConfig(source, destination) {
|
async function migrateConfig(source, destination) {
|
||||||
if (await fs.pathExists(source) && !await fs.pathExists(destination)) {
|
if (await fs.pathExists(source) && !await fs.pathExists(destination)) {
|
||||||
await safeOutputFile(destination, JSON.stringify(
|
await safeOutputFile(destination, JSON.stringify(
|
||||||
renameConfig(JSON.parse(await fs.readFile(source))), null, 4
|
renameConfig(JSON.parse(await fs.readFile(source))), null, "\t"
|
||||||
));
|
));
|
||||||
logger.info(`Migrated ${source} to ${destination}`);
|
logger.info(`Migrated ${source} to ${destination}`);
|
||||||
}
|
}
|
||||||
@@ -211,7 +211,7 @@ async function migrateRename(args) {
|
|||||||
let instancesFile = path.join("database", "instances.json");
|
let instancesFile = path.join("database", "instances.json");
|
||||||
if (await fs.pathExists(instancesFile)) {
|
if (await fs.pathExists(instancesFile)) {
|
||||||
await safeOutputFile(instancesFile, JSON.stringify(
|
await safeOutputFile(instancesFile, JSON.stringify(
|
||||||
JSON.parse(await fs.readFile(instancesFile)).map(renameConfig), null, 4
|
JSON.parse(await fs.readFile(instancesFile)).map(renameConfig), null, "\t"
|
||||||
));
|
));
|
||||||
logger.info(`Migrated ${instancesFile}`);
|
logger.info(`Migrated ${instancesFile}`);
|
||||||
}
|
}
|
||||||
@@ -222,7 +222,7 @@ async function migrateRename(args) {
|
|||||||
for (let role of users["roles"]) {
|
for (let role of users["roles"]) {
|
||||||
role["permissions"] = role["permissions"].map(rename);
|
role["permissions"] = role["permissions"].map(rename);
|
||||||
}
|
}
|
||||||
await safeOutputFile(usersFile, JSON.stringify(users, null, 4));
|
await safeOutputFile(usersFile, JSON.stringify(users, null, "\t"));
|
||||||
logger.info(`Migrated ${usersFile}`);
|
logger.info(`Migrated ${usersFile}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -352,7 +352,7 @@ async function installClusterio(mode, plugins) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
await safeOutputFile("plugin-list.json", JSON.stringify([...pluginList], null, 4));
|
await safeOutputFile("plugin-list.json", JSON.stringify([...pluginList], null, "\t"));
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
throw new InstallError(`Error writing plugin-list.json: ${err.message}`);
|
throw new InstallError(`Error writing plugin-list.json: ${err.message}`);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,28 +1,28 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/create",
|
"name": "@clusterio/create",
|
||||||
"description": "Installer for clusterio",
|
"description": "Installer for clusterio",
|
||||||
"author": "Hornwitser",
|
"author": "Hornwitser",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"version": "2.0.0-alpha.13b",
|
"version": "2.0.0-alpha.13b",
|
||||||
"main": "create.js",
|
"main": "create.js",
|
||||||
"bin": {
|
"bin": {
|
||||||
"clusteriocreate": "./create.js"
|
"clusteriocreate": "./create.js"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"factorio",
|
"factorio",
|
||||||
"clusterio"
|
"clusterio"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"chalk": "^4.1.2",
|
"chalk": "^4.1.2",
|
||||||
"fs-extra": "^11.1.1",
|
"fs-extra": "^11.1.1",
|
||||||
"inquirer": "^8.2.4",
|
"inquirer": "^8.2.4",
|
||||||
"phin": "^3.7.0",
|
"phin": "^3.7.0",
|
||||||
"yargs": "^17.7.2"
|
"yargs": "^17.7.2"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
+1
-1
@@ -324,7 +324,7 @@ I version of clusterio. Expect things to break. I
|
|||||||
);
|
);
|
||||||
startControl().catch(err => {
|
startControl().catch(err => {
|
||||||
if (err.errors) {
|
if (err.errors) {
|
||||||
logger.fatal(JSON.stringify(err.errors, null, 4));
|
logger.fatal(JSON.stringify(err.errors, null, "\t"));
|
||||||
}
|
}
|
||||||
if (!(err instanceof lib.StartupError)) {
|
if (!(err instanceof lib.StartupError)) {
|
||||||
logger.fatal(`
|
logger.fatal(`
|
||||||
|
|||||||
+38
-38
@@ -1,40 +1,40 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/ctl",
|
"name": "@clusterio/ctl",
|
||||||
"description": "Clusterio command line management tool",
|
"description": "Clusterio command line management tool",
|
||||||
"author": "Hornwitser",
|
"author": "Hornwitser",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"main": "dist/ctl.js",
|
"main": "dist/ctl.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build",
|
"prepare": "tsc --build",
|
||||||
"test": "echo \"Error: no test specified\" && exit 1"
|
"test": "echo \"Error: no test specified\" && exit 1"
|
||||||
},
|
},
|
||||||
"bin": {
|
"bin": {
|
||||||
"clusterioctl": "./dist/ctl.js"
|
"clusterioctl": "./dist/ctl.js"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"factorio"
|
"factorio"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"as-table": "^1.0.55",
|
"as-table": "^1.0.55",
|
||||||
"fs-extra": "^11.1.1",
|
"fs-extra": "^11.1.1",
|
||||||
"phin": "^3.7.0",
|
"phin": "^3.7.0",
|
||||||
"set-blocking": "^2.0.0",
|
"set-blocking": "^2.0.0",
|
||||||
"winston": "^3.10.0",
|
"winston": "^3.10.0",
|
||||||
"yargs": "^17.7.2"
|
"yargs": "^17.7.2"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/fs-extra": "^11.0.1",
|
"@types/fs-extra": "^11.0.1",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"@types/set-blocking": "^2.0.0",
|
"@types/set-blocking": "^2.0.0",
|
||||||
"@types/yargs": "^17.0.24",
|
"@types/yargs": "^17.0.24",
|
||||||
"typescript": "^5.1.6"
|
"typescript": "^5.1.6"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -265,7 +265,7 @@ hostCommands.add(new lib.Command({
|
|||||||
new lib.HostConfigCreateRequest(args.id, args.name, args.generateToken)
|
new lib.HostConfigCreateRequest(args.id, args.name, args.generateToken)
|
||||||
);
|
);
|
||||||
|
|
||||||
let content = JSON.stringify(rawConfig.serializedConfig, null, 4);
|
let content = JSON.stringify(rawConfig.serializedConfig, null, "\t");
|
||||||
if (args.output === "-") {
|
if (args.output === "-") {
|
||||||
print(content);
|
print(content);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
+46
-46
@@ -1,48 +1,48 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/host",
|
"name": "@clusterio/host",
|
||||||
"description": "Implementation of Clusterio host server",
|
"description": "Implementation of Clusterio host server",
|
||||||
"author": "Hornwitser",
|
"author": "Hornwitser",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"main": "dist/host.js",
|
"main": "dist/host.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build",
|
"prepare": "tsc --build",
|
||||||
"test": "echo \"Error: no test specified\" && exit 1"
|
"test": "echo \"Error: no test specified\" && exit 1"
|
||||||
},
|
},
|
||||||
"bin": {
|
"bin": {
|
||||||
"clusteriohost": "./dist/host.js"
|
"clusteriohost": "./dist/host.js"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"factorio"
|
"factorio"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"@sinclair/typebox": "^0.30.4",
|
"@sinclair/typebox": "^0.30.4",
|
||||||
"fs-extra": "^11.1.1",
|
"fs-extra": "^11.1.1",
|
||||||
"jimp": "^0.22.8",
|
"jimp": "^0.22.8",
|
||||||
"jszip": "^3.10.1",
|
"jszip": "^3.10.1",
|
||||||
"phin": "^3.7.0",
|
"phin": "^3.7.0",
|
||||||
"pidusage": "^3.0.2",
|
"pidusage": "^3.0.2",
|
||||||
"rcon-client": "^4.2.3",
|
"rcon-client": "^4.2.3",
|
||||||
"semver": "^7.5.4",
|
"semver": "^7.5.4",
|
||||||
"set-blocking": "^2.0.0",
|
"set-blocking": "^2.0.0",
|
||||||
"winston": "^3.10.0",
|
"winston": "^3.10.0",
|
||||||
"winston-daily-rotate-file": "^4.7.1",
|
"winston-daily-rotate-file": "^4.7.1",
|
||||||
"yargs": "^17.7.2"
|
"yargs": "^17.7.2"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/fs-extra": "^11.0.1",
|
"@types/fs-extra": "^11.0.1",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"@types/pidusage": "^2.0.2",
|
"@types/pidusage": "^2.0.2",
|
||||||
"@types/semver": "^7.5.0",
|
"@types/semver": "^7.5.0",
|
||||||
"@types/set-blocking": "^2.0.0",
|
"@types/set-blocking": "^2.0.0",
|
||||||
"@types/yargs": "^17.0.24",
|
"@types/yargs": "^17.0.24",
|
||||||
"typescript": "^5.1.6"
|
"typescript": "^5.1.6"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -215,7 +215,7 @@ class HostRouter {
|
|||||||
}
|
}
|
||||||
logger.warn(`Failed to deliver ${(message as any).name || "message"} (${message.type}): ${err.message}`);
|
logger.warn(`Failed to deliver ${(message as any).name || "message"} (${message.type}): ${err.message}`);
|
||||||
if (err instanceof lib.InvalidMessage && err.errors) {
|
if (err instanceof lib.InvalidMessage && err.errors) {
|
||||||
logger.warn(JSON.stringify(err.errors, null, 4));
|
logger.warn(JSON.stringify(err.errors, null, "\t"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -484,7 +484,7 @@ export default class Host extends lib.Link {
|
|||||||
};
|
};
|
||||||
await lib.safeOutputFile(
|
await lib.safeOutputFile(
|
||||||
path.join(instanceInfo.path, "instance.json"),
|
path.join(instanceInfo.path, "instance.json"),
|
||||||
JSON.stringify(warnedOutput, null, 4)
|
JSON.stringify(warnedOutput, null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -520,7 +520,7 @@ rcon.print(game.table_to_json(players))`.replace(/\r?\n/g, " ");
|
|||||||
let content = JSON.stringify({
|
let content = JSON.stringify({
|
||||||
players: [...this.playerStats],
|
players: [...this.playerStats],
|
||||||
player_autosave_slot: this._playerAutosaveSlot,
|
player_autosave_slot: this._playerAutosaveSlot,
|
||||||
}, null, 4);
|
}, null, "\t");
|
||||||
await lib.safeOutputFile(this.path("instance-stats.json"), content);
|
await lib.safeOutputFile(this.path("instance-stats.json"), content);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -599,7 +599,7 @@ rcon.print(game.table_to_json(players))`.replace(/\r?\n/g, " ");
|
|||||||
};
|
};
|
||||||
await lib.safeOutputFile(
|
await lib.safeOutputFile(
|
||||||
this.server.writePath("server-settings.json"),
|
this.server.writePath("server-settings.json"),
|
||||||
JSON.stringify(serverSettings, null, 4)
|
JSON.stringify(serverSettings, null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -687,7 +687,7 @@ rcon.print(game.table_to_json(players))`.replace(/\r?\n/g, " ");
|
|||||||
// Write mod-list.json
|
// Write mod-list.json
|
||||||
await fs.outputFile(this.path("mods", "mod-list.json"), JSON.stringify({
|
await fs.outputFile(this.path("mods", "mod-list.json"), JSON.stringify({
|
||||||
mods: [...this.activeModPack.mods.values()],
|
mods: [...this.activeModPack.mods.values()],
|
||||||
}, null, 2));
|
}, null, "\t"));
|
||||||
|
|
||||||
// Write mod-settings.dat
|
// Write mod-settings.dat
|
||||||
await fs.outputFile(this.path("mods", "mod-settings.dat"), this.activeModPack.toModSettingsDat());
|
await fs.outputFile(this.path("mods", "mod-settings.dat"), this.activeModPack.toModSettingsDat());
|
||||||
@@ -706,7 +706,7 @@ rcon.print(game.table_to_json(players))`.replace(/\r?\n/g, " ");
|
|||||||
this.logger.verbose("Writing server-adminlist.json");
|
this.logger.verbose("Writing server-adminlist.json");
|
||||||
lib.safeOutputFile(
|
lib.safeOutputFile(
|
||||||
this.server.writePath("server-adminlist.json"),
|
this.server.writePath("server-adminlist.json"),
|
||||||
JSON.stringify([...this._host.adminlist], null, 4)
|
JSON.stringify([...this._host.adminlist], null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -716,7 +716,7 @@ rcon.print(game.table_to_json(players))`.replace(/\r?\n/g, " ");
|
|||||||
this.server.writePath("server-banlist.json"),
|
this.server.writePath("server-banlist.json"),
|
||||||
JSON.stringify([...this._host.banlist].map(
|
JSON.stringify([...this._host.banlist].map(
|
||||||
([username, reason]) => ({ username, reason })
|
([username, reason]) => ({ username, reason })
|
||||||
), null, 4),
|
), null, "\t"),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -724,7 +724,7 @@ rcon.print(game.table_to_json(players))`.replace(/\r?\n/g, " ");
|
|||||||
this.logger.verbose("Writing server-whitelist.json");
|
this.logger.verbose("Writing server-whitelist.json");
|
||||||
lib.safeOutputFile(
|
lib.safeOutputFile(
|
||||||
this.server.writePath("server-whitelist.json"),
|
this.server.writePath("server-whitelist.json"),
|
||||||
JSON.stringify([...this._host.whitelist], null, 4)
|
JSON.stringify([...this._host.whitelist], null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -103,7 +103,7 @@ export class SaveModule {
|
|||||||
if (!lib.ModuleInfo.validate(moduleJson)) {
|
if (!lib.ModuleInfo.validate(moduleJson)) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`module/module.json in plugin ${plugin.info.name} failed validation:\n` +
|
`module/module.json in plugin ${plugin.info.name} failed validation:\n` +
|
||||||
`${JSON.stringify(lib.ModuleInfo.validate.errors, null, 4)}`
|
`${JSON.stringify(lib.ModuleInfo.validate.errors, null, "\t")}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -124,7 +124,7 @@ export class SaveModule {
|
|||||||
if (!lib.ModuleInfo.validate(moduleJson)) {
|
if (!lib.ModuleInfo.validate(moduleJson)) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`${name}/module.json failed validation:\n` +
|
`${name}/module.json failed validation:\n` +
|
||||||
`${JSON.stringify(lib.ModuleInfo.validate.errors, null, 4)}`
|
`${JSON.stringify(lib.ModuleInfo.validate.errors, null, "\t")}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1194,12 +1194,12 @@ export class FactorioServer extends events.EventEmitter {
|
|||||||
async _writeMapSettings(mapGenSettings?: object, mapSettings?: object) {
|
async _writeMapSettings(mapGenSettings?: object, mapSettings?: object) {
|
||||||
if (mapGenSettings) {
|
if (mapGenSettings) {
|
||||||
await lib.safeOutputFile(
|
await lib.safeOutputFile(
|
||||||
this.writePath("map-gen-settings.json"), JSON.stringify(mapGenSettings, null, 4)
|
this.writePath("map-gen-settings.json"), JSON.stringify(mapGenSettings, null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if (mapSettings) {
|
if (mapSettings) {
|
||||||
await lib.safeOutputFile(
|
await lib.safeOutputFile(
|
||||||
this.writePath("map-settings.json"), JSON.stringify(mapSettings, null, 4)
|
this.writePath("map-settings.json"), JSON.stringify(mapSettings, null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ async function buildMod(args, info) {
|
|||||||
}
|
}
|
||||||
delete info.additional_files;
|
delete info.additional_files;
|
||||||
|
|
||||||
zip.file(path.posix.join(modName, "info.json"), JSON.stringify(info, null, 4));
|
zip.file(path.posix.join(modName, "info.json"), JSON.stringify(info, null, "\t"));
|
||||||
|
|
||||||
let modPath = path.join(args.outputDir, `${modName}.zip`);
|
let modPath = path.join(args.outputDir, `${modName}.zip`);
|
||||||
console.log(`Writing ${modPath}`);
|
console.log(`Writing ${modPath}`);
|
||||||
@@ -62,7 +62,7 @@ async function buildMod(args, info) {
|
|||||||
}
|
}
|
||||||
delete info.additional_files;
|
delete info.additional_files;
|
||||||
|
|
||||||
await fs.writeFile(path.join(modDir, "info.json"), JSON.stringify(info, null, 4));
|
await fs.writeFile(path.join(modDir, "info.json"), JSON.stringify(info, null, "\t"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+44
-44
@@ -1,46 +1,46 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/lib",
|
"name": "@clusterio/lib",
|
||||||
"description": "Shared library for Clusterio",
|
"description": "Shared library for Clusterio",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"repository": "https://github.com/clusterio/clusterio",
|
"repository": "https://github.com/clusterio/clusterio",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && pnpm run compile_validator",
|
"prepare": "tsc --build && pnpm run compile_validator",
|
||||||
"compile_validator": "node scripts/compile_validator.js"
|
"compile_validator": "node scripts/compile_validator.js"
|
||||||
},
|
},
|
||||||
"main": "dist/index.js",
|
"main": "dist/index.js",
|
||||||
"browser": "browser.js",
|
"browser": "browser.js",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"factorio"
|
"factorio"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@sinclair/typebox": "^0.30.4",
|
"@sinclair/typebox": "^0.30.4",
|
||||||
"ajv": "^8.12.0",
|
"ajv": "^8.12.0",
|
||||||
"chalk": "^4.1.2",
|
"chalk": "^4.1.2",
|
||||||
"fast-deep-equal": "^3.1.3",
|
"fast-deep-equal": "^3.1.3",
|
||||||
"fs-extra": "^11.1.1",
|
"fs-extra": "^11.1.1",
|
||||||
"jszip": "^3.10.1",
|
"jszip": "^3.10.1",
|
||||||
"klaw": "^4.1.0",
|
"klaw": "^4.1.0",
|
||||||
"set-blocking": "^2.0.0",
|
"set-blocking": "^2.0.0",
|
||||||
"triple-beam": "^1.4.1",
|
"triple-beam": "^1.4.1",
|
||||||
"winston": "^3.10.0",
|
"winston": "^3.10.0",
|
||||||
"winston-transport": "^4.5.0",
|
"winston-transport": "^4.5.0",
|
||||||
"ws": "^8.13.0",
|
"ws": "^8.13.0",
|
||||||
"yargs": "^17.7.2"
|
"yargs": "^17.7.2"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/fs-extra": "^11.0.1",
|
"@types/fs-extra": "^11.0.1",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"@types/set-blocking": "^2.0.0",
|
"@types/set-blocking": "^2.0.0",
|
||||||
"@types/triple-beam": "^1.3.2",
|
"@types/triple-beam": "^1.3.2",
|
||||||
"@types/ws": "^8.5.5",
|
"@types/ws": "^8.5.5",
|
||||||
"@types/yargs": "^17.0.24",
|
"@types/yargs": "^17.0.24",
|
||||||
"typescript": "^5.1.6"
|
"typescript": "^5.1.6"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -78,7 +78,7 @@ export async function loadJsonAsMap(filePath: string): Promise<Map<string, unkno
|
|||||||
*/
|
*/
|
||||||
export async function saveMapAsJson(filePath: string, map: Map<string, unknown>) {
|
export async function saveMapAsJson(filePath: string, map: Map<string, unknown>) {
|
||||||
let obj = mapToObject(map);
|
let obj = mapToObject(map);
|
||||||
await libFileOps.safeOutputFile(filePath, JSON.stringify(obj, null, 4));
|
await libFileOps.safeOutputFile(filePath, JSON.stringify(obj, null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -138,7 +138,7 @@ export async function loadJsonArrayAsMap(filePath: string): Promise<Map<unknown,
|
|||||||
* @throws {Error} if an error occured writing to the file.
|
* @throws {Error} if an error occured writing to the file.
|
||||||
*/
|
*/
|
||||||
export async function saveMapAsJsonArray(filePath: string, map: Map<unknown, { id: unknown }>) {
|
export async function saveMapAsJsonArray(filePath: string, map: Map<unknown, { id: unknown }>) {
|
||||||
await libFileOps.safeOutputFile(filePath, JSON.stringify([...map.values()], null, 4));
|
await libFileOps.safeOutputFile(filePath, JSON.stringify([...map.values()], null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -159,7 +159,7 @@ export abstract class WebSocketBaseConnector extends BaseConnector {
|
|||||||
}
|
}
|
||||||
if (!libData.Message.validate(json)) {
|
if (!libData.Message.validate(json)) {
|
||||||
logger.error(`Received malformed message: ${text}`);
|
logger.error(`Received malformed message: ${text}`);
|
||||||
// logger.error(JSON.stringify(libData.Message.validate.errors, null, 4));
|
// logger.error(JSON.stringify(libData.Message.validate.errors, null, "\t"));
|
||||||
this.close(4000, "Malformed message");
|
this.close(4000, "Malformed message");
|
||||||
return undefined;
|
return undefined;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -109,7 +109,7 @@ export class Link {
|
|||||||
if (err instanceof libErrors.InvalidMessage) {
|
if (err instanceof libErrors.InvalidMessage) {
|
||||||
logger.error(err.message);
|
logger.error(err.message);
|
||||||
if (err.errors) {
|
if (err.errors) {
|
||||||
logger.error(JSON.stringify(err.errors, null, 4));
|
logger.error(JSON.stringify(err.errors, null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
@@ -364,7 +364,7 @@ export class Link {
|
|||||||
response = handler(entry.requestFromJSON(message.data), message.src, message.dst);
|
response = handler(entry.requestFromJSON(message.data), message.src, message.dst);
|
||||||
} catch (err: any) {
|
} catch (err: any) {
|
||||||
if (err.errors) {
|
if (err.errors) {
|
||||||
logger.error(JSON.stringify(err.errors, null, 4));
|
logger.error(JSON.stringify(err.errors, null, "\t"));
|
||||||
}
|
}
|
||||||
this.connector.sendResponseError(
|
this.connector.sendResponseError(
|
||||||
new libData.ResponseError(err.message, err.code, err.stack), message.src
|
new libData.ResponseError(err.message, err.code, err.stack), message.src
|
||||||
@@ -392,7 +392,7 @@ export class Link {
|
|||||||
if (err instanceof libErrors.InvalidMessage) {
|
if (err instanceof libErrors.InvalidMessage) {
|
||||||
logger.error(err.message);
|
logger.error(err.message);
|
||||||
if (err.errors) {
|
if (err.errors) {
|
||||||
logger.error(JSON.stringify(err.errors, null, 4));
|
logger.error(JSON.stringify(err.errors, null, "\t"));
|
||||||
}
|
}
|
||||||
} else if (!(err instanceof libErrors.RequestError)) {
|
} else if (!(err instanceof libErrors.RequestError)) {
|
||||||
logger.error(`Unexpected error responding to ${message.name}:\n${err.stack}`);
|
logger.error(`Unexpected error responding to ${message.name}:\n${err.stack}`);
|
||||||
|
|||||||
@@ -306,7 +306,7 @@ export class LogIndex {
|
|||||||
async save() {
|
async save() {
|
||||||
await libFileOps.safeOutputFile(
|
await libFileOps.safeOutputFile(
|
||||||
path.join(this.logDirectory, "index.json"),
|
path.join(this.logDirectory, "index.json"),
|
||||||
JSON.stringify(this.serialize(), null, 4)
|
JSON.stringify(this.serialize(), null, "\t")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ export async function handlePluginCommand(
|
|||||||
}
|
}
|
||||||
|
|
||||||
pluginList.set(pluginInfo.name, pluginPath);
|
pluginList.set(pluginInfo.name, pluginPath);
|
||||||
await libFileOps.safeOutputFile(pluginListPath, JSON.stringify([...pluginList], null, 4));
|
await libFileOps.safeOutputFile(pluginListPath, JSON.stringify([...pluginList], null, "\t"));
|
||||||
print(`Added ${pluginInfo.name}`);
|
print(`Added ${pluginInfo.name}`);
|
||||||
|
|
||||||
} else if (command === "remove") {
|
} else if (command === "remove") {
|
||||||
@@ -83,7 +83,7 @@ export async function handlePluginCommand(
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
await libFileOps.safeOutputFile(pluginListPath, JSON.stringify([...pluginList], null, 4));
|
await libFileOps.safeOutputFile(pluginListPath, JSON.stringify([...pluginList], null, "\t"));
|
||||||
print(`Removed ${args.name}`);
|
print(`Removed ${args.name}`);
|
||||||
|
|
||||||
} else if (command === "list") {
|
} else if (command === "list") {
|
||||||
@@ -162,7 +162,7 @@ export async function handleConfigCommand(
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
instance.set(args.field as string, args.value);
|
instance.set(args.field as string, args.value);
|
||||||
await libFileOps.safeOutputFile(configPath, JSON.stringify(instance.serialize(), null, 4));
|
await libFileOps.safeOutputFile(configPath, JSON.stringify(instance.serialize(), null, "\t"));
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
if (err instanceof libConfig.InvalidField || err instanceof libConfig.InvalidValue) {
|
if (err instanceof libConfig.InvalidField || err instanceof libConfig.InvalidValue) {
|
||||||
logger.error(err.message);
|
logger.error(err.message);
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{
|
{
|
||||||
"entryPoints": ["index.ts"],
|
"entryPoints": ["index.ts"],
|
||||||
"includeVersion": true
|
"includeVersion": true
|
||||||
}
|
}
|
||||||
@@ -1,57 +1,57 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/web_ui",
|
"name": "@clusterio/web_ui",
|
||||||
"description": "Clusterio web interface implementation",
|
"description": "Clusterio web interface implementation",
|
||||||
"author": "Hornwitser",
|
"author": "Hornwitser",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"browser": "src/index.ts",
|
"browser": "src/index.ts",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "echo \"Error: no test specified\" && exit 1"
|
"test": "echo \"Error: no test specified\" && exit 1"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"clusterio"
|
"clusterio"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@ant-design/icons": "^5.1.4",
|
"@ant-design/icons": "^5.1.4",
|
||||||
"@babel/core": "^7.22.9",
|
"@babel/core": "^7.22.9",
|
||||||
"@babel/preset-react": "^7.22.5",
|
"@babel/preset-react": "^7.22.5",
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"antd": "^5.7.3",
|
"antd": "^5.7.3",
|
||||||
"assert": "^2.0.0",
|
"assert": "^2.0.0",
|
||||||
"babel-loader": "^9.1.3",
|
"babel-loader": "^9.1.3",
|
||||||
"browserify-zlib": "^0.2.0",
|
"browserify-zlib": "^0.2.0",
|
||||||
"buffer": "^6.0.3",
|
"buffer": "^6.0.3",
|
||||||
"clean-webpack-plugin": "^4.0.0",
|
"clean-webpack-plugin": "^4.0.0",
|
||||||
"css-loader": "^6.8.1",
|
"css-loader": "^6.8.1",
|
||||||
"events": "^3.3.0",
|
"events": "^3.3.0",
|
||||||
"file-loader": "^6.2.0",
|
"file-loader": "^6.2.0",
|
||||||
"null-loader": "^4.0.1",
|
"null-loader": "^4.0.1",
|
||||||
"os-browserify": "^0.3.0",
|
"os-browserify": "^0.3.0",
|
||||||
"path-browserify": "^1.0.1",
|
"path-browserify": "^1.0.1",
|
||||||
"process": "^0.11.10",
|
"process": "^0.11.10",
|
||||||
"rc-field-form": "^1.37.0",
|
"rc-field-form": "^1.37.0",
|
||||||
"react": "^18.2.0",
|
"react": "^18.2.0",
|
||||||
"react-dom": "^18.2.0",
|
"react-dom": "^18.2.0",
|
||||||
"react-router-dom": "^6.14.2",
|
"react-router-dom": "^6.14.2",
|
||||||
"stream-browserify": "^3.0.0",
|
"stream-browserify": "^3.0.0",
|
||||||
"style-loader": "^3.3.3",
|
"style-loader": "^3.3.3",
|
||||||
"terser-webpack-plugin": "^5.3.9",
|
"terser-webpack-plugin": "^5.3.9",
|
||||||
"ts-loader": "^9.4.4",
|
"ts-loader": "^9.4.4",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"util": "^0.12.5",
|
"util": "^0.12.5",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"webpack-manifest-plugin": "^5.0.0"
|
"webpack-manifest-plugin": "^5.0.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"@types/react": "^18.2.21",
|
"@types/react": "^18.2.21",
|
||||||
"@types/react-dom": "^18.2.7"
|
"@types/react-dom": "^18.2.7"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -79,8 +79,8 @@ export default function CreateSaveModal(props: CreateSaveModalProps) {
|
|||||||
}
|
}
|
||||||
form.setFields([{ name: "exchangeString", errors: [], value: "" }]);
|
form.setFields([{ name: "exchangeString", errors: [], value: "" }]);
|
||||||
form.setFieldsValue({
|
form.setFieldsValue({
|
||||||
mapGenSettings: JSON.stringify(result.map_gen_settings, null, 4),
|
mapGenSettings: JSON.stringify(result.map_gen_settings, null, "\t"),
|
||||||
mapSettings: JSON.stringify(result.map_settings, null, 4),
|
mapSettings: JSON.stringify(result.map_settings, null, "\t"),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -77,8 +77,8 @@ export default function LoadScenarioModal(props: LoadScenarioModalProps) {
|
|||||||
}
|
}
|
||||||
form.setFields([{ name: "exchangeString", errors: [], value: "" }]);
|
form.setFields([{ name: "exchangeString", errors: [], value: "" }]);
|
||||||
form.setFieldsValue({
|
form.setFieldsValue({
|
||||||
mapGenSettings: JSON.stringify(result.map_gen_settings, null, 4),
|
mapGenSettings: JSON.stringify(result.map_gen_settings, null, "\t"),
|
||||||
mapSettings: JSON.stringify(result.map_settings, null, 4),
|
mapSettings: JSON.stringify(result.map_settings, null, "\t"),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,38 +1,38 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/plugin-global_chat",
|
"name": "@clusterio/plugin-global_chat",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"description": "Clusterio plugin forwarding between Factorio servers",
|
"description": "Clusterio plugin forwarding between Factorio servers",
|
||||||
"author": "Hornwitser <github@hornwitser.no>",
|
"author": "Hornwitser <github@hornwitser.no>",
|
||||||
"homepage": "https://github.com/clusterio/clusterio#readme",
|
"homepage": "https://github.com/clusterio/clusterio#readme",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "clusterio/clusterio",
|
"repository": "clusterio/clusterio",
|
||||||
"main": "dist/plugin/info.js",
|
"main": "dist/plugin/info.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && webpack-cli --env production",
|
"prepare": "tsc --build && webpack-cli --env production",
|
||||||
"test": "echo \"Error: run tests from root\" && exit 1"
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
||||||
},
|
},
|
||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://github.com/clusterio/clusterio/issues"
|
"url": "https://github.com/clusterio/clusterio/issues"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.0"
|
"@clusterio/lib": "^2.0.0-alpha.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"webpack-merge": "^5.9.0"
|
"webpack-merge": "^5.9.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@sinclair/typebox": "^0.30.4"
|
"@sinclair/typebox": "^0.30.4"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,43 +1,43 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/plugin-inventory_sync",
|
"name": "@clusterio/plugin-inventory_sync",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"description": "Clusterio plugin forwarding between Factorio servers",
|
"description": "Clusterio plugin forwarding between Factorio servers",
|
||||||
"author": "Danielv <danielv@danielv.no>",
|
"author": "Danielv <danielv@danielv.no>",
|
||||||
"homepage": "https://github.com/clusterio/factorioClusterio#readme",
|
"homepage": "https://github.com/clusterio/factorioClusterio#readme",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "clusterio/factorioClusterio",
|
"repository": "clusterio/factorioClusterio",
|
||||||
"main": "dist/plugin/info.js",
|
"main": "dist/plugin/info.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && webpack-cli --env production",
|
"prepare": "tsc --build && webpack-cli --env production",
|
||||||
"test": "echo \"Error: run tests from root\" && exit 1"
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
||||||
},
|
},
|
||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://github.com/clusterio/factorioClusterio/issues"
|
"url": "https://github.com/clusterio/factorioClusterio/issues"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.0"
|
"@clusterio/lib": "^2.0.0-alpha.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@sinclair/typebox": "^0.30.4",
|
"@sinclair/typebox": "^0.30.4",
|
||||||
"fs-extra": "^8.1.0"
|
"fs-extra": "^8.1.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
||||||
"@types/fs-extra": "^11.0.1",
|
"@types/fs-extra": "^11.0.1",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"antd": "^5.7.3",
|
"antd": "^5.7.3",
|
||||||
"react": "^18.2.0",
|
"react": "^18.2.0",
|
||||||
"react-dom": "^18.2.0",
|
"react-dom": "^18.2.0",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"webpack-merge": "^5.9.0"
|
"webpack-merge": "^5.9.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,46 +1,46 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/plugin-player_auth",
|
"name": "@clusterio/plugin-player_auth",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"description": "Clusterio plugin authenticating logged in players to the web interface",
|
"description": "Clusterio plugin authenticating logged in players to the web interface",
|
||||||
"author": "Hornwitser <github@hornwitser.no>",
|
"author": "Hornwitser <github@hornwitser.no>",
|
||||||
"homepage": "https://github.com/clusterio/clusterio#readme",
|
"homepage": "https://github.com/clusterio/clusterio#readme",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "clusterio/clusterio",
|
"repository": "clusterio/clusterio",
|
||||||
"main": "dist/plugin/info.js",
|
"main": "dist/plugin/info.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && webpack-cli --env production",
|
"prepare": "tsc --build && webpack-cli --env production",
|
||||||
"test": "echo \"Error: run tests from root\" && exit 1"
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
||||||
},
|
},
|
||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://github.com/clusterio/clusterio/issues"
|
"url": "https://github.com/clusterio/clusterio/issues"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.0"
|
"@clusterio/lib": "^2.0.0-alpha.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@sinclair/typebox": "^0.30.4",
|
"@sinclair/typebox": "^0.30.4",
|
||||||
"express": "^4.16.2",
|
"express": "^4.16.2",
|
||||||
"jsonwebtoken": "^8.2.1"
|
"jsonwebtoken": "^8.2.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
||||||
"@types/express": "^4.17.17",
|
"@types/express": "^4.17.17",
|
||||||
"@types/jsonwebtoken": "^9.0.2",
|
"@types/jsonwebtoken": "^9.0.2",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"antd": "^5.7.3",
|
"antd": "^5.7.3",
|
||||||
"phin": "^3.7.0",
|
"phin": "^3.7.0",
|
||||||
"react": "^18.2.0",
|
"react": "^18.2.0",
|
||||||
"react-dom": "^18.2.0",
|
"react-dom": "^18.2.0",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"webpack-merge": "^5.9.0"
|
"webpack-merge": "^5.9.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -45,7 +45,7 @@ async function saveTechnologies(
|
|||||||
) {
|
) {
|
||||||
let filePath = path.join(controllerConfig.get("controller.database_directory"), "technologies.json");
|
let filePath = path.join(controllerConfig.get("controller.database_directory"), "technologies.json");
|
||||||
logger.verbose(`writing ${filePath}`);
|
logger.verbose(`writing ${filePath}`);
|
||||||
await lib.safeOutputFile(filePath, JSON.stringify([...technologies.entries()], null, 4));
|
await lib.safeOutputFile(filePath, JSON.stringify([...technologies.entries()], null, "\t"));
|
||||||
}
|
}
|
||||||
|
|
||||||
export class ControllerPlugin extends lib.BaseControllerPlugin {
|
export class ControllerPlugin extends lib.BaseControllerPlugin {
|
||||||
|
|||||||
@@ -1,40 +1,40 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/plugin-research_sync",
|
"name": "@clusterio/plugin-research_sync",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"description": "Clusterio plugin for synchronizing research between Factorio servers",
|
"description": "Clusterio plugin for synchronizing research between Factorio servers",
|
||||||
"author": "Hornwitser <github@hornwitser.no>",
|
"author": "Hornwitser <github@hornwitser.no>",
|
||||||
"homepage": "https://github.com/clusterio/clusterio#readme",
|
"homepage": "https://github.com/clusterio/clusterio#readme",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "clusterio/clusterio",
|
"repository": "clusterio/clusterio",
|
||||||
"main": "dist/plugin/info.js",
|
"main": "dist/plugin/info.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && webpack-cli --env production",
|
"prepare": "tsc --build && webpack-cli --env production",
|
||||||
"test": "echo \"Error: run tests from root\" && exit 1"
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
||||||
},
|
},
|
||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://github.com/clusterio/clusterio/issues"
|
"url": "https://github.com/clusterio/clusterio/issues"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.0"
|
"@clusterio/lib": "^2.0.0-alpha.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@sinclair/typebox": "^0.30.4",
|
"@sinclair/typebox": "^0.30.4",
|
||||||
"fs-extra": "^8.1.0"
|
"fs-extra": "^8.1.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"@types/fs-extra": "^11.0.1",
|
"@types/fs-extra": "^11.0.1",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"webpack-merge": "^5.9.0"
|
"webpack-merge": "^5.9.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,35 +1,35 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/plugin-statistics_exporter",
|
"name": "@clusterio/plugin-statistics_exporter",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"description": "Clusterio plugin for gathering statistics from Factorio servers",
|
"description": "Clusterio plugin for gathering statistics from Factorio servers",
|
||||||
"author": "Hornwitser <github@hornwitser.no>",
|
"author": "Hornwitser <github@hornwitser.no>",
|
||||||
"homepage": "https://github.com/clusterio/clusterio#readme",
|
"homepage": "https://github.com/clusterio/clusterio#readme",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "clusterio/clusterio",
|
"repository": "clusterio/clusterio",
|
||||||
"main": "dist/plugin/info.js",
|
"main": "dist/plugin/info.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && webpack-cli --env production",
|
"prepare": "tsc --build && webpack-cli --env production",
|
||||||
"test": "echo \"Error: run tests from root\" && exit 1"
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
||||||
},
|
},
|
||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://github.com/clusterio/clusterio/issues"
|
"url": "https://github.com/clusterio/clusterio/issues"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.0"
|
"@clusterio/lib": "^2.0.0-alpha.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"webpack-merge": "^5.9.0"
|
"webpack-merge": "^5.9.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,44 +1,44 @@
|
|||||||
{
|
{
|
||||||
"name": "@clusterio/plugin-subspace_storage",
|
"name": "@clusterio/plugin-subspace_storage",
|
||||||
"version": "2.0.0-alpha.13",
|
"version": "2.0.0-alpha.13",
|
||||||
"description": "Clusterio plugin for sharing storage between Factorio servers",
|
"description": "Clusterio plugin for sharing storage between Factorio servers",
|
||||||
"author": "Hornwitser <github@hornwitser.no>",
|
"author": "Hornwitser <github@hornwitser.no>",
|
||||||
"homepage": "https://github.com/clusterio/clusterio#readme",
|
"homepage": "https://github.com/clusterio/clusterio#readme",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": "clusterio/clusterio",
|
"repository": "clusterio/clusterio",
|
||||||
"main": "dist/plugin/info.js",
|
"main": "dist/plugin/info.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"prepare": "tsc --build && webpack-cli --env production",
|
"prepare": "tsc --build && webpack-cli --env production",
|
||||||
"test": "echo \"Error: run tests from root\" && exit 1"
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
||||||
},
|
},
|
||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://github.com/clusterio/clusterio/issues"
|
"url": "https://github.com/clusterio/clusterio/issues"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.0"
|
"@clusterio/lib": "^2.0.0-alpha.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@sinclair/typebox": "^0.30.4",
|
"@sinclair/typebox": "^0.30.4",
|
||||||
"fs-extra": "^8.1.0"
|
"fs-extra": "^8.1.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@clusterio/lib": "^2.0.0-alpha.13",
|
"@clusterio/lib": "^2.0.0-alpha.13",
|
||||||
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
"@clusterio/web_ui": "^2.0.0-alpha.13",
|
||||||
"@types/express": "^4.17.17",
|
"@types/express": "^4.17.17",
|
||||||
"@types/fs-extra": "^11.0.1",
|
"@types/fs-extra": "^11.0.1",
|
||||||
"@types/node": "^20.4.5",
|
"@types/node": "^20.4.5",
|
||||||
"antd": "^5.7.3",
|
"antd": "^5.7.3",
|
||||||
"react": "^18.2.0",
|
"react": "^18.2.0",
|
||||||
"react-dom": "^18.2.0",
|
"react-dom": "^18.2.0",
|
||||||
"typescript": "^5.1.6",
|
"typescript": "^5.1.6",
|
||||||
"webpack": "^5.88.2",
|
"webpack": "^5.88.2",
|
||||||
"webpack-cli": "^5.1.4",
|
"webpack-cli": "^5.1.4",
|
||||||
"webpack-merge": "^5.9.0"
|
"webpack-merge": "^5.9.0"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -107,7 +107,7 @@ describe("Integration of host/src/server", function() {
|
|||||||
let settings = await server.exampleSettings();
|
let settings = await server.exampleSettings();
|
||||||
settings.visibility = { public: false, lan: true };
|
settings.visibility = { public: false, lan: true };
|
||||||
settings.require_user_verification = false;
|
settings.require_user_verification = false;
|
||||||
await fs.outputFile(server.writePath("server-settings.json"), JSON.stringify(settings, null, 4));
|
await fs.outputFile(server.writePath("server-settings.json"), JSON.stringify(settings, null, "\t"));
|
||||||
|
|
||||||
// Make sure the test does not fail due to create() failing.
|
// Make sure the test does not fail due to create() failing.
|
||||||
let mapPath = server.writePath("saves", "test.zip");
|
let mapPath = server.writePath("saves", "test.zip");
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ describe("lib/database", function() {
|
|||||||
|
|
||||||
assert.equal(
|
assert.equal(
|
||||||
await fs.readFile(testFile, { encoding: "utf-8" }),
|
await fs.readFile(testFile, { encoding: "utf-8" }),
|
||||||
'{\n "c": {},\n "d": "foo"\n}'
|
'{\n\t"c": {},\n\t"d": "foo"\n}'
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@@ -155,7 +155,7 @@ describe("lib/database", function() {
|
|||||||
|
|
||||||
assert.equal(
|
assert.equal(
|
||||||
await fs.readFile(testFile, { encoding: "utf-8" }),
|
await fs.readFile(testFile, { encoding: "utf-8" }),
|
||||||
'[\n {\n "id": "c"\n },\n {\n "id": "d"\n }\n]'
|
'[\n\t{\n\t\t"id": "c"\n\t},\n\t{\n\t\t"id": "d"\n\t}\n]'
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
+5
-5
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://typedoc.org/schema.json",
|
"$schema": "https://typedoc.org/schema.json",
|
||||||
"entryPoints": ["packages/lib/"],
|
"entryPoints": ["packages/lib/"],
|
||||||
"entryPointStrategy": "packages",
|
"entryPointStrategy": "packages",
|
||||||
"cleanOutputDir": false,
|
"cleanOutputDir": false,
|
||||||
"out": "docs/api"
|
"out": "docs/api"
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user