Skip to content

Commit bdf273f

Browse files
committed
Add basic gocd-cli setup and usage.
1 parent 6c1713d commit bdf273f

File tree

1 file changed

+23
-1
lines changed

1 file changed

+23
-1
lines changed

README.md

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,28 @@ Then to validate your `gopipeline.json` file run something like:
9191
java -jar /usr/lib/gocd-json-plugin/json-config-plugin.jar syntax mypipe.gopipeline.json
9292
```
9393

94+
## Usage with `gocd` command-line helper
95+
96+
This is a product in development, so its command syntax is not stable and there are no distributed binaries yet.
97+
98+
The `gocd` tool is built in [golang](https://golang.org/) so you will need to familiarize yourself with how to set up your [go workspace](https://golang.org/doc/code.html#Workspaces).
99+
100+
Build the `gocd` binary:
101+
102+
```bash
103+
go get github.com/gocd-contrib/gocd-cli
104+
cd ${GOPATH:-~/go}/src/github.com/gocd-contrib/gocd-cli
105+
./build.sh
106+
```
107+
108+
Follow the steps on [https://github.com/gocd-contrib/gocd-cli](https://github.com/gocd-contrib/gocd-cli) to install the plugin jar to the correct place.
109+
110+
Then:
111+
112+
```bash
113+
./gocd configrepo check -i json.config.plugin /path/to/your-pipeline.gopipeline.json
114+
```
115+
94116
## Usage with IDE and docker
95117

96118
[IDE](https://github.com/ai-traders/ide) is a bash script, a cli wrapper around docker to help with running development tasks in docker.
@@ -746,7 +768,7 @@ Optionally any task can have `run_if` and `on_cancel`.
746768
"docs",
747769
"install"
748770
],
749-
"working_directory": null
771+
"working_directory": null
750772
}
751773
```
752774

0 commit comments

Comments
 (0)