Skip to content

Commit

Permalink
Merge pull request acsone#17 from foodles-tech/agaldeano/readme-clien…
Browse files Browse the repository at this point in the history
…t-run-command-update

[DOC] Updated the "Run the client" section and added an example using `go run`
  • Loading branch information
sbidoul authored Nov 29, 2024
2 parents 30399b4 + 1aa3bc3 commit 9d6a013
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,20 +53,29 @@ The server should now listen on http://localhost:8080.

### Run the client

Any of the following should generate a printout of the wkhtmltopdf home page to /tmp/test.pdf.

#### Using the built binary

```
$ go build -o client/go/kwkhtmltopdf_client client/go/kwkhtmltopdf_client.go
$ env KWKHTMLTOPDF_SERVER_URL=http://localhost:8080 \
client/go/kwkhtmltopdf_client https://wkhtmltopdf.org /tmp/test.pdf
```

or
#### Using the Go client

```
$ env KWKHTMLTOPDF_SERVER_URL=http://localhost:8080 \
client/python/kwkhtmltopdf_client.py https://wkhtmltopdf.org /tmp/test.pdf
go run client/go/kwkhtmltopdf_client.go https://wkhtmltopdf.org /tmp/test.pdf
```

This should generate a printout of the wkhtmltopdf home page to /tmp/test.pdf.
#### Using the Python client

```
$ env KWKHTMLTOPDF_SERVER_URL=http://localhost:8080 \
client/python/kwkhtmltopdf_client.py https://wkhtmltopdf.org /tmp/test.pdf
```

## Run tests

Expand Down

0 comments on commit 9d6a013

Please sign in to comment.