Skip to main content

Automatically labels repositories' issues or pull requests on GitHub.

Project description

# githubBot

This project tries to implement a robot that is capable of automate labeling newly added issues to given repository.

## Getting started

At first you need to have an account on github.com and this account needs to be added as a collaborator for targeted repository.

Seccondly, you need to generate a security token for this account.

This token needs to be copied to the authconfig file. By default the name of this file is "auth.cfg", but feel free to name it your way (name of your file then needs to be passed to the app through a parameter --authfile)

Default name of used token in this app is "tokenRobot". If you need to use multiple robot accounts for multiple repositories, you can add another tokens and pass suitable token name as a parameter at the start of this application.

Down below is an example of the authconfig file

```
[github]
tokenRobot = <github_token>
yourNameOfToken = <github_token>
```

## Parameters

* **--authfile** - Relative or absolute path to your authorization configure file. Default value is "auth.cfg"
* **--configfile** - Relative or absolute path to your application configure file. Default value is "configFile.cfg"
* **--timeout** - Number of secconds for checking new issues. Default value is 30 secconds
* **--tokenname** - Name of token in authorization configure file. Default value is "tokenRobot"
* **--repoowner** - Owner of the repository you would like to label issues.
* **--repository** - Name of repository for automatic labeling.
* **--defaultlabel** - Default label for not resolved issues. Default value is "NeedsLabel", but at the same time it needs to be correctly configured in the configure file.
* **--superswitch** - Indicator whether to label issues, pull_requests or both.
* **0** - Label issues and pull_requests
* **1** - Label issues only
* **2** - Label pull_requests only

## Run

```
githubbot.py console [your_parameters]

githubbot.py web [your_parameters]
```

or

```
python -m githubbot.py console [your_parameters]

python -m githubbot.py web [your_parameters]
```

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

githubbot-0.4.2.tar.gz (9.0 kB view details)

Uploaded Source

File details

Details for the file githubbot-0.4.2.tar.gz.

File metadata

  • Download URL: githubbot-0.4.2.tar.gz
  • Upload date:
  • Size: 9.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for githubbot-0.4.2.tar.gz
Algorithm Hash digest
SHA256 92823be06247bee9b0eea0638c16bcb0507bf94f4e2ff23299e45ac85a1c15fc
MD5 1163263f434112e5bd42aba9d47b2d13
BLAKE2b-256 67e19efc524d61674ca24cbddd46e05cc26d91269ba0fa5957df19120ff3b566

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page