Skip to content

Commit

Permalink
boot-message package
Browse files Browse the repository at this point in the history
  • Loading branch information
mightyiam committed Oct 27, 2024
1 parent ab05128 commit d968201
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 16 deletions.
31 changes: 31 additions & 0 deletions boot-message.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{ self, lib, ... }:
{
perSystem =
{ pkgs, ... }:
{
packages.boot-message = pkgs.writeShellApplication {
name = "boot-message";
text =
let
message = lib.escapeShellArg ''
If found, please contact:
Shahar "Dawn" Or
+66613657506
[email protected]
@mightyiam:matrix.org
'';
in
''echo -e ${message} | cowsay --bold --aurora -f dragon'';
runtimeInputs = [ pkgs.neo-cowsay ];
};
};

flake.nixosModules.common.imports = [
(
{ pkgs, ... }:
{
boot.initrd.preDeviceCommands = lib.getExe self.packages.${pkgs.stdenv.system}.boot-message;
}
)
];
}
1 change: 1 addition & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@
inputs:
inputs.flake-parts.lib.mkFlake { inputs = inputs; } {
imports = [
./boot-message.nix
./catppuccin.nix
./fmt.nix
./meta.nix
Expand Down
15 changes: 0 additions & 15 deletions nixos-modules/modules/boot-message.nix

This file was deleted.

1 change: 0 additions & 1 deletion nixos-modules/types/desktop.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
imports = [
../modules/allow-unfree-packages.nix
../modules/bluetooth.nix
../modules/boot-message.nix
../modules/dconf.nix
../modules/editor.nix
../modules/firmware.nix
Expand Down

0 comments on commit d968201

Please sign in to comment.