-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpackage.json
119 lines (119 loc) · 5.31 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
{
"name": "paradox-anticheat",
"version": "3.4.6",
"productName": "Paradox-AntiCheat",
"description": "A utility to fight against malicious hackers on Bedrock Edition",
"private": true,
"type": "module",
"devDependencies": {
"@types/fs-extra": "11.0.4",
"@types/glob": "8.1.0",
"@types/node": "20.11.16",
"@typescript-eslint/eslint-plugin": "6.21.0",
"@typescript-eslint/parser": "6.21.0",
"7zip-bin": "5.2.0",
"adm-zip": "0.5.10",
"chmodr": "1.2.0",
"docsify-cli": "4.4.4",
"eslint": "^8.56.0",
"eslint-config-prettier": "9.1.0",
"eslint-plugin-prettier": "5.1.3",
"finalhandler": "1.2.0",
"fs-extra": "11.2.0",
"glob": "10.3.10",
"prettier": "3.2.5",
"serve-static": "1.15.0",
"typescript": "5.3.3"
},
"dependencies": {
"@minecraft/server": "1.9.0-beta.1.20.60-stable",
"@minecraft/server-ui": "1.2.0-beta.1.20.60-stable"
},
"eslintConfig": {
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module"
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"prettier"
],
"plugins": [
"@typescript-eslint",
"prettier"
],
"env": {
"node": true
},
"rules": {
"indent": [
"error",
4,
{
"SwitchCase": 1
}
],
"semi": [
"error",
"always"
],
"comma-style": [
"error",
"last"
],
"linebreak-style": [
"error",
"unix"
],
"no-constant-condition": [
"error",
{
"checkLoops": false
}
],
"no-empty": [
"error",
{
"allowEmptyCatch": true
}
],
"no-prototype-builtins": "off",
"prettier/prettier": [
"error",
{
"trailingComma": "es5",
"tabWidth": 4,
"useTabs": false,
"semi": true,
"printWidth": 250
}
]
}
},
"scripts": {
"postinstall": "npm install --prefix src @minecraft/[email protected] && npm install --prefix src [email protected]",
"enableMcLoopback": "CheckNetIsolation.exe LoopbackExempt -a -p=S-1-15-2-1958404141-86561845-1752920682-3514627264-368642714-62675701-733520436",
"enableMcPreviewLoopback": "CheckNetIsolation.exe LoopbackExempt -a -p=S-1-15-2-424268864-5579737-879501358-346833251-474568803-887069379-4040235476",
"format": "eslint --fix .",
"test-build": "node test-build.js",
"linux//": " --- BUILD (Linux) --- ",
"server": "node_modules/docsify-cli/bin/docsify serve docs",
"clean": "rm -rf build/",
"mkDirs": "mkdir -p build",
"copy:vanilla-data": "cp -R src/node_modules build/scripts",
"copy:assets": "cp -R animation_controllers/ animations entities/ functions/ CHANGELOG.md LICENSE manifest.json pack_icon.png README.md build",
"build": "npm run format; ./node_modules/typescript/bin/tsc -p tsconfig.json; npm run copy:assets; npm run copy:vanilla-data",
"dist": "npm run clean; npm run format; npm run build; cd build; zip -0 -r Paradox-AntiCheat-v${npm_package_version}.mcpack .",
"windows//": " --- BUILD (Windows) --- ",
"server_win": "node node_modules\\docsify-cli\\bin\\docsify serve docs",
"clean_win": "rd /s /q build>nul 2>&1|echo.>nul",
"mkdir_win": "@if exist build (rd /s /q build && mkdir build) else (mkdir build)",
"copy:win-vanilla-data": "@powershell Copy-Item -Path ^(\\\"src\\node_modules\\\"^) -Destination \"build\\scripts\" -Recurse",
"copy_assets_win": "@powershell Copy-Item -Path ^(\\\"animation_controllers\\\",\\\"animations\\\",\\\"entities\\\",\\\"functions\\\",\\\"CHANGELOG.md\\\",\\\"LICENSE\\\",\\\"manifest.json\\\",\\\"pack_icon.png\\\",\\\"README.md\\\"^) -Destination \"build\" -Recurse",
"build_win": "npm run format && npm run mkdir_win 1>nul && node node_modules\\typescript\\bin\\tsc -p tsconfig.json && npm run copy_assets_win 1>nul && npm run copy:win-vanilla-data 1>nul",
"build_win_noscript": "npm run mkdir_win 1>nul && npm run copy_assets_win 1>nul",
"zip_win": "npm run clean_win && npm run build_win && cd build && node -e \"const path = require('path'); const arch = process.arch.startsWith('arm') ? 'arm64' : (process.arch === 'x32' ? 'ia32' : 'x64'); const executable = path.join(__dirname, '..', 'node_modules', '7zip-bin', 'win', arch, '7za'); require('child_process').execSync(`${executable} a -tzip Paradox-AntiCheat-v%npm_package_version%.zip .`);\"",
"dist_win": "npm run clean_win && npm run format && npm run build_win 1>nul && npm run zip_win 1>nul && powershell -Command \"Rename-Item -Path 'build\\Paradox-AntiCheat-v%npm_package_version%.zip' -NewName 'Paradox-AntiCheat-v%npm_package_version%.mcpack'\""
}
}