Skip to content

Commit

Permalink
Merge branch 'meta-dev' into meta
Browse files Browse the repository at this point in the history
  • Loading branch information
mrFq1 committed Jan 2, 2024
2 parents 727c4e7 + 79c0207 commit 645d898
Show file tree
Hide file tree
Showing 9 changed files with 238 additions and 237 deletions.
9 changes: 3 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,9 @@ on:
inputs:
logLevel:

env:
DEVELOPER_DIR: /Applications/Xcode_14.2.app/Contents/Developer

jobs:
build:
runs-on: macos-12
runs-on: macos-13
steps:
- uses: actions/checkout@v3
with:
Expand All @@ -23,8 +20,8 @@ jobs:
- name: download meta core
uses: robinraju/[email protected]
with:
repository: 'MetaCubeX/Clash.Meta'
tag: "v1.16.0"
repository: 'MetaCubeX/mihomo'
tag: "v1.17.0"
fileName: ".*darwin.*64-v.*.gz"

# releaseId: "62870807"
Expand Down
4 changes: 2 additions & 2 deletions ClashX/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -579,13 +579,13 @@ class AppDelegate: NSObject, NSApplicationDelegate {
let outs = out
.split(separator: "\n")
.first {
$0.starts(with: "Clash Meta")
$0.starts(with: "Clash Meta") || $0.starts(with: "Mihomo Meta")
}?.split(separator: " ")
.map(String.init)

guard let outs,
outs.count == 13,
outs[0] == "Clash",
(outs[0] == "Clash" || outs[0] == "Mihomo"),
outs[1] == "Meta",
outs[3] == "darwin" else {
return nil
Expand Down
154 changes: 77 additions & 77 deletions ClashX/Base.lproj/Main.storyboard

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion ClashX/Basic/Logger.swift
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ class Logger {
}

static func log(_ msg: String, level: ClashLogLevel = .info, file: String = #file, function: String = #function) {
shared.logToFile(msg: "[\(level.rawValue)] \(file) \(function) \(msg)", level: level)
let fileName = URL(fileURLWithPath: file).lastPathComponent
shared.logToFile(msg: "[\(level.rawValue)] \(fileName) \(function) \(msg)", level: level)
}

func logFilePath() -> String {
Expand Down
4 changes: 4 additions & 0 deletions ClashX/ClashX Meta SwiftUI-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSLocationAlwaysAndWhenInUseUsageDescription</key>
<string>ClashX use location info to detect your current WiFi network SSID name and provide the auto suspend services.</string>
<key>NSLocationWhenInUseUsageDescription</key>
<string>ClashX use location info to detect your current WiFi network SSID name and provide the auto suspend services.</string>
<key>BETA</key>
<true/>
<key>CFBundleDevelopmentRegion</key>
Expand Down
3 changes: 2 additions & 1 deletion ClashX/General/AlphaMetaDownloader.swift
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,13 @@ class AlphaMetaDownloader: NSObject {
static func alphaAsset() -> Promise<ReleasesResp.Asset> {
Promise { resolver in
let assetName = assetName()
AF.request("https://api.github.com/repos/MetaCubeX/Clash.Meta/releases/tags/Prerelease-Alpha").responseDecodable(of: ReleasesResp.self) {
AF.request("https://api.github.com/repos/MetaCubeX/mihomo/releases/tags/Prerelease-Alpha").responseDecodable(of: ReleasesResp.self) {
guard let assets = $0.value?.assets,
let assetName,
let asset = assets.first(where: {
$0.name.contains(assetName) &&
!$0.name.contains("cgo") &&
!$0.name.contains("go120") &&
$0.state == "uploaded" &&
$0.contentType == "application/gzip"
}) else {
Expand Down
4 changes: 2 additions & 2 deletions ProxyConfigHelper/Helper-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
<key>CFBundleName</key>
<string>com.metacubex.ClashX.ProxyConfigHelper</string>
<key>CFBundleShortVersionString</key>
<string>1.7</string>
<string>1.8</string>
<key>CFBundleVersion</key>
<string>17</string>
<string>18</string>
<key>SMAuthorizedClients</key>
<array>
<string>anchor apple generic and identifier &quot;com.metacubex.ClashX.ProxyConfigHelper&quot; and (certificate leaf[field.1.2.840.113635.100.6.1.9] /* exists */ or certificate 1[field.1.2.840.113635.100.6.2.6] /* exists */ and certificate leaf[field.1.2.840.113635.100.6.1.13] /* exists */ and certificate leaf[subject.OU] = MEWHFZ92DY)</string>
Expand Down
Loading

0 comments on commit 645d898

Please sign in to comment.