Created
April 23, 2019 14:47
-
-
Save speeddragon/1317e7c63d4585953cd5bd1ffdebfb07 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
description: Build Elixir source code | |
parameters: | |
cache-version: | |
default: v1 | |
description: String key to store cache in | |
type: string | |
steps: | |
- checkout | |
- restore_cache: | |
keys: | |
- >- | |
<< parameters.cache-version >>-mix-cache-{{ .Branch }}-{{ checksum | |
"mix.lock" }} | |
- '<< parameters.cache-version >>-mix-cache-{{ .Branch }}' | |
- << parameters.cache-version >>-mix-cache | |
- restore_cache: | |
keys: | |
- >- | |
<< parameters.cache-version >>-build-cache-{{ .Branch }}-{{ checksum | |
"mix.lock" }} | |
- '<< parameters.cache-version >>-build-cache-{{ .Branch }}' | |
- << parameters.cache-version >>-build-cache | |
- run: mix local.hex --force | |
- run: mix local.rebar --force | |
- run: 'mix do deps.get, compile' | |
- save_cache: | |
key: >- | |
<< parameters.cache-version >>-mix-cache-{{ .Branch }}-{{ checksum | |
"mix.lock" }} | |
paths: deps | |
- save_cache: | |
key: '<< parameters.cache-version >>-mix-cache-{{ .Branch }}' | |
paths: deps | |
- save_cache: | |
key: << parameters.cache-version >>-mix-cache | |
paths: deps | |
- save_cache: | |
key: >- | |
<< parameters.cache-version >>-build-cache-{{ .Branch }}-{{ checksum | |
"mix.lock" }} | |
paths: _build | |
- save_cache: | |
key: '<< parameters.cache-version >>-build-cache-{{ .Branch }}' | |
paths: _build | |
- save_cache: | |
key: << parameters.cache-version >>-build-cache | |
paths: _build |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment