Skip to content

Commit ef7b4c5

Browse files
authored
Merge pull request #133 from sameerasw/main
upstream
2 parents d52812d + 7cf74e1 commit ef7b4c5

11 files changed

Lines changed: 264 additions & 17 deletions

File tree

.github/FUNDING.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,6 @@ lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cl
1212
polar: # Replace with a single Polar username
1313
buy_me_a_coffee: sameerasw
1414
thanks_dev: # Replace with a single thanks.dev username
15-
custom: ['airsync.sameerasw.com'] # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
15+
custom: ['store.sameerasw.com'] # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
1616

1717
#template for @sameerasw

AirSync.xcodeproj/project.pbxproj

Lines changed: 112 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,116 @@
163163
/* End PBXSourcesBuildPhase section */
164164

165165
/* Begin XCBuildConfiguration section */
166+
11F6093B2EA2A88900AB6BDC /* Self Compiled */ = {
167+
isa = XCBuildConfiguration;
168+
baseConfigurationReferenceAnchor = B9673B592E35A2A1006D284A /* airsync-mac */;
169+
baseConfigurationReferenceRelativePath = Configs/SelfCompiled.xcconfig;
170+
buildSettings = {
171+
ALWAYS_SEARCH_USER_PATHS = NO;
172+
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
173+
CLANG_ANALYZER_NONNULL = YES;
174+
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
175+
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
176+
CLANG_ENABLE_MODULES = YES;
177+
CLANG_ENABLE_OBJC_ARC = YES;
178+
CLANG_ENABLE_OBJC_WEAK = YES;
179+
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
180+
CLANG_WARN_BOOL_CONVERSION = YES;
181+
CLANG_WARN_COMMA = YES;
182+
CLANG_WARN_CONSTANT_CONVERSION = YES;
183+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
184+
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
185+
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
186+
CLANG_WARN_EMPTY_BODY = YES;
187+
CLANG_WARN_ENUM_CONVERSION = YES;
188+
CLANG_WARN_INFINITE_RECURSION = YES;
189+
CLANG_WARN_INT_CONVERSION = YES;
190+
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
191+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
192+
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
193+
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
194+
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
195+
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
196+
CLANG_WARN_STRICT_PROTOTYPES = YES;
197+
CLANG_WARN_SUSPICIOUS_MOVE = YES;
198+
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
199+
CLANG_WARN_UNREACHABLE_CODE = YES;
200+
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
201+
COPY_PHASE_STRIP = NO;
202+
DEAD_CODE_STRIPPING = YES;
203+
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
204+
DEVELOPMENT_TEAM = WCB4HTANA6;
205+
ENABLE_NS_ASSERTIONS = NO;
206+
ENABLE_STRICT_OBJC_MSGSEND = YES;
207+
ENABLE_TESTABILITY = NO;
208+
ENABLE_USER_SCRIPT_SANDBOXING = YES;
209+
GCC_C_LANGUAGE_STANDARD = gnu17;
210+
GCC_NO_COMMON_BLOCKS = YES;
211+
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
212+
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
213+
GCC_WARN_UNDECLARED_SELECTOR = YES;
214+
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
215+
GCC_WARN_UNUSED_FUNCTION = YES;
216+
GCC_WARN_UNUSED_VARIABLE = YES;
217+
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
218+
MACOSX_DEPLOYMENT_TARGET = 26.0;
219+
MTL_ENABLE_DEBUG_INFO = NO;
220+
MTL_FAST_MATH = YES;
221+
ONLY_ACTIVE_ARCH = NO;
222+
SDKROOT = macosx;
223+
STRING_CATALOG_GENERATE_SYMBOLS = YES;
224+
SWIFT_COMPILATION_MODE = wholemodule;
225+
};
226+
name = "Self Compiled";
227+
};
228+
11F6093C2EA2A88900AB6BDC /* Self Compiled */ = {
229+
isa = XCBuildConfiguration;
230+
baseConfigurationReferenceAnchor = B9673B592E35A2A1006D284A /* airsync-mac */;
231+
baseConfigurationReferenceRelativePath = Configs/SelfCompiled.xcconfig;
232+
buildSettings = {
233+
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
234+
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
235+
ASSETCATALOG_COMPILER_INCLUDE_ALL_APPICON_ASSETS = YES;
236+
AUTOMATION_APPLE_EVENTS = NO;
237+
CODE_SIGN_ENTITLEMENTS = "";
238+
CODE_SIGN_STYLE = Automatic;
239+
COMBINE_HIDPI_IMAGES = YES;
240+
CURRENT_PROJECT_VERSION = 11;
241+
DEAD_CODE_STRIPPING = YES;
242+
DEVELOPMENT_TEAM = WCB4HTANA6;
243+
ENABLE_APP_SANDBOX = NO;
244+
ENABLE_HARDENED_RUNTIME = YES;
245+
ENABLE_PREVIEWS = YES;
246+
ENABLE_RESOURCE_ACCESS_PHOTO_LIBRARY = NO;
247+
GENERATE_INFOPLIST_FILE = YES;
248+
INFOPLIST_FILE = "airsync-mac/Info.plist";
249+
INFOPLIST_KEY_CFBundleDisplayName = AirSync;
250+
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.productivity";
251+
INFOPLIST_KEY_LSUIElement = NO;
252+
INFOPLIST_KEY_NSHumanReadableCopyright = "";
253+
LD_RUNPATH_SEARCH_PATHS = (
254+
"$(inherited)",
255+
"@executable_path/../Frameworks",
256+
);
257+
MACOSX_DEPLOYMENT_TARGET = 14.5;
258+
MARKETING_VERSION = 2.1.1;
259+
PRODUCT_BUNDLE_IDENTIFIER = "sameerasw.airsync-mac";
260+
PRODUCT_NAME = "$(TARGET_NAME)";
261+
REGISTER_APP_GROUPS = YES;
262+
RUNTIME_EXCEPTION_ALLOW_DYLD_ENVIRONMENT_VARIABLES = NO;
263+
RUNTIME_EXCEPTION_ALLOW_JIT = NO;
264+
RUNTIME_EXCEPTION_ALLOW_UNSIGNED_EXECUTABLE_MEMORY = NO;
265+
RUNTIME_EXCEPTION_DEBUGGING_TOOL = NO;
266+
RUNTIME_EXCEPTION_DISABLE_EXECUTABLE_PAGE_PROTECTION = NO;
267+
RUNTIME_EXCEPTION_DISABLE_LIBRARY_VALIDATION = YES;
268+
STRING_CATALOG_GENERATE_SYMBOLS = YES;
269+
SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor;
270+
SWIFT_EMIT_LOC_STRINGS = YES;
271+
SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES;
272+
SWIFT_VERSION = 5.0;
273+
};
274+
name = "Self Compiled";
275+
};
166276
B9673B602E35A2A3006D284A /* Debug */ = {
167277
isa = XCBuildConfiguration;
168278
buildSettings = {
@@ -387,6 +497,7 @@
387497
buildConfigurations = (
388498
B9673B602E35A2A3006D284A /* Debug */,
389499
B9673B612E35A2A3006D284A /* Release */,
500+
11F6093B2EA2A88900AB6BDC /* Self Compiled */,
390501
);
391502
defaultConfigurationIsVisible = 0;
392503
defaultConfigurationName = Release;
@@ -396,6 +507,7 @@
396507
buildConfigurations = (
397508
B9673B632E35A2A3006D284A /* Debug */,
398509
B9673B642E35A2A3006D284A /* Release */,
510+
11F6093C2EA2A88900AB6BDC /* Self Compiled */,
399511
);
400512
defaultConfigurationIsVisible = 0;
401513
defaultConfigurationName = Release;
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Scheme
3+
LastUpgradeVersion = "2600"
4+
version = "2.2">
5+
<BuildAction
6+
parallelizeBuildables = "YES"
7+
buildImplicitDependencies = "YES"
8+
buildArchitectures = "Automatic">
9+
<BuildActionEntries>
10+
<BuildActionEntry
11+
buildForTesting = "YES"
12+
buildForRunning = "YES"
13+
buildForProfiling = "YES"
14+
buildForArchiving = "YES"
15+
buildForAnalyzing = "YES">
16+
<AutocreatedTestPlanReference>
17+
</AutocreatedTestPlanReference>
18+
</BuildActionEntry>
19+
<BuildActionEntry
20+
buildForTesting = "YES"
21+
buildForRunning = "YES"
22+
buildForProfiling = "YES"
23+
buildForArchiving = "YES"
24+
buildForAnalyzing = "YES">
25+
<BuildableReference
26+
BuildableIdentifier = "primary"
27+
BlueprintIdentifier = "B9673B562E35A2A1006D284A"
28+
BuildableName = "AirSync.app"
29+
BlueprintName = "AirSync"
30+
ReferencedContainer = "container:AirSync.xcodeproj">
31+
</BuildableReference>
32+
</BuildActionEntry>
33+
</BuildActionEntries>
34+
</BuildAction>
35+
<TestAction
36+
buildConfiguration = "Self Compiled"
37+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
38+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
39+
shouldUseLaunchSchemeArgsEnv = "YES"
40+
shouldAutocreateTestPlan = "YES">
41+
</TestAction>
42+
<LaunchAction
43+
buildConfiguration = "Self Compiled"
44+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
45+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
46+
launchStyle = "0"
47+
useCustomWorkingDirectory = "NO"
48+
ignoresPersistentStateOnLaunch = "NO"
49+
debugDocumentVersioning = "YES"
50+
debugServiceExtension = "internal"
51+
allowLocationSimulation = "YES">
52+
<BuildableProductRunnable
53+
runnableDebuggingMode = "0">
54+
<BuildableReference
55+
BuildableIdentifier = "primary"
56+
BlueprintIdentifier = "B9673B562E35A2A1006D284A"
57+
BuildableName = "AirSync.app"
58+
BlueprintName = "AirSync"
59+
ReferencedContainer = "container:AirSync.xcodeproj">
60+
</BuildableReference>
61+
</BuildableProductRunnable>
62+
</LaunchAction>
63+
<ProfileAction
64+
buildConfiguration = "Self Compiled"
65+
shouldUseLaunchSchemeArgsEnv = "YES"
66+
savedToolIdentifier = ""
67+
useCustomWorkingDirectory = "NO"
68+
debugDocumentVersioning = "YES">
69+
<MacroExpansion>
70+
<BuildableReference
71+
BuildableIdentifier = "primary"
72+
BlueprintIdentifier = "B9673B562E35A2A1006D284A"
73+
BuildableName = "AirSync.app"
74+
BlueprintName = "AirSync"
75+
ReferencedContainer = "container:AirSync.xcodeproj">
76+
</BuildableReference>
77+
</MacroExpansion>
78+
</ProfileAction>
79+
<AnalyzeAction
80+
buildConfiguration = "Self Compiled">
81+
</AnalyzeAction>
82+
<ArchiveAction
83+
buildConfiguration = "Self Compiled"
84+
revealArchiveInOrganizer = "YES">
85+
</ArchiveAction>
86+
</Scheme>

AirSync.xcodeproj/xcshareddata/xcschemes/AirSync.xcscheme

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
33
LastUpgradeVersion = "2600"
4-
version = "2.0">
4+
version = "2.2">
55
<BuildAction
66
parallelizeBuildables = "YES"
77
buildImplicitDependencies = "YES"
@@ -21,6 +21,15 @@
2121
ReferencedContainer = "container:AirSync.xcodeproj">
2222
</BuildableReference>
2323
</BuildActionEntry>
24+
<BuildActionEntry
25+
buildForTesting = "YES"
26+
buildForRunning = "YES"
27+
buildForProfiling = "YES"
28+
buildForArchiving = "YES"
29+
buildForAnalyzing = "YES">
30+
<AutocreatedTestPlanReference>
31+
</AutocreatedTestPlanReference>
32+
</BuildActionEntry>
2433
</BuildActionEntries>
2534
</BuildAction>
2635
<TestAction

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
- Min : macOS 14.5
2020
- Opt: scrcpy, adb & media-control brew installs
2121

22+
## Building Locally
23+
In XCode, select the `AirSync Self Compiled` Scheme. Then at the menu bar, select `Product -> Archive`. Once this process is finished, the organizer window will pop up. Select `Distribute`, then `Custom`. Select `Copy App`, then select the folder for output. `AirSync.app` will be located in that folder.
24+
2225
## Contributors <3
2326

2427
<a href="https://github.com/sameerasw/airsync-mac/graphs/contributors">
@@ -43,3 +46,4 @@
4346
- [httpswift/swifter](https://github.com/httpswift/swifter)
4447
- [sparkle-project/Sparkle](https://github.com/sparkle-project/Sparkle)
4548
- [ungive/media-control](https://github.com/ungive/media-control)
49+
- [tfmart/LottieUI](https://github.com/tfmart/LottieUI)
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
SWIFT_ACTIVE_COMPILATION_CONDITIONS=SELF_COMPILED

airsync-mac/Core/AppState.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,15 @@ class AppState: ObservableObject {
6868
startClipboardMonitoring()
6969
}
7070

71+
#if SELF_COMPILED
72+
self.isPlus = true
73+
UserDefaults.standard.set(true, forKey: "isPlus")
74+
UserDefaults.standard.lastLicenseSuccessfulCheckDate = Date().addingTimeInterval(-(24 * 60 * 60))
75+
#else
7176
Task {
7277
await Gumroad().checkLicenseIfNeeded()
7378
}
79+
#endif
7480

7581
self.scrcpyBitrate = UserDefaults.standard.integer(forKey: "scrcpyBitrate")
7682
if self.scrcpyBitrate == 0 { self.scrcpyBitrate = 4 }

airsync-mac/Localization/de.json

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
11
{
22
"app.name": "AirSync",
3-
"menu.mirror": "Mirror",
4-
"menu.about": "About AirSync",
5-
"menu.checkUpdates": "Check for Updates",
3+
"menu.mirror": "Spiegeln",
4+
"menu.about": "Über AirSync",
5+
"menu.checkUpdates": "Auf Updates prüfen...",
66
"menu.quit": "Beenden",
77
"home.title": "AirSync",
8-
"home.sidebar.ready": "Ready",
9-
"onboarding.title": "Welcome to AirSync",
10-
"notifications.empty.title": "You're all caught up!",
8+
"home.sidebar.ready": "Fertig",
9+
"onboarding.title": "Willkommen bei AirSync",
10+
"notifications.empty.title": "Du bist auf dem Laufenden!",
1111
"notifications.empty.emoji": "└(=^‥^=)┐",
12-
"notifications.actions.hide": "Hide",
13-
"notifications.actions.dismiss": "Dismiss",
12+
"notifications.actions.hide": "Ausblenden",
13+
"notifications.actions.dismiss": "Verwerfen",
1414
"notifications.tab": "Benachrichtigungen",
1515
"apps.tab": "Apps",
16-
"transfers.tab": "Transfers",
16+
"transfers.tab": "Übertragungen",
1717
"settings.tab": "Einstellungen",
18-
"qr.tab": "Scan QR",
19-
"transfers.empty": "Nothing transferred yet",
18+
"qr.tab": "QR-Code scannen",
19+
"transfers.empty": "Noch nichts übertragen",
2020
"plus.title": "AirSync+",
21-
"plus.why": "Why Plus?",
22-
"plus.why.body": "Keeps me inspired to continue and maybe even to publish to the Apple app store and Google Play Store. Think of it as a little donation to keep this project alive and evolving.\nThat said, I know not everyone who wants the full experience can afford it. If that’s you, please don’t hesitate to reach out. 😊\n\nThe source code is available on GitHub, and you're more than welcome to build with all Plus features free — for personal use which also opens for contributions which is a win-win!.\nAs a thank-you for supporting the app, AirSync+ unlocks some nice extras: media controls, synced widgets, low battery alerts, wireless ADB, and more to come as I keep adding new features.\n\nEnjoy the app!\n(っ◕‿◕)っ",
23-
"license.enterKey": "Enter license key",
21+
"plus.why": "Wieso Plus?",
22+
"plus.why.body": "Es motiviert mich, weiterzumachen und vielleicht sogar im Apple App Store und Google Play Store zu veröffentlichen. Betrachte es als eine kleine Spende, um dieses Projekt am Leben zu erhalten und weiterzuentwickeln.\nAllerdings weiß ich, dass sich das nicht jeder, der das volle Erlebnis genießen möchte, leisten kann. Wenn das auf dich zutrifft, zöger bitte nicht, mich zu kontaktieren. 😊\n\nDer Quellcode ist auf GitHub verfügbar und du kannst gerne das Projekt selber bauen um alle Plus-Funktionen für den persönlichen Gebrauch kostenlos zu nutzen. Außerdem ermöglicht es das Mitwirken am Projekt. Eine Win-Win-Situation!\nAls Dankeschön für deine Unterstützung der App schaltet AirSync+ einige nette Extras frei: Mediensteuerung, synchronisierte Widgets, Warnungen bei niedrigem Akkustand, drahtloses ADB und weitere Funktionen, die ich nach und nach hinzufügen werde.\n\nViel Spaß mit der App!\n(っ◕‿◕)っ\n\nÜbersetzt mit DeepL.com (kostenlose Version)",
23+
"license.enterKey": "Lizenz-Key eingeben",
2424
"status.battery": "Batterie",
2525
"status.volume": "Lautstärke",
26-
"media.play": "Spiel",
26+
"media.play": "Abspielen",
2727
"media.pause": "Pause"
2828
}

airsync-mac/Model/LicensePlanType.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,19 @@ import Foundation
1313
enum LicensePlanType: String, CaseIterable, Codable, Identifiable {
1414
case membership
1515
case oneTime
16+
#if SELF_COMPILED
17+
case selfCompiled
18+
#endif
1619

1720
var id: String { rawValue }
1821

1922
var displayName: String {
2023
switch self {
2124
case .membership: return "Membership"
2225
case .oneTime: return "One-Time"
26+
#if SELF_COMPILED
27+
case .selfCompiled: return "Self-Compiled"
28+
#endif
2329
}
2430
}
2531
}

airsync-mac/Screens/Settings/Components/PlusUnlockedSheet.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ struct PlusUnlockedSheet: View {
4545
}
4646

4747
HStack(spacing: 8) {
48+
#if !SELF_COMPILED
4849
GlassButtonView(
4950
label: "Unregister",
5051
systemImage: "xmark.circle",
@@ -55,6 +56,7 @@ struct PlusUnlockedSheet: View {
5556
}
5657
)
5758
.focusable(false)
59+
#endif
5860

5961
GlassButtonView(
6062
label: "Awesome",

0 commit comments

Comments
 (0)