This CLI tool is simple RSS aggregator written in Go and following the Blog Aggregator project course on Boot.dev.
- Postgres
- Go
go get github.com/lulock/gator
- manually create a config file in your home directory
~/.gatorconfig.json - It should have the following format:
{ "db_url": "connection_string_goes_here",
"current_user_name": "username_goes_here"
}- no need to set a
current_user_name, the programme will set this.
| command | description |
|---|---|
go run . reset |
resets database |
go run . register [name] |
registers [name] as user and logs user in as current user |
go run . addfeed [feed name] [feed url] |
adds [feed name] found at [feed url] to current logged in user |
go run . follow [feed url] |
follows [feed url] for current logged in user |
go run . unfollow [feed url] |
unfollows [feed url] for current logged in user |
go run . agg [time interval] |
fetches RSS feed every [time interval] and saves posts |
go run . browse [max number] |
browses fetched and saved posts from followed RSS feeds capped at [max number] |