mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-01-05 10:20:36 +02:00
set commit status for all commits in GH, not just pull requests
This commit is contained in:
parent
e935bed53e
commit
13a05a0106
@ -56,6 +56,10 @@ type Config struct {
|
|||||||
Swarm bool `envconfig:"optional"`
|
Swarm bool `envconfig:"optional"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Environment represents a set of global environment
|
||||||
|
// variable declarations that can be injected into
|
||||||
|
// build plugins. An example use case might be SMTP
|
||||||
|
// configuration.
|
||||||
Environment []string `envconfig:"optional"`
|
Environment []string `envconfig:"optional"`
|
||||||
|
|
||||||
// Plugins represents a white-list of plugins
|
// Plugins represents a white-list of plugins
|
||||||
|
@ -214,9 +214,7 @@ func (g *GitHub) Deactivate(u *common.User, r *common.Repo, link string) error {
|
|||||||
|
|
||||||
func (g *GitHub) Status(u *common.User, r *common.Repo, c *common.Commit) error {
|
func (g *GitHub) Status(u *common.User, r *common.Repo, c *common.Commit) error {
|
||||||
client := NewClient(g.API, u.Token, g.SkipVerify)
|
client := NewClient(g.API, u.Token, g.SkipVerify)
|
||||||
if len(c.PullRequest) == 0 {
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
link := fmt.Sprintf("%s/%v", r.Self, c.Sequence)
|
link := fmt.Sprintf("%s/%v", r.Self, c.Sequence)
|
||||||
status := getStatus(c.State)
|
status := getStatus(c.State)
|
||||||
desc := getDesc(c.State)
|
desc := getDesc(c.State)
|
||||||
|
Loading…
Reference in New Issue
Block a user