Pass CLI args to worker and update login script example

The quickLoginExample.bat script was updated to use the new launcher script names and argument format. In napcat.ts, the master process now forwards its command line arguments to the worker process, enabling better parameter handling.
This commit is contained in:
手瓜一十雪 committed 2026-01-17 18:54:18 +08:00
1 parent f1afee8de1
commit 14b301d3e6
2 files changed
+4 -3

No files matched your search

+2 -1
View File
@@ -151,7 +151,8 @@ async function startWorker (): Promise<void> {
const workerScript = getWorkerScriptPath();
const processType = getProcessTypeName();
const child = processManager.createWorker(workerScript, [], {
// 传递 master 进程的命令行参数给 worker 进程
const child = processManager.createWorker(workerScript, process.argv.slice(2), {
env: {
...process.env,
NAPCAT_WORKER_PROCESS: '1',