neovim-flake/flake.nix

630 lines
13 KiB
Nix
Raw Normal View History

{
2023-02-01 21:59:35 +01:00
description = "A neovim flake with a modular configuration";
outputs = {
nixpkgs,
2023-02-07 13:03:21 +01:00
flake-parts,
2023-03-31 23:57:25 +02:00
self,
2023-02-01 21:59:35 +01:00
...
2023-02-10 18:45:23 +01:00
} @ inputs:
2023-02-07 13:03:21 +01:00
flake-parts.lib.mkFlake {inherit inputs;} {
# provide overridable systems
# https://github.com/nix-systems/nix-systems
systems = import inputs.systems;
2023-02-06 02:14:01 +01:00
2023-02-10 18:40:13 +01:00
imports = [
# add lib to module args
{_module.args = {inherit (nixpkgs) lib;};}
./flake/apps.nix
./flake/legacyPackages.nix
2023-02-10 18:45:23 +01:00
./flake/overlays.nix
2023-02-10 18:40:13 +01:00
./flake/packages.nix
];
2023-02-07 13:03:21 +01:00
flake = {
lib = {
2024-04-08 02:28:49 +02:00
inherit (import ./lib/stdlib-extended.nix nixpkgs.lib inputs) nvim;
2023-07-11 23:14:54 +02:00
inherit (import ./configuration.nix inputs) neovimConfiguration;
2023-02-06 02:14:01 +01:00
};
2023-04-02 18:10:24 +02:00
homeManagerModules = {
neovim-flake =
nixpkgs.lib.warn ''
homeManagerModules.neovim-flake has been deprecated.
2024-06-10 09:33:45 +02:00
Plese use the homeManagerModules.nvf instead
''
self.homeManagerModules.nvf;
nvf = {
imports = [(import ./flake/modules/home-manager.nix self.packages inputs)];
2023-04-02 18:10:24 +02:00
};
default = self.homeManagerModules.nvf;
};
2024-04-14 15:51:20 +02:00
nixosModules = {
neovim-flake =
nixpkgs.lib.warn ''
nixosModules.neovim-flake has been deprecated.
Please use the nixosModules.nvf instead
''
2024-05-16 18:08:21 +02:00
self.nixosModules.nvf;
nvf = {
2024-04-14 15:51:20 +02:00
imports = [(import ./flake/modules/nixos.nix self.packages inputs)];
};
default = self.nixosModules.nvf;
2024-04-14 15:51:20 +02:00
};
2023-02-01 21:59:35 +01:00
};
2023-02-07 13:03:21 +01:00
perSystem = {
self',
2023-02-10 18:40:13 +01:00
config,
pkgs,
2023-02-07 13:03:21 +01:00
...
}: {
2023-06-05 20:36:53 +02:00
formatter = pkgs.alejandra;
devShells = {
default = self'.devShells.lsp;
nvim-nix = pkgs.mkShell {nativeBuildInputs = [config.packages.nix];};
lsp = pkgs.mkShell {
nativeBuildInputs = with pkgs; [nil statix deadnix alejandra];
};
};
2023-02-07 13:03:21 +01:00
};
};
# Flake inputs
inputs = {
2024-05-06 21:30:06 +02:00
## Basic Inputs
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
2023-02-07 13:03:21 +01:00
flake-parts.url = "github:hercules-ci/flake-parts";
2023-02-15 09:46:29 +01:00
flake-utils.url = "github:numtide/flake-utils";
systems.url = "github:nix-systems/default";
# For generating documentation website
nmd = {
2023-12-09 20:03:58 +01:00
url = "sourcehut:~rycee/nmd";
flake = false;
};
# TODO: get zig from the zig overlay instead of nixpkgs
zig.url = "github:mitchellh/zig-overlay";
2024-04-08 02:28:49 +02:00
# Langauge server (use master instead of nixpkgs)
rnix-lsp.url = "github:nix-community/rnix-lsp";
nil = {
url = "github:oxalica/nil";
inputs.nixpkgs.follows = "nixpkgs";
inputs.flake-utils.follows = "flake-utils";
};
2024-05-06 21:30:06 +02:00
## Plugins
# LSP plugins
2024-04-08 02:28:49 +02:00
plugin-nvim-lspconfig = {
url = "github:neovim/nvim-lspconfig";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-lspsaga = {
url = "github:tami5/lspsaga.nvim";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-lspkind = {
url = "github:onsails/lspkind-nvim";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-trouble = {
url = "github:folke/trouble.nvim";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-nvim-treesitter-context = {
2023-04-18 01:10:40 +02:00
url = "github:nvim-treesitter/nvim-treesitter-context";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-nvim-lightbulb = {
url = "github:kosayoda/nvim-lightbulb";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-code-action-menu = {
url = "github:weilbith/nvim-code-action-menu";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-lsp-signature = {
url = "github:ray-x/lsp_signature.nvim";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-lsp-lines = {
2023-07-30 18:54:43 +02:00
url = "sourcehut:~whynothugo/lsp_lines.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-none-ls = {
2024-03-09 03:32:01 +01:00
# https://github.com/nvimtools/none-ls.nvim/issues/58
url = "github:nvimtools/none-ls.nvim/bb680d752cec37949faca7a1f509e2fe67ab418a";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-nvim-docs-view = {
url = "github:amrbashir/nvim-docs-view";
flake = false;
};
# language support
2024-04-08 02:28:49 +02:00
plugin-sqls-nvim = {
url = "github:nanotee/sqls.nvim";
flake = false;
};
2023-04-15 11:43:39 +02:00
2024-04-08 02:28:49 +02:00
plugin-rust-tools = {
url = "github:simrat39/rust-tools.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-flutter-tools = {
url = "github:akinsho/flutter-tools.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-neodev-nvim = {
2023-09-23 15:36:26 +02:00
url = "github:folke/neodev.nvim";
flake = false;
};
plugin-elixir-tools = {
url = "github:elixir-tools/elixir-tools.nvim";
2024-02-17 01:19:38 +01:00
flake = false;
};
plugin-ts-error-translator = {
url = "github:dmmulroy/ts-error-translator.nvim";
flake = false;
};
# Copying/Registers
2024-04-08 02:28:49 +02:00
plugin-registers = {
url = "github:tversteeg/registers.nvim";
flake = false;
};
2023-07-19 21:49:06 +02:00
2024-04-08 02:28:49 +02:00
plugin-nvim-neoclip = {
url = "github:AckslD/nvim-neoclip.lua";
flake = false;
};
# Telescope
2024-04-08 02:28:49 +02:00
plugin-telescope = {
url = "github:nvim-telescope/telescope.nvim";
flake = false;
};
2023-05-04 17:41:11 +02:00
# Debuggers
2024-04-08 02:28:49 +02:00
plugin-nvim-dap = {
2023-05-04 17:41:11 +02:00
url = "github:mfussenegger/nvim-dap";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-dap-ui = {
2023-05-04 17:41:11 +02:00
url = "github:rcarriga/nvim-dap-ui";
flake = false;
};
plugin-nvim-dap-go = {
url = "github:leoluz/nvim-dap-go";
flake = false;
};
# Filetrees
2024-04-08 02:28:49 +02:00
plugin-nvim-tree-lua = {
2023-02-03 08:36:08 +01:00
url = "github:nvim-tree/nvim-tree.lua";
flake = false;
};
# Tablines
2024-04-08 02:28:49 +02:00
plugin-nvim-bufferline-lua = {
url = "github:akinsho/nvim-bufferline.lua";
flake = false;
};
# Statuslines
2024-04-08 02:28:49 +02:00
plugin-lualine = {
url = "github:hoob3rt/lualine.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-cmp = {
2023-07-30 17:38:29 +02:00
url = "github:hrsh7th/nvim-cmp";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cmp-buffer = {
url = "github:hrsh7th/cmp-buffer";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cmp-nvim-lsp = {
url = "github:hrsh7th/cmp-nvim-lsp";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cmp-vsnip = {
url = "github:hrsh7th/cmp-vsnip";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cmp-path = {
url = "github:hrsh7th/cmp-path";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cmp-treesitter = {
url = "github:ray-x/cmp-treesitter";
flake = false;
};
# snippets
2024-04-08 02:28:49 +02:00
plugin-vim-vsnip = {
url = "github:hrsh7th/vim-vsnip";
flake = false;
};
# Presence
2024-04-08 02:28:49 +02:00
plugin-neocord = {
url = "github:IogaMaster/neocord";
flake = false; # uses flake-utils, avoid the flake
};
# Autopairs
2024-04-08 02:28:49 +02:00
plugin-nvim-autopairs = {
url = "github:windwp/nvim-autopairs";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-ts-autotag = {
url = "github:windwp/nvim-ts-autotag";
flake = false;
};
# Commenting
2024-04-08 02:28:49 +02:00
plugin-comment-nvim = {
url = "github:numToStr/Comment.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-todo-comments = {
url = "github:folke/todo-comments.nvim";
flake = false;
};
# Buffer tools
2024-04-08 02:28:49 +02:00
plugin-bufdelete-nvim = {
url = "github:famiu/bufdelete.nvim";
flake = false;
};
2023-02-03 08:36:08 +01:00
# Dashboard Utilities
2024-04-08 02:28:49 +02:00
plugin-dashboard-nvim = {
2023-02-03 08:36:08 +01:00
url = "github:glepnir/dashboard-nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-alpha-nvim = {
2023-02-03 08:36:08 +01:00
url = "github:goolord/alpha-nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-vim-startify = {
2023-02-06 06:14:13 +01:00
url = "github:mhinz/vim-startify";
flake = false;
};
# Themes
2024-04-08 02:28:49 +02:00
plugin-tokyonight = {
url = "github:folke/tokyonight.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-onedark = {
url = "github:navarasu/onedark.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-catppuccin = {
url = "github:catppuccin/nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-dracula = {
2023-04-18 01:01:51 +02:00
url = "github:Mofiqul/dracula.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-oxocarbon = {
url = "github:nyoom-engineering/oxocarbon.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-gruvbox = {
2024-01-17 21:08:36 +01:00
url = "github:ellisonleao/gruvbox.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-rose-pine = {
url = "github:rose-pine/neovim";
flake = false;
};
# Rust crates
2024-04-08 02:28:49 +02:00
plugin-crates-nvim = {
url = "github:Saecki/crates.nvim";
flake = false;
};
# Project Management
2024-04-08 02:28:49 +02:00
plugin-project-nvim = {
url = "github:ahmedkhalf/project.nvim";
flake = false;
};
# Visuals
2024-04-08 02:28:49 +02:00
plugin-nvim-cursorline = {
url = "github:yamatsum/nvim-cursorline";
flake = false;
};
2023-02-03 20:53:48 +01:00
2024-04-08 02:28:49 +02:00
plugin-scrollbar-nvim = {
2023-02-03 20:53:48 +01:00
url = "github:petertriho/nvim-scrollbar";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cinnamon-nvim = {
url = "github:declancm/cinnamon.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cellular-automaton = {
url = "github:Eandrju/cellular-automaton.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-indent-blankline = {
url = "github:lukas-reineke/indent-blankline.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-web-devicons = {
2023-05-26 15:08:23 +02:00
url = "github:nvim-tree/nvim-web-devicons";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-gitsigns-nvim = {
url = "github:lewis6991/gitsigns.nvim";
flake = false;
};
plugin-vim-fugitive = {
url = "github:tpope/vim-fugitive";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-fidget-nvim = {
url = "github:j-hui/fidget.nvim";
2023-02-27 20:30:12 +01:00
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-highlight-undo = {
url = "github:tzachar/highlight-undo.nvim";
flake = false;
};
2023-02-01 21:59:35 +01:00
# Minimap
2024-04-08 02:28:49 +02:00
plugin-minimap-vim = {
2023-02-01 21:59:35 +01:00
url = "github:wfxr/minimap.vim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-codewindow-nvim = {
url = "github:gorbit99/codewindow.nvim";
flake = false;
};
# Notifications
2024-04-08 02:28:49 +02:00
plugin-nvim-notify = {
url = "github:rcarriga/nvim-notify";
flake = false;
};
# Utilities
2024-04-08 02:28:49 +02:00
plugin-ccc = {
url = "github:uga-rosa/ccc.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-diffview-nvim = {
2023-03-01 10:08:24 +01:00
url = "github:sindrets/diffview.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-icon-picker-nvim = {
url = "github:ziontee113/icon-picker.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-which-key = {
2023-02-06 06:14:13 +01:00
url = "github:folke/which-key.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-cheatsheet-nvim = {
2023-02-06 06:14:13 +01:00
url = "github:sudormrfbin/cheatsheet.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-gesture-nvim = {
2023-02-06 06:14:13 +01:00
url = "github:notomo/gesture.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-hop-nvim = {
url = "github:phaazon/hop.nvim";
flake = false;
};
2023-02-05 23:09:12 +01:00
2024-04-08 02:28:49 +02:00
plugin-leap-nvim = {
2023-04-05 01:14:13 +02:00
url = "github:ggandor/leap.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-smartcolumn = {
2023-04-05 15:59:08 +02:00
url = "github:m4xshen/smartcolumn.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-surround = {
2023-06-07 13:28:27 +02:00
url = "github:kylechui/nvim-surround";
flake = false;
};
plugin-glow-nvim = {
url = "github:ellisonleao/glow.nvim";
flake = false;
};
plugin-image-nvim = {
url = "github:3rd/image.nvim";
flake = false;
};
# Note-taking
2024-04-08 02:28:49 +02:00
plugin-obsidian-nvim = {
2023-02-05 23:09:12 +01:00
url = "github:epwalsh/obsidian.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-orgmode-nvim = {
2023-02-05 23:09:12 +01:00
url = "github:nvim-orgmode/orgmode";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-mind-nvim = {
url = "github:phaazon/mind.nvim";
flake = false;
};
# Spellchecking
2024-04-08 02:28:49 +02:00
plugin-vim-dirtytalk = {
url = "github:psliwka/vim-dirtytalk";
flake = false;
};
2023-02-06 00:44:38 +01:00
# Terminal
2024-04-08 02:28:49 +02:00
plugin-toggleterm-nvim = {
2023-02-06 00:44:38 +01:00
url = "github:akinsho/toggleterm.nvim";
flake = false;
};
2023-02-06 02:14:01 +01:00
# UI
2024-04-08 02:28:49 +02:00
plugin-nvim-navbuddy = {
2023-07-19 21:49:06 +02:00
url = "github:SmiteshP/nvim-navbuddy";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-navic = {
2023-07-19 21:49:06 +02:00
url = "github:SmiteshP/nvim-navic";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-noice-nvim = {
2023-02-06 01:55:19 +01:00
url = "github:folke/noice.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-modes-nvim = {
2023-04-03 11:12:05 +02:00
url = "github:mvllow/modes.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-nvim-colorizer-lua = {
2024-02-10 02:04:51 +01:00
url = "github:NvChad/nvim-colorizer.lua";
2023-06-06 02:05:05 +02:00
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-vim-illuminate = {
2023-06-06 02:05:05 +02:00
url = "github:RRethy/vim-illuminate";
2023-04-03 11:12:05 +02:00
flake = false;
};
2023-02-06 02:14:01 +01:00
# Assistant
plugin-chatgpt = {
url = "github:jackMort/ChatGPT.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-copilot-lua = {
2023-02-06 02:14:01 +01:00
url = "github:zbirenbaum/copilot.lua";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-copilot-cmp = {
url = "github:zbirenbaum/copilot-cmp";
flake = false;
};
# Session management
2024-04-08 02:28:49 +02:00
plugin-nvim-session-manager = {
url = "github:Shatur/neovim-session-manager";
flake = false;
};
# Dependencies
2024-04-08 02:28:49 +02:00
plugin-plenary-nvim = {
# (required by crates-nvim)
url = "github:nvim-lua/plenary.nvim";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-dressing-nvim = {
# (required by icon-picker-nvim)
url = "github:stevearc/dressing.nvim";
flake = false;
};
2023-02-05 23:09:12 +01:00
2024-04-08 02:28:49 +02:00
plugin-vim-markdown = {
2023-02-05 23:09:12 +01:00
# (required by obsidian-nvim)
url = "github:preservim/vim-markdown";
flake = false;
};
2024-04-08 02:28:49 +02:00
plugin-tabular = {
2023-02-05 23:09:12 +01:00
# (required by vim-markdown)
url = "github:godlygeek/tabular";
flake = false;
};
2023-02-06 01:55:19 +01:00
2024-04-08 02:28:49 +02:00
plugin-nui-nvim = {
2023-02-06 06:14:13 +01:00
# (required by noice.nvim)
2023-02-06 01:55:19 +01:00
url = "github:MunifTanjim/nui.nvim";
flake = false;
};
2023-04-05 01:14:13 +02:00
2024-04-08 02:28:49 +02:00
plugin-vim-repeat = {
# (required by leap.nvim)
2023-04-05 01:14:13 +02:00
url = "github:tpope/vim-repeat";
flake = false;
};
2024-04-03 20:13:19 +02:00
2024-04-08 02:28:49 +02:00
plugin-nvim-nio = {
2024-04-03 20:13:19 +02:00
# (required nvim-dap-ui)
url = "github:nvim-neotest/nvim-nio";
flake = false;
};
2023-02-01 21:59:35 +01:00
};
}