feat: setup neovim & update firefox to nightly
This commit is contained in:
parent
10bb022f75
commit
f442980938
24 changed files with 581 additions and 1256 deletions
|
|
@ -1,85 +0,0 @@
|
|||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
||||
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
||||
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
||||
if vim.v.shell_error ~= 0 then
|
||||
vim.api.nvim_echo({
|
||||
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
||||
{ out, "WarningMsg" },
|
||||
{ "\nPress any key to exit..." },
|
||||
}, true, {})
|
||||
vim.fn.getchar()
|
||||
os.exit(1)
|
||||
end
|
||||
end
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
require("lazy").setup({
|
||||
spec = {
|
||||
-- add LazyVim and import its plugins
|
||||
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
|
||||
-- import any extras modules here
|
||||
{ import = "lazyvim.plugins.extras.coding.luasnip" },
|
||||
{ import = "lazyvim.plugins.extras.coding.mini-surround" },
|
||||
{ import = "lazyvim.plugins.extras.coding.yanky" },
|
||||
{ import = "lazyvim.plugins.extras.dap.core" },
|
||||
{ import = "lazyvim.plugins.extras.dap.nlua" },
|
||||
{ import = "lazyvim.plugins.extras.editor.dial" },
|
||||
-- { import = "lazyvim.plugins.extras.formatting.biome" },
|
||||
{ import = "lazyvim.plugins.extras.formatting.black" },
|
||||
{ import = "lazyvim.plugins.extras.formatting.prettier" },
|
||||
{ import = "lazyvim.plugins.extras.lang.cmake" },
|
||||
{ import = "lazyvim.plugins.extras.lang.docker" },
|
||||
{ import = "lazyvim.plugins.extras.lang.git" },
|
||||
{ import = "lazyvim.plugins.extras.lang.json" },
|
||||
{ import = "lazyvim.plugins.extras.lang.nix" },
|
||||
{ import = "lazyvim.plugins.extras.lang.markdown" },
|
||||
{ import = "lazyvim.plugins.extras.lang.nushell" },
|
||||
{ import = "lazyvim.plugins.extras.lang.omnisharp" },
|
||||
-- { import = "lazyvim.plugins.extras.lang.vue" },
|
||||
-- { import = "lazyvim.plugins.extras.lang.typescript" },
|
||||
-- { import = "lazyvim.plugins.extras.lang.python" },
|
||||
{ import = "lazyvim.plugins.extras.lang.rust" },
|
||||
{ import = "lazyvim.plugins.extras.lang.tailwind" },
|
||||
{ import = "lazyvim.plugins.extras.lang.toml" },
|
||||
{ import = "lazyvim.plugins.extras.lang.yaml" },
|
||||
{ import = "lazyvim.plugins.extras.linting.eslint" },
|
||||
{ import = "lazyvim.plugins.extras.ui.alpha" },
|
||||
{ import = "lazyvim.plugins.extras.ui.edgy" },
|
||||
{ import = "lazyvim.plugins.extras.ui.mini-animate" },
|
||||
{ import = "lazyvim.plugins.extras.ui.mini-indentscope" },
|
||||
{ import = "lazyvim.plugins.extras.ui.smear-cursor" },
|
||||
{ import = "lazyvim.plugins.extras.ui.treesitter-context" },
|
||||
{ import = "lazyvim.plugins.extras.util.dot" },
|
||||
{ import = "lazyvim.plugins.extras.util.mini-hipatterns" },
|
||||
{ import = "lazyvim.plugins.extras.editor.telescope" },
|
||||
-- import/override with your plugins
|
||||
{ import = "plugins" },
|
||||
},
|
||||
defaults = {
|
||||
-- By default, only LazyVim plugins will be lazy-loaded. Your custom plugins will load during startup.
|
||||
-- If you know what you're doing, you can set this to `true` to have all your custom plugins lazy-loaded by default.
|
||||
lazy = false,
|
||||
-- It's recommended to leave version=false for now, since a lot the plugin that support versioning,
|
||||
-- have outdated releases, which may break your Neovim install.
|
||||
version = false, -- always use the latest git commit
|
||||
-- version = "*", -- try installing the latest stable version for plugins that support semver
|
||||
},
|
||||
install = { colorscheme = { "tokyonight", "habamax" } },
|
||||
checker = { enabled = true, notify = false }, -- automatically check for plugin updates
|
||||
performance = {
|
||||
rtp = {
|
||||
-- disable some rtp plugins
|
||||
disabled_plugins = {
|
||||
"gzip",
|
||||
-- "matchit",
|
||||
-- "matchparen",
|
||||
-- "netrwPlugin",
|
||||
"tarPlugin",
|
||||
"tohtml",
|
||||
"tutor",
|
||||
"zipPlugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
|
@ -19,3 +19,6 @@ end
|
|||
if package.config:sub(1, 1) == "\\" then
|
||||
vim.o.shell = GetAvailableWindowsShell()
|
||||
end
|
||||
|
||||
vim.g.lazyvim_python_ruff = "ruff"
|
||||
vim.g.lazyvim_eslint_auto_format = true
|
||||
|
|
|
|||
|
|
@ -1,22 +1,22 @@
|
|||
return {
|
||||
{
|
||||
{
|
||||
"kdheepak/lazygit.nvim",
|
||||
lazy = false,
|
||||
cmd = {
|
||||
"LazyGit",
|
||||
"LazyGitConfig",
|
||||
"LazyGitCurrentFile",
|
||||
"LazyGitFilter",
|
||||
"LazyGitFilterCurrentFile",
|
||||
"LazyGit",
|
||||
"LazyGitConfig",
|
||||
"LazyGitCurrentFile",
|
||||
"LazyGitFilter",
|
||||
"LazyGitFilterCurrentFile",
|
||||
},
|
||||
-- optional for floating window border decoration
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-lua/plenary.nvim",
|
||||
},
|
||||
-- setting the keybinding for LazyGit with 'keys' is recommended in
|
||||
-- order to load the plugin when the command is run for the first time
|
||||
keys = {
|
||||
{ "<leader>gg", "<cmd>LazyGit<cr>", desc = "LazyGit" }
|
||||
}
|
||||
}
|
||||
{ "<leader>gg", "<cmd>LazyGit<cr>", desc = "LazyGit" },
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
local util = require("lspconfig.util")
|
||||
local async = require("lspconfig.async")
|
||||
local mod_cache = nil
|
||||
|
||||
return {
|
||||
{
|
||||
|
|
@ -72,55 +70,51 @@ return {
|
|||
nginx_language_server = {
|
||||
cmd = { "nginx-language-server" },
|
||||
filetypes = { "nginx" },
|
||||
rootPatterns = { "nginx.conf", ".git" },
|
||||
rootPatterns = { "biome.json", "biome.jsonc" },
|
||||
},
|
||||
-- jsonls = {
|
||||
-- cmd = { "vscode-json-languageserver", "--stdio" },
|
||||
-- filetypes = { "json", "jsonc" },
|
||||
-- },
|
||||
vuels = {
|
||||
cmd = { "vue-language-server", "--stdio" },
|
||||
filetypes = { "vue" },
|
||||
},
|
||||
ts_ls = {
|
||||
cmd = { "typescript-language-server", "--stdio" },
|
||||
filetypes = { "vue", "ts", "tsx" },
|
||||
},
|
||||
clangd = {
|
||||
cmd = { "clangd" },
|
||||
root_markers = { ".git", ".clangd", "compile_commands.json" },
|
||||
filetypes = { "cpp", "c" },
|
||||
capabilities = {
|
||||
textDocument = {
|
||||
semanticTokens = {
|
||||
multilineTokenSupport = true,
|
||||
volar = {
|
||||
init_options = {
|
||||
vue = {
|
||||
hybridMode = true,
|
||||
},
|
||||
},
|
||||
settings = {
|
||||
typescript = {
|
||||
inlayHints = {
|
||||
enumMemberValues = {
|
||||
enabled = true,
|
||||
},
|
||||
functionLikeReturnTypes = {
|
||||
enabled = true,
|
||||
},
|
||||
propertyDeclarationTypes = {
|
||||
enabled = true,
|
||||
},
|
||||
parameterTypes = {
|
||||
enabled = true,
|
||||
suppressWhenArgumentMatchesName = true,
|
||||
},
|
||||
variableTypes = {
|
||||
enabled = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
gopls = {
|
||||
cmd = { "gopls" },
|
||||
filetypes = { "go", "gomod", "gowork", "gotmpl" },
|
||||
root_dir = function(fname)
|
||||
-- see: https://github.com/neovim/nvim-lspconfig/issues/804
|
||||
if not mod_cache then
|
||||
local result = async.run_command({ "go", "env", "GOMODCACHE" })
|
||||
|
||||
if result and result[1] then
|
||||
mod_cache = vim.trim(result[1])
|
||||
else
|
||||
mod_cache = vim.fn.system("go env GOMODCACHE")
|
||||
end
|
||||
end
|
||||
if mod_cache and fname:sub(1, #mod_cache) == mod_cache then
|
||||
local clients = util.get_lsp_clients({ name = "gopls" })
|
||||
if #clients > 0 then
|
||||
return clients[#clients].config.root_dir
|
||||
end
|
||||
end
|
||||
return util.root_pattern("go.work", "go.mod", ".git")(fname)
|
||||
vtsls = {},
|
||||
stylelint_lsp = {
|
||||
filetypes = { "css", "scss", "vue" },
|
||||
root_dir = util.root_pattern("packages.json", ".git"),
|
||||
debounce = 100,
|
||||
settings = {
|
||||
stylelintplus = {
|
||||
autoFixOnFormat = true,
|
||||
autoFixOnSave = true,
|
||||
},
|
||||
},
|
||||
on_attach = function(client)
|
||||
client.server_capabilities.document_formatting = false
|
||||
end,
|
||||
single_file_support = true,
|
||||
},
|
||||
},
|
||||
setup = {},
|
||||
|
|
|
|||
|
|
@ -1,11 +0,0 @@
|
|||
return {
|
||||
{
|
||||
"iamcco/markdown-preview.nvim",
|
||||
cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" },
|
||||
build = "cd app && yarn install",
|
||||
init = function()
|
||||
vim.g.mkdp_filetypes = { "markdown" }
|
||||
end,
|
||||
ft = { "markdown" },
|
||||
},
|
||||
}
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
-- Mason is not usable on NixOS
|
||||
return {
|
||||
{ "williamboman/mason-lspconfig.nvim", enabled = false },
|
||||
{ "williamboman/mason.nvim", enabled = false },
|
||||
}
|
||||
|
|
@ -11,7 +11,7 @@
|
|||
./virtualization.nix
|
||||
./hyprland.nix
|
||||
./swaync.nix
|
||||
./neovim.nix
|
||||
./nvim.nix
|
||||
./bin.nix
|
||||
./desktops.nix
|
||||
./direnv.nix
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
...
|
||||
}:
|
||||
let
|
||||
browser = "firefox";
|
||||
browser = "firefox-nightly";
|
||||
noOffloadBrowser = "${browser} -P noOffload -no-remote";
|
||||
iconPrefix = ".local/share/icons/hicolor/scalable/apps";
|
||||
newWindow = "${browser} --new-window";
|
||||
|
|
|
|||
|
|
@ -1,9 +1,10 @@
|
|||
{ mainMod, nvidia-offload-enabled }:
|
||||
let
|
||||
prefix = if nvidia-offload-enabled then "offload " else "";
|
||||
browser = "${prefix}firefox";
|
||||
noOffloadBrowser = "firefox -P noOffload";
|
||||
terminal = "${prefix}ghostty";
|
||||
firefox = "firefox-nightly";
|
||||
prefix = if nvidia-offload-enabled then "offload" else "";
|
||||
browser = "${prefix} ${firefox}";
|
||||
noOffloadBrowser = "${firefox} -P noOffload";
|
||||
terminal = "${prefix} ghostty";
|
||||
filemanager = "nemo";
|
||||
scripts = "~/.config/scripts";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,87 +0,0 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
let
|
||||
treesitterWithGrammars = (
|
||||
pkgs.vimPlugins.nvim-treesitter.withPlugins (p: [
|
||||
p.bash
|
||||
p.comment
|
||||
p.css
|
||||
p.dockerfile
|
||||
p.fish
|
||||
p.gitattributes
|
||||
p.gitignore
|
||||
p.go
|
||||
p.gomod
|
||||
p.gowork
|
||||
p.hcl
|
||||
p.javascript
|
||||
p.jq
|
||||
p.json5
|
||||
p.json
|
||||
p.lua
|
||||
p.make
|
||||
p.markdown
|
||||
p.nix
|
||||
p.python
|
||||
p.rust
|
||||
p.toml
|
||||
p.typescript
|
||||
p.vue
|
||||
p.yaml
|
||||
])
|
||||
);
|
||||
|
||||
treesitter-parsers = pkgs.symlinkJoin {
|
||||
name = "treesitter-parsers";
|
||||
paths = treesitterWithGrammars.dependencies;
|
||||
};
|
||||
configDir = ../config;
|
||||
in
|
||||
{
|
||||
# Other Lsp servers & formatter are defined in system/module/lsp.nix
|
||||
home.packages = with pkgs; [
|
||||
gh
|
||||
vue-language-server
|
||||
dockerfile-language-server-nodejs
|
||||
javascript-typescript-langserver
|
||||
ruff
|
||||
ruff-lsp
|
||||
hadolint
|
||||
nodePackages_latest.typescript
|
||||
];
|
||||
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
vimAlias = true;
|
||||
coc.enable = false;
|
||||
withNodeJs = true;
|
||||
|
||||
plugins =
|
||||
[
|
||||
treesitterWithGrammars
|
||||
]
|
||||
++ (with pkgs.vimPlugins; [
|
||||
markdown-preview-nvim
|
||||
]);
|
||||
extraPackages = [ pkgs.imagemagick ];
|
||||
extraLuaPackages = ps: with ps; [ magick ];
|
||||
};
|
||||
|
||||
home.file."./.config/nvim" = {
|
||||
source = "${configDir}/nvim";
|
||||
recursive = true;
|
||||
};
|
||||
|
||||
home.file."./.config/nvim/init.lua".text = ''
|
||||
require("config.lazy")
|
||||
vim.opt.runtimepath:append("${treesitter-parsers}")
|
||||
'';
|
||||
|
||||
# Treesitter is configured as a locally developed module in lazy.nvim
|
||||
# we hardcode a symlink here so that we can refer to it in our lazy config
|
||||
home.file."./.local/share/nvim/nix/extras/" = {
|
||||
recursive = true;
|
||||
source = treesitterWithGrammars;
|
||||
};
|
||||
|
||||
}
|
||||
327
home/user/nvim.nix
Normal file
327
home/user/nvim.nix
Normal file
|
|
@ -0,0 +1,327 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
gh
|
||||
];
|
||||
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
withPython3 = true;
|
||||
extraPython3Packages = (
|
||||
plugins: with plugins; [
|
||||
debugpy
|
||||
]
|
||||
);
|
||||
|
||||
withNodeJs = true;
|
||||
|
||||
extraPackages = with pkgs; [
|
||||
lua-language-server
|
||||
stylua
|
||||
ripgrep
|
||||
vue-language-server
|
||||
dockerfile-language-server-nodejs
|
||||
ruff
|
||||
ruff-lsp
|
||||
hadolint
|
||||
cmake-language-server
|
||||
cmake-lint
|
||||
cmake-format
|
||||
markdownlint-cli2
|
||||
marksman
|
||||
csharpier
|
||||
netcoredbg
|
||||
black
|
||||
prettierd
|
||||
biome
|
||||
eslint
|
||||
typescript-language-server
|
||||
typescript
|
||||
vtsls
|
||||
stylelint-lsp
|
||||
stylelint
|
||||
clang-tools
|
||||
];
|
||||
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
lazy-nvim
|
||||
];
|
||||
|
||||
extraLuaConfig =
|
||||
let
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
# LazyVim
|
||||
LazyVim
|
||||
bufferline-nvim
|
||||
cmp-buffer
|
||||
cmp-nvim-lsp
|
||||
cmp-path
|
||||
cmp-git
|
||||
blink-cmp
|
||||
crates-nvim
|
||||
conform-nvim
|
||||
dashboard-nvim
|
||||
dressing-nvim
|
||||
flash-nvim
|
||||
friendly-snippets
|
||||
gitsigns-nvim
|
||||
grug-far-nvim
|
||||
indent-blankline-nvim
|
||||
lazydev-nvim
|
||||
lualine-nvim
|
||||
luvit-meta
|
||||
neo-tree-nvim
|
||||
neotest
|
||||
noice-nvim
|
||||
nui-nvim
|
||||
nvim-cmp
|
||||
nvim-lint
|
||||
nvim-lspconfig
|
||||
nvim-snippets
|
||||
nvim-treesitter
|
||||
nvim-treesitter-context
|
||||
nvim-treesitter-textobjects
|
||||
nvim-ts-autotag
|
||||
nvim-ts-context-commentstring
|
||||
nvim-web-devicons
|
||||
persistence-nvim
|
||||
plenary-nvim
|
||||
snacks-nvim
|
||||
telescope-fzf-native-nvim
|
||||
telescope-nvim
|
||||
todo-comments-nvim
|
||||
tokyonight-nvim
|
||||
trouble-nvim
|
||||
ts-comments-nvim
|
||||
which-key-nvim
|
||||
vim-markdown-toc
|
||||
nvim-dap
|
||||
nvim-dap-ui
|
||||
nvim-dap-virtual-text
|
||||
nvim-nio
|
||||
one-small-step-for-vimkind
|
||||
none-ls-nvim
|
||||
markdown-preview-nvim
|
||||
render-markdown-nvim
|
||||
image-nvim
|
||||
|
||||
# Python
|
||||
neotest-python
|
||||
nvim-dap-python
|
||||
|
||||
# C#
|
||||
omnisharp-extended-lsp-nvim
|
||||
neotest-dotnet
|
||||
|
||||
# Cmake
|
||||
cmake-tools-nvim
|
||||
SchemaStore-nvim
|
||||
|
||||
{
|
||||
name = "LuaSnip";
|
||||
path = luasnip;
|
||||
}
|
||||
|
||||
{
|
||||
name = "catppuccin";
|
||||
path = catppuccin-nvim;
|
||||
}
|
||||
{
|
||||
name = "mini.ai";
|
||||
path = mini-nvim;
|
||||
}
|
||||
{
|
||||
name = "mini.bufremove";
|
||||
path = mini-nvim;
|
||||
}
|
||||
{
|
||||
name = "mini.comment";
|
||||
path = mini-nvim;
|
||||
}
|
||||
{
|
||||
name = "mini.indentscope";
|
||||
path = mini-nvim;
|
||||
}
|
||||
{
|
||||
name = "mini.pairs";
|
||||
path = mini-nvim;
|
||||
}
|
||||
{
|
||||
name = "mini.surround";
|
||||
path = mini-nvim;
|
||||
}
|
||||
];
|
||||
mkEntryFromDrv =
|
||||
drv:
|
||||
if lib.isDerivation drv then
|
||||
{
|
||||
name = "${lib.getName drv}";
|
||||
path = drv;
|
||||
}
|
||||
else
|
||||
drv;
|
||||
|
||||
lazyPath = pkgs.linkFarm "lazy-plugins" (builtins.map mkEntryFromDrv plugins);
|
||||
in
|
||||
''
|
||||
require("lazy").setup({
|
||||
defaults = {
|
||||
lazy = true,
|
||||
},
|
||||
dev = {
|
||||
-- reuse files from pkgs.vimPlugins.*
|
||||
path = "${lazyPath}",
|
||||
patterns = { "" },
|
||||
-- fallback to download
|
||||
fallback = true,
|
||||
},
|
||||
spec = {
|
||||
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
|
||||
-- The following configs are needed for fixing lazyvim on nix
|
||||
-- force enable telescope-fzf-native.nvim
|
||||
{ "nvim-telescope/telescope-fzf-native.nvim", enabled = true },
|
||||
|
||||
{ import = "lazyvim.plugins.extras.coding.blink" },
|
||||
{ import = "lazyvim.plugins.extras.coding.luasnip" },
|
||||
{ import = "lazyvim.plugins.extras.coding.mini-surround" },
|
||||
{ import = "lazyvim.plugins.extras.coding.yanky" },
|
||||
{ import = "lazyvim.plugins.extras.dap.core" },
|
||||
{ import = "lazyvim.plugins.extras.dap.nlua" },
|
||||
{ import = "lazyvim.plugins.extras.editor.dial" },
|
||||
-- { import = "lazyvim.plugins.extras.formatting.biome" },
|
||||
{ import = "lazyvim.plugins.extras.formatting.black" },
|
||||
{ import = "lazyvim.plugins.extras.formatting.prettier" },
|
||||
{ import = "lazyvim.plugins.extras.lang.cmake" },
|
||||
{ import = "lazyvim.plugins.extras.lang.docker" },
|
||||
{ import = "lazyvim.plugins.extras.lang.git" },
|
||||
{ import = "lazyvim.plugins.extras.lang.json" },
|
||||
{ import = "lazyvim.plugins.extras.lang.nix" },
|
||||
{ import = "lazyvim.plugins.extras.lang.go" },
|
||||
{ import = "lazyvim.plugins.extras.lang.zig" },
|
||||
{ import = "lazyvim.plugins.extras.lang.markdown" },
|
||||
{ import = "lazyvim.plugins.extras.lang.nushell" },
|
||||
{ import = "lazyvim.plugins.extras.lang.omnisharp" },
|
||||
{ import = "lazyvim.plugins.extras.lang.clangd" },
|
||||
-- { import = "lazyvim.plugins.extras.lang.vue" },
|
||||
{ import = "lazyvim.plugins.extras.lang.typescript" },
|
||||
{ import = "lazyvim.plugins.extras.lang.python" },
|
||||
{ import = "lazyvim.plugins.extras.lang.rust" },
|
||||
{ import = "lazyvim.plugins.extras.lang.tailwind" },
|
||||
{ import = "lazyvim.plugins.extras.lang.toml" },
|
||||
{ import = "lazyvim.plugins.extras.lang.yaml" },
|
||||
{ import = "lazyvim.plugins.extras.linting.eslint" },
|
||||
{ import = "lazyvim.plugins.extras.ui.alpha" },
|
||||
{ import = "lazyvim.plugins.extras.ui.edgy" },
|
||||
{ import = "lazyvim.plugins.extras.ui.mini-animate" },
|
||||
{ import = "lazyvim.plugins.extras.ui.mini-indentscope" },
|
||||
{ import = "lazyvim.plugins.extras.ui.smear-cursor" },
|
||||
{ import = "lazyvim.plugins.extras.ui.treesitter-context" },
|
||||
{ import = "lazyvim.plugins.extras.util.dot" },
|
||||
{ import = "lazyvim.plugins.extras.util.mini-hipatterns" },
|
||||
{ import = "lazyvim.plugins.extras.editor.telescope" },
|
||||
|
||||
-- uncomment to import/override with your plugins
|
||||
{ import = "plugins" },
|
||||
|
||||
-- Vue & Typescript
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
opts = function(_, opts)
|
||||
table.insert(opts.servers.vtsls.filetypes, "vue")
|
||||
LazyVim.extend(opts.servers.vtsls, "settings.vtsls.tsserver.globalPlugins", {
|
||||
{
|
||||
name = "@vue/typescript-plugin",
|
||||
location = "${pkgs.vue-language-server}/lib/node_modules/@vue/language-server",
|
||||
languages = { "vue" },
|
||||
configNamespace = "typescript",
|
||||
enableForWorkspaceTypeScriptVersions = true,
|
||||
},
|
||||
})
|
||||
end
|
||||
},
|
||||
|
||||
-- disable DAP
|
||||
{ "mfussenegger/nvim-dap-python", enabled = false },
|
||||
{ "mfussenegger/nvim-dap", enabled = false },
|
||||
|
||||
-- disable mason.nvim, use config.extraPackages
|
||||
{ "williamboman/mason-lspconfig.nvim", enabled = false },
|
||||
{ "williamboman/mason.nvim", enabled = false },
|
||||
{ "jay-babu/mason-nvim-dap.nvim", enabled = false },
|
||||
|
||||
-- put this line at the end of spec to clear ensure_installed
|
||||
{ "nvim-treesitter/nvim-treesitter", opts = function(_, opts) opts.ensure_installed = {} end },
|
||||
},
|
||||
})
|
||||
'';
|
||||
};
|
||||
|
||||
xdg.configFile."nvim/parser".source =
|
||||
let
|
||||
parsers = pkgs.symlinkJoin {
|
||||
name = "treesitter-parsers";
|
||||
paths =
|
||||
(pkgs.vimPlugins.nvim-treesitter.withPlugins (
|
||||
plugins: with plugins; [
|
||||
c
|
||||
cpp
|
||||
c_sharp
|
||||
lua
|
||||
bash
|
||||
comment
|
||||
css
|
||||
scss
|
||||
nu
|
||||
ninja
|
||||
rst
|
||||
|
||||
# rust
|
||||
rust
|
||||
ron
|
||||
|
||||
# docker
|
||||
dockerfile
|
||||
|
||||
fish
|
||||
|
||||
# cmake
|
||||
cmake
|
||||
|
||||
# git
|
||||
gitattributes
|
||||
gitignore
|
||||
git_config
|
||||
gitcommit
|
||||
git_rebase
|
||||
|
||||
go
|
||||
gomod
|
||||
gowork
|
||||
gosum
|
||||
|
||||
hcl
|
||||
javascript
|
||||
jq
|
||||
json5
|
||||
lua
|
||||
make
|
||||
markdown
|
||||
nix
|
||||
python
|
||||
toml
|
||||
typescript
|
||||
vue
|
||||
yaml
|
||||
zig
|
||||
]
|
||||
)).dependencies;
|
||||
};
|
||||
in
|
||||
"${parsers}/parser";
|
||||
|
||||
xdg.configFile."nvim/lua".source = ../config/nvim/lua;
|
||||
}
|
||||
|
|
@ -46,7 +46,6 @@ in
|
|||
pkgsCross.mingwW64.stdenv.cc
|
||||
pkgsCross.mingwW64.windows.pthreads
|
||||
postman
|
||||
cz-cli
|
||||
|
||||
# Work stuff
|
||||
libreoffice-qt
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, ... }:
|
||||
{ pkgs, inputs, ... }:
|
||||
let
|
||||
userChrome = builtins.readFile ../config/firefox/autohide_toolbox.css;
|
||||
profileSettings = {
|
||||
|
|
@ -35,7 +35,8 @@ in
|
|||
|
||||
firefox = {
|
||||
enable = true;
|
||||
package = (pkgs.wrapFirefox (pkgs.firefox-unwrapped.override { pipewireSupport = true; }) { });
|
||||
# package = (pkgs.wrapFirefox (pkgs.firefox-unwrapped.override { pipewireSupport = true; }) { });
|
||||
package = inputs.firefox.packages.${pkgs.system}.firefox-nightly-bin;
|
||||
languagePacks = [
|
||||
"en-US"
|
||||
"zh-TW"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue