Find the best repos to contribute to, right from Discord!
- Hmm. What's this?
This is the Repo Finder Bot, a bot designed to help people find good GitHub repositories to contribute to.
- How does it work?
Simple. Whenever you execute the /repo [topic]
command in your server, the bot uses the GitHub API to find a good repository matching the topic and then send an array of details related to it.
You can also search for multiple topics, eg: /repo [topic1] [topic2]
.
You can even search repos of specific languages and topics using the /repolang [languages] [topics]
command.
- What sort of details?
A whole array of details, including basic info ranging from the amount of stars and forks to the latest issues contributed to the repo.
Here's an example:
Are there slash commands too?
Wait... what happened to the old message commands?
Earlier versions of this bot included support for legacy commands, but unfortunately, message commands have been removed since the upgrade to version 4 of discord-py-interactions. Now, only slash commands are supported. Check them out by typing /help
What commands are available?
Here's a list of commands that are available:
Command Description /repo
Find a repo matching the topic(s) you specify. /repolang
Find a repo matching the language(s) and topic(s) you specify. /info
Get info about the bot. /help
Get a list of commands.
- Cool bot, can I add it to my server?
Of course you can! Just click this link and select the server of your choice.
- Why is the code so bad?
Because we need you! A number of contributors are helping to expand and improve the code base. Why don't you join us?
- How can I contribute?
Just check out the Issues pane for potential issues and submit a PR to solve them. Of course, you can always submit regular PRs not linked to an issue, and I'd be happy to accept them!
Please read CONTRIBUTING.md for more information on contributing and building a development environment.
- How do I run the bot myself?
- Clone this repository
- Create a Discord bot token from here
Register it for slash commands:
- Under OAuth2 > General, set the Authorization Method to "In-app Authorization"
- Tick
bot
andapplications.commands
- Go to OAuth2 > URL Generator, tick
bot
andapplications.commands
- Copy the generated URL at the bottom of the page to invite it to desired servers
- Create a GitHub personal access token from here (Make sure to copy it immediately! You "lose" it once you refresh or close the tab)
- Make a new file called
.env
inside the repo folder and paste the below code block in the fileGH_TOKEN="[paste Github token here]" TOKEN="[paste Discord bot token here]" DEV_GUILD=[paste your bot testing server ID here] # if you want your commands to register globally, leave this empty
- Run
pip install -r requirements.txt
to install packages. You'll require Python 3.6 or better- Once that's done, run the bot by executing
python3 main.py
in the terminalIf you aren't sure how to obtain your server ID, check out this article
If you get errors related to missing token environment variables, run
source .env
- How do I run the bot via Docker?
- Follow the steps above until step 5
- Run
docker build -t repo-finder-bot .
(don't forget the period at the end)- Run
docker container run --rm repo-finder-bot
If you aren't sure how to obtain your server ID, check out this article
Thanks to all the contributors, without whom this project would not have been possible.
Made with contrib.rocks.