mirror of
https://gh.catmak.name/https://github.com/mihomo-party-org/mihomo-party
synced 2025-12-27 21:20:29 +08:00
support yaml anchor
This commit is contained in:
parent
f7f8dc188a
commit
85a324b428
@ -111,7 +111,7 @@ function getRuntimeConfigStr(): string {
|
||||
return fs.readFileSync(mihomoWorkConfigPath(), 'utf8')
|
||||
}
|
||||
|
||||
function getRuntimeConfig(): Record<string, unknown> {
|
||||
function getRuntimeConfig(): IMihomoConfig {
|
||||
return yaml.parse(getRuntimeConfigStr())
|
||||
}
|
||||
|
||||
|
||||
@ -30,6 +30,7 @@ const Proxies: React.FC = () => {
|
||||
const groups: IMihomoGroup[] = []
|
||||
if (proxies && proxies.proxies) {
|
||||
runtime?.['proxy-groups']?.forEach((group: { name: string; url?: string }) => {
|
||||
group = Object.assign(group, group['<<'])
|
||||
const { name, url } = group
|
||||
if (
|
||||
proxies.proxies[name] &&
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user