Boot.dev project - A multi-user CLI-based RSS feed aggregator
Gator uses PostgreSQL DB (v18.1+) and is written in Go (v1.25.5+), so ensure both are installed.
- Clone this repo locally
- Create a database called
gator - Save the connection string to the database in a file in your home folder called
.gatorconfig.json:
{
"db_url": "postgres://<db_user>:<db_password>@localhost:5432/gator?sslmode=disable",
}
- Install the tool:
go install .
gator <command> [<args..>]
Available commands:
register <username>- adds a user to the db and sets user as the current user in the config filelogin <username>- Sets the given user as the current user in the config fileusers- Lists registered usersaddfeed <feed_name> <feed_url>- Adds a feed to the database, and follows the feed for the current userfeeds- Lists all feeds that have been added to the databasefollow <feed_url>- Follows the given feed URL for the current user, provided it has already been added to the databasefollowing- Lists all the feeds the current user is following by nameunfollow <feed_url>- Unfollows given feed for the current userbrowse <post_limit[optional]>- Displays the most recent posts from your feeds. Number of posts is set by<post_limit>(default 2)agg <poll_interval>- Aggregates posts from all feeds and stores them in the DB.<poll_interval>e.g. 10s, 5m, 1h, etc. how often to check feeds for new posts.reset- (DESTRUCTIVE) If you want to reset your database, here you go. You've been warned :)