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

[Request]: URL handling for ShareToMastodon service #908

Open
1 task done
TriVoxel opened this issue Apr 14, 2024 · 1 comment
Open
1 task done

[Request]: URL handling for ShareToMastodon service #908

TriVoxel opened this issue Apr 14, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@TriVoxel
Copy link

Describe the request

There is a web service for sharing articles to Mastodon. I discovered this while using the GTK app called "Newsflash". If I share to Mastodon, I can choose from a supported app, in this case only Firefox and GNOME Web showed up. It's really basic. The URL is formatted as such:

https://sharetomastodon.github.io/?title=<ARTICLE%20TITLE>&url=

It would be cool if Tuba could handle these sharing links so we can share from apps like Newsflash directly through Tuba! Here's a sample generated by Newsflash:

https://sharetomastodon.github.io/?title=New%20in%20Fedora%20Asahi%20Remix&url=https%3A%2F%2Fasahilinux%2Eorg%2F2024%2F01%2Ffedora%2Dasahi%2Dnew%2F

This will share the (currently) latest article from Asahi Linux. I think this project is a cool initiative to allow people to easily share things on Mastodon!

Screenshot from 2024-04-14 01-16-52

This pops up when you click "Share to Mastodon"

Implementation Details

@TriVoxel TriVoxel added the enhancement New feature or request label Apr 14, 2024
@GeopJr
Copy link
Owner

GeopJr commented Apr 14, 2024

I don't think this is possible unfortunately

Apps can register 'scheme handlers' but they can't filter based on host part for example.
Browsers register http, https (among others). If Tuba registered that, it would be a suggestion for any link which is a bit of an overkill. Tuba already handles 2, tuba:// (used internally for callbacks) and web+ap which is the closest to what you request. It doesn't support composing at its current state (the spec is here https://fedilinks.org/spec/en/6-The-web-ap-URI) but it does support general activitypub links, like web+ap://floss.social/@Tuba should open tuba's profile in tuba

What I can do is either add support for composing like so tuba://compose?text=... with a browser extension that modifies 'sharetomastodon' links orrrr write a spec for that and propose it to other clients so we have a universal fedi://compose?text=...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants