Skip to content

Commit

Permalink
Merge branch 'main' of github.com:oshiro3/gitbucket-go-client
Browse files Browse the repository at this point in the history
  • Loading branch information
oshiro3 committed Jun 6, 2021
2 parents 10723da + a50efbc commit 9fb083f
Showing 1 changed file with 31 additions and 1 deletion.
32 changes: 31 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,31 @@
# gitbucket-go-client
# gitbucket-go-client

`gitbucket-go-client` is a library for manipulating gitbucket by calling the gitbucket API from a go program.

## getting started

```
go get -u github.com/oshiro3/gitbucket-go-client
```

## usage

```
import (
"os"
"github.com/oshiro3/gitbucket-go-client/client"
)
func main() {
cli := client.New(gitbucketHost, repositoryOwner, repositoryName)
cli.SetToken(os.Getenv("token"))
payload := &client.Status{State: "pending", TargetUrl: "http://example.com", Description: "example message", Context: "ci"}
err := cli.SetStatus("$commit_hash", payload)
}
```

## caution

I haven't versioned yet because it's in the early stages of development.

0 comments on commit 9fb083f

Please sign in to comment.