diff --git a/damus/Info.plist b/damus/Info.plist
index 9737cc6b..0f1867e6 100644
--- a/damus/Info.plist
+++ b/damus/Info.plist
@@ -14,6 +14,16 @@
nostr
+
+ CFBundleTypeRole
+ Viewer
+ CFBundleURLName
+ io.damus
+ CFBundleURLSchemes
+
+ damus
+
+
LSApplicationQueriesSchemes
diff --git a/damus/Nostr/NostrLink.swift b/damus/Nostr/NostrLink.swift
index ffd172f6..563af125 100644
--- a/damus/Nostr/NostrLink.swift
+++ b/damus/Nostr/NostrLink.swift
@@ -127,6 +127,9 @@ func decode_nostr_uri(_ s: String) -> NostrLink? {
var uri = s.replacingOccurrences(of: "nostr://", with: "")
uri = uri.replacingOccurrences(of: "nostr:", with: "")
+ uri = s.replacingOccurrences(of: "damus://", with: "")
+ uri = uri.replacingOccurrences(of: "damus:", with: "")
+
let parts = uri.split(separator: ":")
.reduce(into: Array()) { acc, str in
guard let decoded = str.removingPercentEncoding else {
diff --git a/damus/Views/NoteContentView.swift b/damus/Views/NoteContentView.swift
index dc0b51cd..59450303 100644
--- a/damus/Views/NoteContentView.swift
+++ b/damus/Views/NoteContentView.swift
@@ -141,7 +141,7 @@ struct NoteContentView: View {
func hashtag_str(_ htag: String) -> AttributedString {
var attributedString = AttributedString(stringLiteral: "#\(htag)")
- attributedString.link = URL(string: "nostr:t:\(htag)")
+ attributedString.link = URL(string: "damus:t:\(htag)")
attributedString.foregroundColor = Color("DamusPurple")
return attributedString
}
@@ -160,13 +160,13 @@ func mention_str(_ m: Mention, profiles: Profiles) -> AttributedString {
let profile = profiles.lookup(id: pk)
let disp = Profile.displayName(profile: profile, pubkey: pk).username
var attributedString = AttributedString(stringLiteral: "@\(disp)")
- attributedString.link = URL(string: "nostr:\(encode_pubkey_uri(m.ref))")
+ attributedString.link = URL(string: "damus:\(encode_pubkey_uri(m.ref))")
attributedString.foregroundColor = Color("DamusPurple")
return attributedString
case .event:
let bevid = bech32_note_id(m.ref.ref_id) ?? m.ref.ref_id
var attributedString = AttributedString(stringLiteral: "@\(abbrev_pubkey(bevid))")
- attributedString.link = URL(string: "nostr:\(encode_event_id_uri(m.ref))")
+ attributedString.link = URL(string: "damus:\(encode_event_id_uri(m.ref))")
attributedString.foregroundColor = Color("DamusPurple")
return attributedString
}