From df302465c9deb121a59f44e93a0d55ebb243d083 Mon Sep 17 00:00:00 2001 From: Bruno BELANYI Date: Fri, 24 Sep 2021 20:12:18 +0200 Subject: [PATCH] home: remove unused 'secrets' module --- home/default.nix | 1 - home/secrets/.gitattributes | 3 --- home/secrets/canary | Bin 32 -> 0 bytes home/secrets/default.nix | 31 ------------------------------- 4 files changed, 35 deletions(-) delete mode 100644 home/secrets/.gitattributes delete mode 100644 home/secrets/canary delete mode 100644 home/secrets/default.nix diff --git a/home/default.nix b/home/default.nix index 2668156..fee7a8b 100644 --- a/home/default.nix +++ b/home/default.nix @@ -23,7 +23,6 @@ ./packages.nix ./pager.nix ./power-alert.nix - ./secrets # Home-manager specific secrets ./ssh.nix ./terminal ./tmux.nix diff --git a/home/secrets/.gitattributes b/home/secrets/.gitattributes deleted file mode 100644 index a741d4d..0000000 --- a/home/secrets/.gitattributes +++ /dev/null @@ -1,3 +0,0 @@ -* filter=git-crypt diff=git-crypt -.gitattributes !filter !diff -/default.nix !filter !diff diff --git a/home/secrets/canary b/home/secrets/canary deleted file mode 100644 index e910ea3aafe746337b1ea57a9ff37d62d58d350f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 32 ocmZQ@_Y83kiVO&0c*b>ed6DJsmgBoNPv87j#HqYCqGs6~0N0cb+yDRo diff --git a/home/secrets/default.nix b/home/secrets/default.nix deleted file mode 100644 index 76ec2cf..0000000 --- a/home/secrets/default.nix +++ /dev/null @@ -1,31 +0,0 @@ -{ lib, ... }: - -with lib; -let - throwOnCanary = - let - canaryHash = builtins.hashFile "sha256" ./canary; - expectedHash = - "9df8c065663197b5a1095122d48e140d3677d860343256abd5ab6e4fb4c696ab"; - in - if canaryHash != expectedHash - then throw "Secrets are not readable. Have you run `git-crypt unlock`?" - else id; -in -throwOnCanary { - options.my.secrets = mkOption { - type = - let - valueType = with types; oneOf [ - int - str - (attrsOf valueType) - ]; - in - valueType; - }; - - config.my.secrets = { - # Home-manager secrets go here - }; -}