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

[feature] Add opt-in RSS feed for account's latest Public posts #897

Merged
merged 27 commits into from
Oct 8, 2022

Conversation

tsmethurst
Copy link
Contributor

@tsmethurst tsmethurst commented Oct 8, 2022

This PR adds an enable RSS toggle to profiles via the settings panel.

When enabled, accounts will have an RSS feed of their public posts (same ones as on the web view) exposed at https://example.org/@some_user/feed.rss.

Some example data from goblin tech:

<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Posts from @[email protected]</title>
    <link>https://goblin.technology/@tobi</link>
    <description>Posts from @[email protected]</description>
    <pubDate>Sat, 08 Oct 2022 08:22:11 +0000</pubDate>
    <lastBuildDate>Sat, 08 Oct 2022 08:22:11 +0000</lastBuildDate>
    <image>
      <url>https://goblin.technology/fileserver/016T5Q3SQKBT337DAKVSKNXXW1/attachment/small/01NQKSYP0SC5MMWG3R16V3M948.jpeg</url>
      <title>Avatar for @[email protected]</title>
      <link>https://goblin.technology/@tobi</link>
    </image>
    <item>
      <title>i keep reiterating that GtS is terrible and stinky and yet people keep expecting it to be good and smell like fresh flowers �...</title>
      <link>https://goblin.technology/@tobi/statuses/01GEVB00DMJK2G2H3YDBPNEY8D</link>
      <description>@[email protected] made a new post: &#34;i keep reiterating that GtS is terrible and stinky and yet people keep expecting it to be good and smell like fresh flowers 🤔 &#34;</description>
      <content:encoded><![CDATA[<p>i keep reiterating that GtS is terrible and stinky and yet people keep expecting it to be good and smell like fresh flowers 🤔</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEVB00DMJK2G2H3YDBPNEY8D</guid>
      <pubDate>Sat, 08 Oct 2022 08:22:11 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>it doesn&#39;t really work properly yet and I need to format it nicely, but you can in theory point an rss reader here: https://g...</title>
      <link>https://goblin.technology/@tobi/statuses/01GET3N0MGX6K5R2P5KDJXWM3B</link>
      <description>@[email protected] made a new post: &#34;it doesn&#39;t really work properly yet and I need to format it nicely, but you can in theory point an rss reader here: https://goblin.technology/@tobi/feed.rss&#34;</description>
      <content:encoded><![CDATA[<p>it doesn’t really work properly yet and I need to format it nicely, but you can in theory point an rss reader here: <a href="https://goblin.technology/@tobi/feed.rss" rel="nofollow noreferrer noopener" target="_blank">https://goblin.technology/@tobi/feed.rss</a></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GET3N0MGX6K5R2P5KDJXWM3B</guid>
      <pubDate>Fri, 07 Oct 2022 20:54:36 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>test, don&#39;t mind me</title>
      <link>https://goblin.technology/@tobi/statuses/01GET3JAFE0YQY57XKAS59KGXF</link>
      <description>@[email protected] made a new post: &#34;test, don&#39;t mind me&#34;</description>
      <content:encoded><![CDATA[<p>test, don’t mind me</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GET3JAFE0YQY57XKAS59KGXF</guid>
      <pubDate>Fri, 07 Oct 2022 20:53:08 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>This be the episode</title>
      <link>https://goblin.technology/@tobi/statuses/01GESXJCK936KRRGJME7HR3BB0</link>
      <description>@[email protected] posted 1 attachment: &#34;This be the episode&#34;</description>
      <content:encoded><![CDATA[<p>This be the episode</p>]]></content:encoded>
      <author>@[email protected]</author>
      <enclosure url="https://goblin.technology/fileserver/016T5Q3SQKBT337DAKVSKNXXW1/attachment/original/01V3RBTJS67VM6TJ3QSTRXC44P.jpeg" length="2996857" type="image/jpeg"></enclosure>
      <guid>https://goblin.technology/@tobi/statuses/01GESXJCK936KRRGJME7HR3BB0</guid>
      <pubDate>Fri, 07 Oct 2022 19:08:19 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>making a mess of the code whoops</title>
      <link>https://goblin.technology/@tobi/statuses/01GERTH89YA3AGG20T3BMXW2YD</link>
      <description>@[email protected] made a new post: &#34;making a mess of the code whoops&#34;</description>
      <content:encoded><![CDATA[<p>making a mess of the code whoops</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GERTH89YA3AGG20T3BMXW2YD</guid>
      <pubDate>Fri, 07 Oct 2022 08:56:02 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>:aoe_priest: wololo</title>
      <link>https://goblin.technology/@tobi/statuses/01GEQHT5JF53Z3B3F1Y3VA7SKC</link>
      <description>@[email protected] made a new post: &#34;:aoe_priest: wololo&#34;</description>
      <content:encoded><![CDATA[<p><img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01N5W9646PT6STX5GQ6SFR58ZW.gif" title=":aoe_priest:" alt=":aoe_priest:" class="emoji"/> wololo</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEQHT5JF53Z3B3F1Y3VA7SKC</guid>
      <pubDate>Thu, 06 Oct 2022 21:04:22 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>Me on a date: haha no problem let me pay!&#xA;&#xA;I open up my wallet, it&#39;s full of blood&#xA;&#xA;My date: :blob_sweating_: :minion_shocked_: </title>
      <link>https://goblin.technology/@tobi/statuses/01GEQ35FAK2MC7BAEYCKR477FE</link>
      <description>@[email protected] made a new post: &#34;Me on a date: haha no problem let me pay!&#xA;&#xA;I open up my wallet, it&#39;s full of blood&#xA;&#xA;My date: :blob_sweating_: :minion_shocked_: &#34;</description>
      <content:encoded><![CDATA[<p>Me on a date: haha no problem let me pay!</p><p>I open up my wallet, it’s full of blood</p><p>My date: <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01CRMD05A20ZGV9R768MSCAFYM.png" title=":blob_sweating_:" alt=":blob_sweating_:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/018VR2TBSY2DMNJVMFD7ZSKQQ6.gif" title=":minion_shocked_:" alt=":minion_shocked_:" class="emoji"/></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEQ35FAK2MC7BAEYCKR477FE</guid>
      <pubDate>Thu, 06 Oct 2022 16:48:24 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>I open up my blood&#xA;And it&#39;s full of wallets</title>
      <link>https://goblin.technology/@tobi/statuses/01GEQ2P02BRT6H15DTK98FJRFM</link>
      <description>@[email protected] made a new post: &#34;I open up my blood&#xA;And it&#39;s full of wallets&#34;</description>
      <content:encoded><![CDATA[<p>I open up my blood<br>And it’s full of wallets</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEQ2P02BRT6H15DTK98FJRFM</guid>
      <pubDate>Thu, 06 Oct 2022 16:39:57 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>Look at this little fella :spinning_mushrooms_: </title>
      <link>https://goblin.technology/@tobi/statuses/01GEQ1VC29F03867ASNK6KZYRZ</link>
      <description>@[email protected] posted 1 attachment: &#34;Look at this little fella :spinning_mushrooms_: &#34;</description>
      <content:encoded><![CDATA[<p>Look at this little fella <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01SKVCF6RN5HT35GN64YHWMWHC.gif" title=":spinning_mushrooms_:" alt=":spinning_mushrooms_:" class="emoji"/></p>]]></content:encoded>
      <author>@[email protected]</author>
      <enclosure url="https://goblin.technology/fileserver/016T5Q3SQKBT337DAKVSKNXXW1/attachment/original/01S6WY0A36KZ3E7A1VKHG4QPH8.jpeg" length="4016021" type="image/jpeg"></enclosure>
      <guid>https://goblin.technology/@tobi/statuses/01GEQ1VC29F03867ASNK6KZYRZ</guid>
      <pubDate>Thu, 06 Oct 2022 16:25:24 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>rip AND tear, in this economy? :rip_and_tear: </title>
      <link>https://goblin.technology/@tobi/statuses/01GEPQH1QM5V9PC2JGTBQDQPVM</link>
      <description>@[email protected] made a new post: &#34;rip AND tear, in this economy? :rip_and_tear: &#34;</description>
      <content:encoded><![CDATA[<p>rip AND tear, in this economy? <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01JJEB6TY0BA8ENSG87P4PXM7P.png" title=":rip_and_tear:" alt=":rip_and_tear:" class="emoji"/></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEPQH1QM5V9PC2JGTBQDQPVM</guid>
      <pubDate>Thu, 06 Oct 2022 13:25:00 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>tweaked custom emojis to make &#39;em just a lil bit bigger and to also be larger on hover :blob_jump_excited: :blob_lewd_: :skul...</title>
      <link>https://goblin.technology/@tobi/statuses/01GEPCJ7FH50HSBC9YWGAMBRT8</link>
      <description>@[email protected] made a new post: &#34;tweaked custom emojis to make &#39;em just a lil bit bigger and to also be larger on hover :blob_jump_excited: :blob_lewd_: :skull_spinning_: :dark_souls_estus_: &#34;</description>
      <content:encoded><![CDATA[<p>tweaked custom emojis to make ‘em just a lil bit bigger and to also be larger on hover <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/0166DYPFGZSFB4XS2B07NQAEYE.png" title=":blob_jump_excited:" alt=":blob_jump_excited:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01EHAF6N031FCB1MAQDEVS0PSM.png" title=":blob_lewd_:" alt=":blob_lewd_:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01E6TCG50CCHMEYQVYNZ4YAYE7.gif" title=":skull_spinning_:" alt=":skull_spinning_:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/018TFBTW55Z228WZFMW55Y2EE0.png" title=":dark_souls_estus_:" alt=":dark_souls_estus_:" class="emoji"/></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEPCJ7FH50HSBC9YWGAMBRT8</guid>
      <pubDate>Thu, 06 Oct 2022 10:13:25 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>new emoji just dropped, subtooting all of you with this one&#xA;&#xA;:nerds:</title>
      <link>https://goblin.technology/@tobi/statuses/01GEP7AJBFJ08R1G170CHEPAE2</link>
      <description>@[email protected] made a new post: &#34;new emoji just dropped, subtooting all of you with this one&#xA;&#xA;:nerds:&#34;</description>
      <content:encoded><![CDATA[<p>new emoji just dropped, subtooting all of you with this one</p><p><img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01G8J7TD6K26KSSNTTJQACGK3C.png" title=":nerds:" alt=":nerds:" class="emoji"/></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEP7AJBFJ08R1G170CHEPAE2</guid>
      <pubDate>Thu, 06 Oct 2022 08:41:51 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>Oh you use GoToSocial? That&#39;s bloat. Just scream into the void directly. Noob.</title>
      <link>https://goblin.technology/@tobi/statuses/01GEMK03AKS4ZYE0C6ZN0P1ZT8</link>
      <description>@[email protected] made a new post: &#34;Oh you use GoToSocial? That&#39;s bloat. Just scream into the void directly. Noob.&#34;</description>
      <content:encoded><![CDATA[<p>Oh you use GoToSocial? That’s bloat. Just scream into the void directly. Noob.</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEMK03AKS4ZYE0C6ZN0P1ZT8</guid>
      <pubDate>Wed, 05 Oct 2022 17:27:22 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>ooooooooo Thunderbird got some nice visual updates :catjam: </title>
      <link>https://goblin.technology/@tobi/statuses/01GEKQ6AWKV31R06PFJ5XZ53CZ</link>
      <description>@[email protected] made a new post: &#34;ooooooooo Thunderbird got some nice visual updates :catjam: &#34;</description>
      <content:encoded><![CDATA[<p>ooooooooo Thunderbird got some nice visual updates <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01AN1HG4A2FNCWQGSEBF8JHV9R.gif" title=":catjam:" alt=":catjam:" class="emoji"/></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEKQ6AWKV31R06PFJ5XZ53CZ</guid>
      <pubDate>Wed, 05 Oct 2022 09:21:26 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>i&#39;ve acquired a candle that promises to &#34;smell like fresh linen&#34; and &#34;eliminate bad odors,&#34; so expect me to be eliminated pos...</title>
      <link>https://goblin.technology/@tobi/statuses/01GEER2255DCYE93STWG5R5JJQ</link>
      <description>@[email protected] made a new post: &#34;i&#39;ve acquired a candle that promises to &#34;smell like fresh linen&#34; and &#34;eliminate bad odors,&#34; so expect me to be eliminated post haste&#34;</description>
      <content:encoded><![CDATA[<p>i’ve acquired a candle that promises to “smell like fresh linen” and “eliminate bad odors,” so expect me to be eliminated post haste</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEER2255DCYE93STWG5R5JJQ</guid>
      <pubDate>Mon, 03 Oct 2022 11:00:22 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>*breaks production just a little bit, as a treat*</title>
      <link>https://goblin.technology/@tobi/statuses/01GEEMDKVECCRB6TFWR0ZVKAZF</link>
      <description>@[email protected] made a new post: &#34;*breaks production just a little bit, as a treat*&#34;</description>
      <content:encoded><![CDATA[<p><em>breaks production just a little bit, as a treat</em></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEEMDKVECCRB6TFWR0ZVKAZF</guid>
      <pubDate>Mon, 03 Oct 2022 09:56:47 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>listening to morrissey before the Big Fight because his agonized self-important whining spurs me to incredible acts of violence</title>
      <link>https://goblin.technology/@tobi/statuses/01GEEG4VAM9TJRPAHTHH10VVVQ</link>
      <description>@[email protected] made a new post: &#34;listening to morrissey before the Big Fight because his agonized self-important whining spurs me to incredible acts of violence&#34;</description>
      <content:encoded><![CDATA[<p>listening to morrissey before the Big Fight because his agonized self-important whining spurs me to incredible acts of violence</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEEG4VAM9TJRPAHTHH10VVVQ</guid>
      <pubDate>Mon, 03 Oct 2022 08:42:05 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>Morrissey: &#34;take me out toniiight&#34;&#xA;Me: *\*assassinates morrissey*\*</title>
      <link>https://goblin.technology/@tobi/statuses/01GEEFHCJ7HPJXTDNVDDCJJCTE</link>
      <description>@[email protected] made a new post: &#34;Morrissey: &#34;take me out toniiight&#34;&#xA;Me: *\*assassinates morrissey*\*&#34;</description>
      <content:encoded><![CDATA[<p>Morrissey: “take me out toniiight”<br>Me: <em>*assassinates morrissey</em>*</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GEEFHCJ7HPJXTDNVDDCJJCTE</guid>
      <pubDate>Mon, 03 Oct 2022 08:31:27 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>Should I obtain a big fluffy onesie? 👀</title>
      <link>https://goblin.technology/@tobi/statuses/01GED2EQAKDPTC5KGM395T5EN4</link>
      <description>@[email protected] made a new post: &#34;Should I obtain a big fluffy onesie? 👀&#34;</description>
      <content:encoded><![CDATA[<p>Should I obtain a big fluffy onesie? 👀</p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GED2EQAKDPTC5KGM395T5EN4</guid>
      <pubDate>Sun, 02 Oct 2022 19:23:34 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
    <item>
      <title>:catjam: rage against the machine kind of afternoon :dancing_baby_: :guillotine_: :molotov_: :nes_fire: :rip_and_tear: </title>
      <link>https://goblin.technology/@tobi/statuses/01GECEPWWBSDESEN6NBZDM6S7J</link>
      <description>@[email protected] made a new post: &#34;:catjam: rage against the machine kind of afternoon :dancing_baby_: :guillotine_: :molotov_: :nes_fire: :rip_and_tear: &#34;</description>
      <content:encoded><![CDATA[<p><img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01AN1HG4A2FNCWQGSEBF8JHV9R.gif" title=":catjam:" alt=":catjam:" class="emoji"/> rage against the machine kind of afternoon <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01BF4KHW9YKP6MCYDYW0Z3RE33.gif" title=":dancing_baby_:" alt=":dancing_baby_:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01J3NHWT6X9WE11VZA4M51D6M7.png" title=":guillotine_:" alt=":guillotine_:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01VE1T471TCK7FVCYTZSYSPYEW.png" title=":molotov_:" alt=":molotov_:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/019A94YQ358BGW0VPYQQ18GSZX.png" title=":nes_fire:" alt=":nes_fire:" class="emoji"/> <img src="https://goblin.technology/fileserver/01BPSX2MKCRVMD4YN4D71G9CP5/emoji/original/01JJEB6TY0BA8ENSG87P4PXM7P.png" title=":rip_and_tear:" alt=":rip_and_tear:" class="emoji"/></p>]]></content:encoded>
      <author>@[email protected]</author>
      <guid>https://goblin.technology/@tobi/statuses/01GECEPWWBSDESEN6NBZDM6S7J</guid>
      <pubDate>Sun, 02 Oct 2022 13:38:30 +0000</pubDate>
      <source>https://goblin.technology/@tobi/feed.rss</source>
    </item>
  </channel>
</rss>

And a screenshot of how it looks via an RSS reader:

Screenshot from 2022-10-08 13-38-21

closes #874

@tsmethurst tsmethurst merged commit 8066306 into main Oct 8, 2022
@tsmethurst tsmethurst deleted the add_rss_functionality branch October 8, 2022 12:00

If you like, you can configure your GoToSocial account to expose an RSS feed of your posts to the web. This allows people to get regular updates about your posts even when they don't have a Fediverse account. This is great when you're using GoToSocial to create longer-form, blog style posts, and you want anyone to be able to read them easily.

The RSS feed for GoToSocial profiles is turned off by default. You can enable it via the [User Settings Panel](./user_panel.md) at `https://[your-instance-domain]/settings`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/user not /settings

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this in a release yet, btw?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/user not /settings

It will be /settings by the time this is included in a release :)

@mirabilos
Copy link
Contributor

mirabilos commented Nov 7, 2022 via email

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

Successfully merging this pull request may close these issues.

[feature] RSS feed for user posts
2 participants