Skip to content

Commit

Permalink
fix: remove url schemes and applinks
Browse files Browse the repository at this point in the history
  • Loading branch information
asdfzxcvbn committed Oct 17, 2024
1 parent 6b9624f commit cb1a801
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions appdupe.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,18 +103,20 @@

# step 4: modify everything lol
plist["CFBundleIdentifier"] = BUNDLE

try:
del plist["UISupportedDevices"]
except KeyError:
pass # no worries if we don't have it ig
for key in ["UISupportedDevices", "CFBundleURLTypes"]:
if key in plist:
del plist[key]

entitlements["application-identifier"] = f"{TEAM_ID}.{BUNDLE}"
entitlements["com.apple.developer.team-identifier"] = TEAM_ID
entitlements["keychain-access-groups"] = [BUNDLE_TI]
entitlements["com.apple.security.application-groups"] = [
f"group.{BUNDLE_TI}"]

# we don't want duped apps having associated applinks
if "com.apple.developer.associated-domains" in entitlements:
del entitlements["com.apple.developer.associated-domains"]

# step 5: write entitlements back to executable
with open(ENT_PATH, "wb") as f:
plistlib.dump(entitlements, f) # type: ignore
Expand Down

0 comments on commit cb1a801

Please sign in to comment.