diff options
author | Linnnus <[email protected]> | 2024-11-16 11:55:22 +0100 |
---|---|---|
committer | Linnnus <[email protected]> | 2024-11-16 11:55:36 +0100 |
commit | e396c06c4c2b9f8d47162dcd20155ec09163cb3b (patch) | |
tree | f1f9d2cb2003b798d71a0c950666f4aa4d770909 /pkgs/cscript/default.nix | |
parent | ef360099f4c2e4e59e9f9cad75be9fd65ee6a82c (diff) |
muhammed: Add cscript
Diffstat (limited to 'pkgs/cscript/default.nix')
-rw-r--r-- | pkgs/cscript/default.nix | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/pkgs/cscript/default.nix b/pkgs/cscript/default.nix new file mode 100644 index 0000000..8c6faae --- /dev/null +++ b/pkgs/cscript/default.nix @@ -0,0 +1,30 @@ +{ + stdenv, + lib, + fetchFromGitHub, +}: +stdenv.mkDerivation rec { + pname = "cscript"; + version = "16-11-2024"; # Date of latest commit. + + src = fetchFromGitHub { + owner = "linnnus"; + repo = pname; + rev = "855f35a4e6d5046000a1d9ff7b887ccd7c4a8c91"; + hash = "sha256-d722f3K3QXnPqDVNVGBK+mj6Bl1VNShmJ4WICj0p64s="; + }; + + preInstall = "mkdir -p $out/bin"; + makeFlags = ["INSTALL=$(out)/bin"]; + + meta = with lib; { + description = "My take on the native shebang programming task from Rosetta Code"; + longDescription = '' + This package contains a C "interpreter". Behind the scenes it actually + compiles the file and runs it immediately, so it's not really an + interpreter. Point is, it allows you to use a shebang (just like + `#!/bin/sh`) to write C programs that execute like a Bash scripts. + ''; + license = licenses.unlicense; + }; +} |