Skip to content

Commit

Permalink
chore(*): format .conform.yaml (#71)
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewrynhard authored Oct 5, 2018
1 parent 05cfacb commit 4194aa5
Showing 1 changed file with 46 additions and 52 deletions.
98 changes: 46 additions & 52 deletions .conform.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,31 +4,29 @@ metadata:
binaryPath: /conform
gitRepository: github.com/autonomy/conform
maintainer: Andrew Rynhard <andrew.rynhard@autonomy.io>

policies:
- type: conventionalCommit
spec:
types:
- "chore"
- "docs"
- "perf"
- "refactor"
- "style"
- "test"
scopes:
- "ci"
- "cli"
- "docker"
- "fmt"
- "git"
- "metadata"
- "pipeline"
- "policy"
- "readme"
- "renderer"
- "service"
- "*"

- type: conventionalCommit
spec:
types:
- chore
- docs
- perf
- refactor
- style
- test
scopes:
- ci
- cli
- docker
- fmt
- git
- metadata
- pipeline
- policy
- readme
- renderer
- service
- '*'
script:
template: |
#!/bin/bash
Expand Down Expand Up @@ -69,28 +67,25 @@ script:
docker push {{ .Repository }}:{{ .Version.Major }}.{{ .Version.Minor }}.{{ .Version.Patch }}
fi
fi
pipeline:
stages:
- src
- test
- build

- src
- test
- build
stages:
build:
tasks:
- binary
- image
src:
tasks:
- src
- src
test:
artifacts:
- source: /src/github.com/autonomy/conform/coverage.txt
destination: coverage.txt
- source: /src/github.com/autonomy/conform/coverage.txt
destination: coverage.txt
tasks:
- test
build:
tasks:
- binary
- image

- test
tasks:
binary:
template: |
Expand All @@ -102,14 +97,13 @@ tasks:
{{ else }}
RUN go build -o {{ index .Variables "binaryPath" }}
{{ end }}
test:
image:
template: |
FROM autonomy/conform:src AS {{ .Docker.CurrentStage }}
RUN curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin v1.10.1
RUN chmod +x ./hack/test.sh
RUN ./hack/test.sh --lint ./hack/golangci-lint.yaml
RUN ./hack/test.sh --unit
RUN ./hack/test.sh --coverage
FROM alpine:3.8 AS {{ .Docker.CurrentStage }}
LABEL maintainer="{{ index .Variables "maintainer" }}"
RUN apk --no-cache add bash
COPY --from=binary {{ index .Variables "binaryPath" }} /bin
ENTRYPOINT ["conform"]
src:
template: |
FROM golang:1.11.1 AS {{ .Docker.CurrentStage }}
Expand All @@ -119,11 +113,11 @@ tasks:
COPY ./ ./
RUN go mod download
RUN go mod verify
image:
test:
template: |
FROM alpine:3.8 AS {{ .Docker.CurrentStage }}
LABEL maintainer="{{ index .Variables "maintainer" }}"
RUN apk --no-cache add bash
COPY --from=binary {{ index .Variables "binaryPath" }} /bin
ENTRYPOINT ["conform"]
FROM autonomy/conform:src AS {{ .Docker.CurrentStage }}
RUN curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin v1.10.1
RUN chmod +x ./hack/test.sh
RUN ./hack/test.sh --lint ./hack/golangci-lint.yaml
RUN ./hack/test.sh --unit
RUN ./hack/test.sh --coverage

0 comments on commit 4194aa5

Please sign in to comment.