update add remote config
This commit is contained in:
@@ -64,7 +64,7 @@
|
||||
"filesize": "^11.0.13",
|
||||
"form-data": "^4.0.5",
|
||||
"ignore": "^7.0.5",
|
||||
"inquirer": "^13.0.1",
|
||||
"inquirer": "^13.0.2",
|
||||
"jsonwebtoken": "^9.0.2",
|
||||
"tar": "^7.5.2",
|
||||
"zustand": "^5.0.9"
|
||||
|
||||
278
pnpm-lock.yaml
generated
278
pnpm-lock.yaml
generated
@@ -76,8 +76,8 @@ importers:
|
||||
specifier: ^7.0.5
|
||||
version: 7.0.5
|
||||
inquirer:
|
||||
specifier: ^13.0.1
|
||||
version: 13.0.1(@types/node@24.10.1)
|
||||
specifier: ^13.0.2
|
||||
version: 13.0.2(@types/node@24.10.1)
|
||||
jsonwebtoken:
|
||||
specifier: ^9.0.2
|
||||
version: 9.0.2
|
||||
@@ -202,6 +202,10 @@ packages:
|
||||
resolution: {integrity: sha512-QAZUk6BBncv/XmSEZTscd8qazzjV3E0leUMrEPjxCd51QBgCKmprUGLex5DTsNtURm7LMzv+CLcd6S86xvBfYg==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
|
||||
'@inquirer/ansi@2.0.2':
|
||||
resolution: {integrity: sha512-SYLX05PwJVnW+WVegZt1T4Ip1qba1ik+pNJPDiqvk6zS5Y/i8PhRzLpGEtVd7sW0G8cMtkD8t4AZYhQwm8vnww==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
|
||||
'@inquirer/checkbox@5.0.1':
|
||||
resolution: {integrity: sha512-5VPFBK8jKdsjMK3DTFOlbR0+Kkd4q0AWB7VhWQn6ppv44dr3b7PU8wSJQTC5oA0f/aGW7v/ZozQJAY9zx6PKig==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -211,6 +215,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/checkbox@5.0.2':
|
||||
resolution: {integrity: sha512-iTPV4tMMct7iOpwer5qmTP7gjnk1VQJjsNfAaC2b8Q3qiuHM3K2yjjDr5u1MKfkrvp2JD4Flf8sIPpF21pmZmw==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/confirm@6.0.1':
|
||||
resolution: {integrity: sha512-wD+pM7IxLn1TdcQN12Q6wcFe5VpyCuh/I2sSmqO5KjWH2R4v+GkUToHb+PsDGobOe1MtAlXMwGNkZUPc2+L6NA==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -220,6 +233,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/confirm@6.0.2':
|
||||
resolution: {integrity: sha512-A0/13Wyi+8iFeNDX6D4zZYKPoBLIEbE4K/219qHcnpXMer2weWvaTo63+2c7mQPPA206DEMSYVOPnEw3meOlCw==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/core@11.0.1':
|
||||
resolution: {integrity: sha512-Tpf49h50e4KYffVUCXzkx4gWMafUi3aDQDwfVAAGBNnVcXiwJIj4m2bKlZ7Kgyf6wjt1eyXH1wDGXcAokm4Ssw==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -229,6 +251,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/core@11.0.2':
|
||||
resolution: {integrity: sha512-lgMRx/n02ciiNELBvFLHtmcjbV5tf5D/I0UYfCg2YbTZWmBZ10/niLd3IjWBxz8LtM27xP+4oLEa06Slmb7p7A==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/editor@5.0.1':
|
||||
resolution: {integrity: sha512-zDKobHI7Ry++4noiV9Z5VfYgSVpPZoMApviIuGwLOMciQaP+dGzCO+1fcwI441riklRiZg4yURWyEoX0Zy2zZw==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -238,6 +269,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/editor@5.0.2':
|
||||
resolution: {integrity: sha512-pXQ4Nf0qmFcJuYB6NlcIIxH6l6zKOwNg1Jh/ZRdKd2dTqBB4OXKUFbFwR2K4LVXVtq15ZFFatBVT+rerYR8hWQ==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/expand@5.0.1':
|
||||
resolution: {integrity: sha512-TBrTpAB6uZNnGQHtSEkbvJZIQ3dXZOrwqQSO9uUbwct3G2LitwBCE5YZj98MbQ5nzihzs5pRjY1K9RRLH4WgoA==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -247,6 +287,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/expand@5.0.2':
|
||||
resolution: {integrity: sha512-siFG1swxfjFIOxIcehtZkh+KUNB/YCpyfHNEGu+nC/SBXIbgUWibvThLn/WesSxLRGOeSKdNKoTm+GQCKFm6Ww==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/external-editor@2.0.1':
|
||||
resolution: {integrity: sha512-BPYWJXCAK9w6R+pb2s3WyxUz9ts9SP/LDOUwA9fu7LeuyYgojz83i0DSRwezu736BgMwz14G63Xwj70hSzHohQ==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -256,10 +305,23 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/external-editor@2.0.2':
|
||||
resolution: {integrity: sha512-X/fMXK7vXomRWEex1j8mnj7s1mpnTeP4CO/h2gysJhHLT2WjBnLv4ZQEGpm/kcYI8QfLZ2fgW+9kTKD+jeopLg==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/figures@2.0.1':
|
||||
resolution: {integrity: sha512-KtMxyjLCuDFqAWHmCY9qMtsZ09HnjMsm8H3OvpSIpfhHdfw3/AiGWHNrfRwbyvHPtOJpumm8wGn5fkhtvkWRsg==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
|
||||
'@inquirer/figures@2.0.2':
|
||||
resolution: {integrity: sha512-qXm6EVvQx/FmnSrCWCIGtMHwqeLgxABP8XgcaAoywsL0NFga9gD5kfG0gXiv80GjK9Hsoz4pgGwF/+CjygyV9A==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
|
||||
'@inquirer/input@5.0.1':
|
||||
resolution: {integrity: sha512-cEhEUohCpE2BCuLKtFFZGp4Ief05SEcqeAOq9NxzN5ThOQP8Rl5N/Nt9VEDORK1bRb2Sk/zoOyQYfysPQwyQtA==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -269,6 +331,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/input@5.0.2':
|
||||
resolution: {integrity: sha512-hN2YRo1QiEc9lD3mK+CPnTS4TK2RhCMmMmP4nCWwTkmQL2vx9jPJWYk+rbUZpwR1D583ZJk1FI3i9JZXIpi/qg==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/number@4.0.1':
|
||||
resolution: {integrity: sha512-4//zgBGHe8Q/FfCoUXZUrUHyK/q5dyqiwsePz3oSSPSmw1Ijo35ZkjaftnxroygcUlLYfXqm+0q08lnB5hd49A==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -278,6 +349,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/number@4.0.2':
|
||||
resolution: {integrity: sha512-4McnjTSYrlthNW1ojkkmP75WLRYhQs7GXm6pDDoIrHqJuV5uUYwfdbB0geHdaKMarAqJQgoOVjzIT0jdWCsKew==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/password@5.0.1':
|
||||
resolution: {integrity: sha512-UJudHpd7Ia30Q+x+ctYqI9Nh6SyEkaBscpa7J6Ts38oc1CNSws0I1hJEdxbQBlxQd65z5GEJPM4EtNf6tzfWaQ==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -287,6 +367,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/password@5.0.2':
|
||||
resolution: {integrity: sha512-oSDziMKiw4G2e4zS+0JRfxuPFFGh6N/9yUaluMgEHp2/Yyj2JGwfDO7XbwtOrxVrz+XsP/iaGyWXdQb9d8A0+g==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/prompts@8.0.1':
|
||||
resolution: {integrity: sha512-MURRu/cyvLm9vchDDaVZ9u4p+ADnY0Mz3LQr0KTgihrrvuKZlqcWwlBC4lkOMvd0KKX4Wz7Ww9+uA7qEpQaqjg==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -296,6 +385,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/prompts@8.0.2':
|
||||
resolution: {integrity: sha512-2zK5zY48fZcl6+gG4eqOC/UzZsJckHCRvjXoLuW4D8LKOCVGdcJiSKkLnumSZjR/6PXPINDGOrGHqNxb+sxJDg==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/rawlist@5.0.1':
|
||||
resolution: {integrity: sha512-vVfVHKUgH6rZmMlyd0jOuGZo0Fw1jfcOqZF96lMwlgavx7g0x7MICe316bV01EEoI+c68vMdbkTTawuw3O+Fgw==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -305,6 +403,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/rawlist@5.0.2':
|
||||
resolution: {integrity: sha512-AcNALEdQKUQDeJcpC1a3YC53m1MLv+sMUS+vRZ8Qigs1Yg3Dcdtmi82rscJplogKOY8CXkKW4wvVwHS2ZjCIBQ==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/search@4.0.1':
|
||||
resolution: {integrity: sha512-XwiaK5xBvr31STX6Ji8iS3HCRysBXfL/jUbTzufdWTS6LTGtvDQA50oVETt1BJgjKyQBp9vt0VU6AmU/AnOaGA==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -314,6 +421,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/search@4.0.2':
|
||||
resolution: {integrity: sha512-hg63w5toohdzE65S3LiGhdfIL0kT+yisbZARf7zw65PvyMUTutTN3eMAvD/B6y/25z88vTrB7kSB45Vz5CbrXg==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/select@5.0.1':
|
||||
resolution: {integrity: sha512-gPByrgYoezGyKMq5KjV7Tuy1JU2ArIy6/sI8sprw0OpXope3VGQwP5FK1KD4eFFqEhKu470Dwe6/AyDPmGRA0Q==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -323,6 +439,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/select@5.0.2':
|
||||
resolution: {integrity: sha512-JygTohvQxSNnvt7IKANVlg/eds+yN5sLRilYeGc4ri/9Aqi/2QPoXBMV5Cz/L1VtQv63SnTbPXJZeCK2pSwsOA==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/type@4.0.1':
|
||||
resolution: {integrity: sha512-odO8YwoQAw/eVu/PSPsDDVPmqO77r/Mq7zcoF5VduVqIu2wSRWUgmYb5K9WH1no0SjLnOe8MDKtDL++z6mfo2g==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
@@ -332,6 +457,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@inquirer/type@4.0.2':
|
||||
resolution: {integrity: sha512-cae7mzluplsjSdgFA6ACLygb5jC8alO0UUnFPyu0E7tNRPrL+q/f8VcSXp+cjZQ7l5CMpDpi2G1+IQvkOiL1Lw==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
'@isaacs/fs-minipass@4.0.1':
|
||||
resolution: {integrity: sha512-wgm9Ehl2jpeqP3zw/7mo3kRHFp5MEDhqAdwy1fTGkHAwnkGOVsgpvQhL8B5n1qlb01jV3n/bI0ZfZp5lWA1k4w==}
|
||||
engines: {node: '>=18.0.0'}
|
||||
@@ -1072,6 +1206,15 @@ packages:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
inquirer@13.0.2:
|
||||
resolution: {integrity: sha512-dgqORaV0s5vgDPFS5eSkq67xxDz8F4s1loWlDlSkqGs2JpU6WVIlp3c5TUvVDKwl53DlkcHYXzbEXDf4/Ipv3g==}
|
||||
engines: {node: '>=23.5.0 || ^22.13.0 || ^21.7.0 || ^20.12.0'}
|
||||
peerDependencies:
|
||||
'@types/node': '>=18'
|
||||
peerDependenciesMeta:
|
||||
'@types/node':
|
||||
optional: true
|
||||
|
||||
ip-address@9.0.5:
|
||||
resolution: {integrity: sha512-zHtQzGojZXTwZTHQqra+ETKd4Sn3vgi7uBmlPoXVWZqYvuKmtI0l/VZTjqGmJY9x88GGOaZ9+G9ES8hC4T4X8g==}
|
||||
engines: {node: '>= 12'}
|
||||
@@ -1707,6 +1850,8 @@ snapshots:
|
||||
|
||||
'@inquirer/ansi@2.0.1': {}
|
||||
|
||||
'@inquirer/ansi@2.0.2': {}
|
||||
|
||||
'@inquirer/checkbox@5.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.1
|
||||
@@ -1716,6 +1861,15 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/checkbox@5.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.2
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/figures': 2.0.2
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/confirm@6.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.1(@types/node@24.10.1)
|
||||
@@ -1723,6 +1877,13 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/confirm@6.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/core@11.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.1
|
||||
@@ -1735,6 +1896,18 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/core@11.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.2
|
||||
'@inquirer/figures': 2.0.2
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
cli-width: 4.1.0
|
||||
mute-stream: 3.0.0
|
||||
signal-exit: 4.1.0
|
||||
wrap-ansi: 9.0.2
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/editor@5.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.1(@types/node@24.10.1)
|
||||
@@ -1743,6 +1916,14 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/editor@5.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/external-editor': 2.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/expand@5.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.1(@types/node@24.10.1)
|
||||
@@ -1750,6 +1931,13 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/expand@5.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/external-editor@2.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
chardet: 2.1.1
|
||||
@@ -1757,8 +1945,17 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/external-editor@2.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
chardet: 2.1.1
|
||||
iconv-lite: 0.7.0
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/figures@2.0.1': {}
|
||||
|
||||
'@inquirer/figures@2.0.2': {}
|
||||
|
||||
'@inquirer/input@5.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.1(@types/node@24.10.1)
|
||||
@@ -1766,6 +1963,13 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/input@5.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/number@4.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.1(@types/node@24.10.1)
|
||||
@@ -1773,6 +1977,13 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/number@4.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/password@5.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.1
|
||||
@@ -1781,6 +1992,14 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/password@5.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.2
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/prompts@8.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/checkbox': 5.0.1(@types/node@24.10.1)
|
||||
@@ -1796,6 +2015,21 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/prompts@8.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/checkbox': 5.0.2(@types/node@24.10.1)
|
||||
'@inquirer/confirm': 6.0.2(@types/node@24.10.1)
|
||||
'@inquirer/editor': 5.0.2(@types/node@24.10.1)
|
||||
'@inquirer/expand': 5.0.2(@types/node@24.10.1)
|
||||
'@inquirer/input': 5.0.2(@types/node@24.10.1)
|
||||
'@inquirer/number': 4.0.2(@types/node@24.10.1)
|
||||
'@inquirer/password': 5.0.2(@types/node@24.10.1)
|
||||
'@inquirer/rawlist': 5.0.2(@types/node@24.10.1)
|
||||
'@inquirer/search': 4.0.2(@types/node@24.10.1)
|
||||
'@inquirer/select': 5.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/rawlist@5.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.1(@types/node@24.10.1)
|
||||
@@ -1803,6 +2037,13 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/rawlist@5.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/search@4.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.1(@types/node@24.10.1)
|
||||
@@ -1811,6 +2052,14 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/search@4.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/figures': 2.0.2
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/select@5.0.1(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.1
|
||||
@@ -1820,10 +2069,23 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/select@5.0.2(@types/node@24.10.1)':
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.2
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/figures': 2.0.2
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/type@4.0.1(@types/node@24.10.1)':
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@inquirer/type@4.0.2(@types/node@24.10.1)':
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
'@isaacs/fs-minipass@4.0.1':
|
||||
dependencies:
|
||||
minipass: 7.1.2
|
||||
@@ -2540,6 +2802,18 @@ snapshots:
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
inquirer@13.0.2(@types/node@24.10.1):
|
||||
dependencies:
|
||||
'@inquirer/ansi': 2.0.2
|
||||
'@inquirer/core': 11.0.2(@types/node@24.10.1)
|
||||
'@inquirer/prompts': 8.0.2(@types/node@24.10.1)
|
||||
'@inquirer/type': 4.0.2(@types/node@24.10.1)
|
||||
mute-stream: 3.0.0
|
||||
run-async: 4.0.6
|
||||
rxjs: 7.8.2
|
||||
optionalDependencies:
|
||||
'@types/node': 24.10.1
|
||||
|
||||
ip-address@9.0.5:
|
||||
dependencies:
|
||||
jsbn: 1.1.0
|
||||
|
||||
96
src/command/config-remote.ts
Normal file
96
src/command/config-remote.ts
Normal file
@@ -0,0 +1,96 @@
|
||||
import { program, Command } from '@/program.ts';
|
||||
import { query } from '@/module/query.ts';
|
||||
import { QueryConfig } from '@/query/query-config/query-config.ts';
|
||||
import { showMore } from '@/uitls/show-more.ts';
|
||||
import fs from 'node:fs';
|
||||
import path from 'node:path';
|
||||
|
||||
const queryConfig = new QueryConfig({ query: query as any });
|
||||
const command = new Command('remote-config')
|
||||
.alias('rc').description('获取或设置远程配置');
|
||||
|
||||
|
||||
const getCommand = new Command('get')
|
||||
.option('-k, --key <key>', '配置键名')
|
||||
.action(async (options) => {
|
||||
const { key } = options || {};
|
||||
if (!key) {
|
||||
console.log('Please provide a key using -k or --key option.');
|
||||
return;
|
||||
}
|
||||
const res = await queryConfig.getConfigByKey(key);
|
||||
console.log('res Config Result:', showMore(res.data));
|
||||
})
|
||||
|
||||
const listCommand = new Command('list')
|
||||
.description('列出所有配置')
|
||||
.action(async () => {
|
||||
const res = await queryConfig.listConfig();
|
||||
console.log('Remote Configs:', res);
|
||||
if (res.code === 200) {
|
||||
const list = res.data?.list || [];
|
||||
list.forEach(item => {
|
||||
console.log(item.id, item.key, item.data);
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
const updateCommand = new Command('update')
|
||||
.description('更新远程配置')
|
||||
.option('-k, --key <key>', '配置键名')
|
||||
.option('-v, --value <value>', '配置值')
|
||||
.option('-f, --file <file>', '从文件读取配置值')
|
||||
.action(async (options) => {
|
||||
const { key, value, file } = options || {};
|
||||
if (!key) {
|
||||
console.log('请提供配置键名,使用 -k 或 --key 选项。', options);
|
||||
return;
|
||||
}
|
||||
try {
|
||||
let data: any = {}
|
||||
const filePath = path.resolve(process.cwd(), file);
|
||||
const hasFile = fs.existsSync(filePath);
|
||||
if (value) {
|
||||
data = JSON.parse(value);
|
||||
} else if (file || hasFile) {
|
||||
// 从文件读取配置值
|
||||
if (!hasFile) {
|
||||
console.log('指定的文件不存在:', filePath);
|
||||
return;
|
||||
}
|
||||
data = JSON.parse(fs.readFileSync(filePath, 'utf-8'));
|
||||
} else {
|
||||
console.log('请提供配置值,使用 -v 或 --value 选项,或使用 -f 或 --file 从文件读取。');
|
||||
return;
|
||||
}
|
||||
const res = await queryConfig.updateConfig({
|
||||
key,
|
||||
data,
|
||||
});
|
||||
console.log('Update Config Result:', showMore(res.data));
|
||||
} catch (error) {
|
||||
console.log('Error parsing JSON:');
|
||||
}
|
||||
});
|
||||
|
||||
const deleteCommand = new Command('delete')
|
||||
.description('删除远程配置')
|
||||
.option('-i, --id <id>', '配置ID')
|
||||
.option('-k, --key <key>', '配置键名')
|
||||
.action(async (options) => {
|
||||
const { key, id } = options || {};
|
||||
if (!key && !id) {
|
||||
console.log('请提供配置键名或配置ID,使用 -k 或 --key 选项,或 -i 或 --id 选项。');
|
||||
return;
|
||||
}
|
||||
const res = await queryConfig.deleteConfig({ key, id });
|
||||
console.log('Delete Config Result:', showMore(res));
|
||||
});
|
||||
|
||||
command.addCommand(listCommand);
|
||||
command.addCommand(getCommand);
|
||||
command.addCommand(updateCommand);
|
||||
command.addCommand(deleteCommand);
|
||||
|
||||
program.addCommand(command);
|
||||
@@ -15,6 +15,8 @@ import './command/sync/sync.ts';
|
||||
import './command/app/index.ts';
|
||||
|
||||
import './command/gist/index.ts';
|
||||
import './command/config-remote.ts';
|
||||
|
||||
// program.parse(process.argv);
|
||||
|
||||
export const runParser = async (argv: string[]) => {
|
||||
|
||||
121
src/query/query-config/query-config.ts
Normal file
121
src/query/query-config/query-config.ts
Normal file
@@ -0,0 +1,121 @@
|
||||
/**
|
||||
* 配置查询
|
||||
* @updatedAt 2025-12-03 10:33:00
|
||||
*/
|
||||
import { Query } from '@kevisual/query';
|
||||
import type { Result } from '@kevisual/query/query';
|
||||
type QueryConfigOpts = {
|
||||
query?: Query;
|
||||
};
|
||||
export type Config<T = any> = {
|
||||
id?: string;
|
||||
title?: string;
|
||||
key?: string;
|
||||
description?: string;
|
||||
data?: T;
|
||||
createdAt?: string;
|
||||
updatedAt?: string;
|
||||
};
|
||||
export type UploadConfig = {
|
||||
key?: string;
|
||||
version?: string;
|
||||
};
|
||||
type PostOpts = {
|
||||
token?: string;
|
||||
payload?: Record<string, any>;
|
||||
};
|
||||
export const defaultConfigKeys = ['upload.json', 'workspace.json', 'ai.json', 'user.json', 'life.json'] as const;
|
||||
type DefaultConfigKey = (typeof defaultConfigKeys)[number];
|
||||
|
||||
export class QueryConfig {
|
||||
query: Query;
|
||||
constructor(opts?: QueryConfigOpts) {
|
||||
this.query = opts?.query || new Query();
|
||||
}
|
||||
async post<T = Config>(data: any) {
|
||||
return this.query.post<T>({ path: 'config', ...data });
|
||||
}
|
||||
async getConfig({ id, key }: { id?: string; key?: string }, opts?: PostOpts) {
|
||||
return this.post({
|
||||
key: 'get',
|
||||
data: {
|
||||
id,
|
||||
key,
|
||||
},
|
||||
...opts,
|
||||
});
|
||||
}
|
||||
async updateConfig(data: Config, opts?: PostOpts) {
|
||||
return this.post({
|
||||
key: 'update',
|
||||
data,
|
||||
...opts,
|
||||
});
|
||||
}
|
||||
async deleteConfig(data: { id?: string, key?: string }, opts?: PostOpts) {
|
||||
console.log('Delete Config Params:', data);
|
||||
return this.post({
|
||||
key: 'delete',
|
||||
data,
|
||||
});
|
||||
}
|
||||
async listConfig(opts?: PostOpts) {
|
||||
return this.post<{ list: Config[] }>({
|
||||
key: 'list',
|
||||
...opts,
|
||||
});
|
||||
}
|
||||
/**
|
||||
* 获取上传配置
|
||||
* @returns
|
||||
*/
|
||||
async getUploadConfig(opts?: PostOpts) {
|
||||
return this.post<Result<Config<UploadConfig>>>({
|
||||
key: 'getUploadConfig',
|
||||
...opts,
|
||||
});
|
||||
}
|
||||
/**
|
||||
* 更新上传配置
|
||||
* @param data
|
||||
* @returns
|
||||
*/
|
||||
async updateUploadConfig(data: Config, opts?: PostOpts) {
|
||||
return this.post<Result<Config<UploadConfig>>>({
|
||||
key: 'updateUploadConfig',
|
||||
data,
|
||||
...opts,
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 检测配置是否存在
|
||||
* @param id
|
||||
* @returns
|
||||
*/
|
||||
async detectConfig(opts?: PostOpts) {
|
||||
return this.post<{ updateList: Config[] }>({
|
||||
key: 'detect',
|
||||
...opts,
|
||||
});
|
||||
}
|
||||
/**
|
||||
* 获取配置, 获取默认的配置项
|
||||
* @param key
|
||||
* @returns
|
||||
*/
|
||||
async getConfigByKey(key: DefaultConfigKey, opts?: PostOpts) {
|
||||
return this.post<Result<Config>>({
|
||||
key: 'defaultConfig',
|
||||
configKey: key,
|
||||
...opts,
|
||||
});
|
||||
}
|
||||
async getByKey<T = any>(key: string, opts?: PostOpts) {
|
||||
return this.post<Result<Config<T>>>({
|
||||
key: 'get',
|
||||
...opts,
|
||||
data: { key },
|
||||
});
|
||||
}
|
||||
}
|
||||
5
src/uitls/show-more.ts
Normal file
5
src/uitls/show-more.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
import util from 'node:util';
|
||||
|
||||
export const showMore = (obj: any, depth = 5) => {
|
||||
return util.inspect(obj, { showHidden: false, depth, colors: true });
|
||||
};
|
||||
Reference in New Issue
Block a user