This bot interacts on GitHub issues and pull requests due to multiple reasons.
One example are issues that haven't had any activity for multiple months. Due to the fast nature of fastlane, issues often can't be reproduced anymore after 2-3 months of inactivity. Those issues are closed.
Other use cases:
- comment on PRs that were merged and will be included in the next release
- comment on PRs whose content is now available and released
- adds label to PRs that have been open for too long
- closes and locks old, inactive issues and PRs
- responds to issues that contain trigger words with specific message
- adds label to issues that require a reply from the original poster
Please note that the issue-bot system run by the fastlane
core team does not automatically deploy code changes made to this repository. When merging changes to the repository, please let a member of the fastlane
core team know (via Slack or at-mention in the GitHub pull request), so that they can manually deploy your code change.
-
You can use
rake
to easily run a couple of tasks.Run
bundle exec rake --tasks
(or simply-T
) to get a list of all the available tasks and their description.You run a task using
bundle exec rake <task name>
. -
You can also use
pry
to test different methods from theBot
class. For example, to test the processing of new issues:cd
into the repository's project- run
bundle exec pry
- execute
require "logger"
- execute
load "bot.rb"
- execute
Fastlane::Bot.new(Logger.new(STDOUT)).start(process: :issues)
After you modify the bot, you execute
load "bot.rb"
again for the new changes take effect. -
If you want to test it with actual data, you need to create a GitHub access token by going to https://github.com/settings/tokens, generating a new token and following these steps:
- create a testing GitHub project
- update the
SLUG
constant with this new project's path (<username>/<project name>
) - run
export GITHUB_API_TOKEN=<token>
- run the steps
2.ii
-2.v