1
0
mirror of https://github.com/helm/chart-testing.git synced 2026-02-05 09:45:14 +01:00

Add Homebrew installer (#244)

The Homebrew formula installs the config files to Homebrew's
etc directory, so we add that to the search locations for config files.

Signed-off-by: Reinhard Nägele <unguiculus@gmail.com>
This commit is contained in:
Reinhard Nägele
2020-07-24 22:32:42 +02:00
committed by GitHub
parent 93b10e8e55
commit 50db473a1e
3 changed files with 20 additions and 7 deletions

View File

@@ -56,3 +56,18 @@ dockers:
extra_files:
- etc/chart_schema.yaml
- etc/lintconf.yaml
brews:
- github:
owner: helm
name: homebrew-tap
commit_author:
name: helm-bot
email: helm-bot@users.noreply.github.com
folder: Formula
homepage: https://github.com/helm/chart-testing/
description: Testing and linting Helm charts
install: |
bin.install "ct"
etc.install "etc" => "ct"
test: |
system "#{bin}/ct version"

View File

@@ -34,16 +34,13 @@ Unpack the `ct` binary, add it to your PATH, and you are good to go!
A Docker image is available at `quay.io/helmpack/chart-testing` with list of
available tags [here](https://quay.io/repository/helmpack/chart-testing?tab=tags).
### From Source
### Homebrew
To install from head with [Go](https://golang.org) 1.14 or higher:
```cli
go get github.com/helm/chart-testing/v3/ct
```console
$ brew tap helm/tap
$ brew install chart-testing
```
This will put `ct` in `$(go env GOPATH)/bin`. You may need to add that directory to your `$PATH` as shown [here](https://golang.org/doc/code.html#GOPATH) if you encounter the error `ct: command not found` after installation.
## Usage
See documentation for individual commands:

View File

@@ -34,6 +34,7 @@ var (
configSearchLocations = []string{
".",
path.Join(homeDir, ".ct"),
"/usr/local/etc/ct",
"/etc/ct",
}
)