helm/packages/fennel.nix

34 lines
795 B
Nix
Raw Permalink Normal View History

2021-03-16 09:36:15 -07:00
{ lib, stdenv, luajit, my, ... }:
let name = "fennel";
version = "0.9.2";
2021-03-16 09:36:15 -07:00
in stdenv.mkDerivation {
inherit name version;
src = fetchTarball {
url = "https://fennel-lang.org/downloads/${name}-${version}.tar.gz";
sha256 = "0p9zr2vb9gq877advb5jvybx6dmqzmxqh4i7yzdr7fwvz7xzd2jv";
2021-03-16 09:36:15 -07:00
};
buildInputs = [
luajit
];
phases = "installPhase";
installPhase = ''
mkdir -p $out $out/bin
2021-03-16 09:36:15 -07:00
cp $src/fennel $out/bin/fennel
cp $src/fennel.lua $out/fennel.lua
2021-03-16 09:36:15 -07:00
chmod +x $out/bin/fennel
sed -i 's%^#!/usr/bin/env lua$%#!${luajit}/bin/luajit%' $out/bin/fennel
2021-03-16 09:36:15 -07:00
'';
meta = {
homepage = "https://github.com/bakpakin/Fennel";
description = "Lua Lisp Language";
license = lib.licenses.mit;
platforms = [ "x86_64-linux" ];
maintainers = [];
};
}