From 89cd41776076edfbbfe8ffb874a4e92d496e3ad2 Mon Sep 17 00:00:00 2001 From: Paul Bonaud Date: Fri, 26 Apr 2019 18:19:05 +0200 Subject: dhall(upgrade): upgrade code to be compatible with dhall 1.21.0 --- .travis.yml | 5 ++--- dhall-1.18.nix | 16 ---------------- dhall-1.21.0.nix | 22 ++++++++++++++++++++++ dhall/addon/Postgresql.dhall | 2 +- 4 files changed, 25 insertions(+), 20 deletions(-) delete mode 100644 dhall-1.18.nix create mode 100644 dhall-1.21.0.nix diff --git a/.travis.yml b/.travis.yml index ef53f71..720eade 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,9 +4,8 @@ language: nix sudo: false install: - - nix-env -i python2.7-ansible - - nix-env -i python2.7-ansible-lint - - nix-env -if ./dhall-1.18.nix + - nix-env -i python2.7-ansible python2.7-ansible-lint + - nix-env -if ./dhall-1.21.0.nix # Check ansible version - ansible --version diff --git a/dhall-1.18.nix b/dhall-1.18.nix deleted file mode 100644 index d6522bd..0000000 --- a/dhall-1.18.nix +++ /dev/null @@ -1,16 +0,0 @@ -{ pkgs ? import {} }: with pkgs; - -stdenv.mkDerivation rec { - name = "dhall-${version}"; - version = "1.18.0"; - phases = [ "installPhase "]; - src = fetchurl { - url = "https://github.com/dhall-lang/dhall-haskell/releases/download/${version}/dhall-${version}-x86_64-linux.tar.bz2"; - sha256 = "0jvw6ss96xifb21mzpvfjzvaffcnpj0jhpc4rd36cl2r22800qgx"; - }; - installPhase = '' - mkdir -p $out/bin - tar -xjf $src - mv bin/dhall $out/bin/ - ''; -} diff --git a/dhall-1.21.0.nix b/dhall-1.21.0.nix new file mode 100644 index 0000000..e53369b --- /dev/null +++ b/dhall-1.21.0.nix @@ -0,0 +1,22 @@ +{ pkgs ? import {} }: with pkgs; + +let + mkVersion = + version: sha256: + stdenv.mkDerivation { + name = "dhall-${version}"; + inherit version; + src = fetchurl { + url = "https://github.com/dhall-lang/dhall-haskell/releases/download/${version}/dhall-${version}-x86_64-linux.tar.bz2"; + inherit sha256; + }; + unpackPhase = '' + tar -xjf $src + ''; + installPhase = '' + mkdir -p $out/bin + mv bin/dhall $out/bin/ + ''; + }; +in + mkVersion "1.21.0" "0x7q6v1y62fq6724kx1hcfp1fcqv3lbv33ji6jzfd5y316a31r77" diff --git a/dhall/addon/Postgresql.dhall b/dhall/addon/Postgresql.dhall index 9dd9744..ed6b411 100644 --- a/dhall/addon/Postgresql.dhall +++ b/dhall/addon/Postgresql.dhall @@ -1,3 +1,3 @@ - let addon = constructors ./Addon.dhall +let addon = ./Addon.dhall in addon.Postgresql { name = "pg", env_prefix = "POSTGRESQL_ADDON" } -- cgit v1.2.3