Merge remote-tracking branch 'origin/nixos' into nixos

This commit is contained in:
Moritz Böhme 2023-06-28 09:17:44 +02:00
commit a35d93ae2a
11 changed files with 49 additions and 135 deletions

View file

@ -55,34 +55,6 @@
"type": "github" "type": "github"
} }
}, },
"attic": {
"inputs": {
"crane": "crane",
"flake-compat": "flake-compat",
"flake-utils": [
"flake-utils"
],
"nixpkgs": [
"nixpkgs"
],
"nixpkgs-stable": [
"stable"
]
},
"locked": {
"lastModified": 1685309025,
"narHash": "sha256-pZxMM3AMP/ojwhrFD0A2ML4NOgehlBLGHseInnO5evc=",
"owner": "zhaofengli",
"repo": "attic",
"rev": "b1fb790b5f2afaaa1b2f7f18979b8318abe604bb",
"type": "github"
},
"original": {
"owner": "zhaofengli",
"repo": "attic",
"type": "github"
}
},
"cmp-async-path": { "cmp-async-path": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -115,36 +87,6 @@
"type": "github" "type": "github"
} }
}, },
"crane": {
"inputs": {
"flake-compat": [
"attic",
"flake-compat"
],
"flake-utils": [
"attic",
"flake-utils"
],
"nixpkgs": [
"attic",
"nixpkgs"
],
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1677892403,
"narHash": "sha256-/Wi0L1spSWLFj+UQxN3j0mPYMoc7ZoAujpUF/juFVII=",
"owner": "ipetkov",
"repo": "crane",
"rev": "105e27adb70a9890986b6d543a67761cbc1964a2",
"type": "github"
},
"original": {
"owner": "ipetkov",
"repo": "crane",
"type": "github"
}
},
"darwin": { "darwin": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -231,22 +173,6 @@
"type": "github" "type": "github"
} }
}, },
"flake-compat_5": {
"flake": false,
"locked": {
"lastModified": 1673956053,
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": { "flake-parts": {
"inputs": { "inputs": {
"nixpkgs-lib": [ "nixpkgs-lib": [
@ -668,7 +594,7 @@
}, },
"neovim-nightly-overlay": { "neovim-nightly-overlay": {
"inputs": { "inputs": {
"flake-compat": "flake-compat_2", "flake-compat": "flake-compat",
"flake-parts": "flake-parts", "flake-parts": "flake-parts",
"hercules-ci-effects": "hercules-ci-effects", "hercules-ci-effects": "hercules-ci-effects",
"neovim-flake": "neovim-flake", "neovim-flake": "neovim-flake",
@ -696,7 +622,7 @@
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ],
"rust-overlay": "rust-overlay_2" "rust-overlay": "rust-overlay"
}, },
"locked": { "locked": {
"lastModified": 1685532165, "lastModified": 1685532165,
@ -737,25 +663,24 @@
}, },
"nix-super": { "nix-super": {
"inputs": { "inputs": {
"flake-compat": "flake-compat_4", "flake-compat": "flake-compat_3",
"lowdown-src": "lowdown-src", "lowdown-src": "lowdown-src",
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "stable"
], ],
"nixpkgs-regression": "nixpkgs-regression" "nixpkgs-regression": "nixpkgs-regression"
}, },
"locked": { "locked": {
"lastModified": 1683240066, "lastModified": 1687621557,
"narHash": "sha256-XXTB64SAMukIt2suhoPP87QDKX9vB2ByXXuE7l2Vyxw=", "narHash": "sha256-FWtdWRmtzmqjjAsvYXefdZ2uVv5p5UfB7eftqsctSck=",
"owner": "privatevoid-net", "owner": "privatevoid-net",
"repo": "nix-super", "repo": "nix-super",
"rev": "aaba1f91e7eba8ce029fa6bfa81ad9e14a13708d", "rev": "c39cdf9ad2365509a602f8e2c6faa35aec1097a3",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "privatevoid-net", "owner": "privatevoid-net",
"repo": "nix-super", "repo": "nix-super",
"rev": "aaba1f91e7eba8ce029fa6bfa81ad9e14a13708d",
"type": "github" "type": "github"
} }
}, },
@ -955,7 +880,7 @@
}, },
"pre-commit-hooks": { "pre-commit-hooks": {
"inputs": { "inputs": {
"flake-compat": "flake-compat_5", "flake-compat": "flake-compat_4",
"flake-utils": "flake-utils_4", "flake-utils": "flake-utils_4",
"gitignore": "gitignore_2", "gitignore": "gitignore_2",
"nixpkgs": "nixpkgs_7", "nixpkgs": "nixpkgs_7",
@ -977,7 +902,7 @@
}, },
"pre-commit-hooks-nix": { "pre-commit-hooks-nix": {
"inputs": { "inputs": {
"flake-compat": "flake-compat_3", "flake-compat": "flake-compat_2",
"flake-utils": "flake-utils_2", "flake-utils": "flake-utils_2",
"gitignore": "gitignore", "gitignore": "gitignore",
"nixpkgs": [ "nixpkgs": [
@ -1024,7 +949,6 @@
"agenix": "agenix", "agenix": "agenix",
"arkenfox-userjs": "arkenfox-userjs", "arkenfox-userjs": "arkenfox-userjs",
"asus-touchpad-numpad-driver": "asus-touchpad-numpad-driver", "asus-touchpad-numpad-driver": "asus-touchpad-numpad-driver",
"attic": "attic",
"cmp-async-path": "cmp-async-path", "cmp-async-path": "cmp-async-path",
"copilot-lua": "copilot-lua", "copilot-lua": "copilot-lua",
"flake-utils": "flake-utils", "flake-utils": "flake-utils",
@ -1046,33 +970,6 @@
} }
}, },
"rust-overlay": { "rust-overlay": {
"inputs": {
"flake-utils": [
"attic",
"crane",
"flake-utils"
],
"nixpkgs": [
"attic",
"crane",
"nixpkgs"
]
},
"locked": {
"lastModified": 1675391458,
"narHash": "sha256-ukDKZw922BnK5ohL9LhwtaDAdCsJL7L6ScNEyF1lO9w=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "383a4acfd11d778d5c2efcf28376cbd845eeaedf",
"type": "github"
},
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
"type": "github"
}
},
"rust-overlay_2": {
"inputs": { "inputs": {
"flake-utils": [ "flake-utils": [
"nil", "nil",

View file

@ -17,11 +17,6 @@
agenix.inputs.nixpkgs.follows = "nixpkgs"; agenix.inputs.nixpkgs.follows = "nixpkgs";
agenix.url = "github:ryantm/agenix"; agenix.url = "github:ryantm/agenix";
attic.inputs.flake-utils.follows = "flake-utils";
attic.inputs.nixpkgs-stable.follows = "stable";
attic.inputs.nixpkgs.follows = "nixpkgs";
attic.url = "github:zhaofengli/attic";
home-manager.inputs.nixpkgs.follows = "nixpkgs"; home-manager.inputs.nixpkgs.follows = "nixpkgs";
home-manager.url = "github:nix-community/home-manager"; home-manager.url = "github:nix-community/home-manager";
@ -31,8 +26,8 @@
pre-commit-hooks.url = "github:cachix/pre-commit-hooks.nix"; pre-commit-hooks.url = "github:cachix/pre-commit-hooks.nix";
nix-super.url = "github:privatevoid-net/nix-super/aaba1f91e7eba8ce029fa6bfa81ad9e14a13708d"; nix-super.url = "github:privatevoid-net/nix-super";
nix-super.inputs.nixpkgs.follows = "nixpkgs"; nix-super.inputs.nixpkgs.follows = "stable";
rofi-wayland.url = "github:lbonn/rofi/wayland"; rofi-wayland.url = "github:lbonn/rofi/wayland";
rofi-wayland.flake = false; rofi-wayland.flake = false;

View file

@ -18,6 +18,7 @@
personal.enable = true; personal.enable = true;
}; };
programs.hyprland.nvidiaSupport = true; programs.hyprland.nvidiaSupport = true;
programs.hyprland.keyboardLayouts = [ "us" "de" ];
services.mullvad.enable = true; services.mullvad.enable = true;
programs.ledger.enable = true; programs.ledger.enable = true;
}; };

View file

@ -100,7 +100,6 @@ in
statix statix
manix manix
nix-output-monitor nix-output-monitor
attic
# other # other
bat bat

View file

@ -25,7 +25,7 @@ in
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/ # For all categories, see https://wiki.hyprland.org/Configuring/Variables/
input { input {
kb_layout = de,us kb_layout = ${concatStringsSep "," cfg.keyboardLayouts}
kb_variant = kb_variant =
kb_model = kb_model =
kb_options = grp:win_space_toggle,caps:escape kb_options = grp:win_space_toggle,caps:escape

View file

@ -25,6 +25,11 @@ in
description = "enable window shadows"; description = "enable window shadows";
default = true; default = true;
}; };
keyboardLayouts = mkOption {
type = types.listOf types.str;
description = "list of keyboard layouts";
default = [ "de" "us" ];
};
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {

View file

@ -239,11 +239,12 @@ in
stylua stylua
sumneko-lua-language-server sumneko-lua-language-server
taplo taplo
typst
typst-lsp
yamlfmt yamlfmt
]; ];
plugins = with pkgs.vimPlugins; [ plugins = [
lazy-nvim pkgs.vimPlugins.lazy-nvim
nvim-treesitter.withAllGrammars
]; ];
}; };
}; };

View file

@ -1,4 +1,4 @@
{ pkgs, ... }: { lib, pkgs, ... }:
with builtins; with builtins;
{ {
@ -115,9 +115,22 @@ with builtins;
lazy = false; lazy = false;
} }
{ {
plugin = nvim-treesitter.withAllGrammars; plugin = nvim-treesitter;
event = [ "BufReadPost" "BufNewFile" ]; event = [ "BufReadPost" "BufNewFile" ];
conf = readFile ./nvim-treesitter.lua; conf =
let
parserDir = pkgs.symlinkJoin {
name = "tresitter-grammars-all";
paths = lib.attrValues (lib.filterAttrs (_: builtins.isAttrs) nvim-treesitter-parsers);
};
in
readFile ./nvim-treesitter.lua + ''
vim.opt.runtimepath:append("${parserDir}")
require'nvim-treesitter.configs'.setup {
parser_install_dir = "${parserDir}",
}
'';
dependencies = [ dependencies = [
{ plugin = nvim-ts-context-commentstring; } { plugin = nvim-ts-context-commentstring; }
{ {
@ -189,6 +202,7 @@ with builtins;
{ {
plugin = telescope-fzf-native-nvim; plugin = telescope-fzf-native-nvim;
conf = readFile ./telescope-fzf-native-nvim.lua; conf = readFile ./telescope-fzf-native-nvim.lua;
cmd = [ "Telescope" ];
keys = [ keys = [
{ key = "<leader>ff"; cmd = "<cmd>Telescope find_files<cr>"; desc = "Find files"; } { key = "<leader>ff"; cmd = "<cmd>Telescope find_files<cr>"; desc = "Find files"; }
{ key = "<leader>fb"; cmd = "<cmd>Telescope buffers<cr>"; desc = "Find buffers"; } { key = "<leader>fb"; cmd = "<cmd>Telescope buffers<cr>"; desc = "Find buffers"; }
@ -220,5 +234,14 @@ with builtins;
cmd = [ "StartupTime" ]; cmd = [ "StartupTime" ];
conf = readFile ./vim-startuptime.lua; conf = readFile ./vim-startuptime.lua;
} }
{
plugin = typst-vim;
ft = [ "typst" "typ" ];
}
{
plugin = comment-nvim;
event = [ "BufReadPost" "BufNewFile" ];
conf = "require('Comment').setup()";
}
]; ];
} }

View file

@ -1,11 +1,4 @@
require("mini.align").setup() require("mini.align").setup()
require("mini.comment").setup({
options = {
custom_commentstring = function()
return require("ts_context_commentstring.internal").calculate_commentstring() or vim.bo.commentstring
end,
},
})
require("mini.surround").setup() require("mini.surround").setup()
require("mini.move").setup() require("mini.move").setup()
require("mini.pairs").setup() require("mini.pairs").setup()

View file

@ -127,6 +127,7 @@ local servers = {
"pylsp", "pylsp",
"ruff_lsp", "ruff_lsp",
"rust_analyzer", "rust_analyzer",
"typst_lsp",
} }
for _, lsp in ipairs(servers) do for _, lsp in ipairs(servers) do
lspconfig_setup(lsp, {}) lspconfig_setup(lsp, {})

View file

@ -3,7 +3,6 @@
_: prev: _: prev:
{ {
agenix = inputs.agenix.packages.${prev.system}.default; agenix = inputs.agenix.packages.${prev.system}.default;
attic = inputs.attic.packages.${prev.system}.default;
hyprpaper = inputs.hyprpaper.packages.${prev.system}.default; hyprpaper = inputs.hyprpaper.packages.${prev.system}.default;
nil = inputs.nil.packages.${prev.system}.default; nil = inputs.nil.packages.${prev.system}.default;
nix-super = inputs.nix-super.packages.${prev.system}.default; nix-super = inputs.nix-super.packages.${prev.system}.default;