Skip to content

Commit

Permalink
updating circleci yml (#18)
Browse files Browse the repository at this point in the history
  • Loading branch information
cpoile authored Jun 11, 2019
1 parent 0dfb343 commit 81ce5f2
Showing 1 changed file with 27 additions and 58 deletions.
85 changes: 27 additions & 58 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,82 +1,51 @@
version: 2.1
executors:
default:
docker:
- image: circleci/golang:1.12

jobs:
lint:
executor:
name: default
steps:
- checkout
- run: make check-style

test:
executor:
name: default
steps:
- checkout
- run: make test

build:
executor:
name: default
steps:
- checkout
- run: make dist
- persist_to_workspace:
root: .
paths: ./dist/*.tar.gz

publish-github-release:
docker:
- image: cibuilds/github:0.12
steps:
- attach_workspace:
at: .
- run:
name: "Publish Release on GitHub"
command: |
ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${CIRCLE_TAG} ./dist/com.mattermost.aws-sns-*.tar.gz
orbs:
plugin-ci: mattermost/plugin-ci@volatile

workflows:
version: 2
untagged-build:
jobs:
- lint
- test
tagged-build:
ci-build:
jobs:
- lint:
- plugin-ci/lint:
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/
- test:
- plugin-ci/test:
filters:
tags:
only: /^v.*/
- plugin-ci/build:
filters:
tags:
only: /^v.*/
- plugin-ci/deploy-ci:
filters:
branches:
ignore: /.*/
- build:
only: master
context: plugin-ci
requires:
- lint
- test
- plugin-ci/lint
- plugin-ci/test
- plugin-ci/build
- plugin-ci/deploy-release:
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/
- publish-github-release:
context: matterbuild-github-token
context: plugin-ci
requires:
- lint
- test
- build
- plugin-ci/lint
- plugin-ci/test
- plugin-ci/build
- plugin-ci/deploy-release-github:
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/
context: matterbuild-github-token
requires:
- plugin-ci/lint
- plugin-ci/test
- plugin-ci/build

0 comments on commit 81ce5f2

Please sign in to comment.