Compare commits
10 commits
57796225c0
...
a5794fb120
Author | SHA1 | Date | |
---|---|---|---|
a5794fb120 | |||
a109fa82e2 | |||
aefd0e189e | |||
5af51c43b0 | |||
534cdc3370 | |||
4f40dedf97 | |||
8919061aef | |||
313ee92b64 | |||
094a6a5a7b | |||
bcfbc610ab |
11 changed files with 511 additions and 148 deletions
250
flake.lock
250
flake.lock
|
@ -1,12 +1,193 @@
|
|||
{
|
||||
"nodes": {
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1733328505,
|
||||
"narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat_2": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696426674,
|
||||
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": [
|
||||
"neovim-nightly-overlay",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1738453229,
|
||||
"narHash": "sha256-7H9XgNiGLKN1G1CgRh0vUL4AheZSYzPm+zmZ7vxbJdo=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "32ea77a06711b758da0ad9bd6a844c5740a87abd",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-parts_2": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": [
|
||||
"neovim-nightly-overlay",
|
||||
"hercules-ci-effects",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1738453229,
|
||||
"narHash": "sha256-7H9XgNiGLKN1G1CgRh0vUL4AheZSYzPm+zmZ7vxbJdo=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "32ea77a06711b758da0ad9bd6a844c5740a87abd",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "flake-parts",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"git-hooks": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat_2",
|
||||
"gitignore": "gitignore",
|
||||
"nixpkgs": [
|
||||
"neovim-nightly-overlay",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1737465171,
|
||||
"narHash": "sha256-R10v2hoJRLq8jcL4syVFag7nIGE7m13qO48wRIukWNg=",
|
||||
"owner": "cachix",
|
||||
"repo": "git-hooks.nix",
|
||||
"rev": "9364dc02281ce2d37a1f55b6e51f7c0f65a75f17",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "cachix",
|
||||
"repo": "git-hooks.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"gitignore": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"neovim-nightly-overlay",
|
||||
"git-hooks",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1709087332,
|
||||
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"hercules-ci-effects": {
|
||||
"inputs": {
|
||||
"flake-parts": "flake-parts_2",
|
||||
"nixpkgs": [
|
||||
"neovim-nightly-overlay",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1739595404,
|
||||
"narHash": "sha256-0CjCfbq0yHWexOrpO06e2WU1r5JAqR6ffy1zgM3NksI=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "hercules-ci-effects",
|
||||
"rev": "06519cec8fb32d219006da6eacd255504a9996af",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "hercules-ci-effects",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"neovim-nightly-overlay": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-parts": "flake-parts",
|
||||
"git-hooks": "git-hooks",
|
||||
"hercules-ci-effects": "hercules-ci-effects",
|
||||
"neovim-src": "neovim-src",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"treefmt-nix": "treefmt-nix"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1740790052,
|
||||
"narHash": "sha256-hF7yeQ+ljZeHdybfemarAVjABCWb5SUtWgyhEgIzUVc=",
|
||||
"owner": "nix-community",
|
||||
"repo": "neovim-nightly-overlay",
|
||||
"rev": "06c050aa63007593fec78c38d37f75e28fe3f740",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "neovim-nightly-overlay",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"neovim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1740786347,
|
||||
"narHash": "sha256-yY6ipjD1eMUtOK69ZrBH3JCxrmKlLAxWf+DgYUpqwgE=",
|
||||
"owner": "neovim",
|
||||
"repo": "neovim",
|
||||
"rev": "45d7aa3301d436aef3cf5d88db8d0da145f9b70c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "neovim",
|
||||
"repo": "neovim",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixCats": {
|
||||
"locked": {
|
||||
"lastModified": 1740730062,
|
||||
"narHash": "sha256-tqIpClZGNV/CgY+V9fVOdWwpc2eeEj2rcisCwD0MUzw=",
|
||||
"lastModified": 1740837766,
|
||||
"narHash": "sha256-LKeBL3gjm+Fg2yVDKqB2gIiVnccv4TSUtt5NmQcasrk=",
|
||||
"owner": "BirdeeHub",
|
||||
"repo": "nixCats-nvim",
|
||||
"rev": "4f193d7298ff1184d2f28a98acb1ce7a2a6bc3f7",
|
||||
"rev": "83264cfaf7d7438c52db28a95934d87ae45faaae",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -17,11 +198,27 @@
|
|||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1740762151,
|
||||
"narHash": "sha256-Rn0j0gP6po1m46RsW/4jrn7938TZGR+wRZ0+MSZThBg=",
|
||||
"lastModified": 1740547748,
|
||||
"narHash": "sha256-Ly2fBL1LscV+KyCqPRufUBuiw+zmWrlJzpWOWbahplg=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "3a05eebede89661660945da1f151959900903b6a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixpkgs-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1740791350,
|
||||
"narHash": "sha256-igS2Z4tVw5W/x3lCZeeadt0vcU9fxtetZ/RyrqsCRQ0=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5954d3359cc7178623da6c7fd23dc7f7504d7187",
|
||||
"rev": "199169a2135e6b864a888e89a2ace345703c025d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -31,10 +228,49 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"plugins-nvim-emmet": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1717158539,
|
||||
"narHash": "sha256-LgKASQ1xBL8ugxK1g4R3BLQ3ha05cFtZaSYvd2Hy73c=",
|
||||
"owner": "olrtg",
|
||||
"repo": "nvim-emmet",
|
||||
"rev": "cde4fb2968704aae5c18b7f8a9bc2508767bb78d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "olrtg",
|
||||
"repo": "nvim-emmet",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"neovim-nightly-overlay": "neovim-nightly-overlay",
|
||||
"nixCats": "nixCats",
|
||||
"nixpkgs": "nixpkgs"
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"plugins-nvim-emmet": "plugins-nvim-emmet"
|
||||
}
|
||||
},
|
||||
"treefmt-nix": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"neovim-nightly-overlay",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1739829690,
|
||||
"narHash": "sha256-mL1szCeIsjh6Khn3nH2cYtwO5YXG6gBiTw1A30iGeDU=",
|
||||
"owner": "numtide",
|
||||
"repo": "treefmt-nix",
|
||||
"rev": "3d0579f5cc93436052d94b73925b48973a104204",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "treefmt-nix",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
337
flake.nix
337
flake.nix
|
@ -7,9 +7,14 @@
|
|||
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
|
||||
nixCats.url = "github:BirdeeHub/nixCats-nvim";
|
||||
|
||||
# neovim-nightly-overlay = {
|
||||
# url = "github:nix-community/neovim-nightly-overlay";
|
||||
# };
|
||||
neovim-nightly-overlay = {
|
||||
url = "github:nix-community/neovim-nightly-overlay";
|
||||
};
|
||||
|
||||
"plugins-nvim-emmet" = {
|
||||
url = "github:olrtg/nvim-emmet";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
# see :help nixCats.flake.inputs
|
||||
# If you want your plugin to be loaded by the standard overlay,
|
||||
|
@ -20,11 +25,15 @@
|
|||
# overlay defined for custom builds in the overlays directory.
|
||||
# for specific tags, branches and commits, see:
|
||||
# https://nixos.org/manual/nix/stable/command-ref/new-cli/nix3-flake.html#examples
|
||||
|
||||
};
|
||||
|
||||
# see :help nixCats.flake.outputs
|
||||
outputs = { self, nixpkgs, nixCats, ... }@inputs: let
|
||||
outputs = {
|
||||
self,
|
||||
nixpkgs,
|
||||
nixCats,
|
||||
...
|
||||
} @ inputs: let
|
||||
inherit (nixCats) utils;
|
||||
luaPath = "${./.}";
|
||||
forEachSystem = utils.eachSystem nixpkgs.lib.platforms.all;
|
||||
|
@ -50,27 +59,39 @@
|
|||
# in a set of ${system}, or simply a list.
|
||||
# the nixCats builder function will accept either.
|
||||
# see :help nixCats.flake.outputs.overlays
|
||||
dependencyOverlays = /* (import ./overlays inputs) ++ */ [
|
||||
# This overlay grabs all the inputs named in the format
|
||||
# `plugins-<pluginName>`
|
||||
# Once we add this overlay to our nixpkgs, we are able to
|
||||
# use `pkgs.neovimPlugins`, which is a set of our plugins.
|
||||
(utils.standardPluginOverlay inputs)
|
||||
# add any other flake overlays here.
|
||||
dependencyOverlays =
|
||||
/*
|
||||
(import ./overlays inputs) ++
|
||||
*/
|
||||
[
|
||||
# This overlay grabs all the inputs named in the format
|
||||
# `plugins-<pluginName>`
|
||||
# Once we add this overlay to our nixpkgs, we are able to
|
||||
# use `pkgs.neovimPlugins`, which is a set of our plugins.
|
||||
(utils.standardPluginOverlay inputs)
|
||||
# add any other flake overlays here.
|
||||
|
||||
# when other people mess up their overlays by wrapping them with system,
|
||||
# you may instead call this function on their overlay.
|
||||
# it will check if it has the system in the set, and if so return the desired overlay
|
||||
# (utils.fixSystemizedOverlay inputs.codeium.overlays
|
||||
# (system: inputs.codeium.overlays.${system}.default)
|
||||
# )
|
||||
];
|
||||
# when other people mess up their overlays by wrapping them with system,
|
||||
# you may instead call this function on their overlay.
|
||||
# it will check if it has the system in the set, and if so return the desired overlay
|
||||
# (utils.fixSystemizedOverlay inputs.codeium.overlays
|
||||
# (system: inputs.codeium.overlays.${system}.default)
|
||||
# )
|
||||
];
|
||||
|
||||
# see :help nixCats.flake.outputs.categories
|
||||
# and
|
||||
# :help nixCats.flake.outputs.categoryDefinitions.scheme
|
||||
categoryDefinitions = { pkgs, settings, categories, extra, name, mkNvimPlugin, ... }@packageDef: {
|
||||
# to define and use a new category, simply add a new list to a set here,
|
||||
categoryDefinitions = {
|
||||
pkgs,
|
||||
settings,
|
||||
categories,
|
||||
extra,
|
||||
name,
|
||||
mkNvimPlugin,
|
||||
...
|
||||
} @ packageDef: {
|
||||
# to define and use a new category, simply add a new list to a set here,
|
||||
# and later, you will include categoryname = true; in the set you
|
||||
# provide when you build the package using this builder function.
|
||||
# see :help nixCats.flake.outputs.packageDefinitions for info on that section.
|
||||
|
@ -96,73 +117,86 @@
|
|||
# NOTE: lazy doesnt care if these are in startupPlugins or optionalPlugins
|
||||
# also you dont have to download everything via nix if you dont want.
|
||||
# but you have the option, and that is demonstrated here.
|
||||
startupPlugins = with pkgs.vimPlugins; {
|
||||
startupPlugins = with pkgs.vimPlugins; with pkgs.neovimPlugins; {
|
||||
general = [
|
||||
# LazyVim
|
||||
lazy-nvim
|
||||
LazyVim
|
||||
bufferline-nvim
|
||||
|
||||
# Coding
|
||||
{
|
||||
plugin = mini-pairs;
|
||||
name = "mini.pairs";
|
||||
}
|
||||
ts-comments-nvim
|
||||
{
|
||||
plugin = mini-ai;
|
||||
name = "mini.ai";
|
||||
}
|
||||
lazydev-nvim
|
||||
cmp-buffer
|
||||
cmp-nvim-lsp
|
||||
cmp-path
|
||||
cmp_luasnip
|
||||
conform-nvim
|
||||
dashboard-nvim
|
||||
dressing-nvim
|
||||
|
||||
# Colorscheme
|
||||
tokyonight-nvim
|
||||
{
|
||||
plugin = catppuccin-nvim;
|
||||
name = "catppuccin";
|
||||
}
|
||||
|
||||
# Editor
|
||||
grug-far-nvim
|
||||
flash-nvim
|
||||
friendly-snippets
|
||||
which-key-nvim
|
||||
gitsigns-nvim
|
||||
indent-blankline-nvim
|
||||
lualine-nvim
|
||||
neo-tree-nvim
|
||||
neoconf-nvim
|
||||
neodev-nvim
|
||||
noice-nvim
|
||||
nui-nvim
|
||||
nvim-cmp
|
||||
trouble-nvim
|
||||
todo-comments-nvim
|
||||
|
||||
# Formatting
|
||||
conform-nvim
|
||||
|
||||
# Linting
|
||||
nvim-lint
|
||||
|
||||
# LSP
|
||||
nvim-lspconfig
|
||||
nvim-notify
|
||||
nvim-spectre
|
||||
nvim-treesitter-context
|
||||
|
||||
# Treesitter
|
||||
nvim-treesitter.withAllGrammars
|
||||
nvim-treesitter-textobjects
|
||||
nvim-ts-autotag
|
||||
nvim-ts-context-commentstring
|
||||
nvim-web-devicons
|
||||
|
||||
# UI
|
||||
bufferline-nvim
|
||||
lualine-nvim
|
||||
noice-nvim
|
||||
{
|
||||
plugin = mini-icons;
|
||||
name = "mini.icons";
|
||||
}
|
||||
nui-nvim
|
||||
|
||||
# Util
|
||||
snacks-nvim
|
||||
persistence-nvim
|
||||
plenary-nvim
|
||||
telescope-fzf-native-nvim
|
||||
telescope-nvim
|
||||
todo-comments-nvim
|
||||
tokyonight-nvim
|
||||
trouble-nvim
|
||||
vim-illuminate
|
||||
vim-startuptime
|
||||
which-key-nvim
|
||||
snacks-nvim
|
||||
nvim-treesitter-textobjects
|
||||
nvim-treesitter.withAllGrammars
|
||||
# This is for if you only want some of the grammars
|
||||
# (nvim-treesitter.withPlugins (
|
||||
# plugins: with plugins; [
|
||||
# nix
|
||||
# lua
|
||||
# ]
|
||||
# ))
|
||||
|
||||
# sometimes you have to fix some names
|
||||
{ plugin = luasnip; name = "LuaSnip"; }
|
||||
{ plugin = catppuccin-nvim; name = "catppuccin"; }
|
||||
{ plugin = mini-ai; name = "mini.ai"; }
|
||||
{ plugin = mini-icons; name = "mini.icons"; }
|
||||
{ plugin = mini-bufremove; name = "mini.bufremove"; }
|
||||
{ plugin = mini-comment; name = "mini.comment"; }
|
||||
{ plugin = mini-indentscope; name = "mini.indentscope"; }
|
||||
{ plugin = mini-pairs; name = "mini.pairs"; }
|
||||
{ plugin = mini-surround; name = "mini.surround"; }
|
||||
# you could do this within the lazy spec instead if you wanted
|
||||
# and get the new names from `:NixCats pawsible` debug command
|
||||
# Extras
|
||||
# Coding
|
||||
# Blink
|
||||
blink-cmp
|
||||
friendly-snippets
|
||||
|
||||
# Luasnip
|
||||
{
|
||||
plugin = luasnip;
|
||||
name = "LuaSnip";
|
||||
}
|
||||
|
||||
# Custom
|
||||
rose-pine
|
||||
diffview-nvim
|
||||
nvim-emmet
|
||||
treesj
|
||||
vim-caddyfile
|
||||
];
|
||||
};
|
||||
|
||||
|
@ -195,7 +229,7 @@
|
|||
# https://github.com/NixOS/nixpkgs/blob/master/pkgs/build-support/setup-hooks/make-wrapper.sh
|
||||
extraWrapperArgs = {
|
||||
test = [
|
||||
'' --set CATTESTVAR2 "It worked again!"''
|
||||
''--set CATTESTVAR2 "It worked again!"''
|
||||
];
|
||||
};
|
||||
|
||||
|
@ -207,16 +241,14 @@
|
|||
# vim.g.python3_host_prog
|
||||
# or run from nvim terminal via :!<packagename>-python3
|
||||
extraPython3Packages = {
|
||||
test = [ (_:[]) ];
|
||||
test = [(_: [])];
|
||||
};
|
||||
# populates $LUA_PATH and $LUA_CPATH
|
||||
extraLuaPackages = {
|
||||
test = [ (_:[]) ];
|
||||
test = [(_: [])];
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
# And then build a package with specific categories from above here:
|
||||
# All categories you wish to include must be marked true,
|
||||
# but false may be omitted.
|
||||
|
@ -226,7 +258,11 @@
|
|||
packageDefinitions = {
|
||||
# These are the names of your packages
|
||||
# you can include as many as you wish.
|
||||
nvim = { pkgs, mkNvimPlugin, ... }: {
|
||||
nvim = {
|
||||
pkgs,
|
||||
mkNvimPlugin,
|
||||
...
|
||||
}: {
|
||||
# they contain a settings set defined above
|
||||
# see :help nixCats.flake.outputs.settings
|
||||
settings = {
|
||||
|
@ -234,7 +270,7 @@
|
|||
# IMPORTANT:
|
||||
# your alias may not conflict with your other packages.
|
||||
# aliases = [ "vim" ];
|
||||
# neovim-unwrapped = inputs.neovim-nightly-overlay.packages.${pkgs.system}.neovim;
|
||||
neovim-unwrapped = inputs.neovim-nightly-overlay.packages.${pkgs.system}.neovim;
|
||||
};
|
||||
# and a set of categories that you want
|
||||
# (and other information to pass to lua)
|
||||
|
@ -247,7 +283,11 @@
|
|||
# an extra test package with normal lua reload for fast edits
|
||||
# nix doesnt provide the config in this package, allowing you free reign to edit it.
|
||||
# then you can swap back to the normal pure package when done.
|
||||
testnvim = { pkgs, mkNvimPlugin, ... }: {
|
||||
testnvim = {
|
||||
pkgs,
|
||||
mkNvimPlugin,
|
||||
...
|
||||
}: {
|
||||
settings = {
|
||||
wrapRc = false;
|
||||
unwrappedCfgPath = "/absolute/path/to/config";
|
||||
|
@ -259,70 +299,87 @@
|
|||
extra = {};
|
||||
};
|
||||
};
|
||||
# In this section, the main thing you will need to do is change the default package name
|
||||
# to the name of the packageDefinitions entry you wish to use as the default.
|
||||
# In this section, the main thing you will need to do is change the default package name
|
||||
# to the name of the packageDefinitions entry you wish to use as the default.
|
||||
defaultPackageName = "nvim";
|
||||
in
|
||||
# see :help nixCats.flake.outputs.exports
|
||||
forEachSystem (system: let
|
||||
# the builder function that makes it all work
|
||||
nixCatsBuilder =
|
||||
utils.baseBuilder luaPath {
|
||||
inherit nixpkgs system dependencyOverlays extra_pkg_config;
|
||||
}
|
||||
categoryDefinitions
|
||||
packageDefinitions;
|
||||
defaultPackage = nixCatsBuilder defaultPackageName;
|
||||
# this is just for using utils such as pkgs.mkShell
|
||||
# The one used to build neovim is resolved inside the builder
|
||||
# and is passed to our categoryDefinitions and packageDefinitions
|
||||
pkgs = import nixpkgs {inherit system;};
|
||||
in {
|
||||
# these outputs will be wrapped with ${system} by utils.eachSystem
|
||||
|
||||
# this will make a package out of each of the packageDefinitions defined above
|
||||
# and set the default package to the one passed in here.
|
||||
packages = utils.mkAllWithDefault defaultPackage;
|
||||
|
||||
# see :help nixCats.flake.outputs.exports
|
||||
forEachSystem (system: let
|
||||
# the builder function that makes it all work
|
||||
nixCatsBuilder = utils.baseBuilder luaPath {
|
||||
inherit nixpkgs system dependencyOverlays extra_pkg_config;
|
||||
} categoryDefinitions packageDefinitions;
|
||||
defaultPackage = nixCatsBuilder defaultPackageName;
|
||||
# this is just for using utils such as pkgs.mkShell
|
||||
# The one used to build neovim is resolved inside the builder
|
||||
# and is passed to our categoryDefinitions and packageDefinitions
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
in
|
||||
{
|
||||
# these outputs will be wrapped with ${system} by utils.eachSystem
|
||||
|
||||
# this will make a package out of each of the packageDefinitions defined above
|
||||
# and set the default package to the one passed in here.
|
||||
packages = utils.mkAllWithDefault defaultPackage;
|
||||
|
||||
# choose your package for devShell
|
||||
# and add whatever else you want in it.
|
||||
devShells = {
|
||||
default = pkgs.mkShell {
|
||||
name = defaultPackageName;
|
||||
packages = [ defaultPackage ];
|
||||
inputsFrom = [ ];
|
||||
shellHook = ''
|
||||
'';
|
||||
# choose your package for devShell
|
||||
# and add whatever else you want in it.
|
||||
devShells = {
|
||||
default = pkgs.mkShell {
|
||||
name = defaultPackageName;
|
||||
packages = [defaultPackage];
|
||||
inputsFrom = [];
|
||||
shellHook = ''
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
})
|
||||
// (let
|
||||
# we also export a nixos module to allow reconfiguration from configuration.nix
|
||||
nixosModule = utils.mkNixosModules {
|
||||
moduleNamespace = [defaultPackageName];
|
||||
inherit
|
||||
defaultPackageName
|
||||
dependencyOverlays
|
||||
luaPath
|
||||
categoryDefinitions
|
||||
packageDefinitions
|
||||
extra_pkg_config
|
||||
nixpkgs
|
||||
;
|
||||
};
|
||||
# and the same for home manager
|
||||
homeModule = utils.mkHomeModules {
|
||||
moduleNamespace = [defaultPackageName];
|
||||
inherit
|
||||
defaultPackageName
|
||||
dependencyOverlays
|
||||
luaPath
|
||||
categoryDefinitions
|
||||
packageDefinitions
|
||||
extra_pkg_config
|
||||
nixpkgs
|
||||
;
|
||||
};
|
||||
in {
|
||||
# these outputs will be NOT wrapped with ${system}
|
||||
|
||||
}) // (let
|
||||
# we also export a nixos module to allow reconfiguration from configuration.nix
|
||||
nixosModule = utils.mkNixosModules {
|
||||
moduleNamespace = [ defaultPackageName ];
|
||||
inherit defaultPackageName dependencyOverlays luaPath
|
||||
categoryDefinitions packageDefinitions extra_pkg_config nixpkgs;
|
||||
};
|
||||
# and the same for home manager
|
||||
homeModule = utils.mkHomeModules {
|
||||
moduleNamespace = [ defaultPackageName ];
|
||||
inherit defaultPackageName dependencyOverlays luaPath
|
||||
categoryDefinitions packageDefinitions extra_pkg_config nixpkgs;
|
||||
};
|
||||
in {
|
||||
# this will make an overlay out of each of the packageDefinitions defined above
|
||||
# and set the default overlay to the one named here.
|
||||
overlays =
|
||||
utils.makeOverlays luaPath {
|
||||
inherit nixpkgs dependencyOverlays extra_pkg_config;
|
||||
}
|
||||
categoryDefinitions
|
||||
packageDefinitions
|
||||
defaultPackageName;
|
||||
|
||||
# these outputs will be NOT wrapped with ${system}
|
||||
nixosModules.default = nixosModule;
|
||||
homeModules.default = homeModule;
|
||||
|
||||
# this will make an overlay out of each of the packageDefinitions defined above
|
||||
# and set the default overlay to the one named here.
|
||||
overlays = utils.makeOverlays luaPath {
|
||||
inherit nixpkgs dependencyOverlays extra_pkg_config;
|
||||
} categoryDefinitions packageDefinitions defaultPackageName;
|
||||
|
||||
nixosModules.default = nixosModule;
|
||||
homeModules.default = homeModule;
|
||||
|
||||
inherit utils nixosModule homeModule;
|
||||
inherit (utils) templates;
|
||||
});
|
||||
inherit utils nixosModule homeModule;
|
||||
inherit (utils) templates;
|
||||
});
|
||||
}
|
||||
|
|
3
init.lua
3
init.lua
|
@ -16,6 +16,9 @@ local function getlockfilepath()
|
|||
end
|
||||
local lazyOptions = {
|
||||
lockfile = getlockfilepath(),
|
||||
install = {
|
||||
missing = false,
|
||||
},
|
||||
}
|
||||
|
||||
-- NOTE: this the lazy wrapper. Use it like require('lazy').setup() but with an extra
|
||||
|
|
10
lua/config/autocmds.lua
Normal file
10
lua/config/autocmds.lua
Normal file
|
@ -0,0 +1,10 @@
|
|||
-- Open help window in a vsplit to the right.
|
||||
vim.api.nvim_create_autocmd('BufWinEnter', {
|
||||
group = vim.api.nvim_create_augroup('help_window_right', {}),
|
||||
pattern = { '*.txt' },
|
||||
callback = function()
|
||||
if vim.o.filetype == 'help' then
|
||||
vim.cmd.wincmd 'L'
|
||||
end
|
||||
end,
|
||||
})
|
2
lua/config/options.lua
Normal file
2
lua/config/options.lua
Normal file
|
@ -0,0 +1,2 @@
|
|||
vim.o.textwidth = 80
|
||||
vim.o.colorcolumn = '+1'
|
6
lua/plugins/diffview.lua
Normal file
6
lua/plugins/diffview.lua
Normal file
|
@ -0,0 +1,6 @@
|
|||
return {
|
||||
{
|
||||
'sindrets/diffview.nvim',
|
||||
config = true,
|
||||
},
|
||||
}
|
|
@ -1 +0,0 @@
|
|||
return {}
|
9
lua/plugins/nvim-emmet.lua
Normal file
9
lua/plugins/nvim-emmet.lua
Normal file
|
@ -0,0 +1,9 @@
|
|||
return {
|
||||
{
|
||||
'nvim-emmet',
|
||||
keys = {
|
||||
{ '<LEADER>xe', mode = { 'n', 'v' }, require('nvim-emmet').wrap_with_abbreviation, desc = 'Wrap with Emmet abbr' },
|
||||
},
|
||||
ft = { 'html', 'css', 'scss', 'vue', 'blade' },
|
||||
},
|
||||
}
|
26
lua/plugins/rose-pine.lua
Normal file
26
lua/plugins/rose-pine.lua
Normal file
|
@ -0,0 +1,26 @@
|
|||
return {
|
||||
{
|
||||
'rose-pine/neovim',
|
||||
name = 'rose-pine',
|
||||
},
|
||||
{
|
||||
'LazyVim/LazyVim',
|
||||
opts = {
|
||||
colorscheme = 'rose-pine',
|
||||
},
|
||||
},
|
||||
{
|
||||
'akinsho/bufferline.nvim',
|
||||
optional = true,
|
||||
opts = {
|
||||
highlights = require 'rose-pine.plugins.bufferline',
|
||||
},
|
||||
},
|
||||
{
|
||||
'nvim-lualine/lualine.nvim',
|
||||
optional = true,
|
||||
opts = function(_, opts)
|
||||
table.insert(opts.options, { theme = 'rose-pine' })
|
||||
end,
|
||||
},
|
||||
}
|
10
lua/plugins/treesj.lua
Normal file
10
lua/plugins/treesj.lua
Normal file
|
@ -0,0 +1,10 @@
|
|||
return {
|
||||
{
|
||||
'Wansmer/treesj',
|
||||
keys = { '<SPACE>m', '<SPACE>j', '<SPACE>s' },
|
||||
dependencies = { 'nvim-treesitter/nvim-treesitter' },
|
||||
opts = {
|
||||
max_join_length = vim.o.textwidth,
|
||||
},
|
||||
},
|
||||
}
|
5
lua/plugins/vim-caddyfile.lua
Normal file
5
lua/plugins/vim-caddyfile.lua
Normal file
|
@ -0,0 +1,5 @@
|
|||
return {
|
||||
{
|
||||
'isobit/vim-caddyfile',
|
||||
},
|
||||
}
|
Loading…
Reference in a new issue