Skip to content
This repository was archived by the owner on Jan 25, 2019. It is now read-only.

Commit e8e69dd

Browse files
authored
Merge branch 'master' into master
2 parents 7997810 + 562029c commit e8e69dd

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

.travis.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
sudo: required
2+
language: bash
3+
services:
4+
- docker
5+
script:
6+
- docker build -t quay.io/operatorframework/helm-app-operator-ci:$(git rev-parse --short HEAD) .

ci.Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ FROM golang:1.10 as builder
22
ENV API_VERSION 'test.com/v1'
33
WORKDIR /go/src/github.com/operator-framework/helm-app-operator-kit/helm-app-operator
44
COPY helm-app-operator .
5-
RUN dep ensure
5+
RUN ./gofmt.sh
6+
RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
7+
RUN dep ensure -v
68
RUN go test ./...
79
RUN CGO_ENABLED=0 GOOS=linux go build -o bin/operator cmd/helm-app-operator/main.go
810
RUN chmod +x bin/operator

helm-app-operator/gofmt.sh

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#!/bin/sh
2+
3+
unformatted=$(gofmt -l .)
4+
[ -z "$unformatted" ] && exit 0
5+
6+
echo >&2 "Go files must be formatted with gofmt. Please run:"
7+
for fn in $unformatted; do
8+
echo >&2 " gofmt -w $PWD/$fn"
9+
done
10+
11+
exit 1

0 commit comments

Comments
 (0)