Skip to content

Commit 0fe4c8e

Browse files
committed
v1.2.3
1 parent 2f92857 commit 0fe4c8e

File tree

8 files changed

+143
-13
lines changed

8 files changed

+143
-13
lines changed

sm_osx.xcodeproj/project.pbxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@
363363
"$(inherited)",
364364
"@executable_path/../Frameworks",
365365
);
366-
MARKETING_VERSION = 1.2.1;
366+
MARKETING_VERSION = 1.2.3;
367367
ONLY_ACTIVE_ARCH = NO;
368368
PRODUCT_BUNDLE_IDENTIFIER = "com.CubingStudios.sm-osx";
369369
PRODUCT_NAME = "$(TARGET_NAME)";
@@ -395,7 +395,7 @@
395395
"$(inherited)",
396396
"@executable_path/../Frameworks",
397397
);
398-
MARKETING_VERSION = 1.2.1;
398+
MARKETING_VERSION = 1.2.3;
399399
ONLY_ACTIVE_ARCH = NO;
400400
PRODUCT_BUNDLE_IDENTIFIER = "com.CubingStudios.sm-osx";
401401
PRODUCT_NAME = "$(TARGET_NAME)";
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "menu bar logo.svg",
5+
"idiom" : "universal",
6+
"scale" : "1x"
7+
},
8+
{
9+
"idiom" : "universal",
10+
"scale" : "2x"
11+
},
12+
{
13+
"idiom" : "universal",
14+
"scale" : "3x"
15+
}
16+
],
17+
"info" : {
18+
"author" : "xcode",
19+
"version" : 1
20+
}
21+
}
Lines changed: 52 additions & 0 deletions
Loading

sm_osx/GlobalFunctions.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import UniformTypeIdentifiers
1010
import AppKit
1111

1212
struct CurrentVersion {
13-
public let currentVersion = "v1.2.2\n"
13+
public let currentVersion = "v1.2.3\n"
1414
}
1515

1616
public func isArm() -> Bool {

sm_osx/LauncherView.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -412,9 +412,9 @@ struct LauncherView: View {
412412

413413
if (detectArmBrewInstall?.contains("/opt/homebrew/bin/brew") ?? false && detectIntelBrewInstall == "/usr/local/bin/brew\n" && isArm()) || (detectIntelBrewInstall == "/usr/local/bin/brew\n" && !isArm()) {
414414
if isArm() {
415-
homebrewText = "Both versions of homebrew are installed."
415+
homebrewText = ""
416416
} else {
417-
homebrewText = "Homebrew are installed."
417+
homebrewText = ""
418418
}
419419
}
420420
else if !(detectArmBrewInstall?.contains("/opt/homebrew/bin/brew") ?? false) && detectIntelBrewInstall == "/usr/local/bin/brew\n" && isArm() {

sm_osx/MenuBarCommands.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ struct MenuCommands: Commands {
3636
launcherRepos[iE].isEditing = false
3737
}
3838

39-
print(try? Shell().shell("\(LauncherRepo.path ?? "its broken") \(LauncherRepo.args ?? "")"))
39+
print(try? Shell().shell("\(LauncherRepo.path ?? "its broken") \(LauncherRepo.args ?? "")", false))
4040
}
4141
}
4242
}

sm_osx/RomView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ struct RomView: View {
205205
commandsCompile.append("echo 'Compiling Now' && ")
206206

207207
if repo == .sm64ex_coop || repo == .sm64ex_coop_dev {
208-
commandsCompile.append("cd ~/SM64Repos/\(repo) && arch -x86_64 /bin/zsh -cl 'gmake OSX_BUILD=1 TARGET_ARCH=x86_64-apple-darwin TARGET_BITS=64 EXTERNAL_DATA=\(extData) DEBUG=\(debug) COLOR=0 \(compSpeed.rawValue)' && ")
208+
commandsCompile.append("cd ~/SM64Repos/\(repo) && arch -x86_64 /bin/zsh -cl 'gmake OSX_BUILD=1 TARGET_ARCH=x86_64-apple-darwin TARGET_BITS=64 USE_APP=0 EXTERNAL_DATA=\(extData) DEBUG=\(debug) COLOR=0 \(compSpeed.rawValue)' && ")
209209
}
210210
else if repo == .moon64 {
211211
commandsCompile.append("cd ~/SM64Repos/\(repo) && arch -x86_64 /bin/zsh -cl 'gmake OSX_BUILD=1 BETTERCAMERA=\(betterCamera) EXTERNAL_DATA=\(extData) NODRAWDISTANCE=\(drawDistance) \(compSpeed.rawValue)' && ")

sm_osx/sm_osxApp.swift

Lines changed: 63 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,6 @@ struct sm_osxApp: App {
1515
@State var showAddRepos = false
1616
@State var updateAlert = false
1717

18-
func isVentura() -> Bool {
19-
if #available(macOS 13.0, *) { return true } else { return false }
20-
}
21-
2218
var body: some Scene {
2319

2420
WindowGroup {
@@ -29,11 +25,72 @@ struct sm_osxApp: App {
2925
SidebarCommands()
3026

3127
MenuCommands(updateAlert: $updateAlert, showAddRepos: $showAddRepos, dataController: dataController)
32-
3328
}
34-
29+
3530
Settings {
3631
SettingsView()
3732
}
33+
34+
//menuExtras(dataController: dataController, updateAlert: $updateAlert, showAddRepos: $showAddRepos).body
35+
}
36+
}
37+
38+
/*
39+
struct menuExtras: Scene {
40+
41+
@State var dataController: DataController
42+
let moc = NSManagedObjectContext(concurrencyType: .mainQueueConcurrencyType)
43+
@Binding var updateAlert: Bool
44+
@Binding var showAddRepos: Bool
45+
46+
private func fetchLaunchers() -> [LauncherRepos] {
47+
let fetchRequest: NSFetchRequest<LauncherRepos>
48+
fetchRequest = LauncherRepos.fetchRequest()
49+
50+
let context = dataController.container.viewContext
51+
52+
let objects = try? context.fetch(fetchRequest)
53+
54+
return objects ?? []
55+
}
56+
57+
58+
var body: some Scene {
59+
if #available(macOS 13.0, *) {
60+
return MenuBarExtra(isInserted: .constant(true)) {
61+
ForEach(fetchLaunchers()) { Launcher in
62+
Button(Launcher.title ?? "") {
63+
64+
let launcherRepos = fetchLaunchers()
65+
66+
for iE in 0...launcherRepos.count - 1 {
67+
launcherRepos[iE].isEditing = false
68+
}
69+
70+
try? Shell().shell("\(Launcher.path ?? "its broken") \(Launcher.args ?? "")", false)
71+
}
72+
}
73+
74+
Divider()
75+
76+
Button("Add New Repo") {
77+
showAddRepos = true
78+
}
79+
80+
Divider()
81+
82+
Button("Check for Updates") {
83+
checkForUpdates(updateAlert: &updateAlert)
84+
}
85+
86+
Link("Check Latest Changelog", destination: URL(string: "https://github.com/EmeraldLoc/sm_osx/releases/latest")!)
87+
} label: {
88+
Image("menu_bar_dark")
89+
}
90+
} else {
91+
return WindowGroup { EmptyView() }
92+
}
3893
}
3994
}
95+
96+
*/

0 commit comments

Comments
 (0)