mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-03-18 07:13:44 +01:00
fix: nix.settings.auto-optimise-store, and add command 'fhs'
This commit is contained in:
@@ -87,3 +87,4 @@ Other configurations that inspired me:
|
||||
- [fufexan/dotfiles](https://github.com/fufexan/dotfiles)
|
||||
- [davidtwco/veritas](https://github.com/davidtwco/veritas)
|
||||
- [NixOS-CN/NixOS-CN-telegram](https://github.com/NixOS-CN/NixOS-CN-telegram)
|
||||
- [Tips&Tricks for NixOS Desktop](https://discourse.nixos.org/t/tips-tricks-for-nixos-desktop/28488/2)
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
# Manual optimise storage: nix-store --optimise
|
||||
# https://nixos.org/manual/nix/stable/command-ref/conf-file.html#conf-auto-optimise-store
|
||||
auto-optimise-store = true;
|
||||
nix.settings.auto-optimise-store = true;
|
||||
|
||||
# enable flakes globally
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
@@ -141,6 +141,16 @@
|
||||
});
|
||||
version = "latest";
|
||||
}))
|
||||
|
||||
# create a fhs environment by command `fhs`, so we can run non-nixos packages in nixos!
|
||||
(let base = pkgs.appimageTools.defaultFhsEnvArgs; in
|
||||
pkgs.buildFHSUserEnv (base // {
|
||||
name = "fhs";
|
||||
targetPkgs = pkgs: (base.targetPkgs pkgs) ++ [pkgs.pkg-config];
|
||||
profile = "export FHS=1";
|
||||
runScript = "bash";
|
||||
extraOutputsToInstall = ["dev"];
|
||||
}))
|
||||
];
|
||||
|
||||
# replace default editor with neovim
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
# Manual optimise storage: nix-store --optimise
|
||||
# https://nixos.org/manual/nix/stable/command-ref/conf-file.html#conf-auto-optimise-store
|
||||
auto-optimise-store = true;
|
||||
nix.settings.auto-optimise-store = true;
|
||||
|
||||
# enable flakes globally
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
|
||||
Reference in New Issue
Block a user