mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-01 01:33:20 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
39 lines
1.1 KiB
Nix
39 lines
1.1 KiB
Nix
{ lib, stdenv, fetchFromGitHub, luaPackages, unstableGitUpdater }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "nelua";
|
|
version = "0-unstable-2024-10-18";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "edubart";
|
|
repo = "nelua-lang";
|
|
rev = "038c45f19842d7b18c32b6b4f7e631e15d77d453";
|
|
hash = "sha256-Qnr+A4nYPnBLUxNGRbUwEwuw2POV0AKXtpKKYcLtF1M=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace lualib/nelua/version.lua \
|
|
--replace "NELUA_GIT_HASH = nil" "NELUA_GIT_HASH = '${src.rev}'" \
|
|
--replace "NELUA_GIT_DATE = nil" "NELUA_GIT_DATE = '${lib.removePrefix "0-unstable-" version}'"
|
|
'';
|
|
|
|
makeFlags = [ "PREFIX=$(out)" ];
|
|
|
|
nativeCheckInputs = [ luaPackages.luacheck ];
|
|
|
|
doCheck = true;
|
|
|
|
passthru.updateScript = unstableGitUpdater {
|
|
# no releases, only stale "latest" tag
|
|
hardcodeZeroVersion = true;
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "Minimal, efficient, statically-typed and meta-programmable systems programming language heavily inspired by Lua, which compiles to C and native code";
|
|
homepage = "https://nelua.io/";
|
|
license = licenses.mit;
|
|
platforms = platforms.all;
|
|
maintainers = [ ];
|
|
};
|
|
}
|