Skip to content
This repository was archived by the owner on Mar 20, 2024. It is now read-only.

Commit b4fa951

Browse files
committed
Add buildbot 0.9 support in README.md
1 parent 7ac3136 commit b4fa951

File tree

1 file changed

+34
-1
lines changed

1 file changed

+34
-1
lines changed

README.md

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ pip install -e homu
9696

9797
4. Add a Webhook to your continuous integration service:
9898

99-
- Buildbot
99+
- Buildbot 0.8
100100

101101
Insert the following code to the `master.cfg` file:
102102

@@ -109,6 +109,39 @@ pip install -e homu
109109
))
110110
```
111111

112+
- Buildbot 0.9 via GithubStatusPush
113+
114+
Buildbot 0.9 support [GithubStatusPush](http://docs.buildbot.net/latest/manual/cfg-reporters.html#githubstatuspush),
115+
so we can use this to integrate with Github and Buildbot 0.9.
116+
117+
Insert the following code to the `master.cfg` file:
118+
119+
```python
120+
from buildbot.plugins import reporters, util
121+
from buildbot.process.properties import Interpolate
122+
123+
124+
context = Interpolate("buildbot/%(prop:buildername)s")
125+
gs = reporters.GitHubStatusPush(token='A Github personal acess token',
126+
context=context,
127+
startDescription='Build started.',
128+
endDescription='Build done.')
129+
c['services'].append(gs)
130+
```
131+
132+
**Note**: Buildbot 0.9 use project to detect the repository at Github. So made your `project` to `<owner>/<repo>`
133+
in [GitPoller](http://docs.buildbot.net/latest/manual/cfg-changesources.html#gitpoller).
134+
135+
Now the config of the repository in Homu's config file should looks like below:
136+
137+
```toml
138+
[repo.NAME.status.LABEL1]
139+
context = "buildbot/<builder-name>" # <builder-name> should replaced by the real builder name
140+
141+
[repo.NAME.status.LABEL2]
142+
context = "buildbot/<builder2-name>" # <builder2-name> should replaced by the real builder name
143+
```
144+
112145
- Travis CI
113146

114147
Add [your Travis token][travis] as `repo.NAME.travis.token` in cfg.toml.

0 commit comments

Comments
 (0)