Basic Question on Non-Flake Install #783
-
Hi. Sorry for the basic question, but I am not sure exactly how the given code for the 'Without flakes' install option should be added to a configuration.nix file. (referencing this: https://github.com/nix-community/nixvim#without-flakes) I threw it in my configuration.nix and got errors related to unexpected brackets, it seems like I shouldn't have just dropped it in there the way I did (right after my user profile config). # Define a user account. Don't forget to set a password with ‘passwd’.
users.users.gigi = {
...
};
# Nixvim Configuration
{ pkgs, lib, ... }:
let
nixvim = import (builtins.fetchGit {
url = "https://github.com/nix-community/nixvim";
});
in
{
imports = [
# For NixOS
nixvim.nixosModules.nixvim
];
programs.nixvim.enable = true;
plugins.which-key.enable = true;
colorschemes.tokyonight.enable = true;
} Does anyone have an example of a 'real' non-flake install or have pointers on how I should be adding it to my configuration.nix? I have only seen flake-based configurations. Thanks for any help. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hello ! |
Beta Was this translation helpful? Give feedback.
Hello !
Indeed, you should not just put it like this.
The
{ pkgs, lib, ... }:
should be at the beginning of the file.Then you can just add the rest within your
configuration.nix
file.