Skip to content

TonicPow's official bot for posting on Twetch

License

Notifications You must be signed in to change notification settings

tonicpow/twetch-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

TonicPow: Twetch Bot

The official TonicPow bot for posting on Twetch

last commit version Build Status Mergify Status
Sponsor slack


Table of Contents


Pre-Requisites

These are required for building and running the Typescript project:

yarn global add tsc
yarn global add ts-node-dev

Installation

Yarn

Install:

yarn

Local development (watch):

yarn dev

Build & run with:

yarn prod

PM2

pm2 start yarn --name api -- prod

Make

twetch-bot requires a supported release of Node.

make install

Run the bot with:

make start

Documentation

The bot will query RSSURL to check for new campaigns every X seconds as defined in the refreshRate parameter in the .env file.

If new campaigns are found, then the bot will automatically twetch those links with the privateKey configured in the .env file.

Once a privateKey is setup, upon starting the bot the signing address will be logged along with the message and signature necessary to configure in the twetch account.

The client identifier should also be configured in the .env file to take advantage of 10% platform fee savings.

Environment Variables

Required environment variables:

  • TWETCH_CLIENT_ID (twetch client id)
  • TWETCH_PK (private key for twetch account)
  • TWETCH_REFRESH_RATE (rate to refresh/fetch new rss)

Features

  • Consume the TonicPow RSS feed
  • Auto post on new campaigns
Release Deployment

goreleaser for easy binary or library deployment to Github and can be installed via: brew install goreleaser.

The .goreleaser.yml file is used to configure goreleaser.

Use make release-snap to create a snapshot version of the release, and finally make release to ship to production.

Makefile Commands

View all makefile commands

make help

List of all current commands:

audit                          Checks for vulnerabilities in dependencies
clean                          Remove previous builds and any test cache data
help                           Show all commands available
install                        Installs the dependencies for the package
lint                           Runs the standard-js lint tool
outdated                       Checks for outdated packages via npm
release                        Full production release (creates release in Github)
release-test                   Full production test release (everything except deploy)
release-snap                   Test the full release (build binaries)
start                          Starts running the bot
tag                            Generate a new tag and push (IE: tag version=0.0.0)
tag-remove                     Remove a tag if found (IE: tag-remove version=0.0.0)
tag-update                     Update an existing tag to current commit (IE: tag-update version=0.0.0)
update-releaser                Update the goreleaser application

Examples & Tests

Tests & examples coming soon!


Maintainers

Josh Satchmo MrZ
Josh Satchmo MrZ

Contributing

View the contributing guidelines and please follow the code of conduct.

How can I help?

All kinds of contributions are welcome πŸ™Œ! The most basic way to show your support is to star 🌟 the project, or to raise issues πŸ’¬. You can also support this project by becoming a sponsor on GitHub πŸ‘ or by making a bitcoin donation to ensure this journey continues indefinitely! πŸš€

Stars


License

license