about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Helgesson <robert@rycee.net>2022-01-18 13:33:52 +0100
committerRobert Helgesson <robert@rycee.net>2022-01-18 13:48:41 +0100
commit3c2143ee7f1591b641c06eb8ac476c1b8c12e791 (patch)
treeb9a675328e061af548e4efe6483931150be1c925
parent363577461d27f8283a249602da91d68b61d189a0 (diff)
downloadnixlib-3c2143ee7f1591b641c06eb8ac476c1b8c12e791.tar
nixlib-3c2143ee7f1591b641c06eb8ac476c1b8c12e791.tar.gz
nixlib-3c2143ee7f1591b641c06eb8ac476c1b8c12e791.tar.bz2
nixlib-3c2143ee7f1591b641c06eb8ac476c1b8c12e791.tar.lz
nixlib-3c2143ee7f1591b641c06eb8ac476c1b8c12e791.tar.xz
nixlib-3c2143ee7f1591b641c06eb8ac476c1b8c12e791.tar.zst
nixlib-3c2143ee7f1591b641c06eb8ac476c1b8c12e791.zip
cue: 0.4.0 -> 0.4.1
Also

- download source from GitHub,

- run test suite, and

- add simple installation test.
-rw-r--r--pkgs/development/tools/cue/default.nix20
1 files changed, 13 insertions, 7 deletions
diff --git a/pkgs/development/tools/cue/default.nix b/pkgs/development/tools/cue/default.nix
index f177ced3092d..9119dbce158d 100644
--- a/pkgs/development/tools/cue/default.nix
+++ b/pkgs/development/tools/cue/default.nix
@@ -1,18 +1,19 @@
-{ buildGoModule, fetchgit, lib }:
+{ buildGoModule, fetchFromGitHub, lib }:
 
 buildGoModule rec {
   pname = "cue";
-  version = "0.4.0";
+  version = "0.4.1";
 
-  src = fetchgit {
-    url = "https://cue.googlesource.com/cue";
+  src = fetchFromGitHub {
+    owner = "cue-lang";
+    repo = "cue";
     rev = "v${version}";
-    sha256 = "sha256-rcGEl+CMFyxZKsOKhVimhv5/ONo3xS6FjgKModZGR2o=";
+    sha256 = "1q1mkqb6fk515g556yn8ks3gqrimfbadprmbv5rill1lpipq5xbj";
   };
 
-  vendorSha256 = "sha256-eSKVlBgnHR1R0j1lNwtFoIgRuj8GqoMbvuBl/N1SanY=";
+  vendorSha256 = "12p77a97lbff6qhncs5qx13k3wmf9hrr09mhh12isw5s0p0n53xm";
 
-  doCheck = false;
+  checkPhase = "go test ./...";
 
   subPackages = [ "cmd/cue" ];
 
@@ -20,6 +21,11 @@ buildGoModule rec {
     "-s" "-w" "-X cuelang.org/go/cmd/cue/cmd.version=${version}"
   ];
 
+  doInstallCheck = true;
+  installCheckPhase = ''
+    $out/bin/cue eval - <<<'a: "all good"' > /dev/null
+  '';
+
   meta = {
     description = "A data constraint language which aims to simplify tasks involving defining and using data";
     homepage = "https://cuelang.org/";