~mjorgensen/gof

a command-line utility to post RSS/Atom feeds to the fediverse

#1 Add CLI arguments

~mjorgensen commented on gof todo

4 months ago

#1 Add CLI arguments

~mjorgensen filed ticket on gof todo

4 months ago

#gof

gof is a command-line utility to post RSS/Atom feeds to the fediverse. It has first-class support for Pleroma, and thus should support Mastodon, too...

gof is for "go feediverse", "go fediverse", "go fedi", or really whatever you want. gof is a port of feediverse written in Go.

gof supports multiple feeds and multiple accounts.

#requirements

  • Go 1.16

#usage

Before you can start using gof, you'll need to configure it. An example configuration can be found here. You can also just copy the example:

$ cd $REPO
$ cp gof.yaml.example gof.yaml
$ vim gof.yaml # don't forget to edit it!

You'll need an access token as well. You can get on from the Pleroma Access Token Generator.

Build the thing:

$ go build

Then you can use it:

$ ./gof

You could also specify the configuration file to use via the command line:

$ ./gof -c /path/to/your/gof.yaml

This would allow you to place the executable (and configuration) anywhere on your system. Once gof is configured, you might want to add it to your crontab:

*/30 * * * * cd /path/to/$REPO; gof

#post format

You can specify how the message looks. The variables you have to work with are URL, Title, and Summary. You don't have to use all variables.

An example template:

template: '{{.Title}}: {{.URL}}'

If you want the message to include line breaks, use YAML's multiline syntax:

template: |-
  {{.Title}}

  {{.URL}}

Formatted posts are also supported. You can choose from plaintext, Markdown, HTML, or BBCode, as long as they’re supported by your Pleroma instance.

template: |-
  **{{.Title}}**

  > {{.Summary}}

  {{.URL}}
format: markdown

See configuration details in the wiki.