Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lostfictions/heathbot
toots cliffs
https://github.com/lostfictions/heathbot
bot botally comics mastodon node twitter-bot typescript
Last synced: about 1 month ago
JSON representation
toots cliffs
- Host: GitHub
- URL: https://github.com/lostfictions/heathbot
- Owner: lostfictions
- License: agpl-3.0
- Created: 2017-12-22T06:58:11.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2023-09-11T23:48:21.000Z (over 1 year ago)
- Last Synced: 2024-04-18T07:01:53.131Z (8 months ago)
- Topics: bot, botally, comics, mastodon, node, twitter-bot, typescript
- Language: TypeScript
- Homepage: https://twitter.com/its_heathcliff
- Size: 312 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## heathbot
tweets and toots Extremely Official Heathcliff Comics™.
https://mastodon.social/@heathcliff
~~https://twitter.com/its_heathcliff~~ no longer functional on twitter as of may 2023
![a mixed-up heathcliff comic](https://i.imgur.com/Sm4PpX6.png)
this is a twitter and mastodon bot written in
[typescript](https://www.typescriptlang.org/) and running on
[node.js](http://nodejs.org/).you can run it on your computer or remix it into something new! you'll need node
and git installed. (you'll also need [yarn v1](https://classic.yarnpkg.com). if
you're on a recent version of node, just run [`corepack
enable`](https://nodejs.org/api/corepack.html) and you'll be good to go.)then run:
```
git clone https://github.com/lostfictions/heathbot
cd heathbot
yarn install
```to install the dependencies.
you'll also need some heathcliff comics to work with! you can find some on the
internet. same them to a folder named `persist/heathcliff` in the repo
directory. or place them anywhere els on your computer and set the `DATA_DIR`
environment variable when running the bot to tell it where to look.when you're ready, run
```
yarn dev
```to start generating some images locally. they'll be output to your system's temp
directory, and the bot will print the file locations as it goes.in a server environment, this bot can be run with
[docker](https://docs.docker.com/) for an easier time. (i recommend
[dokku](http://dokku.viewdocs.io/dokku/) if you're looking for a nice way to
develop and host bots on your own server.)the bot needs environment variables if you want it to do stuff:
- `MASTODON_TOKEN`: a Mastodon user API token
- `MASTODON_SERVER`: the instance to which API calls should be made (usually
where the bot user lives.) (default: https://mastodon.social)- ~~`TWITTER_API_KEY`, `TWITTER_API_SECRET`, `TWITTER_ACCESS_TOKEN`, and
`TWITTER_ACCESS_SECRET`: you need all of these guys to make a tweet.~~ twitter
broke api usage in may 2023 and this code has been removed.- `DATA_DIR`: the directory to search for heathcliff comics. (default:
'persist')heathbot uses the [znv](https://github.com/lostfictions/znv/) library as well as
[dotenv](https://github.com/motdotla/dotenv), so you can alternately stick
any of the above environment variables in a file named `.env` in the project
root. (it's gitignored, so there's no risk of accidentally committing private
API tokens you put in there.)![another mixed-up heathcliff comic](https://i.imgur.com/J061W3c.png)
###### [more bots?](https://github.com/lostfictions?tab=repositories&q=botally)