#39 Add config for URL tile announcement scope

Otevřený
otevřeno před 8 roky uživatelem fr33domlover · 1 komentářů

Instead of simple on/off support these:

  1. No title annoucenements
  2. Take the entire message as the URL
  3. Take the first word as the URL
  4. Try all words as URLs (announce just the first, or all of them?)

In case 4, possibly handle cases where the URL is followed by non-whitespace, for example "hey jane, check out https://gnu.org, cool thing". Can a URL contain a comma as the last char? Is there a good way to strip those suffixes, at least common ones like comma? If yes, support it. If not, it's fine too, just a bonus.

Instead of simple on/off support these: 1. No title annoucenements 2. Take the entire message as the URL 3. Take the first word as the URL 4. Try all words as URLs (announce just the first, or all of them?) In case 4, possibly handle cases where the URL is followed by non-whitespace, for example "*hey jane, check out https://gnu.org, cool thing*". Can a URL contain a comma as the last char? Is there a good way to strip those suffixes, at least common ones like comma? If yes, support it. If not, it's fine too, just a bonus.
smichel17 okomentoval před 6 roky

You could make a GET to the url with the comma. If you get a 404, try without the comma. If it also 404's, announce a dead link.

You could make a GET to the url with the comma. If you get a 404, try without the comma. If it also 404's, announce a dead link.
Přihlaste se pro zapojení do konverzace.
Bez milníku
Bez zpracovatele
2 účastníků
Načítání...
Zrušit
Uložit
Není zde žádný obsah.