Skip to content

GianniBYoung/hardcover-quotes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hardcover Quotes - HCQ

Go program to fetch a random quote from your hardcover.app reading journals and output it to your terminal (think message of the day or on initial shell invocation).

ps. add me on hardcover 🤓 https://hardcover.app/@countmancy

WARNING: the hardcover api is still under development and might have changes that break this project. please review the api access page for more information

Requirements

Installation

Grab the latest binary release or install via go:

go install github.com/GianniBYoung/hardcover-quotes/cmd/hcq@latest

Usage and Applications

  • hcq will output a formatted string to stdout

  • A webhook will be sent if the env var HCQ_WEBHOOK_URL is set Hardcover Quotes Screenshot

  • Pipe it to lolcat or cowsay for more fun!

  • Set the MOTD(message of the day)

  • Print a quote upon shell invocation!

  • Send a webhook to a service such as trml for displaying the quote on an e-ink display!

    • note, the link above contains my referral code if you decide to purchase a trml device
[[ $SHLVL -le 1 ]] && hcq

Hardcover Quotes Screenshot

Configuration Options

Environmental Variables

  • HARDCOVER_API_TOKEN -> required to set be able to access your profile and retrieve quotes
  • HCQ_WEBHOOK_URL -> If set, will send a POST request to the specified URL with the quote
  • HCQ_INFO_LEVEL -> increase the verbosity for debugging
    • debug
    • info
    • warning

Inspiration

Links to some projects that inspired me to start this project, check them out!

Contributing

Contributions appreciated!

Take a look at the issues, submit feature requests, submit Pull requests etc

About

Fetch Quotes from hardcover.app

Topics

Resources

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published