Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add App Clip to Demo project #659

Open
wants to merge 19 commits into
base: trunk
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
80cab2d
Add App Clip to Demo project
mokagio Feb 7, 2025
e255c78
Rename App Clip folder to `Demo-App-Clip`
mokagio Feb 7, 2025
ce0a479
Use correct bundle identifier for App Clip target
mokagio Feb 7, 2025
30fbe3e
Add `appclips:gravatar.com` associated domain to both app and clip
mokagio Feb 7, 2025
23e672a
Remove snake casing from App Clip SwiftUI `App`
mokagio Feb 7, 2025
66e048f
Rename App Clip entitlement to match folder name
mokagio Feb 7, 2025
f7fba40
Configure provisioning profile for Debug – Includes entitlements fix
mokagio Feb 7, 2025
dbdce7a
Update dummy text in App Clip `ContentView.swift`
mokagio Feb 7, 2025
f8b7a66
Update Fastlane to latest version, 2.226.0
mokagio Feb 7, 2025
89aa1c3
Update automation to strip App Clip when building prototype build
mokagio Feb 7, 2025
c11c843
Move Demo app entitlement to Demo sources folder for consistency
mokagio Feb 7, 2025
5e5a614
Change App Clip CURRENT_PROJECT_VERSION (CFBundleVersion) to match App
andrewdmontgomery Feb 7, 2025
51b5a1a
Add associated domains for OAUth to App Clip
mokagio Feb 10, 2025
382b8f2
Move project-level `xcconfig` for demo app to dedicated folder
mokagio Feb 10, 2025
171ccf6
Inherit App Clip version from `Base.xcconfig`
mokagio Feb 10, 2025
c3c161f
Inherit App Clip `IPHONEOS_DEPLOYMENT_TARGET` from project-level setting
mokagio Feb 10, 2025
acf4606
DRY Demo project `IPHONEOS_DEPLOYMENT_TARGET` to `Base.xcconfig`
mokagio Feb 10, 2025
b46367e
Inherit App target `CURRENT_PROJECT_VERSION` from `xcconfig`
mokagio Feb 10, 2025
b17a5fd
Leverage `xcconfig` for App Clip project, too (#663)
andrewdmontgomery Feb 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Demo/Demo/Base.xcconfig → Demo/Config/Base.xcconfig
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@ CURRENT_PROJECT_VERSION = 0

SWIFT_VERSION = 5.0
SWIFT_STRICT_CONCURRENCY = complete

IPHONEOS_DEPLOYMENT_TARGET = 15.0
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"colors" : [
{
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"images" : [
{
"idiom" : "universal",
"platform" : "ios",
"size" : "1024x1024"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
}
],
"idiom" : "universal",
"platform" : "ios",
"size" : "1024x1024"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "tinted"
}
],
"idiom" : "universal",
"platform" : "ios",
"size" : "1024x1024"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
6 changes: 6 additions & 0 deletions Demo/Demo-App-Clip/Assets.xcassets/Contents.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
17 changes: 17 additions & 0 deletions Demo/Demo-App-Clip/ContentView.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import SwiftUI

struct ContentView: View {
var body: some View {
VStack {
Image(systemName: "globe")
.imageScale(.large)
.foregroundStyle(.tint)
Text("Gravatar Demo App Clip")
}
.padding()
}
}

#Preview {
ContentView()
}
16 changes: 16 additions & 0 deletions Demo/Demo-App-Clip/Demo-App-Clip.entitlements
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.developer.associated-domains</key>
<array>
<string>appclips:gravatar.com</string>
<string>applinks:gravatar.com</string>
<string>webcredentials:gravatar.com</string>
</array>
<key>com.apple.developer.parent-application-identifiers</key>
<array>
<string>$(AppIdentifierPrefix)com.automattic.gravatar-sdk-demo-uikit</string>
</array>
</dict>
</plist>
10 changes: 10 additions & 0 deletions Demo/Demo-App-Clip/DemoAppClipApp.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import SwiftUI

@main
struct DemoAppClipApp: App {
var body: some Scene {
WindowGroup {
ContentView()
}
}
}
13 changes: 13 additions & 0 deletions Demo/Demo-App-Clip/Info.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSAppClip</key>
<dict>
<key>NSAppClipRequestEphemeralUserNotification</key>
<false/>
<key>NSAppClipRequestLocationConfirmation</key>
<false/>
</dict>
</dict>
</plist>
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<array>
<string>webcredentials:gravatar.com</string>
<string>applinks:gravatar.com</string>
<string>appclips:gravatar.com</string>
</array>
</dict>
</plist>
2 changes: 1 addition & 1 deletion Demo/Demo/Gravatar-Demo/Gravatar-Demo.Release.xcconfig
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#include "Gravatar-Demo.Base.xcconfig"
#include "../Enterprise.xcconfig"
#include "../../Config/Enterprise.xcconfig"

// Declared explicitly rather than by building on top of what's defined in Base so it can be read by other tools such as Fastlane
PRODUCT_BUNDLE_IDENTIFIER = com.automattic.gravatar-sdk-demo-uikit.prototype-build
Expand Down
Loading