mirror of
https://github.com/nmasur/dotfiles
synced 2024-11-09 23:22:57 +00:00
wsl fixes
This commit is contained in:
parent
e1e27ca065
commit
084e832039
@ -21,6 +21,11 @@
|
|||||||
if pkgs.stdenv.isDarwin then "$HOME/Downloads" else "$HOME/downloads";
|
if pkgs.stdenv.isDarwin then "$HOME/Downloads" else "$HOME/downloads";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
identityFile = lib.mkOption {
|
||||||
|
type = lib.types.str;
|
||||||
|
description = "Path to existing identity file.";
|
||||||
|
default = "/etc/ssh/ssh_host_ed25519_key";
|
||||||
|
};
|
||||||
gui = {
|
gui = {
|
||||||
enable = mkEnableOption {
|
enable = mkEnableOption {
|
||||||
description = "Enable graphics";
|
description = "Enable graphics";
|
||||||
@ -39,6 +44,7 @@
|
|||||||
else
|
else
|
||||||
"/home/${config.user}");
|
"/home/${config.user}");
|
||||||
};
|
};
|
||||||
|
|
||||||
dotfilesPath = mkOption {
|
dotfilesPath = mkOption {
|
||||||
type = types.path;
|
type = types.path;
|
||||||
description = "Path of dotfiles repository.";
|
description = "Path of dotfiles repository.";
|
||||||
@ -55,33 +61,31 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
config =
|
config = let stateVersion = "22.11";
|
||||||
let stateVersion = "22.11";
|
in {
|
||||||
in
|
|
||||||
{
|
|
||||||
|
|
||||||
# Enable features in Nix commands
|
# Enable features in Nix commands
|
||||||
nix.extraOptions = "experimental-features = nix-command flakes";
|
nix.extraOptions = "experimental-features = nix-command flakes";
|
||||||
|
|
||||||
# Basic common system packages for all devices
|
# Basic common system packages for all devices
|
||||||
environment.systemPackages = with pkgs; [ git vim wget curl ];
|
environment.systemPackages = with pkgs; [ git vim wget curl ];
|
||||||
|
|
||||||
# Use the system-level nixpkgs instead of Home Manager's
|
# Use the system-level nixpkgs instead of Home Manager's
|
||||||
home-manager.useGlobalPkgs = true;
|
home-manager.useGlobalPkgs = true;
|
||||||
|
|
||||||
# Install packages to /etc/profiles instead of ~/.nix-profile, useful when
|
# Install packages to /etc/profiles instead of ~/.nix-profile, useful when
|
||||||
# using multiple profiles for one user
|
# using multiple profiles for one user
|
||||||
home-manager.useUserPackages = true;
|
home-manager.useUserPackages = true;
|
||||||
|
|
||||||
# Allow specified unfree packages (identified elsewhere)
|
# Allow specified unfree packages (identified elsewhere)
|
||||||
# Retrieves package object based on string name
|
# Retrieves package object based on string name
|
||||||
nixpkgs.config.allowUnfreePredicate = pkg:
|
nixpkgs.config.allowUnfreePredicate = pkg:
|
||||||
builtins.elem (lib.getName pkg) config.unfreePackages;
|
builtins.elem (lib.getName pkg) config.unfreePackages;
|
||||||
|
|
||||||
# Pin a state version to prevent warnings
|
# Pin a state version to prevent warnings
|
||||||
home-manager.users.${config.user}.home.stateVersion = stateVersion;
|
home-manager.users.${config.user}.home.stateVersion = stateVersion;
|
||||||
home-manager.users.root.home.stateVersion = stateVersion;
|
home-manager.users.root.home.stateVersion = stateVersion;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -12,6 +12,7 @@ nixpkgs.lib.nixosSystem {
|
|||||||
nixpkgs.overlays = [ nur.overlay ];
|
nixpkgs.overlays = [ nur.overlay ];
|
||||||
# Set registry to flake packages, used for nix X commands
|
# Set registry to flake packages, used for nix X commands
|
||||||
nix.registry.nixpkgs.flake = nixpkgs;
|
nix.registry.nixpkgs.flake = nixpkgs;
|
||||||
|
identityFile = "/home/${globals.user}/.ssh/id_ed25519";
|
||||||
gaming.steam = true;
|
gaming.steam = true;
|
||||||
gaming.leagueoflegends = true;
|
gaming.leagueoflegends = true;
|
||||||
gaming.legendary = true;
|
gaming.legendary = true;
|
||||||
|
@ -12,6 +12,7 @@ darwin.lib.darwinSystem {
|
|||||||
})
|
})
|
||||||
home-manager.darwinModules.home-manager
|
home-manager.darwinModules.home-manager
|
||||||
{
|
{
|
||||||
|
identityFile = "/home/${globals.user}/.ssh/id_ed25519";
|
||||||
gui.enable = true;
|
gui.enable = true;
|
||||||
colorscheme = (import ../../modules/colorscheme/gruvbox);
|
colorscheme = (import ../../modules/colorscheme/gruvbox);
|
||||||
mailUser = globals.user;
|
mailUser = globals.user;
|
||||||
|
@ -12,6 +12,7 @@ nixpkgs.lib.nixosSystem {
|
|||||||
networking.hostName = "wsl";
|
networking.hostName = "wsl";
|
||||||
# Set registry to flake packages, used for nix X commands
|
# Set registry to flake packages, used for nix X commands
|
||||||
nix.registry.nixpkgs.flake = nixpkgs;
|
nix.registry.nixpkgs.flake = nixpkgs;
|
||||||
|
identityFile = "/home/${globals.user}/.ssh/id_ed25519";
|
||||||
gui.enable = false;
|
gui.enable = false;
|
||||||
colorscheme = (import ../../modules/colorscheme/gruvbox);
|
colorscheme = (import ../../modules/colorscheme/gruvbox);
|
||||||
passwordHash =
|
passwordHash =
|
||||||
|
@ -75,11 +75,10 @@
|
|||||||
};
|
};
|
||||||
mu.enable = false;
|
mu.enable = false;
|
||||||
notmuch.enable = false;
|
notmuch.enable = false;
|
||||||
passwordCommand = ''
|
passwordCommand =
|
||||||
${pkgs.age}/bin/age --decrypt \
|
"${pkgs.age}/bin/age --decrypt --identity ${config.identityFile} ${
|
||||||
--identity ${config.identityFile} \
|
builtins.toString ../../private/mailpass.age
|
||||||
${builtins.toString ../../private/mailpass.age}
|
}";
|
||||||
'';
|
|
||||||
smtp = {
|
smtp = {
|
||||||
host = "smtp.purelymail.com";
|
host = "smtp.purelymail.com";
|
||||||
port = 465;
|
port = 465;
|
||||||
|
@ -14,8 +14,7 @@ M.packer = function(use)
|
|||||||
return vim.fn.executable(program) == 1
|
return vim.fn.executable(program) == 1
|
||||||
end
|
end
|
||||||
|
|
||||||
local capabilities =
|
local capabilities = require("cmp_nvim_lsp").default_capabilities()
|
||||||
require("cmp_nvim_lsp").update_capabilities(vim.lsp.protocol.make_client_capabilities())
|
|
||||||
if on_path("lua-language-server") then
|
if on_path("lua-language-server") then
|
||||||
require("lspconfig").sumneko_lua.setup({
|
require("lspconfig").sumneko_lua.setup({
|
||||||
capabilities = capabilities,
|
capabilities = capabilities,
|
||||||
|
@ -7,12 +7,6 @@
|
|||||||
|
|
||||||
options = {
|
options = {
|
||||||
|
|
||||||
identityFile = lib.mkOption {
|
|
||||||
type = lib.types.str;
|
|
||||||
description = "Path to existing identity file.";
|
|
||||||
default = "/etc/ssh/ssh_host_ed25519_key";
|
|
||||||
};
|
|
||||||
|
|
||||||
secretsDirectory = lib.mkOption {
|
secretsDirectory = lib.mkOption {
|
||||||
type = lib.types.str;
|
type = lib.types.str;
|
||||||
description = "Default path to place secrets.";
|
description = "Default path to place secrets.";
|
||||||
|
Loading…
Reference in New Issue
Block a user