switch to mdboko-alerts from nixpkgs

This commit is contained in:
Adithya 2024-09-07 19:30:23 +05:30
parent 320293f4a2
commit 81b93cc3e4
Signed by: adtya
GPG key ID: B8857BFBA2C47B9C
2 changed files with 3 additions and 27 deletions

View file

@ -18,8 +18,7 @@
pkgs = import nixpkgs {
inherit system;
};
mdbook-alerts = pkgs.callPackage ./mdbook-alerts.nix { };
package = pkgs.callPackage ./default.nix { inherit mdbook-alerts; };
package = pkgs.callPackage ./default.nix { };
app = pkgs.writeShellScriptBin "app" ''
trap 'kill "''${child_pid}"; wait "''${child_pid}";' SIGINT SIGTERM
${pkgs.merecat}/bin/merecat -n -p 8080 ${package}/share/web &
@ -32,11 +31,11 @@
devShells.default = pkgs.mkShell {
packages = [
pkgs.mdbook
mdbook-alerts
pkgs.mdbook-alerts
];
};
packages = {
inherit app mdbook-alerts;
inherit app;
default = package;
};
}

View file

@ -1,23 +0,0 @@
{ lib, fetchFromGitHub, rustPlatform }:
rustPlatform.buildRustPackage rec {
pname = "mdbook-alerts";
version = "0.5.2";
src = fetchFromGitHub {
owner = "lambdalisue";
repo = "rs-mdbook-alerts";
rev = "v${version}";
hash = "sha256-YlCvsDdWuoajuXt2hOGx7jW+lmLeMOSQ809bG9ZBaBY=";
};
cargoHash = "sha256-OuZo8QTE5Z1991S5CEkfxlXghQbnalt1UGNs4KozmEk=";
meta = with lib; {
description = "mdBook preprocessor to add GitHub Flavored Markdown's Alerts to your book";
mainProgram = "mdbook-alerts";
license = licenses.mit;
maintainers = with maintainers; [ adtya ];
homepage = "https://github.com/lambdalisue/rs-mdbook-alerts";
};
}