no idea
This commit is contained in:
@@ -1,6 +1,5 @@
|
|||||||
# Edit this configuration file to define what should be installed on your system. Help is available
|
# Edit this configuration file to define what should be installed on your system. Help is available
|
||||||
# in the configuration.nix(5) man page and in the NixOS manual (accessible by running ‘nixos-help’).
|
# in the configuration.nix(5) man page and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, pkgs, inputs, ... }:
|
{ config, pkgs, inputs, ... }:
|
||||||
|
|
||||||
{ imports =
|
{ imports =
|
||||||
@@ -23,6 +22,8 @@
|
|||||||
xwayland.enable = true;
|
xwayland.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
programs.adb.enable = true;
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
@@ -30,6 +31,11 @@ boot.loader.efi.canTouchEfiVariables = true;
|
|||||||
|
|
||||||
swapDevices = [ ];
|
swapDevices = [ ];
|
||||||
|
|
||||||
|
fileSystems."mnt/win" = {
|
||||||
|
device = "/dev/sdb1";
|
||||||
|
fsType = "ntfs";
|
||||||
|
};
|
||||||
|
|
||||||
# Flakes
|
# Flakes
|
||||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||||
|
|
||||||
@@ -47,8 +53,8 @@ boot.loader.efi.canTouchEfiVariables = true;
|
|||||||
# VM
|
# VM
|
||||||
virtualisation.virtualbox.host.enable = true;
|
virtualisation.virtualbox.host.enable = true;
|
||||||
virtualisation.virtualbox.host.enableExtensionPack = true;
|
virtualisation.virtualbox.host.enableExtensionPack = true;
|
||||||
# virtualisation.virtualbox.host.enableKvm = true;
|
virtualisation.virtualbox.host.enableKvm = true;
|
||||||
# virtualisation.virtualbox.host.addNetworkInterface = false;
|
virtualisation.virtualbox.host.addNetworkInterface = false;
|
||||||
users.extraGroups.vboxusers.members = [ "nico" ];
|
users.extraGroups.vboxusers.members = [ "nico" ];
|
||||||
# virtualisation.virtualbox.guest.enable = true;
|
# virtualisation.virtualbox.guest.enable = true;
|
||||||
# virtualisation.virtualbox.guest.dragAndDrop = true;
|
# virtualisation.virtualbox.guest.dragAndDrop = true;
|
||||||
@@ -99,7 +105,7 @@ boot.loader.efi.canTouchEfiVariables = true;
|
|||||||
|
|
||||||
# Enable touchpad support (enabled default in most desktopManager). services.xserver.libinput.enable
|
# Enable touchpad support (enabled default in most desktopManager). services.xserver.libinput.enable
|
||||||
# = true;
|
# = true;
|
||||||
|
services.mullvad-vpn.enable = true;
|
||||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||||
users.users.nico = { isNormalUser = true; description = "nico"; extraGroups = [ "networkmanager"
|
users.users.nico = { isNormalUser = true; description = "nico"; extraGroups = [ "networkmanager"
|
||||||
"wheel" "adbusers" "docker"]; packages = with pkgs; [
|
"wheel" "adbusers" "docker"]; packages = with pkgs; [
|
||||||
@@ -132,6 +138,7 @@ boot.loader.efi.canTouchEfiVariables = true;
|
|||||||
heroic
|
heroic
|
||||||
wineWowPackages.stable
|
wineWowPackages.stable
|
||||||
spotify
|
spotify
|
||||||
|
#spicetify-cli
|
||||||
sshfs
|
sshfs
|
||||||
|
|
||||||
# sway
|
# sway
|
||||||
|
|||||||
65
flake.lock
generated
65
flake.lock
generated
@@ -47,11 +47,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1743527271,
|
"lastModified": 1744038920,
|
||||||
"narHash": "sha256-EuanEW1qqXZ2h0zJnq7uz8BoHbsgHgUrqWkCZHwZ9FA=",
|
"narHash": "sha256-9a4V1wQXS8hXZtc7mRtz0qINkGW+C99aDrmXY6oYBFg=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "f4d9d1e2ad19d544a0a0cf3f8f371c6139c762e9",
|
"rev": "a4d8020820a85b47f842eae76ad083b0ec2a886a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -78,11 +78,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1743315132,
|
"lastModified": 1743827369,
|
||||||
"narHash": "sha256-6hl6L/tRnwubHcA4pfUUtk542wn2Om+D4UnDhlDW9BE=",
|
"narHash": "sha256-rpqepOZ8Eo1zg+KJeWoq1HAOgoMCDloqv5r2EAa9TSA=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "52faf482a3889b7619003c0daec593a1912fddc1",
|
"rev": "42a1c966be226125b48c384171c44c651c236c22",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -92,11 +92,62 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"nixpkgs_3": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1743827369,
|
||||||
|
"narHash": "sha256-rpqepOZ8Eo1zg+KJeWoq1HAOgoMCDloqv5r2EAa9TSA=",
|
||||||
|
"owner": "NixOS",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "42a1c966be226125b48c384171c44c651c236c22",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "NixOS",
|
||||||
|
"ref": "nixos-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"ags": "ags",
|
"ags": "ags",
|
||||||
"home-manager": "home-manager",
|
"home-manager": "home-manager",
|
||||||
"nixpkgs": "nixpkgs_2"
|
"nixpkgs": "nixpkgs_2",
|
||||||
|
"spicetify-nix": "spicetify-nix"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"spicetify-nix": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": "nixpkgs_3",
|
||||||
|
"systems": "systems"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1743946771,
|
||||||
|
"narHash": "sha256-n/LxWCGJtDi/rWMKEXWQn39v46iFZpW+V9mY4/4LJQs=",
|
||||||
|
"owner": "Gerg-L",
|
||||||
|
"repo": "spicetify-nix",
|
||||||
|
"rev": "af24d96983faa41e79fa00312106c37a7cc2ca0a",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "Gerg-L",
|
||||||
|
"repo": "spicetify-nix",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"systems": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681028828,
|
||||||
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"type": "github"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -10,6 +10,8 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
ags.url = "github:Aylur/ags";
|
ags.url = "github:Aylur/ags";
|
||||||
|
|
||||||
|
spicetify-nix.url = "github:Gerg-L/spicetify-nix";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs, ... }@inputs:
|
outputs = { self, nixpkgs, ... }@inputs:
|
||||||
|
|||||||
@@ -6,6 +6,7 @@
|
|||||||
|
|
||||||
imports = [
|
imports = [
|
||||||
./packages
|
./packages
|
||||||
|
inputs.spicetify-nix.homeManagerModules.default
|
||||||
];
|
];
|
||||||
|
|
||||||
nixpkgs = {
|
nixpkgs = {
|
||||||
@@ -19,6 +20,25 @@
|
|||||||
floorp
|
floorp
|
||||||
];
|
];
|
||||||
|
|
||||||
|
programs.spicetify =
|
||||||
|
let
|
||||||
|
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
enable = true;
|
||||||
|
theme = spicePkgs.themes.catppuccin;
|
||||||
|
colorScheme = "mocha";
|
||||||
|
|
||||||
|
enabledExtensions = with spicePkgs.extensions; [
|
||||||
|
keyboardShortcut
|
||||||
|
wikify
|
||||||
|
songStats
|
||||||
|
betterGenres
|
||||||
|
hidePodcasts
|
||||||
|
fullScreen
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
home.stateVersion = "24.05";
|
home.stateVersion = "24.05";
|
||||||
|
|
||||||
programs.home-manager.enable = true;
|
programs.home-manager.enable = true;
|
||||||
|
|||||||
@@ -10,7 +10,6 @@
|
|||||||
./emacs
|
./emacs
|
||||||
./kitty
|
./kitty
|
||||||
./rofi
|
./rofi
|
||||||
./tmux
|
|
||||||
./hyprland
|
./hyprland
|
||||||
# ./vscode
|
# ./vscode
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -62,6 +62,11 @@ bindm = $mainMod, mouse:272, movewindow
|
|||||||
bindm = $mainMod, mouse:273, resizewindow
|
bindm = $mainMod, mouse:273, resizewindow
|
||||||
|
|
||||||
|
|
||||||
|
# Mediakeys
|
||||||
|
bind = , XF86AudioRaiseVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ +1%
|
||||||
|
bind = , XF86AudioLowerVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ -1%
|
||||||
|
bind = , XF86AudioMute, exec, pactl set-sink-mute @DEFAULT_SINK@ toggle
|
||||||
|
|
||||||
|
|
||||||
# will switch to a submap called resize
|
# will switch to a submap called resize
|
||||||
bind = $mainMod, R, submap, resize
|
bind = $mainMod, R, submap, resize
|
||||||
|
|||||||
@@ -6,6 +6,7 @@
|
|||||||
nil
|
nil
|
||||||
ripgrep
|
ripgrep
|
||||||
lldb
|
lldb
|
||||||
|
lazygit
|
||||||
gcc
|
gcc
|
||||||
];
|
];
|
||||||
|
|
||||||
@@ -17,7 +18,6 @@ programs.neovim = {
|
|||||||
|
|
||||||
programs.neovim.plugins = [
|
programs.neovim.plugins = [
|
||||||
pkgs.vimPlugins.lazy-nvim
|
pkgs.vimPlugins.lazy-nvim
|
||||||
pkgs.vimPlugins.nvim-lspconfig
|
|
||||||
];
|
];
|
||||||
|
|
||||||
home.file =
|
home.file =
|
||||||
@@ -25,8 +25,11 @@ programs.neovim.plugins = [
|
|||||||
{
|
{
|
||||||
".config/nvim/init.lua".source = ./init.lua;
|
".config/nvim/init.lua".source = ./init.lua;
|
||||||
".config/nvim/lua/config/lazy.lua".source = ./lua/config/lazy.lua;
|
".config/nvim/lua/config/lazy.lua".source = ./lua/config/lazy.lua;
|
||||||
# ".config/nvim/lua/plugins/flutter.lua".source = ./lua/plugins/flutter.lua;
|
".config/nvim/lua/plugins/flutter.lua".source = ./lua/plugins/flutter.lua;
|
||||||
".config/nvim/lua/plugins/coq.lua".source = ./lua/plugins/coq.lua;
|
# ".config/nvim/lua/plugins/coq.lua".source = ./lua/plugins/coq.lua;
|
||||||
|
".config/nvim/lua/plugins/blink-cmp.lua".source = ./lua/plugins/blink-cmp.lua;
|
||||||
|
".config/nvim/lua/plugins/lsp.lua".source = ./lua/plugins/lsp.lua;
|
||||||
|
# ".config/nvim/lua/plugins/mason.lua".source = ./lua/plugins/mason.lua;
|
||||||
".config/nvim/lua/plugins/treesitter.lua".source = ./lua/plugins/treesitter.lua;
|
".config/nvim/lua/plugins/treesitter.lua".source = ./lua/plugins/treesitter.lua;
|
||||||
".config/nvim/lua/plugins/catppuccin.lua".source = ./lua/plugins/catppuccin.lua;
|
".config/nvim/lua/plugins/catppuccin.lua".source = ./lua/plugins/catppuccin.lua;
|
||||||
".config/nvim/lua/plugins/telescope.lua".source = ./lua/plugins/telescope.lua;
|
".config/nvim/lua/plugins/telescope.lua".source = ./lua/plugins/telescope.lua;
|
||||||
@@ -39,6 +42,7 @@ programs.neovim.plugins = [
|
|||||||
".config/nvim/lua/plugins/dap.lua".source = ./lua/plugins/dap.lua;
|
".config/nvim/lua/plugins/dap.lua".source = ./lua/plugins/dap.lua;
|
||||||
".config/nvim/lua/plugins/blankline.lua".source = ./lua/plugins/blankline.lua;
|
".config/nvim/lua/plugins/blankline.lua".source = ./lua/plugins/blankline.lua;
|
||||||
".config/nvim/lua/plugins/rustaceanvim.lua".source = ./lua/plugins/rustaceanvim.lua;
|
".config/nvim/lua/plugins/rustaceanvim.lua".source = ./lua/plugins/rustaceanvim.lua;
|
||||||
|
".config/nvim/lua/plugins/lazygit.lua".source = ./lua/plugins/lazygit.lua;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -31,11 +31,12 @@ vim.keymap.set('n', '<C-Down>', ':resize +2<CR>', opts)
|
|||||||
vim.keymap.set('n', '<C-Left>', ':vertical resize -2<CR>', opts)
|
vim.keymap.set('n', '<C-Left>', ':vertical resize -2<CR>', opts)
|
||||||
vim.keymap.set('n', '<C-Right>', ':vertical resize +2<CR>', opts)
|
vim.keymap.set('n', '<C-Right>', ':vertical resize +2<CR>', opts)
|
||||||
|
|
||||||
|
|
||||||
vim.keymap.set('i', 'jk', '<Esc>', opts)
|
vim.keymap.set('i', 'jk', '<Esc>', opts)
|
||||||
|
vim.keymap.set('n', 'gd', vim.lsp.buf.definition, bufopts)
|
||||||
|
|
||||||
-- Lazy
|
-- Lazy
|
||||||
require("config.lazy")
|
require("config.lazy")
|
||||||
|
|
||||||
-- require("flutter-tools").setup {} -- use defaults
|
-- require("flutter-tools").setup {} -- use defaults
|
||||||
require("catppuccin").setup({
|
require("catppuccin").setup({
|
||||||
integrations = {
|
integrations = {
|
||||||
@@ -51,7 +52,6 @@ require("catppuccin").setup({
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
-- css colors
|
-- css colors
|
||||||
vim.opt.termguicolors = true
|
vim.opt.termguicolors = true
|
||||||
require('nvim-highlight-colors').setup({})
|
require('nvim-highlight-colors').setup({})
|
||||||
@@ -59,69 +59,101 @@ require('nvim-highlight-colors').setup({})
|
|||||||
vim.cmd.colorscheme "catppuccin"
|
vim.cmd.colorscheme "catppuccin"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
-- lsp
|
|
||||||
local on_attach = function(_, bufnr)
|
|
||||||
|
|
||||||
local bufmap = function(keys, func)
|
|
||||||
vim.keymap.set('n', keys, func, { buffer = bufnr })
|
|
||||||
end
|
|
||||||
|
|
||||||
bufmap('<leader>r', vim.lsp.buf.rename)
|
|
||||||
bufmap('<leader>a', vim.lsp.buf.code_action)
|
|
||||||
|
|
||||||
bufmap('gd', vim.lsp.buf.definition)
|
|
||||||
bufmap('gD', vim.lsp.buf.declaration)
|
|
||||||
bufmap('gI', vim.lsp.buf.implementation)
|
|
||||||
bufmap('<leader>D', vim.lsp.buf.type_definition)
|
|
||||||
|
|
||||||
bufmap('gr', require('telescope.builtin').lsp_references)
|
|
||||||
bufmap('<leader>s', require('telescope.builtin').lsp_document_symbols)
|
|
||||||
bufmap('<leader>S', require('telescope.builtin').lsp_dynamic_workspace_symbols)
|
|
||||||
|
|
||||||
bufmap('K', vim.lsp.buf.hover)
|
|
||||||
|
|
||||||
vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_)
|
|
||||||
vim.lsp.buf.format()
|
|
||||||
end, {})
|
|
||||||
end
|
|
||||||
|
|
||||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
|
||||||
capabilities = require('coq').lsp_ensure_capabilities(capabilities)
|
|
||||||
|
|
||||||
require('lspconfig').lua_ls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
root_dir = function()
|
|
||||||
return vim.loop.cwd()
|
|
||||||
end,
|
|
||||||
cmd = { "lua-language-server" },
|
|
||||||
settings = {
|
|
||||||
Lua = {
|
|
||||||
workspace = { checkThirdParty = false },
|
|
||||||
telemetry = { enable = false },
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').nil_ls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
|
|
||||||
--[[ require('lspconfig').rust_analyzer.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
} ]]
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
-- Plugin setups
|
-- Plugin setups
|
||||||
require('lualine').setup()
|
require('lualine').setup()
|
||||||
require("dapui").setup()
|
require("dapui").setup()
|
||||||
require("ibl").setup()
|
require("ibl").setup()
|
||||||
|
require("telescope").load_extension("flutter")
|
||||||
|
|
||||||
-- -- Debugger
|
-- alternatively you can override the default configs
|
||||||
|
require("flutter-tools").setup {
|
||||||
|
ui = {
|
||||||
|
-- the border type to use for all floating windows, the same options/formats
|
||||||
|
-- used for ":h nvim_open_win" e.g. "single" | "shadow" | {<table-of-eight-chars>}
|
||||||
|
border = "rounded",
|
||||||
|
-- This determines whether notifications are show with `vim.notify` or with the plugin's custom UI
|
||||||
|
-- please note that this option is eventually going to be deprecated and users will need to
|
||||||
|
-- depend on plugins like `nvim-notify` instead.
|
||||||
|
notification_style = 'plugin'
|
||||||
|
},
|
||||||
|
decorations = {
|
||||||
|
statusline = {
|
||||||
|
-- set to true to be able use the 'flutter_tools_decorations.app_version' in your statusline
|
||||||
|
-- this will show the current version of the flutter app from the pubspec.yaml file
|
||||||
|
app_version = false,
|
||||||
|
-- set to true to be able use the 'flutter_tools_decorations.device' in your statusline
|
||||||
|
-- this will show the currently running device if an application was started with a specific
|
||||||
|
-- device
|
||||||
|
device = true,
|
||||||
|
-- set to true to be able use the 'flutter_tools_decorations.project_config' in your statusline
|
||||||
|
-- this will show the currently selected project configuration
|
||||||
|
project_config = false,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
debugger = { -- integrate with nvim dap + install dart code debugger
|
||||||
|
enabled = true,
|
||||||
|
-- if empty dap will not stop on any exceptions, otherwise it will stop on those specified
|
||||||
|
-- see |:help dap.set_exception_breakpoints()| for more info
|
||||||
|
exception_breakpoints = { "uncaught" },
|
||||||
|
-- Whether to call toString() on objects in debug views like hovers and the
|
||||||
|
-- variables list.
|
||||||
|
-- Invoking toString() has a performance cost and may introduce side-effects,
|
||||||
|
-- although users may expected this functionality. null is treated like false.
|
||||||
|
evaluate_to_string_in_debug_views = true,
|
||||||
|
},
|
||||||
|
flutter_lookup_cmd = nil, -- example "dirname $(which flutter)" or "asdf where flutter"
|
||||||
|
root_patterns = { ".git", "pubspec.yaml" }, -- patterns to find the root of your flutter project
|
||||||
|
fvm = false, -- takes priority over path, uses <workspace>/.fvm/flutter_sdk if enabled
|
||||||
|
widget_guides = {
|
||||||
|
enabled = true,
|
||||||
|
},
|
||||||
|
closing_tags = {
|
||||||
|
highlight = "ErrorMsg", -- highlight for the closing tag
|
||||||
|
prefix = ">", -- character to use for close tag e.g. > Widget
|
||||||
|
priority = 10, -- priority of virtual text in current line
|
||||||
|
-- consider to configure this when there is a possibility of multiple virtual text items in one line
|
||||||
|
-- see `priority` option in |:help nvim_buf_set_extmark| for more info
|
||||||
|
enabled = true -- set to false to disable
|
||||||
|
},
|
||||||
|
dev_log = {
|
||||||
|
enabled = true,
|
||||||
|
filter = nil, -- optional callback to filter the log
|
||||||
|
-- takes a log_line as string argument; returns a boolean or nil;
|
||||||
|
-- the log_line is only added to the output if the function returns true
|
||||||
|
notify_errors = false, -- if there is an error whilst running then notify the user
|
||||||
|
open_cmd = "15split", -- command to use to open the log buffer
|
||||||
|
focus_on_open = true, -- focus on the newly opened log window
|
||||||
|
},
|
||||||
|
dev_tools = {
|
||||||
|
autostart = false, -- autostart devtools server if not detected
|
||||||
|
auto_open_browser = false, -- Automatically opens devtools in the browser
|
||||||
|
},
|
||||||
|
outline = {
|
||||||
|
open_cmd = "30vnew", -- command to use to open the outline buffer
|
||||||
|
auto_open = false -- if true this will open the outline automatically when it is first populated
|
||||||
|
},
|
||||||
|
lsp = {
|
||||||
|
color = { -- show the derived colours for dart variables
|
||||||
|
enabled = true, -- whether or not to highlight color variables at all, only supported on flutter >= 2.10
|
||||||
|
background = true, -- highlight the background
|
||||||
|
background_color = nil, -- required, when background is transparent (i.e. background_color = { r = 19, g = 17, b = 24},)
|
||||||
|
foreground = false, -- highlight the foreground
|
||||||
|
virtual_text = true, -- show the highlight using virtual text
|
||||||
|
virtual_text_str = "■", -- the virtual text character to highlight
|
||||||
|
},
|
||||||
|
-- see the link below for details on each option:
|
||||||
|
-- https://github.com/dart-lang/sdk/blob/master/pkg/analysis_server/tool/lsp_spec/README.md#client-workspace-configuration
|
||||||
|
settings = {
|
||||||
|
showTodos = true,
|
||||||
|
completeFunctionCalls = true,
|
||||||
|
renameFilesWithClasses = "prompt", -- "always"
|
||||||
|
enableSnippets = true,
|
||||||
|
updateImportsOnRename = true, -- Whether to update imports and other directives when files are renamed. Required for `FlutterRename` command.
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
------------- -- Debugger
|
||||||
local dap, dapui = require("dap"), require("dapui")
|
local dap, dapui = require("dap"), require("dapui")
|
||||||
dap.listeners.before.attach.dapui_config = function()
|
dap.listeners.before.attach.dapui_config = function()
|
||||||
dapui.open()
|
dapui.open()
|
||||||
@@ -145,6 +177,16 @@ dap.adapters.lldb = {
|
|||||||
dap.configurations.c = dap.configurations.cpp
|
dap.configurations.c = dap.configurations.cpp
|
||||||
dap.configurations.rust = dap.configurations.cpp
|
dap.configurations.rust = dap.configurations.cpp
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
--------------------------------------------
|
--------------------------------------------
|
||||||
local builtin = require('telescope.builtin')
|
local builtin = require('telescope.builtin')
|
||||||
-- Telescope binds
|
-- Telescope binds
|
||||||
@@ -152,7 +194,7 @@ vim.keymap.set('n', '<leader>ff', builtin.find_files, { desc = 'Telescope find f
|
|||||||
vim.keymap.set('n', '<leader>fg', builtin.live_grep, { desc = 'Telescope live grep' })
|
vim.keymap.set('n', '<leader>fg', builtin.live_grep, { desc = 'Telescope live grep' })
|
||||||
vim.keymap.set('n', '<leader>fb', ":Telescope file_browser<CR>", { desc = 'Telescope file_browser' })
|
vim.keymap.set('n', '<leader>fb', ":Telescope file_browser<CR>", { desc = 'Telescope file_browser' })
|
||||||
vim.keymap.set('n', '<leader>fh', builtin.help_tags, { desc = 'Telescope help tags' })
|
vim.keymap.set('n', '<leader>fh', builtin.help_tags, { desc = 'Telescope help tags' })
|
||||||
|
vim.keymap.set('n', '<leader>fl', ": Telescope flutter commands<CR>", { desc = "Open Telescope flutter" })
|
||||||
-- Dap binds
|
-- Dap binds
|
||||||
vim.keymap.set('n', '<leader>do', dapui.open, { desc = "Open debug overlay" })
|
vim.keymap.set('n', '<leader>do', dapui.open, { desc = "Open debug overlay" })
|
||||||
vim.keymap.set('n', '<leader>dc', dapui.close, { desc = "Close debug overlay" })
|
vim.keymap.set('n', '<leader>dc', dapui.close, { desc = "Close debug overlay" })
|
||||||
|
|||||||
@@ -21,6 +21,7 @@ vim.opt.rtp:prepend(lazypath)
|
|||||||
vim.g.mapleader = " "
|
vim.g.mapleader = " "
|
||||||
vim.g.maplocalleader = "\\"
|
vim.g.maplocalleader = "\\"
|
||||||
|
|
||||||
|
|
||||||
-- Setup lazy.nvim
|
-- Setup lazy.nvim
|
||||||
require("lazy").setup({
|
require("lazy").setup({
|
||||||
spec = {
|
spec = {
|
||||||
|
|||||||
48
packages/nvim/lua/plugins/blink-cmp.lua
Normal file
48
packages/nvim/lua/plugins/blink-cmp.lua
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
return {
|
||||||
|
'saghen/blink.cmp',
|
||||||
|
-- optional: provides snippets for the snippet source
|
||||||
|
dependencies = { 'rafamadriz/friendly-snippets' },
|
||||||
|
|
||||||
|
-- use a release tag to download pre-built binaries
|
||||||
|
version = '1.*',
|
||||||
|
-- AND/OR build from source, requires nightly: https://rust-lang.github.io/rustup/concepts/channels.html#working-with-nightly-rust
|
||||||
|
-- build = 'cargo build --release',
|
||||||
|
-- If you use nix, you can build from source using latest nightly rust with:
|
||||||
|
-- build = 'nix run .#build-plugin',
|
||||||
|
|
||||||
|
---@module 'blink.cmp'
|
||||||
|
---@type blink.cmp.Config
|
||||||
|
opts = {
|
||||||
|
-- See :h blink-cmp-config-keymap for defining your own keymap
|
||||||
|
keymap = {
|
||||||
|
preset = 'enter',
|
||||||
|
-- map tap to cycle through
|
||||||
|
['<S-Tab>'] = { 'select_prev', 'fallback' },
|
||||||
|
['<Tab>'] = { 'select_next', 'fallback' },
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
appearance = {
|
||||||
|
-- 'mono' (default) for 'Nerd Font Mono' or 'normal' for 'Nerd Font'
|
||||||
|
-- Adjusts spacing to ensure icons are aligned
|
||||||
|
nerd_font_variant = 'mono'
|
||||||
|
},
|
||||||
|
|
||||||
|
-- (Default) Only show the documentation popup when manually triggered
|
||||||
|
completion = { documentation = { auto_show = false } },
|
||||||
|
|
||||||
|
-- Default list of enabled providers defined so that you can extend it
|
||||||
|
-- elsewhere in your config, without redefining it, due to `opts_extend`
|
||||||
|
sources = {
|
||||||
|
default = { 'lsp', 'path', 'snippets', 'buffer' },
|
||||||
|
},
|
||||||
|
|
||||||
|
-- (Default) Rust fuzzy matcher for typo resistance and significantly better performance
|
||||||
|
-- You may use a lua implementation instead by using `implementation = "lua"` or fallback to the lua implementation,
|
||||||
|
-- when the Rust fuzzy matcher is not available, by using `implementation = "prefer_rust"`
|
||||||
|
--
|
||||||
|
-- See the fuzzy documentation for more information
|
||||||
|
fuzzy = { implementation = "prefer_rust_with_warning" }
|
||||||
|
},
|
||||||
|
opts_extend = { "sources.default" }
|
||||||
|
}
|
||||||
21
packages/nvim/lua/plugins/lazygit.lua
Normal file
21
packages/nvim/lua/plugins/lazygit.lua
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
-- nvim v0.8.0
|
||||||
|
return {
|
||||||
|
"kdheepak/lazygit.nvim",
|
||||||
|
lazy = true,
|
||||||
|
cmd = {
|
||||||
|
"LazyGit",
|
||||||
|
"LazyGitConfig",
|
||||||
|
"LazyGitCurrentFile",
|
||||||
|
"LazyGitFilter",
|
||||||
|
"LazyGitFilterCurrentFile",
|
||||||
|
},
|
||||||
|
-- optional for floating window border decoration
|
||||||
|
dependencies = {
|
||||||
|
"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>lg", "<cmd>LazyGit<cr>", desc = "LazyGit" }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,53 +1,30 @@
|
|||||||
local on_attach = function(_, bufnr)
|
return {
|
||||||
|
'neovim/nvim-lspconfig',
|
||||||
|
dependencies = { 'saghen/blink.cmp' },
|
||||||
|
|
||||||
local bufmap = function(keys, func)
|
-- example using `opts` for defining servers
|
||||||
vim.keymap.set('n', keys, func, { buffer = bufnr })
|
opts = {
|
||||||
|
servers = {
|
||||||
|
lua_ls = {},
|
||||||
|
nil_ls = {},
|
||||||
|
rust_analyzer = {}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
config = function(_, opts)
|
||||||
|
local lspconfig = require('lspconfig')
|
||||||
|
for server, config in pairs(opts.servers) do
|
||||||
|
-- passing config.capabilities to blink.cmp merges with the capabilities in your
|
||||||
|
-- `opts[server].capabilities, if you've defined it
|
||||||
|
config.capabilities = require('blink.cmp').get_lsp_capabilities(config.capabilities)
|
||||||
|
lspconfig[server].setup(config)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
bufmap('<leader>r', vim.lsp.buf.rename)
|
-- -- example calling setup directly for each LSP
|
||||||
bufmap('<leader>a', vim.lsp.buf.code_action)
|
-- config = function()
|
||||||
|
-- local capabilities = require('blink.cmp').get_lsp_capabilities()
|
||||||
bufmap('gd', vim.lsp.buf.definition)
|
-- local lspconfig = require('lspconfig')
|
||||||
bufmap('gD', vim.lsp.buf.declaration)
|
--
|
||||||
bufmap('gI', vim.lsp.buf.implementation)
|
-- lspconfig['lua_ls'].setup({ capabilities = capabilities })
|
||||||
bufmap('<leader>D', vim.lsp.buf.type_definition)
|
-- end
|
||||||
|
|
||||||
bufmap('gr', require('telescope.builtin').lsp_references)
|
|
||||||
bufmap('<leader>s', require('telescope.builtin').lsp_document_symbols)
|
|
||||||
bufmap('<leader>S', require('telescope.builtin').lsp_dynamic_workspace_symbols)
|
|
||||||
|
|
||||||
bufmap('K', vim.lsp.buf.hover)
|
|
||||||
|
|
||||||
vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_)
|
|
||||||
vim.lsp.buf.format()
|
|
||||||
end, {})
|
|
||||||
end
|
|
||||||
|
|
||||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
|
||||||
capabilities = require('coq').lsp_capabilities(capabilities) -- COQ spezifische Fähigkeiten
|
|
||||||
|
|
||||||
require('neodev').setup()
|
|
||||||
require('lspconfig').lua_ls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
root_dir = function()
|
|
||||||
return vim.loop.cwd()
|
|
||||||
end,
|
|
||||||
cmd = { "lua-language-server" },
|
|
||||||
settings = {
|
|
||||||
Lua = {
|
|
||||||
workspace = { checkThirdParty = false },
|
|
||||||
telemetry = { enable = false },
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
require('lspconfig').nil_ls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').rust_analyzer.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
37
packages/nvim/lua/plugins/mason.lua
Normal file
37
packages/nvim/lua/plugins/mason.lua
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
return {
|
||||||
|
|
||||||
|
"williamboman/mason.nvim",
|
||||||
|
cmd = "Mason",
|
||||||
|
keys = { { "<leader>cm", "<cmd>Mason<cr>", desc = "Mason" } },
|
||||||
|
build = ":MasonUpdate",
|
||||||
|
opts_extend = { "ensure_installed" },
|
||||||
|
opts = {
|
||||||
|
ensure_installed = {
|
||||||
|
"stylua",
|
||||||
|
"shfmt",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
---@param opts MasonSettings | {ensure_installed: string[]}
|
||||||
|
config = function(_, opts)
|
||||||
|
require("mason").setup(opts)
|
||||||
|
local mr = require("mason-registry")
|
||||||
|
mr:on("package:install:success", function()
|
||||||
|
vim.defer_fn(function()
|
||||||
|
-- trigger FileType event to possibly load this newly installed LSP server
|
||||||
|
require("lazy.core.handler.event").trigger({
|
||||||
|
event = "FileType",
|
||||||
|
buf = vim.api.nvim_get_current_buf(),
|
||||||
|
})
|
||||||
|
end, 100)
|
||||||
|
end)
|
||||||
|
|
||||||
|
mr.refresh(function()
|
||||||
|
for _, tool in ipairs(opts.ensure_installed) do
|
||||||
|
local p = mr.get_package(tool)
|
||||||
|
if not p:is_installed() then
|
||||||
|
p:install()
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end)
|
||||||
|
end,
|
||||||
|
}
|
||||||
@@ -38,7 +38,7 @@ window#waybar {
|
|||||||
margin-left: 6px;
|
margin-left: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#workspaces button.focused{
|
#workspaces button.active{
|
||||||
background: @mauve;
|
background: @mauve;
|
||||||
color: @base;
|
color: @base;
|
||||||
opacity: 0.8;
|
opacity: 0.8;
|
||||||
|
|||||||
Reference in New Issue
Block a user