-
Notifications
You must be signed in to change notification settings - Fork 11
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
Links don't seem to be clickable #10
Comments
Sorry, I haven't looked at this for a while and I know a lot of things might be a bit broken. I'll probably try to fix this over the weekend. Do you mind if I just use your regex? |
Certainly use it. But please give it a few tests to make sure I’m not missing something. I am not much of a regex wizard. :) |
Hello everybody. I found bskyrb with the same intention of posting "Hey, new blogpost at $URL" posts, got everything up and running and stumbled into the same issue with the non-clickable links. I too did not find the correct place to somehow patch things up with the regex from @chipotle. @ShreyanJain9: Can you already tell, when you will incorporate this into the official gem? Thank you very much for your great work so far. |
Unfortunately I haven't had time to maintain this gem for a while, though I do plan to come back to it at some point in the future. In the meantime you may want to look at @mackuba's minisky tool, which is lower-level and will take some more effort to use on your part, but Kuba is very helpful and can probably help with a lot of the higher-level pieces you'll have to implement. |
I am not sure what the situation is now (Nov. 2024)—maybe @ShreyanJain9 has updated the repo and fixed bugs, haven't looked—but link facets are definitely working for me. I'm using the current git version, not the gem from rubygems (which doesn't have any code for facets). (Facets in BlueSky are what let you make clickable links and @-sign mentions.) Sample code that works for me:
On BlueSky, that message has a clickable link for github.com. Yay. Minisky is cool, but I'm pretty sure it doesn't support facets at all yet. AFAIK bskyrb (git version!) is the only ruby gem that supports BlueSky's facets (therefore clickable links and mentions). |
This is good news, thanks for the headsup @sabat. For my very basic need (New blogpost announcement) I fumbled together a working solution with minisky and the regex from @chipotle. I named it it_skeet.rb. |
I'm working on an app that uses this gem, which really helped give me a leg up on initially understanding the basic API (though I find that some of the rough edges are such that I'm considering eliminating the dependency). For anyone looking for some tips on how to generate facets yourself, I shared a couple of file listings in a gist to look at as an example. YMMV |
Yeah, I wrote the gem way back and I didn't understand the API that well when I did, and haven't really had time to maintain it since, so eliminating the dependency is probably not a bad idea for now :) |
It's working for me so far, and even if I ultimately cut it, thank you for the starting point!! |
I've been trying to write an autoposter that just posts "#{title} - #{link}" style posts from a blog, and I absolutely cannot get clickable links to be posted.
As far as I can tell, the
link_pattern
in thedetect_facets
method isn't working. I did some tests in local code with a much simpler regex pattern and your function, and this seems to be getting the right response. Unfortunately, I can't for the life of me figure out how to get this code into a local copy of the library that my autoposter will actually work with, because I am apparently hopelessly confused by Ruby's dependency management or how to build this specific gem or something. (I used your providedinstall-local.sh
script with my change to the gem, but no matter what I do I get auninitialized constant Bskyrb::Credentials (NameError)
unless I load from the published Gem, which works flawlessly, except that the facets aren't being processed correctly and the links aren't clickable.)This is the simple dumb pattern I used and the test. It basically just assumes anything that starts with
https://
orhttp://
is a URL up until the next whitespace character. The only change to theenum_for.each
loop is in theURI.parse
, where I removed the trailing/
(if one exists it will be grabbed by the regex).The text was updated successfully, but these errors were encountered: