Initial commit

This commit is contained in:
NotAShelf 2023-12-24 20:02:13 +03:00 committed by NotAShelf
commit a94a991fab
No known key found for this signature in database
GPG key ID: 02D1DD3FA08B6B29
372 changed files with 215877 additions and 0 deletions

26
nix/package.nix Normal file
View file

@ -0,0 +1,26 @@
{
buildGoModule,
lib,
...
}: let
inherit (lib) hasSuffix;
pname = "mdlinkt";
version = "0.1.0";
in
buildGoModule {
inherit pname version;
src = builtins.filterSource (path: type: type != "directory" || hasSuffix path != ".nix") ../.;
vendorHash = null;
ldflags = ["-s" "-w"];
doCheck = false;
meta = {
description = "A CLI tool for checking for dead links in a markdown file";
license = lib.licenses.gpl3Only;
mainProgram = pname;
maintainers = with lib.maintainers; [NotAShelf];
};
}

15
nix/shell.nix Normal file
View file

@ -0,0 +1,15 @@
{
callPackage,
gopls,
go,
}: let
mainPkg = callPackage ./package.nix {};
in
mainPkg.overrideAttrs (oa: {
nativeBuildInputs =
[
gopls
go
]
++ (oa.nativeBuildInputs or []);
})