Dhall LSP releases

This commit is contained in:
Jack Henahan 2020-03-27 11:32:53 -04:00
parent 4f6da8c7e7
commit e758f79ae2
No known key found for this signature in database
GPG key ID: 0EA4DC9C030864F9
2 changed files with 28 additions and 0 deletions

View file

@ -20,4 +20,8 @@
dhall-yaml-simple = import ./dhall-yaml-simple.nix {
inherit pkgs;
};
dhall-lsp-simple = import ./dhall-lsp-simple.nix {
inherit pkgs;
};
}

24
dhall-lsp-simple.nix Normal file
View file

@ -0,0 +1,24 @@
{ pkgs ? import <nixpkgs> {} }:
pkgs.stdenv.mkDerivation rec {
name = "dhall-lsp-simple";
src = if pkgs.stdenv.isDarwin
then pkgs.fetchurl {
url = "https://github.com/dhall-lang/dhall-haskell/releases/download/1.30.0/dhall-lsp-server-1.0.5-x86_64-macos.tar.bz2";
sha256 = "1ng7f6mrxz1yjwskdf0knlbrb1r8d95yb9sqzbfymnynvpakjn1g";
}
else pkgs.fetchurl {
url = "https://github.com/dhall-lang/dhall-haskell/releases/download/1.30.0/dhall-lsp-server-1.0.5-x86_64-linux.tar.bz2";
sha256 = "0bgidy98s6nn2ysfbyl13s36rc8mn1rr5lw2wdpad6achz0mr397";
};
installPhase = ''
mkdir -p $out/bin
DHALL_LSP=$out/bin/dhall-lsp-server
install -D -m555 -T dhall-lsp-server $DHALL_LSP
mkdir -p $out/etc/bash_completion.d/
$DHALL_LSP --bash-completion-script $DHALL_LSP > $out/etc/bash_completion.d/dhall-lsp-server-completion.bash
'';
}