Digdag client library written in Go. (Unofficial)
- digdag server
$ go get -u github.com/szyn/digdag-go-client
package main
import (
"fmt"
digdag "github.com/szyn/digdag-go-client"
)
func main() {
/*
default endpoint: http://localhost:65432
If you want to change endpoint, write as the following.
client, err := digdag.NewClient("http://hostname:5432", false)
*/
client, err := digdag.NewClient("", false)
if err != nil {
fmt.Println(err)
}
projects, err := client.GetProjects()
if err != nil {
fmt.Println(err)
}
for _, project := range projects {
fmt.Println(project.ID, project.Name)
}
}
See also: Godoc
- Fork it ( http://github.com/szyn/digdag-go-client )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Run test suite (
go test ./...
) and confirm that it passes - Run gofmt (
gofmt -s
) - Create new Pull Request 😆