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

Support opening any Mastodon URL directly in the app #717

Open
sindresorhus opened this issue Mar 11, 2023 · 7 comments
Open

Support opening any Mastodon URL directly in the app #717

sindresorhus opened this issue Mar 11, 2023 · 7 comments

Comments

@sindresorhus
Copy link

It would be useful to be able to open Mastodon links directly in the app. This is especially useful when running the app on macOS.

More details: mastodon/mastodon-ios#968

@xmflsct
Copy link
Member

xmflsct commented Mar 16, 2023

@sindresorhus v4.9.2 is out with this change. Let me know if it doesn't work or needs any adjustments. Thanks!

@sindresorhus
Copy link
Author

@xmflsct Thanks for handling this so quickly. I think you forgot the Info.plist changes mentioned in mastodon/mastodon-ios#968

@xmflsct
Copy link
Member

xmflsct commented Mar 16, 2023

@sindresorhus I did not att https into Info.plist as it does seem to work without. Trying open -a 'tooot' 'https://mastodon.social/@sindresorhus/109983299847844086' on my machine does pass the link data correctly and open up the corresponding toot.

I am not an expert in native code though (that is why I went for React Native), let me know if I misunderstood any required declaration.

@xmflsct
Copy link
Member

xmflsct commented Mar 16, 2023

Separate topic, I will reopen this ticket as I notice none of the links work the first time the app is launched (including tooot's schema), only works if the app is already running. Not sure why though as the same Shortcut triggers correctly on iPhone but not on Mac.

@xmflsct xmflsct reopened this Mar 16, 2023
@sindresorhus
Copy link
Author

Trying open -a 'tooot' 'https://mastodon.social/@sindresorhus/109983299847844086' on my machine does pass the link data correctly and open up the corresponding toot.

It works from open because it's not sandboxed. It will not work from any sandboxed apps (any app in the App Store).

@sindresorhus
Copy link
Author

Tested it now. It does not work if I run open -a 'tooot' 'https://mastodon.social/@sindresorhus/109983299847844086' and the app is not already open. This is expected to work.

@xmflsct xmflsct reopened this Mar 21, 2023
@ain
Copy link

ain commented Mar 22, 2023

Great call, I could help test it, if needed. Please call it out here then :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants