mirror of
https://github.com/pompurin404/mihomo-party.git
synced 2024-11-16 03:32:17 +08:00
fix check failed
This commit is contained in:
parent
dd7134c389
commit
deeaa5933d
|
@ -1,4 +1,4 @@
|
|||
import { ChildProcess, execSync, spawn } from 'child_process'
|
||||
import { ChildProcess, execFileSync, execSync, spawn } from 'child_process'
|
||||
import {
|
||||
logPath,
|
||||
mihomoCorePath,
|
||||
|
@ -50,13 +50,11 @@ export function restartCore(): void {
|
|||
startCore()
|
||||
}
|
||||
|
||||
// mihomo -t -d path return status code
|
||||
export function checkProfile(): void {
|
||||
const corePath = mihomoCorePath(getAppConfig().core ?? 'mihomo')
|
||||
generateProfile()
|
||||
if (process.platform !== 'win32') {
|
||||
execSync(`chmod +x ${corePath}`)
|
||||
}
|
||||
|
||||
execSync(`${corePath} -t -f ${mihomoWorkConfigPath()} -d ${mihomoTestDir()}`)
|
||||
execFileSync(corePath, ['-t', '-f', mihomoWorkConfigPath(), '-d', mihomoTestDir()])
|
||||
}
|
||||
|
|
|
@ -17,7 +17,7 @@ const LogItem: React.FC<IMihomoLogInfo> = (props) => {
|
|||
</div>
|
||||
<small className="text-default-500">{time}</small>
|
||||
</CardHeader>
|
||||
<CardBody className="pt-0">{payload}</CardBody>
|
||||
<CardBody className="pt-0 text-sm">{payload}</CardBody>
|
||||
</Card>
|
||||
)
|
||||
}
|
||||
|
|
2
src/shared/types.d.ts
vendored
2
src/shared/types.d.ts
vendored
|
@ -1,5 +1,5 @@
|
|||
type OutboundMode = 'rule' | 'global' | 'direct'
|
||||
type LogLevel = 'info' | 'debug' | 'warn' | 'error' | 'silent'
|
||||
type LogLevel = 'info' | 'debug' | 'warning' | 'error' | 'silent'
|
||||
type SysProxyMode = 'auto' | 'manual'
|
||||
interface IMihomoVersion {
|
||||
version: string
|
||||
|
|
Loading…
Reference in New Issue
Block a user