Skip to content

Commit

Permalink
Bump required version of Elixir to 1.6; update CI
Browse files Browse the repository at this point in the history
  • Loading branch information
fhunleth authored and mobileoverlord committed Feb 20, 2019
1 parent 683dd39 commit ff07d0d
Show file tree
Hide file tree
Showing 2 changed files with 82 additions and 9 deletions.
89 changes: 81 additions & 8 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,89 @@
# Elixir CircleCI 2.0 configuration file
#
# Check https://circleci.com/docs/2.0/language-elixir/ for more details
install_elixir: &install_elixir
run:
name: Install Elixir
command: |
wget https://repo.hex.pm/builds/elixir/v$ELIXIR_VERSION.zip
unzip -d /usr/local/elixir v$ELIXIR_VERSION.zip
echo 'export PATH=/usr/local/elixir/bin:$PATH' >> $BASH_ENV
install_hex_rebar: &install_hex_rebar
run:
name: Install hex and rebar
command: |
mix local.hex --force
mix local.rebar --force
install_system_deps: &install_system_deps
run:
name: Install system dependencies
command: |
apt update
apt install -y unzip astyle libmnl-dev
defaults: &defaults
working_directory: ~/repo

version: 2

jobs:
build:
build_elixir_1_7_otp_21:
docker:
- image: circleci/elixir:1.5.2
working_directory: ~/repo
- image: erlang:21.2
environment:
ELIXIR_VERSION: 1.7.4-otp-21
LC_ALL: C.UTF-8
SUDO: true
<<: *defaults
steps:
- checkout
- run: mix local.hex --force && mix local.rebar --force
- run: mix deps.get --only test
- <<: *install_system_deps
- <<: *install_elixir
- <<: *install_hex_rebar
- run: mix deps.get
- run: mix format --check-formatted
- run: mix hex.build
- run: mix test
- run: mix docs

build_elixir_1_6_otp_21:
docker:
- image: erlang:21.1
environment:
ELIXIR_VERSION: 1.6.6-otp-21
LC_ALL: C.UTF-8
SUDO: true
<<: *defaults
steps:
- checkout
- <<: *install_system_deps
- <<: *install_elixir
- <<: *install_hex_rebar
- run: mix deps.get
- run: mix test

build_elixir_1_6_otp_20:
docker:
- image: erlang:20.3.8
environment:
ELIXIR_VERSION: 1.6.6
LC_ALL: C.UTF-8
SUDO: true
<<: *defaults
steps:
- checkout
- <<: *install_system_deps
- <<: *install_elixir
- <<: *install_hex_rebar
- run: mix deps.get
- run: mix test

workflows:
version: 2
build_test:
jobs:
- build_elixir_1_7_otp_21:
context: org-global
- build_elixir_1_6_otp_21:
context: org-global
- build_elixir_1_6_otp_20:
context: org-global
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defmodule SystemRegistry.Mixfile do
[
app: :system_registry,
version: "0.8.1",
elixir: "~> 1.5",
elixir: "~> 1.6",
start_permanent: Mix.env() == :prod,
elixirc_paths: elixirc_paths(Mix.env()),
description: description(),
Expand Down

0 comments on commit ff07d0d

Please sign in to comment.