diff --git a/common/packages.nix b/common/packages.nix index be60ef6..f12d8f5 100644 --- a/common/packages.nix +++ b/common/packages.nix @@ -76,6 +76,7 @@ in anki audacity arduino-ide + bitwarden-cli bitwarden-desktop brave dino diff --git a/overlays/bitwarden-cli-adblock/default.nix b/overlays/bitwarden-cli-adblock/default.nix new file mode 100644 index 0000000..fda003e --- /dev/null +++ b/overlays/bitwarden-cli-adblock/default.nix @@ -0,0 +1,7 @@ +# implements https://github.com/NixOS/nixpkgs/pull/400183 +self: super: { + bitwarden-cli = super.bitwarden-cli.overrideAttrs (old: + assert (old.patches or []) == []; + { patches = [ ./remove-ad.patch ]; } + ); +} diff --git a/overlays/bitwarden-cli-adblock/remove-ad.patch b/overlays/bitwarden-cli-adblock/remove-ad.patch new file mode 100644 index 0000000..3a0e3a3 --- /dev/null +++ b/overlays/bitwarden-cli-adblock/remove-ad.patch @@ -0,0 +1,16 @@ +diff --git i/apps/cli/src/program.ts w/apps/cli/src/program.ts +index c6b79c7dff..139ebf0323 100644 +--- i/apps/cli/src/program.ts ++++ w/apps/cli/src/program.ts +@@ -74,11 +74,6 @@ export class Program extends BaseProgram { + }); + + program.on("--help", () => { +- writeLn( +- chalk.yellowBright( +- "\n Tip: Managing and retrieving secrets for dev environments is easier with Bitwarden Secrets Manager. Learn more under https://bitwarden.com/products/secrets-manager/", +- ), +- ); + writeLn("\n Examples:"); + writeLn(""); + writeLn(" bw login"); diff --git a/overlays/default.nix b/overlays/default.nix index bedffd1..48a0e8e 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -1,7 +1,14 @@ -map import [ - ./nheko.nix - ./newPackages.nix - ./fetchurl-with-wetransfer - ./betterbird - ./hpn.nix -] +let + directoryListing = builtins.removeAttrs (builtins.readDir ./.) [ "default.nix" ]; + overlayAttrs = builtins.mapAttrs ( + fileName: kind: + let + fileNameLength = builtins.stringLength fileName; + lastFour = builtins.substring (fileNameLength - 4) (-1) fileName; + in + assert kind == "directory" || kind == "regular"; + assert (kind == "regular") -> lastFour == ".nix"; + import ./${fileName} + ) directoryListing; +in +builtins.attrValues overlayAttrs