mirror of
https://github.com/myned/watcher.git
synced 2024-12-23 21:07:27 +00:00
Discord bot for activity roles
c5376f6c6e
Python does this implicitly |
||
---|---|---|
.github | ||
commands | ||
tasks | ||
tools | ||
.gitignore | ||
config.py | ||
LICENSE | ||
poetry.toml | ||
pyproject.toml | ||
README.md | ||
run.py |
Watcher
An experimental Hikari Discord bot for assigning active and inactive roles based on member activity
Prerequisites
A Unix-based operating system is used for the following commands
WSL can be used to run Linux on Windows, but is not required to run the bot
Requirements
Installing
Clone this repository
git clone https://github.com/Myned/Watcher.git
Go to the project folder
cd Watcher
Create a virtual environment and install dependencies
poetry install
Usage
Go to the project folder
cd Watcher
Run with optimizations
poetry run python -OO run.py
Setup
Run to create config.toml
The file will automatically generate if it does not exist
client = 0 # bot application id
token = "" # bot token
activity = "you" # bot status
db = "watcher.db" # sqlite3 db filepath
guild = 0 # guild id to watch
active = 0 # active role id
inactive = 0 # inactive role id
duration = 0 # time in seconds before considered inactive
Updating
Go to the project folder
cd Watcher
Pull changes from the repository
git pull
Update the virtual environment
poetry update
Uninstalling
Remove the project folder
rm -rf Watcher
Contributing
- Fork this repository on GitHub
- Make changes to the code
- Format the code with Black inside the project folder
poetry run python black .
- Commit the changes to the fork
- Create a pull request from the fork