diff --git a/README.org b/README.org index 144cb23..c2368b3 100644 --- a/README.org +++ b/README.org @@ -40,3 +40,19 @@ as source to BASH. before we install - NIX will copy each ORG file to the 'extras' folder - Entanglement should happen in tmpfolder place (IDEALLY tmp buff) - Can I do this by tangling a big org thing for the features? Yes? No? Probably not! + +* usage tips + +If you want nix rpel + +#+begin_src bash +nix repl +#+end_src + +Then in this directory: + +#+begin_src nix +:lf . +#+end_src + +You'll get acces to 'lib' and such. (It evals here) diff --git a/modules/home-manager/gpg-agent.conf b/home-manager/gpg-agent.conf similarity index 100% rename from modules/home-manager/gpg-agent.conf rename to home-manager/gpg-agent.conf diff --git a/home-manager/gpg-agent.nix b/home-manager/gpg-agent.nix new file mode 100644 index 0000000..06f5ba3 --- /dev/null +++ b/home-manager/gpg-agent.nix @@ -0,0 +1,13 @@ +#https://xeiaso.net/talks/asg-2023-nixos/ example +{ lib, config, pkgs, ... }: +let + cfg = config.azos.gpgagent; +in +{ + options.azos.gpgagent.enable = lib.mkEnableOption "Enables AZOS GPG agent"; + + config = lib.mkIf cfg.enable { + home.packages = [ pkgs.gnupg ]; + home.file.".gnupg/gpg-agent.conf".source = ./gpg-agent.conf; + }; +} diff --git a/home-manager/home.nix b/home-manager/home.nix index 53a6793..600cdcc 100644 --- a/home-manager/home.nix +++ b/home-manager/home.nix @@ -18,6 +18,7 @@ # You can also split up your configuration and import pieces of it here: # ./nvim.nix + ./gpg-agent.nix ]; nixpkgs = { @@ -47,12 +48,23 @@ }; }; + azos.gpgagent.enable = true; + # TODO: Set your username home = { username = "aner"; homeDirectory = "/home/aner"; + + }; + # config = { + # #My config stuff + # azos.gpg-agent.enable = true; + # }; + # home.config.azos.gpg-agent.enable = true; + + # Add stuff for your user as you see fit: # programs.neovim.enable = true; home.packages = with pkgs; [ @@ -72,6 +84,7 @@ programs.home-manager.enable = true; programs.git.enable = true; + # Nicely reload system units when changing configs systemd.user.startServices = "sd-switch"; diff --git a/modules/home-manager/default.nix b/modules/home-manager/default.nix index 05db906..43e8fb7 100644 --- a/modules/home-manager/default.nix +++ b/modules/home-manager/default.nix @@ -2,6 +2,4 @@ # These should be stuff you would like to share with others, not your personal configurations. { # List your module files here - # gpg-agent = import ./gpg-agent.nix; - # config.azos.gpg-agent.enable = true; } diff --git a/modules/home-manager/gpg-agent.nix b/modules/home-manager/gpg-agent.nix deleted file mode 100644 index f66a9c0..0000000 --- a/modules/home-manager/gpg-agent.nix +++ /dev/null @@ -1,14 +0,0 @@ -#https://xeiaso.net/talks/asg-2023-nixos/ example -{ lib, config, pkgs, ... }: - -with lib; - -let cfg = config.azos.gpg-agent; -in { - cfg.enable = mkEnableOption "Enables AZOS GPG agent"; - - config = mkIf cfg.enable { - programs.gnupg.agent.enable = true; - home.file.".gnupg/gpg-agent.conf".source = ./gpg-agent.conf; - }; -} diff --git a/nixos/configuration-vm.nix b/nixos/configuration-vm.nix index aa7c27b..3e390ee 100644 --- a/nixos/configuration-vm.nix +++ b/nixos/configuration-vm.nix @@ -15,7 +15,6 @@ x = 1280; y = 1024; }; - virtualisation.diskImage = "/dev/null"; virtualisation.qemu.options = [ # Better display option "-vga virtio"