-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #62 from haskell-works/PR-ugly-fix-jumps
Pr ugly fix jumps
- Loading branch information
Showing
13 changed files
with
249 additions
and
513 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,86 +1,110 @@ | ||
version: 2.0 | ||
jobs: | ||
build: | ||
working_directory: ~/hw-kafka-client | ||
docker: | ||
- image: fpco/stack-build:latest | ||
defaults: &defaults | ||
working_directory: ~/build | ||
docker: | ||
- image: quay.io/haskell_works/stack-build-python | ||
|
||
- image: confluentinc/cp-zookeeper | ||
environment: | ||
ZOOKEEPER_CLIENT_PORT: 2181 | ||
- image: confluentinc/cp-zookeeper | ||
environment: | ||
ZOOKEEPER_CLIENT_PORT: 2181 | ||
|
||
- image: confluentinc/cp-kafka | ||
environment: | ||
KAFKA_ZOOKEEPER_CONNECT: "localhost:2181" | ||
KAFKA_ADVERTISED_LISTENERS: "PLAINTEXT://localhost:9092" | ||
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1 | ||
- image: confluentinc/cp-kafka | ||
environment: | ||
KAFKA_ZOOKEEPER_CONNECT: "localhost:2181" | ||
KAFKA_ADVERTISED_LISTENERS: "PLAINTEXT://localhost:9092" | ||
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1 | ||
|
||
steps: | ||
- checkout | ||
steps: | ||
- checkout | ||
|
||
- run: | ||
name: Copying scripts | ||
command: | | ||
mkdir -p ~/.local/bin | ||
cp ./scripts/* ~/.local/bin | ||
- restore_cache: | ||
keys: | ||
- dot-stack-{{ checksum "stack.yaml" }}-{{ checksum "hw-kafka-client.cabal" }} | ||
- dot-stack | ||
- restore_cache: | ||
key: stack-work-{{ checksum "stack.yaml" }} | ||
- restore_cache: | ||
key: librdkafka-{{ checksum "scripts/build-librdkafka" }} | ||
- restore_cache: | ||
keys: | ||
- dot-stack-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "package.yaml" }} | ||
- dot-stack-{{ arch }}-{{ .Environment.CIRCLE_JOB }} | ||
|
||
- run: | ||
name: Build librdkafka | ||
command: build-librdkafka | ||
- restore_cache: | ||
key: stack-work-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "package.yaml" }} | ||
|
||
- run: stack setup | ||
- run: stack build --test --no-run-tests --haddock --no-haddock-deps | ||
- restore_cache: | ||
key: librdkafka--{{ arch }}-{{ checksum "scripts/build-librdkafka" }} | ||
|
||
- run: | ||
name: Copying documentation | ||
command: copy-docs | ||
- run: | ||
name: Build librdkafka | ||
command: ./scripts/build-librdkafka | ||
|
||
- run: | ||
name: Running unit tests | ||
command: stack test | ||
- save_cache: | ||
key: librdkafka--{{ arch }}-{{ checksum "scripts/build-librdkafka" }} | ||
paths: ~/build/.librdkafka | ||
|
||
- save_cache: | ||
key: dot-stack-base | ||
paths: | ||
- ~/.stack | ||
- run: stack setup --resolver ${LTS} | ||
- run: stack build --test --no-run-tests --haddock --no-haddock-deps --resolver ${LTS} | ||
|
||
- save_cache: | ||
key: dot-stack-{{ checksum "stack.yaml" }}-{{ checksum "hw-kafka-client.cabal" }} | ||
paths: | ||
- ~/.stack | ||
- save_cache: | ||
key: dot-stack-{{ arch }}-{{ .Environment.CIRCLE_JOB }} | ||
paths: | ||
- ~/.stack | ||
|
||
- save_cache: | ||
key: stack-work-{{ checksum "stack.yaml" }} | ||
paths: ~/hw-kafka-client/.stack-work | ||
- run: | ||
name: Running unit tests | ||
command: stack test --resolver ${LTS} | ||
|
||
- save_cache: | ||
key: librdkafka-{{ checksum "scripts/build-librdkafka" }} | ||
paths: ~/hw-kafka-client/.librdkafka | ||
- save_cache: | ||
key: dot-stack-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "package.yaml" }} | ||
paths: | ||
- ~/.stack | ||
|
||
- store_artifacts: | ||
path: /tmp/doc | ||
- save_cache: | ||
key: stack-work-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "package.yaml" }} | ||
paths: ~/build/.stack-work | ||
|
||
version: 2.0 | ||
jobs: | ||
lts-7: | ||
environment: | ||
- LTS: "lts-7" | ||
<<: *defaults | ||
|
||
lts-9: | ||
environment: | ||
- LTS: "lts-9" | ||
<<: *defaults | ||
|
||
lts-11: | ||
environment: | ||
- LTS: "lts-11" | ||
<<: *defaults | ||
|
||
nightly: | ||
environment: | ||
- LTS: "nightly" | ||
<<: *defaults | ||
|
||
release: | ||
working_directory: ~/build | ||
docker: | ||
- image: quay.io/haskell_works/stack-build-python | ||
|
||
steps: | ||
- checkout | ||
|
||
- run: | ||
name: Making a release | ||
command: ./scripts/release | ||
|
||
|
||
workflows: | ||
version: 2 | ||
multiple-ghcs: | ||
jobs: | ||
- lts-7 | ||
- lts-9 | ||
- lts-11 | ||
# - nightly | ||
- deploy: | ||
command: | | ||
if [ "$CIRCLE_PROJECT_USERNAME" == "haskell-works" ]; then | ||
if [[ "$CIRCLE_BRANCH" == master ]]; then | ||
when tag autotag | ||
elif [[ "$CIRCLE_TAG" =~ v.* ]]; then | ||
setup-cred && publish && publish-docs | ||
fi | ||
fi | ||
deployment: | ||
tagged_builds: | ||
tag: /v.*/ | ||
commands: | ||
- echo "Make tags run in 2.0" | ||
requires: | ||
- lts-7 | ||
- lts-9 | ||
- lts-11 | ||
filters: | ||
branches: | ||
only: master | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.