wip: move various programs to nix
This commit is contained in:
parent
17a2a04b96
commit
f4e8c1725a
65 changed files with 2460 additions and 2229 deletions
|
|
@ -1,12 +1,10 @@
|
|||
{ lib
|
||||
, pkgs
|
||||
, ...
|
||||
{ ...
|
||||
}: {
|
||||
imports = [
|
||||
./login_manager.nix
|
||||
./big_g.nix
|
||||
./env.nix
|
||||
./xkb_layout.nix
|
||||
../hardware/streamdeck.nix
|
||||
./login_manager.nix
|
||||
./big_g.nix
|
||||
./env.nix
|
||||
./xkb_layout.nix
|
||||
../hardware/streamdeck.nix
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,23 +1,49 @@
|
|||
{pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
{ pkgs
|
||||
, ...
|
||||
}: {
|
||||
# greetd display manager
|
||||
services.greetd = let
|
||||
session = {
|
||||
command = "${pkgs.hyprland}/bin/Hyprland --config /home/dashie/.config/hypr/hyprgreet.conf";
|
||||
user = "dashie";
|
||||
services.greetd =
|
||||
let
|
||||
session = {
|
||||
command = "${pkgs.hyprland}/bin/Hyprland --config /home/dashie/.config/hypr/hyprgreet.conf";
|
||||
user = "dashie";
|
||||
};
|
||||
in
|
||||
{
|
||||
enable = true;
|
||||
settings = {
|
||||
terminal.vt = 1;
|
||||
default_session = session;
|
||||
initial_session = session;
|
||||
};
|
||||
};
|
||||
in {
|
||||
programs.regreet = {
|
||||
enable = true;
|
||||
settings = {
|
||||
terminal.vt = 1;
|
||||
default_session = session;
|
||||
initial_session = session;
|
||||
|
||||
background = {
|
||||
fit = "Contain";
|
||||
};
|
||||
|
||||
env = {
|
||||
QT_QPA_PLATFORMTHEME = "qt5ct";
|
||||
PATH = "/home/dashie/.cargo/bin:PATH";
|
||||
};
|
||||
|
||||
GTK = {
|
||||
application_prefer_dark_theme = true;
|
||||
cursor_theme_name = "Adwaita";
|
||||
icon_theme_name = "Adwaita";
|
||||
theme_name = "adw-gtk3";
|
||||
|
||||
command = {
|
||||
reboot = [ "systemctl" "reboot" ];
|
||||
|
||||
poweroff = [ "systemctl" "poweroff" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
programs.regreet.enable = true;
|
||||
|
||||
# unlock GPG keyring on login
|
||||
security.pam.services.greetd.enableGnomeKeyring = true;
|
||||
|
|
|
|||
134
nix/flake.lock
generated
134
nix/flake.lock
generated
|
|
@ -47,6 +47,27 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"crane": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"ironbar",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1711681752,
|
||||
"narHash": "sha256-LEg6/dmEFxx6Ygti5DO9MOhGNpyB7zdxdWtzv/FCTXk=",
|
||||
"owner": "ipetkov",
|
||||
"repo": "crane",
|
||||
"rev": "ada0fb4dcce4561acb1eb17c59b7306d9d4a95f3",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "ipetkov",
|
||||
"repo": "crane",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": [
|
||||
|
|
@ -68,6 +89,24 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"inputs": {
|
||||
"systems": "systems_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1705309234,
|
||||
"narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
|
|
@ -221,6 +260,47 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"ironbar": {
|
||||
"inputs": {
|
||||
"crane": "crane",
|
||||
"naersk": "naersk",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"rust-overlay": "rust-overlay"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1713218218,
|
||||
"narHash": "sha256-f2GOHnoLe9PeVI0Itvm0RVPxc102ZdHabNDYUxoL/RY=",
|
||||
"owner": "JakeStanger",
|
||||
"repo": "ironbar",
|
||||
"rev": "3fea6e3254a8cda16b32443d1f8f3282218b07c5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "JakeStanger",
|
||||
"repo": "ironbar",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"naersk": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1698420672,
|
||||
"narHash": "sha256-/TdeHMPRjjdJub7p7+w55vyABrsJlt5QkznPYy55vKA=",
|
||||
"owner": "nix-community",
|
||||
"repo": "naersk",
|
||||
"rev": "aeb58d5e8faead8980a807c840232697982d47b9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "naersk",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-flatpak": {
|
||||
"locked": {
|
||||
"lastModified": 1711997375,
|
||||
|
|
@ -237,6 +317,20 @@
|
|||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1711715736,
|
||||
"narHash": "sha256-9slQ609YqT9bT/MNX9+5k5jltL9zgpn36DpFB7TkttM=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "807c549feabce7eddbf259dbdcec9e0600a0660d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "nixpkgs",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1713088362,
|
||||
"narHash": "sha256-ttDSOqkEBinjA1dlMWkBjaXzTqjiAPt5lNkoONbz25Y=",
|
||||
|
|
@ -257,8 +351,31 @@
|
|||
"anyrun": "anyrun",
|
||||
"home-manager": "home-manager",
|
||||
"hyprland": "hyprland",
|
||||
"ironbar": "ironbar",
|
||||
"nix-flatpak": "nix-flatpak",
|
||||
"nixpkgs": "nixpkgs"
|
||||
"nixpkgs": "nixpkgs_2"
|
||||
}
|
||||
},
|
||||
"rust-overlay": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": [
|
||||
"ironbar",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1711851236,
|
||||
"narHash": "sha256-EJ03x3N9ihhonAttkaCrqxb0djDq3URCuDpmVPbNZhA=",
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"rev": "f258266af947599e8069df1c2e933189270f143a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
|
|
@ -276,6 +393,21 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems_2": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"wlroots": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
|
|
|
|||
|
|
@ -17,12 +17,16 @@
|
|||
url = "github:KZDKM/Hyprspace";
|
||||
inputs.hyprland.follows = "hyprland";
|
||||
};
|
||||
ironbar = {
|
||||
url = "github:JakeStanger/ironbar";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
anyrun.url = "github:Kirottu/anyrun";
|
||||
anyrun.inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
outputs = inputs @ { self, nixpkgs, home-manager, nix-flatpak, hyprland, anyrun, ... }:
|
||||
outputs = inputs @ { self, nixpkgs, home-manager, nix-flatpak, hyprland, anyrun, ironbar, ... }:
|
||||
let
|
||||
pkgs = import nixpkgs {
|
||||
system = "x86_64-linux";
|
||||
|
|
@ -68,6 +72,7 @@
|
|||
./programs/default.nix
|
||||
hyprland.homeManagerModules.default
|
||||
anyrun.homeManagerModules.default
|
||||
ironbar.homeManagerModules.default
|
||||
./programs/hyprland/default.nix #{inherit Hyprspace; }
|
||||
nix-flatpak.homeManagerModules.nix-flatpak
|
||||
./programs/flatpak.nix
|
||||
|
|
|
|||
170
nix/nvim/default.nix
Normal file
170
nix/nvim/default.nix
Normal file
|
|
@ -0,0 +1,170 @@
|
|||
{ lib, pkgs, ... }:
|
||||
{
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
extraPackages = with pkgs; [
|
||||
# Telescope
|
||||
ripgrep
|
||||
# lua
|
||||
lua-language-server
|
||||
stylua
|
||||
# nix
|
||||
nil
|
||||
# go
|
||||
gopls
|
||||
# jafuck
|
||||
jdt-language-server
|
||||
taplo
|
||||
typst-lsp
|
||||
sqls
|
||||
shfmt
|
||||
texlab
|
||||
nixpkgs-fmt
|
||||
crate2nix
|
||||
ruff-lsp
|
||||
nodePackages.pyright
|
||||
lemminx
|
||||
marksman
|
||||
clang-tools_18
|
||||
];
|
||||
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
lazy-nvim
|
||||
];
|
||||
|
||||
extraLuaConfig =
|
||||
let
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
# LazyVim
|
||||
LazyVim
|
||||
bufferline-nvim
|
||||
cmp-buffer
|
||||
cmp-nvim-lsp
|
||||
cmp-path
|
||||
cmp_luasnip
|
||||
conform-nvim
|
||||
dashboard-nvim
|
||||
dressing-nvim
|
||||
flash-nvim
|
||||
friendly-snippets
|
||||
gitsigns-nvim
|
||||
indent-blankline-nvim
|
||||
lualine-nvim
|
||||
neo-tree-nvim
|
||||
neoconf-nvim
|
||||
neodev-nvim
|
||||
noice-nvim
|
||||
nui-nvim
|
||||
nvim-cmp
|
||||
nvim-lint
|
||||
nvim-lspconfig
|
||||
nvim-notify
|
||||
nvim-spectre
|
||||
nvim-treesitter
|
||||
nvim-treesitter-context
|
||||
nvim-treesitter-textobjects
|
||||
nvim-ts-autotag
|
||||
nvim-ts-context-commentstring
|
||||
nvim-web-devicons
|
||||
persistence-nvim
|
||||
plenary-nvim
|
||||
telescope-fzf-native-nvim
|
||||
telescope-nvim
|
||||
todo-comments-nvim
|
||||
tokyonight-nvim
|
||||
trouble-nvim
|
||||
vim-illuminate
|
||||
vim-startuptime
|
||||
which-key-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" },
|
||||
{ import = "lazyvim.plugins.extras.ui.alpha" },
|
||||
{ import = "plugins" },
|
||||
{ import = "plugins.plugins" },
|
||||
{ import = "lazyvim.plugins.extras.lang.rust" },
|
||||
{ import = "lazyvim.plugins.extras.lang.tailwind" },
|
||||
{ import = "lazyvim.plugins.extras.lang.java" },
|
||||
{ import = "lazyvim.plugins.extras.lang.go" },
|
||||
{ import = "lazyvim.plugins.extras.lang.clangd" },
|
||||
{ import = "lazyvim.plugins.extras.lang.typescript" },
|
||||
{ import = "lazyvim.plugins.extras.lang.python" },
|
||||
{ import = "lazyvim.plugins.extras.lang.markdown" },
|
||||
{ import = "lazyvim.plugins.extras.lang.cmake" },
|
||||
{ import = "lazyvim.plugins.extras.lang.omnisharp" },
|
||||
{ import = "lazyvim.plugins.extras.lang.json" },
|
||||
{ import = "lazyvim.plugins.extras.lang.tex" },
|
||||
{ import = "lazyvim.plugins.extras.util.dot" },
|
||||
{ import = "lazyvim.plugins.extras.dap.core" },
|
||||
{ import = "lazyvim.plugins.extras.test.core" },
|
||||
{ "nvim-telescope/telescope-fzf-native.nvim", enabled = true },
|
||||
-- disable mason.nvim, use programs.neovim.extraPackages
|
||||
{ "williamboman/mason-lspconfig.nvim", enabled = false },
|
||||
{ "williamboman/mason.nvim", enabled = false },
|
||||
-- import/override with your plugins
|
||||
{ import = "plugins" },
|
||||
-- treesitter handled by xdg.configFile."nvim/parser", put this line at the end of spec to clear ensure_installed
|
||||
{ "nvim-treesitter/nvim-treesitter", opts = { ensure_installed = {} } },
|
||||
},
|
||||
install = { colorscheme = { "tokyonight" } },
|
||||
checker = { enabled = true, notify = false },
|
||||
change_detection = { enabled = true, notify = false },
|
||||
performance = {
|
||||
rtp = {
|
||||
disabled_plugins = {
|
||||
"gzip",
|
||||
"netrw",
|
||||
"tarPlugin",
|
||||
"tohtml",
|
||||
"tutor",
|
||||
"zipPlugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
'';
|
||||
};
|
||||
|
||||
# https://github.com/nvim-treesitter/nvim-treesitter#i-get-query-error-invalid-node-type-at-position
|
||||
xdg.configFile."nvim/parser".source =
|
||||
let
|
||||
parsers = pkgs.symlinkJoin {
|
||||
name = "treesitter-parsers";
|
||||
paths = (pkgs.vimPlugins.nvim-treesitter.withPlugins (plugins: with plugins; [
|
||||
c
|
||||
lua
|
||||
])).dependencies;
|
||||
};
|
||||
in
|
||||
"${parsers}/parser";
|
||||
|
||||
# Normal LazyVim config here, see https://github.com/LazyVim/starter/tree/main/lua
|
||||
xdg.configFile."nvim/lua".source = ./lua;
|
||||
}
|
||||
201
nix/nvim/lua/config/keymaps.lua
Normal file
201
nix/nvim/lua/config/keymaps.lua
Normal file
|
|
@ -0,0 +1,201 @@
|
|||
local Util = require("lazyvim.util")
|
||||
|
||||
local function map(mode, lhs, rhs, opts)
|
||||
local keys = require("lazy.core.handler").handlers.keys
|
||||
---@cast keys LazyKeysHandler
|
||||
-- do not create the map if a lazy keys handler exists
|
||||
if not keys.active[keys.parse({ lhs, mode = mode }).id] then
|
||||
opts = opts or {}
|
||||
opts.silent = opts.silent ~= false
|
||||
vim.keymap.set(mode, lhs, rhs, opts)
|
||||
end
|
||||
end
|
||||
local opts = { noremap = true, silent = true }
|
||||
local term_opts = { silent = true }
|
||||
|
||||
-- crimes against humanity, but I don't care
|
||||
map("n", "j", "h", opts)
|
||||
map("n", "l", "k", opts)
|
||||
map("n", "k", "j", opts)
|
||||
map("n", ";", "l", opts)
|
||||
map("v", "j", "h", opts)
|
||||
map("v", "k", "j", opts)
|
||||
map("v", "l", "k", opts)
|
||||
map("v", ";", "l", opts)
|
||||
|
||||
-- test plugin
|
||||
map("n", "<leader>OO", ':lua require("test_plugin").test()<CR>', { desc = "Toggle breakpoint" })
|
||||
|
||||
-- debug
|
||||
map("n", "<leader>db", ':lua require("dap").toggle_breakpoint()<CR>', { desc = "Toggle breakpoint" })
|
||||
map("n", "<leader>do", ':lua require("dap").step_over()<CR>', { desc = "Step over" })
|
||||
map("n", "<leader>di", ':lua require("dap").step_into()<CR>', { desc = "Step into" })
|
||||
map("n", "<leader>dc", ':lua require("dap").continue()<CR>', { desc = "Continue" })
|
||||
map("n", "<leader>du", function()
|
||||
require("dapui").toggle()
|
||||
end, { desc = "Toggle DAP UI" })
|
||||
map("n", "<leader>de", function()
|
||||
require("dapui").eval()
|
||||
end, { desc = "DAP Eval" })
|
||||
|
||||
-- window movement
|
||||
map("n", "<A-j>", [[<Cmd>wincmd h<CR>]], opts)
|
||||
map("n", "<A-;>", [[<Cmd>wincmd l<CR>]], opts)
|
||||
map("n", "<A-t>", [[<Cmd>wincmd j<CR>]], opts)
|
||||
map("i", "<A-j>", [[<Cmd>wincmd h<CR>]], opts)
|
||||
map("i", "<A-;>", [[<Cmd>wincmd l<CR>]], opts)
|
||||
map("i", "<A-k>", [[<Cmd>wincmd j<CR>]], opts)
|
||||
|
||||
-- toggle terminal
|
||||
local lazyterm = function()
|
||||
Util.terminal(nil, { cwd = Util.root(), esc_esc = false, ctrl_hjkl = false })
|
||||
end
|
||||
map("n", "<c-t>", lazyterm, { desc = "Terminal (root dir)" })
|
||||
map("t", "<c-t>", "<cmd>close<cr>", { desc = "Hide Terminal" })
|
||||
|
||||
-- semicolon thing
|
||||
-- map("i","<C-m>" ,"<C-o>A;<CR>", {desc = "add semi and newline"})
|
||||
-- map("i","<C-n>" ,"<C-o>A;<ESC>", {desc = "add semi"})
|
||||
map("n", "<leader>m", "$a;<CR>", { desc = "add semi and newline" })
|
||||
map("n", "<leader>n", "$a;<ESC>", { desc = "add semi" })
|
||||
|
||||
-- tab switching
|
||||
map("n", "<F1>", ":BufferLineCyclePrev<CR>", opts)
|
||||
map("n", "<F2>", ":BufferLineCycleNext<CR>", opts)
|
||||
|
||||
-- git
|
||||
map("n", "<leader>gq", function()
|
||||
require("telescope.builtin").git_commits()
|
||||
end, { desc = "Commits" })
|
||||
map("n", "<leader>gw", function()
|
||||
require("telescope.builtin").git_bcommits()
|
||||
end, { desc = "Commits in branch" })
|
||||
map("n", "<leader>gb", function()
|
||||
require("telescope.builtin").git_branches()
|
||||
end, { desc = "Branches" })
|
||||
map("n", "<leader>gr", function()
|
||||
require("telescope.builtin").git_status()
|
||||
end, { desc = "Git status" })
|
||||
map("n", "<leader>ga", function()
|
||||
require("telescope.builtin").git_stash()
|
||||
end, { desc = "Git stash" })
|
||||
map("n", "<leader>gg", function()
|
||||
Util.terminal({ "gitui" }, { cwd = Util.root() })
|
||||
end, { desc = "gitui (root dir)" })
|
||||
map("n", "<leader>gG", function()
|
||||
Util.terminal({ "gitui" })
|
||||
end, { desc = "gitui (cwd)" })
|
||||
map("n", "<leader>gB", function()
|
||||
require("gitblame")
|
||||
vim.cmd(":GitBlameToggle")
|
||||
end, { desc = "git blame" })
|
||||
|
||||
-- harpoon man
|
||||
map("n", "<leader>h1", function()
|
||||
require("harpoon.ui").nav_file(1)
|
||||
end, { desc = "First Harpoon File" })
|
||||
map("n", "<leader>h2", function()
|
||||
require("harpoon.ui").nav_file(2)
|
||||
end, { desc = "Second Harpoon File" })
|
||||
map("n", "<leader>h3", function()
|
||||
require("harpoon.ui").nav_file(3)
|
||||
end, { desc = "First Harpoon File" })
|
||||
map("n", "<leader>ha", function()
|
||||
require("harpoon.mark").add_file()
|
||||
end, { desc = "First Harpoon File" })
|
||||
map("n", "<leader>hd", function()
|
||||
require("harpoon.mark").remove_file()
|
||||
end, { desc = "First Harpoon File" })
|
||||
map("n", "<leader>hm", ":Telescope harpoon marks<CR>", { noremap = true, silent = true, desc = "Show harpoon marks" })
|
||||
|
||||
-- telescope
|
||||
map("n", "<leader>fb", function()
|
||||
require("telescope").extensions.file_browser.file_browser({})
|
||||
end, { desc = "File Browser" })
|
||||
map("n", "<leader>ff", function()
|
||||
require("telescope.builtin").find_files()
|
||||
end, { desc = "Find Files" })
|
||||
map("n", "<leader>fg", function()
|
||||
Live_grep_from_project_git_root()
|
||||
end, { desc = "Live Grep (root)" })
|
||||
map("n", "<leader>fG", function()
|
||||
require("telescope.builtin").live_grep()
|
||||
end, { desc = "Live Grep (cwd)" })
|
||||
map("n", "<leader>fh", function()
|
||||
require("telescope.builtin").help_tags()
|
||||
end, { desc = "Help" })
|
||||
map("n", "<leader>fp", function()
|
||||
require("telescope").extensions.project.project({})
|
||||
end, { noremap = true, silent = true, desc = "Projects" })
|
||||
map("n", "<leader>z", function()
|
||||
require("telescope").extensions.zoxide.list({})
|
||||
end, { desc = "Zoxide" })
|
||||
|
||||
-- neoscroll
|
||||
local t = {}
|
||||
t["<A-l>"] = { "scroll", { "-vim.wo.scroll", "true", "250" } }
|
||||
t["<A-k>"] = { "scroll", { "vim.wo.scroll", "true", "250" } }
|
||||
require("neoscroll.config").set_mappings(t)
|
||||
|
||||
-- trouble
|
||||
map("n", "<leader>t", "<cmd>TroubleToggle<CR>", term_opts)
|
||||
|
||||
-- format
|
||||
map({ "n", "v" }, "<F4>", function()
|
||||
Util.format({ force = true })
|
||||
end, { desc = "Format" })
|
||||
|
||||
-- better yank
|
||||
function Better_yank(opts)
|
||||
local current_line = unpack(vim.api.nvim_win_get_cursor(0))
|
||||
vim.api.nvim_command(current_line .. "," .. (opts.count - (current_line - 1)) .. "y")
|
||||
end
|
||||
|
||||
vim.api.nvim_create_user_command("BetterYank", Better_yank, { count = 1 })
|
||||
map("n", "by", ":BetterYank<CR>", term_opts)
|
||||
|
||||
-- better delete
|
||||
function Better_delete(opts)
|
||||
local current_line = unpack(vim.api.nvim_win_get_cursor(0))
|
||||
vim.api.nvim_command(current_line .. "," .. (opts.count - (current_line - 1)) .. "d")
|
||||
end
|
||||
|
||||
vim.api.nvim_create_user_command("BetterDelete", Better_delete, { count = 1 })
|
||||
map("n", "bd", ":BetterDelete<CR>", term_opts)
|
||||
|
||||
-- neovide zoom
|
||||
local change_scale_factor = function(delta)
|
||||
vim.g.neovide_scale_factor = vim.g.neovide_scale_factor * delta
|
||||
end
|
||||
vim.keymap.set("n", "<C-=>", function()
|
||||
change_scale_factor(1.25)
|
||||
end)
|
||||
vim.keymap.set("n", "<C-->", function()
|
||||
change_scale_factor(1 / 1.25)
|
||||
end)
|
||||
|
||||
-- neovide paste
|
||||
vim.g.neovide_input_use_logo = 1
|
||||
vim.api.nvim_set_keymap("i", "<C-S-V>", "<ESC>p<CR>I", { noremap = true, silent = true })
|
||||
|
||||
function Get_git_root()
|
||||
local opts = {}
|
||||
local function is_git_repo()
|
||||
vim.fn.system("git rev-parse --is-inside-work-tree")
|
||||
|
||||
return vim.v.shell_error == 0
|
||||
end
|
||||
if is_git_repo() then
|
||||
local dot_git_path = vim.fn.finddir(".git", ".;")
|
||||
local root = vim.fn.fnamemodify(dot_git_path, ":h")
|
||||
opts = {
|
||||
cwd = root,
|
||||
}
|
||||
end
|
||||
return opts
|
||||
end
|
||||
|
||||
function Live_grep_from_project_git_root()
|
||||
local opts = Get_git_root()
|
||||
require("telescope.builtin").live_grep(opts)
|
||||
end
|
||||
56
nix/nvim/lua/config/lazy.lua
Normal file
56
nix/nvim/lua/config/lazy.lua
Normal file
|
|
@ -0,0 +1,56 @@
|
|||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||
if not vim.loop.fs_stat(lazypath) then
|
||||
vim.fn.system({
|
||||
"git",
|
||||
"clone",
|
||||
"--filter=blob:none",
|
||||
"https://github.com/folke/lazy.nvim.git",
|
||||
"--branch=stable",
|
||||
lazypath,
|
||||
})
|
||||
end
|
||||
vim.opt.rtp:prepend(vim.env.LAZY or lazypath)
|
||||
|
||||
require("lazy").setup({
|
||||
spec = {
|
||||
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
|
||||
{ import = "lazyvim.plugins.extras.ui.alpha" },
|
||||
-- { import = "lazyvim.plugins.extras.ui.edgy" },
|
||||
{ import = "plugins" },
|
||||
{ import = "plugins.plugins" },
|
||||
{ import = "lazyvim.plugins.extras.lang.rust" },
|
||||
{ import = "lazyvim.plugins.extras.lang.tailwind" },
|
||||
{ import = "lazyvim.plugins.extras.lang.java" },
|
||||
{ import = "lazyvim.plugins.extras.lang.go" },
|
||||
{ import = "lazyvim.plugins.extras.lang.clangd" },
|
||||
{ import = "lazyvim.plugins.extras.lang.typescript" },
|
||||
{ import = "lazyvim.plugins.extras.lang.python" },
|
||||
{ import = "lazyvim.plugins.extras.lang.markdown" },
|
||||
{ import = "lazyvim.plugins.extras.lang.cmake" },
|
||||
{ import = "lazyvim.plugins.extras.lang.omnisharp" },
|
||||
{ import = "lazyvim.plugins.extras.lang.json" },
|
||||
{ import = "lazyvim.plugins.extras.lang.tex" },
|
||||
{ import = "lazyvim.plugins.extras.util.dot" },
|
||||
{ import = "lazyvim.plugins.extras.dap.core" },
|
||||
{ import = "lazyvim.plugins.extras.test.core" },
|
||||
},
|
||||
defaults = {
|
||||
lazy = true,
|
||||
version = false,
|
||||
},
|
||||
install = { colorscheme = { "tokyonight", "catppuccin-mocha" } },
|
||||
checker = { enabled = true, notify = false },
|
||||
change_detection = { enabled = true, notify = false },
|
||||
performance = {
|
||||
rtp = {
|
||||
disabled_plugins = {
|
||||
"gzip",
|
||||
"netrw",
|
||||
"tarPlugin",
|
||||
"tohtml",
|
||||
"tutor",
|
||||
"zipPlugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
126
nix/nvim/lua/config/lsp-keymap.lua
Normal file
126
nix/nvim/lua/config/lsp-keymap.lua
Normal file
|
|
@ -0,0 +1,126 @@
|
|||
local M = {}
|
||||
|
||||
---@type PluginLspKeys
|
||||
M._keys = nil
|
||||
|
||||
---@return (LazyKeys|{has?:string})[]
|
||||
function M.get()
|
||||
local format = function()
|
||||
require("lazyvim.util").format({ force = true })
|
||||
end
|
||||
if not M._keys then
|
||||
---@class PluginLspKeys
|
||||
M._keys = {
|
||||
{ "<leader>cld", vim.diagnostic.open_float, desc = "Line Diagnostics" },
|
||||
{ "<leader>cl", "<cmd>LspInfo<cr>", desc = "Lsp Info" },
|
||||
{ "<leader>ca", "<cmd>Telescope lsp_definitions<cr>", desc = "Goto Definition", has = "definition" },
|
||||
{ "<leader>cs", "<cmd>Telescope lsp_references<cr>", desc = "References" },
|
||||
{ "<leader>cA", vim.lsp.buf.declaration, desc = "Goto Declaration" },
|
||||
{ "<leader>cf", "<cmd>Telescope lsp_implementations<cr>", desc = "Goto Implementation" },
|
||||
{ "<leader>cd", "<cmd>Telescope lsp_type_definitions<cr>", desc = "Goto Type Definition" },
|
||||
{ "<leader>ce", vim.lsp.buf.hover, desc = "Hover" },
|
||||
{ "<leader>cw", vim.lsp.buf.signature_help, desc = "Signature Help", has = "signatureHelp" },
|
||||
{ "<c-k>", vim.lsp.buf.signature_help, mode = "i", desc = "Signature Help", has = "signatureHelp" },
|
||||
{ "]d", M.diagnostic_goto(true), desc = "Next Diagnostic" },
|
||||
{ "[d", M.diagnostic_goto(false), desc = "Prev Diagnostic" },
|
||||
{ "]e", M.diagnostic_goto(true, "ERROR"), desc = "Next Error" },
|
||||
{ "[e", M.diagnostic_goto(false, "ERROR"), desc = "Prev Error" },
|
||||
{ "]w", M.diagnostic_goto(true, "WARN"), desc = "Next Warning" },
|
||||
{ "[w", M.diagnostic_goto(false, "WARN"), desc = "Prev Warning" },
|
||||
{ "<F4>", format, desc = "Format Range", mode = "v", has = "documentRangeFormatting" },
|
||||
{ "<leader>cr", ":IncRename ", desc = "Rename", has = "rename" },
|
||||
{
|
||||
"<leader>cq",
|
||||
function()
|
||||
vim.lsp.buf.code_action({
|
||||
context = {
|
||||
only = {
|
||||
"quickfix",
|
||||
"quickfix.ltex",
|
||||
"source",
|
||||
"source.fixAll",
|
||||
"source.organizeImports",
|
||||
"",
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
desc = "Fix",
|
||||
mode = { "n", "v" },
|
||||
has = "codeAction",
|
||||
},
|
||||
{
|
||||
"<leader>cQ",
|
||||
function()
|
||||
vim.lsp.buf.code_action({
|
||||
context = {
|
||||
only = {
|
||||
"refactor",
|
||||
"refactor.inline",
|
||||
"refactor.extract",
|
||||
"refactor.rewrite",
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
desc = "Refactor",
|
||||
mode = { "n", "v" },
|
||||
has = "codeAction",
|
||||
},
|
||||
}
|
||||
end
|
||||
return M._keys
|
||||
end
|
||||
|
||||
---@param method string
|
||||
function M.has(buffer, method)
|
||||
method = method:find("/") and method or "textDocument/" .. method
|
||||
local clients = require("lazyvim.util").lsp.get_clients({ bufnr = buffer })
|
||||
for _, client in ipairs(clients) do
|
||||
if client.supports_method(method) then
|
||||
return true
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
---@return (LazyKeys|{has?:string})[]
|
||||
function M.resolve(buffer)
|
||||
local Keys = require("lazy.core.handler.keys")
|
||||
if not Keys.resolve then
|
||||
return {}
|
||||
end
|
||||
local spec = M.get()
|
||||
local opts = require("lazyvim.util").opts("nvim-lspconfig")
|
||||
local clients = require("lazyvim.util").lsp.get_clients({ bufnr = buffer })
|
||||
for _, client in ipairs(clients) do
|
||||
local maps = opts.servers[client.name] and opts.servers[client.name].keys or {}
|
||||
vim.list_extend(spec, maps)
|
||||
end
|
||||
return Keys.resolve(spec)
|
||||
end
|
||||
|
||||
function M.on_attach(_, buffer)
|
||||
local Keys = require("lazy.core.handler.keys")
|
||||
local keymaps = M.resolve(buffer)
|
||||
|
||||
for _, keys in pairs(keymaps) do
|
||||
if not keys.has or M.has(buffer, keys.has) then
|
||||
local opts = Keys.opts(keys)
|
||||
opts.has = nil
|
||||
opts.silent = opts.silent ~= false
|
||||
opts.buffer = buffer
|
||||
vim.keymap.set(keys.mode or "n", keys.lhs, keys.rhs, opts)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function M.diagnostic_goto(next, severity)
|
||||
local go = next and vim.diagnostic.goto_next or vim.diagnostic.goto_prev
|
||||
severity = severity and vim.diagnostic.severity[severity] or nil
|
||||
return function()
|
||||
go({ severity = severity })
|
||||
end
|
||||
end
|
||||
|
||||
return M
|
||||
25
nix/nvim/lua/config/options.lua
Normal file
25
nix/nvim/lua/config/options.lua
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
-- Options are automatically loaded before lazy.nvim startup
|
||||
-- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua
|
||||
-- Add any additional options here
|
||||
local options = {
|
||||
fileencoding = "utf-8",
|
||||
number = true,
|
||||
showmode = true,
|
||||
termguicolors = true,
|
||||
spelllang = "en_us",
|
||||
shell = "fish",
|
||||
relativenumber = false,
|
||||
scrolloff = 5,
|
||||
scrolljump = 5,
|
||||
wrap = false,
|
||||
}
|
||||
vim.o.guifont = "JetBrainsMono Nerd Font:h14"
|
||||
vim.g.neovide_refresh_rate_idle = 180
|
||||
vim.g.neovide_refresh_rate_idle = 5
|
||||
vim.g.neovide_hide_mouse_when_typing = true
|
||||
vim.g.mkdp_browser = "/usr/bin/firefox"
|
||||
vim.g.mkdp_auto_start = 1
|
||||
vim.g.autoformat = false
|
||||
for k, v in pairs(options) do
|
||||
vim.opt[k] = v
|
||||
end
|
||||
302
nix/nvim/lua/config/plugins.lua
Normal file
302
nix/nvim/lua/config/plugins.lua
Normal file
|
|
@ -0,0 +1,302 @@
|
|||
local Util = require("lazyvim.util")
|
||||
|
||||
return {
|
||||
{
|
||||
"LazyVim/LazyVim",
|
||||
opts = {
|
||||
colorscheme = "tokyonight-night",
|
||||
-- colorscheme = "catppuccin-mocha",
|
||||
},
|
||||
},
|
||||
{
|
||||
"nvim-telescope/telescope.nvim",
|
||||
cmd = "Telescope",
|
||||
keys = function()
|
||||
return {}
|
||||
end,
|
||||
opts = {
|
||||
defaults = {
|
||||
layout_strategy = 'flex';
|
||||
layout_config = {
|
||||
flex = {
|
||||
height = 0.95,
|
||||
width = 0.95,
|
||||
flip_columns = 100,
|
||||
vertical = { preview_height = 0.5, preview_cutoff = 5 },
|
||||
horizontal = { preview_width = 0.7, preview_cutoff = 99 },
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"ThePrimeagen/harpoon",
|
||||
lazy = true,
|
||||
config = function()
|
||||
require("telescope").load_extension("harpoon")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"iamcco/markdown-preview.nvim",
|
||||
lazy = true,
|
||||
event = "FileType markdown",
|
||||
build = "cd app && yarn install",
|
||||
},
|
||||
{
|
||||
"nvim-telescope/telescope-project.nvim",
|
||||
lazy = true,
|
||||
},
|
||||
{
|
||||
"nvim-telescope/telescope-file-browser.nvim",
|
||||
lazy = true,
|
||||
config = function()
|
||||
require("telescope").load_extension("file_browser")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"jvgrootveld/telescope-zoxide",
|
||||
lazy = true,
|
||||
config = function()
|
||||
local z_utils = require("telescope._extensions.zoxide.utils")
|
||||
local t = require("telescope")
|
||||
-- Configure the extension
|
||||
t.setup({
|
||||
extensions = {
|
||||
zoxide = {
|
||||
prompt_title = "[ Queries ]",
|
||||
mappings = {
|
||||
default = {
|
||||
after_action = function(selection)
|
||||
print("Update to (" .. selection.z_score .. ") " .. selection.path)
|
||||
end,
|
||||
},
|
||||
["<C-s>"] = {
|
||||
before_action = function(selection)
|
||||
print("before C-s")
|
||||
end,
|
||||
action = function(selection)
|
||||
vim.cmd("edit " .. selection.path)
|
||||
end,
|
||||
},
|
||||
["<C-q>"] = { action = z_utils.create_basic_command("split") },
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
-- Load the extension
|
||||
t.load_extension("zoxide")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"lervag/vimtex",
|
||||
config = function()
|
||||
vim.cmd("let g:vimtex_quickfix_mode=0")
|
||||
vim.cmd("let g:vimtex_view_general_viewer = 'evince'")
|
||||
vim.cmd("let g:vimtex_compiler_method = 'latexmk'")
|
||||
vim.cmd(
|
||||
"let g:vimtex_compiler_latexmk = {'options': ['-pdf', '-shell-escape', '-file-line-error', '--extra-mem-bot=10000000', '-synctex=1', '-interaction=nonstopmode',],}"
|
||||
)
|
||||
end,
|
||||
},
|
||||
{
|
||||
"rcarriga/nvim-notify",
|
||||
opts = {
|
||||
top_down = false,
|
||||
},
|
||||
},
|
||||
{
|
||||
"jbyuki/instant.nvim",
|
||||
config = function()
|
||||
vim.cmd("let g:instant_username = 'dashie'")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = {
|
||||
textobjects = {
|
||||
select = {
|
||||
enable = true,
|
||||
lookahead = true,
|
||||
keymaps = {
|
||||
-- You can use the capture groups defined in textobjects.scm
|
||||
["af"] = "@function.outer",
|
||||
["if"] = "@function.inner",
|
||||
["ac"] = "@class.outer",
|
||||
["ic"] = "@class.inner",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"karb94/neoscroll.nvim",
|
||||
config = function()
|
||||
require("neoscroll").setup()
|
||||
end,
|
||||
},
|
||||
{
|
||||
"kaarmu/typst.vim",
|
||||
lazy = true,
|
||||
event = "FileType typst",
|
||||
},
|
||||
{
|
||||
"folke/which-key.nvim",
|
||||
event = "VeryLazy",
|
||||
opts = {
|
||||
plugins = { spelling = true },
|
||||
defaults = {
|
||||
mode = { "n", "v" },
|
||||
["g"] = { name = "+goto" },
|
||||
["gz"] = { name = "+surround" },
|
||||
["]"] = { name = "+next" },
|
||||
["["] = { name = "+prev" },
|
||||
["<leader><tab>"] = { name = "+tabs" },
|
||||
["<leader>b"] = { name = "+buffer" },
|
||||
["<leader>c"] = { name = "+code" },
|
||||
["<leader>f"] = { name = "+file/find" },
|
||||
["<leader>g"] = { name = "+git" },
|
||||
["<leader>gh"] = { name = "+hunks" },
|
||||
["<leader>q"] = { name = "+quit/session" },
|
||||
["<leader>s"] = { name = "+search" },
|
||||
["<leader>u"] = { name = "+ui" },
|
||||
["<leader>w"] = { name = "+windows" },
|
||||
["<leader>x"] = { name = "+diagnostics/quickfix" },
|
||||
["<leader>h"] = { name = "+harpoon" },
|
||||
["<leader>d"] = { name = "+DAP" },
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
local wk = require("which-key")
|
||||
wk.setup(opts)
|
||||
wk.register(opts.defaults)
|
||||
end,
|
||||
},
|
||||
{
|
||||
"f-person/git-blame.nvim",
|
||||
lazy = true,
|
||||
},
|
||||
{
|
||||
"mg979/vim-visual-multi",
|
||||
},
|
||||
{
|
||||
"barreiroleo/ltex_extra.nvim",
|
||||
ft = { "markdown", "tex", "typst", "typ" },
|
||||
lazy = true,
|
||||
},
|
||||
{
|
||||
"smjonas/inc-rename.nvim",
|
||||
lazy = true,
|
||||
event = "BufEnter",
|
||||
config = function()
|
||||
require("inc_rename").setup({
|
||||
cmd_name = "IncRename", -- the name of the command
|
||||
hl_group = "Substitute", -- the highlight group used for highlighting the identifier's new name
|
||||
preview_empty_name = true, -- whether an empty new name should be previewed; if false the command preview will be cancelled instead
|
||||
show_message = true, -- whether to display a `Renamed m instances in n files` message after a rename operation
|
||||
input_buffer_type = nil, -- the type of the external input buffer to use (the only supported value is currently "dressing")
|
||||
post_hook = nil, -- callback to run after renaming, receives the result table (from LSP handler) as an argument
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-neo-tree/neo-tree.nvim",
|
||||
opts = {
|
||||
window = {
|
||||
position = "right",
|
||||
mappings = {
|
||||
["l"] = "none",
|
||||
},
|
||||
},
|
||||
},
|
||||
keys = {
|
||||
{
|
||||
"<leader>fe",
|
||||
function()
|
||||
require("neo-tree.command").execute({ position = "right", toggle = true, dir = Util.root() })
|
||||
end,
|
||||
desc = "Explorer NeoTree (root dir)",
|
||||
},
|
||||
{
|
||||
"<leader>fE",
|
||||
function()
|
||||
require("neo-tree.command").execute({ position = "right", toggle = true, dir = vim.loop.cwd() })
|
||||
end,
|
||||
desc = "Explorer NeoTree (cwd)",
|
||||
},
|
||||
{ "<A-f>", "<leader>fe", desc = "Explorer NeoTree (root dir)", remap = true },
|
||||
{ "<A-F>", "<leader>fE", desc = "Explorer NeoTree (cwd)", remap = true },
|
||||
},
|
||||
},
|
||||
{
|
||||
"folke/edgy.nvim",
|
||||
opts = {
|
||||
animate = {
|
||||
enabled = false,
|
||||
},
|
||||
left = {},
|
||||
right = {
|
||||
-- Neo-tree filesystem always takes half the screen height
|
||||
{
|
||||
title = "Neo-Tree",
|
||||
ft = "neo-tree",
|
||||
filter = function(buf)
|
||||
return vim.b[buf].neo_tree_source == "filesystem"
|
||||
end,
|
||||
size = { height = 0.5 },
|
||||
},
|
||||
{
|
||||
title = "Neo-Tree Git",
|
||||
ft = "neo-tree",
|
||||
filter = function(buf)
|
||||
return vim.b[buf].neo_tree_source == "git_status"
|
||||
end,
|
||||
pinned = true,
|
||||
open = "Neotree position=right git_status",
|
||||
},
|
||||
{
|
||||
title = "Neo-Tree Buffers",
|
||||
ft = "neo-tree",
|
||||
filter = function(buf)
|
||||
return vim.b[buf].neo_tree_source == "buffers"
|
||||
end,
|
||||
pinned = true,
|
||||
open = "Neotree position=top buffers",
|
||||
},
|
||||
{
|
||||
ft = "Outline",
|
||||
pinned = true,
|
||||
open = "SymbolsOutlineOpen",
|
||||
},
|
||||
-- any other neo-tree windows
|
||||
"neo-tree",
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"rcarriga/nvim-dap-ui",
|
||||
keys = {
|
||||
{
|
||||
"<leader>dk",
|
||||
function()
|
||||
require("dap").down()
|
||||
end,
|
||||
desc = "Down",
|
||||
},
|
||||
{
|
||||
"<leader>dl",
|
||||
function()
|
||||
require("dap").up()
|
||||
end,
|
||||
desc = "Up",
|
||||
},
|
||||
{
|
||||
"<leader>d;",
|
||||
function()
|
||||
require("dap").run_last()
|
||||
end,
|
||||
desc = "Run Last",
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
144
nix/nvim/lua/plugins/cmp.lua
Normal file
144
nix/nvim/lua/plugins/cmp.lua
Normal file
|
|
@ -0,0 +1,144 @@
|
|||
return {
|
||||
{
|
||||
"L3MON4D3/LuaSnip",
|
||||
build = (not jit.os:find("Windows"))
|
||||
and "echo -e 'NOTE: jsregexp is optional, so not a big deal if it fails to build\n'; make install_jsregexp"
|
||||
or nil,
|
||||
dependencies = {
|
||||
"rafamadriz/friendly-snippets",
|
||||
config = function()
|
||||
require("luasnip.loaders.from_vscode").lazy_load()
|
||||
end,
|
||||
},
|
||||
opts = {
|
||||
history = true,
|
||||
delete_check_events = "TextChanged",
|
||||
updateevents = "TextChanged,TextChangedI",
|
||||
enable_autosnippets = true,
|
||||
},
|
||||
keys = function()
|
||||
return {}
|
||||
end,
|
||||
config = function(_, opts)
|
||||
require("luasnip").setup(opts)
|
||||
end,
|
||||
},
|
||||
{
|
||||
"hrsh7th/nvim-cmp",
|
||||
version = false,
|
||||
event = "InsertEnter",
|
||||
dependencies = {
|
||||
"hrsh7th/cmp-nvim-lsp",
|
||||
"hrsh7th/cmp-buffer",
|
||||
"FelipeLema/cmp-async-path",
|
||||
"saadparwaiz1/cmp_luasnip",
|
||||
"Saecki/crates.nvim",
|
||||
{ "roobert/tailwindcss-colorizer-cmp.nvim", config = true },
|
||||
},
|
||||
opts = function()
|
||||
vim.api.nvim_set_hl(0, "CmpGhostText", { link = "Comment", default = true })
|
||||
local cmp = require("cmp")
|
||||
local defaults = require("cmp.config.default")()
|
||||
local luasnip = require("luasnip")
|
||||
local compare = require("cmp.config.compare")
|
||||
return {
|
||||
preselect = cmp.PreselectMode.None,
|
||||
completion = {
|
||||
-- completeopt = "menu,menuone,noinsert",
|
||||
},
|
||||
snippet = {
|
||||
expand = function(args)
|
||||
luasnip.lsp_expand(args.body)
|
||||
end,
|
||||
},
|
||||
mapping = {
|
||||
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
||||
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
||||
["<C-Space>"] = cmp.mapping.complete(),
|
||||
["<C-e>"] = cmp.mapping.abort(),
|
||||
["<CR>"] = cmp.mapping.confirm({ select = false }), -- Accept currently selected item. Set `select` to `false` to only confirm explicitly selected items.
|
||||
["<S-CR>"] = cmp.mapping.confirm({
|
||||
behavior = cmp.ConfirmBehavior.Replace,
|
||||
select = false,
|
||||
}), -- Accept cur
|
||||
["<Tab>"] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
cmp.select_next_item({ behavior = cmp.SelectBehavior.Insert })
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, { "i", "s" }),
|
||||
["<S-Tab>"] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
cmp.select_prev_item({ behavior = cmp.SelectBehavior.Insert })
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, {
|
||||
"i",
|
||||
"s",
|
||||
}),
|
||||
["<C-j>"] = cmp.mapping(function(fallback)
|
||||
if luasnip.expandable() then
|
||||
luasnip.expand()
|
||||
elseif luasnip.expand_or_jumpable() then
|
||||
luasnip.expand_or_jump()
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, {
|
||||
"i",
|
||||
"s",
|
||||
}),
|
||||
["<C-k>"] = cmp.mapping(function(fallback)
|
||||
if luasnip.expand_or_jumpable(-1) then
|
||||
luasnip.jump(-1)
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, {
|
||||
"i",
|
||||
"s",
|
||||
}),
|
||||
},
|
||||
sources = cmp.config.sources({
|
||||
{ name = "nvim_lsp", priority = 99 },
|
||||
{ name = "luasnip", priority = 3, max_item_count = 3 },
|
||||
{ name = "buffer", priority = 2, max_item_count = 2, keyword_length = 5 },
|
||||
{ name = "async_path", priority = 1, max_item_count = 2, keyword_length = 3, trigger_characters = {} },
|
||||
{ name = "crates" },
|
||||
}),
|
||||
sorting = {
|
||||
priority_weight = 90,
|
||||
comparators = {
|
||||
compare.exact,
|
||||
compare.score,
|
||||
compare.offset,
|
||||
compare.kind,
|
||||
},
|
||||
},
|
||||
formatting = {
|
||||
preselect = cmp.PreselectMode.None,
|
||||
format = function(entry, item)
|
||||
local icons = require("lazyvim.config").icons.kinds
|
||||
if icons[item.kind] then
|
||||
item.kind = icons[item.kind] .. item.kind
|
||||
end
|
||||
return require("tailwindcss-colorizer-cmp").formatter(entry, item)
|
||||
end,
|
||||
},
|
||||
experimental = {
|
||||
ghost_text = {
|
||||
hl_group = "CmpGhostText",
|
||||
},
|
||||
},
|
||||
}
|
||||
end,
|
||||
config = function(_, opts)
|
||||
local cmp = require("cmp")
|
||||
require("luasnip.loaders.from_lua").load({ paths = "~/.config/nvim/snippets" })
|
||||
cmp.setup(opts)
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
100
nix/nvim/lua/plugins/dashboard.lua
Normal file
100
nix/nvim/lua/plugins/dashboard.lua
Normal file
|
|
@ -0,0 +1,100 @@
|
|||
return {
|
||||
{
|
||||
"goolord/alpha-nvim",
|
||||
event = "VimEnter",
|
||||
opts = function()
|
||||
local alpha = require("alpha")
|
||||
local dashboard = require("alpha.themes.dashboard")
|
||||
dashboard.section.header.val = {
|
||||
[[ _______ ___ _______. __ __ __ _______ ]],
|
||||
[[| \ / \ / || | | | | | | ____|]],
|
||||
[[| .--. | / ^ \ | (----`| |__| | | | | |__ ]],
|
||||
[[| | | | / /_\ \ \ \ | __ | | | | __| ]],
|
||||
[[| '--' | / _____ \ .----) | | | | | | | | |____ ]],
|
||||
[[|_______/ /__/ \__\ |_______/ |__| |__| |__| |_______|]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⢤⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠪⣍⣒⠒⠦⠤⠤⠤⠄⠠⡜⡐⠁⠪⡢⡀⠀⠀⠀⠀⠀⠀⠀⠀⣀⠤⢄⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠈⠛⠯⣉⠁⣐⣂⠐⠮⠥⠟⣓⣲⣾⣿⣿⣿⣶⡃⠀⠀⠈⢞⢆⠀⠀⠀⠀⠀⠀⡰⢁⠂⠄⣇⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⣠⠤⠤⠭⠷⠎⡡⠔⠒⠘⠀⢹⣿⣿⣿⣿⣿⠀⠈⠀⠀⠀⢢⢣⠀⠀⠀⠀⢀⡇⠈⠀⢰⢰⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⢸⢰⠀⠀⠀⡩⢋⣀⣤⣤⣤⣤⣤⣿⣿⠟⠿⣿⡀⠀⠀⠀⠀⠀⠆⢳⠀⠀⠀⢸⠀⠂⠀⠀⡈⡆⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⢣⢂⠀⠮⡪⠛⠉⢋⠝⠻⢿⢿⡿⢁⠔⢋⣸⠇⠀⠀⠀⠀⠀⡘⣆⢣⠀⠀⡼⠀⠀⠀⠀⡇⣇⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⡣⢲⡊⠀⠀⠀⠀⠀⡴⠃⣼⠡⢪⠔⠋⠀⠀⠀⢀⠀⠀⠀⢸⣿⡄⢆⠀⡇⠀⠀⠀⠀⠁⢸⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⢰⢡⡇⠀⠀⢀⠔⠠⠊⣰⠞⡇⢠⠃⠀⣠⣶⣿⣷⣷⣷⠄⠀⠈⡟⣷⡸⡄⡇⠀⠀⠀⠀⠀⢸⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⡇⣾⠀⣀⠔⣁⣤⣦⢺⣿⡆⡆⡃⠀⢨⠃⢸⣿⣿⣿⠏⠀⠠⢀⢠⣿⡇⣧⡇⠀⠀⠀⠀⠀⢸⣆⢔⡲⡆⠀ ]],
|
||||
[[ ⠀⠀⣠⠞⠼⠧⢙⡒⣾⣿⣿⡷⡘⣟⣷⣜⡃⠀⡼⠀⠀⠷⠗⠋⠀⠀⠀⢀⡟⣿⣿⢀⠓⠀⠀⠀⠀⠀⢸⢋⠊⠀⡇⠀ ]],
|
||||
[[ ⠘⠛⠒⠒⠉⠉⠁⡇⣿⣽⣿⡇⠈⢹⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡀⣠⠟⠀⣷⣿⣇⠱⡀⠀⠀⠀⡄⢀⠃⠀⡄⡇⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⡇⢸⣏⢀⣧⠀⠈⠆⠀⠀⠀⠀⠀⠀⠀⠀⡠⢊⡴⡟⠀⡼⢁⢸⡙⣠⠁⠀⠀⠀⢇⠆⠀⢀⢳⡇⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⢳⢀⣵⢸⣯⣷⣤⣀⠀⠀⠀⠀⠀⢀⣐⠮⠔⡎⠘⠀⠈⢀⢮⣿⣷⠁⠇⠠⠀⢰⠎⠀⠀⡘⣸⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⢀⠎⢬⢘⣯⠛⢻⠏⣿⣿⣶⣶⡶⠋⠉⠀⠀⢸⠀⠀⡔⠀⣪⣿⣿⢻⠀⠸⠈⡇⠛⠀⠠⢀⢃⡇⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠈⡹⡡⣪⡏⠛⠀⠀⢠⡟⢻⣿⣿⡇⠀⠀⠀⠀⢼⡆⠠⡇⢰⣿⣿⣿⣻⡄⠀⡆⠁⠀⣠⠃⠌⠼⠤⠤⡀ ]],
|
||||
[[ ⠀⠀⠀⣀⡠⢞⣳⣽⢸⡇⠀⡇⠀⠸⠀⣼⣿⣿⡇⠀⠀⠀⠀⠈⡇⣰⠃⣶⡍⣼⣿⣏⠃⠀⠁⢠⠊⣀⣜⠤⠐⢂⢆⠇ ]],
|
||||
[[ ⠀⠀⠈⠉⠉⠁⠀⢇⢸⡟⠀⡇⠀⡇⢸⢷⣹⣿⡇⠀⠀⠀⠀⠀⢳⡽⠃⡞⣇⣿⣧⣿⠀⠀⢸⠃⢠⠃⠀⢀⠤⢢⠞⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⢸⡀⡇⠀⠁⢠⠁⣿⠈⣿⣿⠇⠀⠀⠀⠀⠀⠀⠁⡆⡇⣾⠿⣹⣿⠀⠀⠃⡰⠃⡰⢔⣡⠞⠁⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⢇⢠⠀⠂⡌⠀⢽⠁⣟⡟⠀⠀⠀⠀⠀⠀⠀⠀⣇⢶⢹⣤⣿⠇⠀⣀⣈⠝⡱⠒⠉⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠈⣎⡄⠀⡷⠀⢸⠀⢹⠇⠀⠀⠀⠀⠀⠀⠀⠀⠫⣼⣾⣿⢋⠤⠤⠥⢆⡞⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⢀⢫⣡⢸⠎⢃⢘⠀⢈⡄⠀⠀⠀⠀⠀⠀⠀⠀⢀⡽⣽⢀⡋⠉⠑⠉⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠘⠉⠳⡯⣇⢆⠻⣆⠈⣤⠀⠀⠀⠀⣀⡀⠤⢚⡨⠷⣝⠗⠑⢄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠫⣗⠳⡜⠵⠀⡍⡥⠤⠤⠤⠄⠒⠉⠀⠀⠀⠉⠉⠉⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⠫⡆⣇⠇⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢰⡙⡰⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
[[ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣦⠞⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||
}
|
||||
dashboard.section.buttons.val = {
|
||||
dashboard.button("f", " Find file", ":lua require('telescope.builtin').find_files()<CR>"),
|
||||
dashboard.button("y", " Yazi", ":lua require('yazi').yazi()<CR>"),
|
||||
dashboard.button("p", " Find project", ":lua require('telescope').extensions.project.project{}<CR>"),
|
||||
dashboard.button("t", " Zoxide", ":lua require('telescope').extensions.zoxide.list{}<CR>"),
|
||||
dashboard.button("c", " Configuration", ":e ~/.config/nvim/init.lua <CR>"),
|
||||
dashboard.button("q", " Quit Neovim", ":qa<CR>"),
|
||||
}
|
||||
|
||||
local function footer()
|
||||
return "dashie@dashie.org"
|
||||
end
|
||||
|
||||
dashboard.section.footer.val = footer()
|
||||
|
||||
dashboard.section.footer.opts.hl = "Type"
|
||||
dashboard.section.header.opts.hl = "Include"
|
||||
dashboard.section.buttons.opts.hl = "Keyword"
|
||||
|
||||
dashboard.opts.opts.noautocmd = true
|
||||
|
||||
-- alpha.pad_margin(dashboard.section.header.val, dashboard.opts , 0, 0)
|
||||
alpha.setup(dashboard.opts)
|
||||
end,
|
||||
config = function(_, dashboard)
|
||||
-- close Lazy and re-open when the dashboard is ready
|
||||
if vim.o.filetype == "lazy" then
|
||||
vim.cmd.close()
|
||||
vim.api.nvim_create_autocmd("User", {
|
||||
pattern = "AlphaReady",
|
||||
callback = function()
|
||||
require("lazy").show()
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
require("alpha").setup({
|
||||
layout = {
|
||||
{ type = "padding", val = 1 },
|
||||
dashboard.section.header,
|
||||
{ type = "padding", val = 1 },
|
||||
dashboard.section.buttons,
|
||||
{ type = "padding", val = 1 },
|
||||
dashboard.section.footer,
|
||||
},
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd("User", {
|
||||
pattern = "LazyVimStarted",
|
||||
callback = function()
|
||||
local stats = require("lazy").stats()
|
||||
local ms = (math.floor(stats.startuptime * 100 + 0.5) / 100)
|
||||
dashboard.section.footer.val = "⚡ Neovim loaded " .. stats.count .. " plugins in " .. ms .. "ms"
|
||||
pcall(vim.cmd.AlphaRedraw)
|
||||
end,
|
||||
})
|
||||
end,
|
||||
},
|
||||
}
|
||||
8
nix/nvim/lua/plugins/disabled.lua
Normal file
8
nix/nvim/lua/plugins/disabled.lua
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
return {
|
||||
{
|
||||
{ "rcarriga/nvim-notify", enabled = false },
|
||||
},
|
||||
{ { "folke/noice.nvim", enabled = false } },
|
||||
{ { "nvimtools/none-ls.nvim", enabled = false } },
|
||||
{ { "nvimdev/dashboard-nvim", enabled = false } },
|
||||
}
|
||||
162
nix/nvim/lua/plugins/lsp.lua
Normal file
162
nix/nvim/lua/plugins/lsp.lua
Normal file
|
|
@ -0,0 +1,162 @@
|
|||
return {
|
||||
{
|
||||
"williamboman/mason.nvim",
|
||||
opts = {
|
||||
ensure_installed = {},
|
||||
},
|
||||
},
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
---@class PluginLspOpts
|
||||
opts = {
|
||||
-- inlay_hints = {
|
||||
-- enabled = true,
|
||||
-- },
|
||||
format_notify = false,
|
||||
-- LSP Server Settings
|
||||
---@type lspconfig.options
|
||||
servers = {
|
||||
rust_analyzer = {
|
||||
mason = false,
|
||||
},
|
||||
marksman = {
|
||||
mason = false,
|
||||
},
|
||||
clangd = {
|
||||
mason = false,
|
||||
},
|
||||
jdtls = {
|
||||
mason = false,
|
||||
},
|
||||
gopls = {
|
||||
mason = false,
|
||||
},
|
||||
pyright = {
|
||||
mason = false,
|
||||
},
|
||||
ruff_lsp = {
|
||||
mason = false,
|
||||
},
|
||||
texlab = {
|
||||
mason = false,
|
||||
},
|
||||
taplo = {
|
||||
keys = {
|
||||
{
|
||||
"K",
|
||||
function()
|
||||
if vim.fn.expand("%:t") == "Cargo.toml" and require("crates").popup_available() then
|
||||
require("crates").show_popup()
|
||||
else
|
||||
vim.lsp.buf.hover()
|
||||
end
|
||||
end,
|
||||
desc = "Show Crate Documentation",
|
||||
},
|
||||
},
|
||||
mason = false,
|
||||
},
|
||||
bashls = {
|
||||
mason = false,
|
||||
},
|
||||
ansiblels = {
|
||||
mason = false,
|
||||
},
|
||||
typst_lsp = {
|
||||
settings = {
|
||||
experimentalFormatterMode = "on",
|
||||
exportPdf = "onSave",
|
||||
},
|
||||
mason = false,
|
||||
},
|
||||
nil_ls = {
|
||||
settings = {
|
||||
["nil"] = {
|
||||
formatting = {
|
||||
command = { "nixpkgs-fmt" },
|
||||
},
|
||||
},
|
||||
},
|
||||
mason = false,
|
||||
},
|
||||
ltex = {
|
||||
settings = {
|
||||
ltex = {
|
||||
checkFrequency = "save",
|
||||
},
|
||||
},
|
||||
filetypes = {
|
||||
"bib",
|
||||
"gitcommit",
|
||||
"markdown",
|
||||
"org",
|
||||
"plaintex",
|
||||
"rst",
|
||||
"rnoweb",
|
||||
"tex",
|
||||
"pandoc",
|
||||
"typst",
|
||||
"typ",
|
||||
},
|
||||
mason = false,
|
||||
},
|
||||
sqlls = {
|
||||
mason = false,
|
||||
},
|
||||
lemminx = {
|
||||
mason = false,
|
||||
},
|
||||
opencl_ls = {
|
||||
mason = false,
|
||||
},
|
||||
yamlls = {
|
||||
mason = false,
|
||||
},
|
||||
lua_ls = {
|
||||
mason = false,
|
||||
{
|
||||
Lua = {
|
||||
workspace = {
|
||||
checkThirdParty = false,
|
||||
},
|
||||
completion = {
|
||||
callSnippet = "Replace",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
init = function()
|
||||
local keys = require("lazyvim.plugins.lsp.keymaps").get()
|
||||
local my_keys = require("config.lsp-keymap").get()
|
||||
local count = 0
|
||||
for _ in pairs(my_keys) do
|
||||
keys[#keys + 1] = my_keys[count]
|
||||
count = count + 1
|
||||
end
|
||||
end,
|
||||
},
|
||||
{
|
||||
"stevearc/conform.nvim",
|
||||
opts = {
|
||||
keys = {
|
||||
{
|
||||
-- Customize or remove this keymap to your liking
|
||||
"<leader>cF",
|
||||
function()
|
||||
require("conform").format({ async = true, lsp_fallback = true })
|
||||
end,
|
||||
mode = "",
|
||||
desc = "Format buffer",
|
||||
},
|
||||
},
|
||||
formatters_by_ft = {
|
||||
typst = { "typstfmt" },
|
||||
nix = { "nixpkgs-fmt" },
|
||||
lua = { "stylua" },
|
||||
sh = { "shfmt" },
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
255
nix/nvim/lua/plugins/plugins.lua
Normal file
255
nix/nvim/lua/plugins/plugins.lua
Normal file
|
|
@ -0,0 +1,255 @@
|
|||
local Util = require("lazyvim.util")
|
||||
|
||||
return {
|
||||
{
|
||||
"LazyVim/LazyVim",
|
||||
opts = {
|
||||
colorscheme = "tokyonight-night",
|
||||
-- colorscheme = "catppuccin-mocha",
|
||||
},
|
||||
},
|
||||
{
|
||||
"nvim-telescope/telescope.nvim",
|
||||
cmd = "Telescope",
|
||||
keys = function()
|
||||
return {}
|
||||
end,
|
||||
opts = {
|
||||
defaults = {
|
||||
layout_strategy = "flex",
|
||||
layout_config = {
|
||||
flex = {
|
||||
height = 0.95,
|
||||
width = 0.95,
|
||||
flip_columns = 100,
|
||||
},
|
||||
vertical = { preview_height = 0.5, preview_cutoff = 5 },
|
||||
horizontal = { preview_width = 0.7, preview_cutoff = 99 },
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"nvim-telescope/telescope-project.nvim",
|
||||
lazy = true,
|
||||
},
|
||||
{
|
||||
"nvim-telescope/telescope-file-browser.nvim",
|
||||
lazy = true,
|
||||
config = function()
|
||||
require("telescope").load_extension("file_browser")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"jvgrootveld/telescope-zoxide",
|
||||
lazy = true,
|
||||
config = function()
|
||||
local z_utils = require("telescope._extensions.zoxide.utils")
|
||||
local t = require("telescope")
|
||||
-- Configure the extension
|
||||
t.setup({
|
||||
extensions = {
|
||||
zoxide = {
|
||||
prompt_title = "[ Queries ]",
|
||||
mappings = {
|
||||
default = {
|
||||
after_action = function(selection)
|
||||
print("Update to (" .. selection.z_score .. ") " .. selection.path)
|
||||
end,
|
||||
},
|
||||
["<C-s>"] = {
|
||||
before_action = function(selection)
|
||||
print("before C-s")
|
||||
end,
|
||||
action = function(selection)
|
||||
vim.cmd("edit " .. selection.path)
|
||||
end,
|
||||
},
|
||||
["<C-q>"] = { action = z_utils.create_basic_command("split") },
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
-- Load the extension
|
||||
t.load_extension("zoxide")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"lervag/vimtex",
|
||||
config = function()
|
||||
vim.cmd("let g:vimtex_quickfix_mode=0")
|
||||
vim.cmd("let g:vimtex_view_general_viewer = 'evince'")
|
||||
vim.cmd("let g:vimtex_compiler_method = 'latexmk'")
|
||||
vim.cmd(
|
||||
"let g:vimtex_compiler_latexmk = {'options': ['-pdf', '-shell-escape', '-file-line-error', '--extra-mem-bot=10000000', '-synctex=1', '-interaction=nonstopmode',],}"
|
||||
)
|
||||
end,
|
||||
},
|
||||
{
|
||||
"jbyuki/instant.nvim",
|
||||
config = function()
|
||||
vim.cmd("let g:instant_username = 'dashie'")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = {
|
||||
textobjects = {
|
||||
select = {
|
||||
enable = true,
|
||||
lookahead = true,
|
||||
keymaps = {
|
||||
-- You can use the capture groups defined in textobjects.scm
|
||||
["af"] = "@function.outer",
|
||||
["if"] = "@function.inner",
|
||||
["ac"] = "@class.outer",
|
||||
["ic"] = "@class.inner",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"karb94/neoscroll.nvim",
|
||||
config = function()
|
||||
require("neoscroll").setup()
|
||||
end,
|
||||
},
|
||||
{
|
||||
"kaarmu/typst.vim",
|
||||
lazy = true,
|
||||
event = "FileType typst",
|
||||
},
|
||||
{
|
||||
"folke/which-key.nvim",
|
||||
event = "VeryLazy",
|
||||
opts = {
|
||||
plugins = { spelling = true },
|
||||
defaults = {
|
||||
mode = { "n", "v" },
|
||||
["g"] = { name = "+goto" },
|
||||
["gz"] = { name = "+surround" },
|
||||
["]"] = { name = "+next" },
|
||||
["["] = { name = "+prev" },
|
||||
["<leader><tab>"] = { name = "+tabs" },
|
||||
["<leader>b"] = { name = "+buffer" },
|
||||
["<leader>c"] = { name = "+code" },
|
||||
["<leader>f"] = { name = "+file/find" },
|
||||
["<leader>g"] = { name = "+git" },
|
||||
["<leader>gh"] = { name = "+hunks" },
|
||||
["<leader>q"] = { name = "+quit/session" },
|
||||
["<leader>s"] = { name = "+search" },
|
||||
["<leader>u"] = { name = "+ui" },
|
||||
["<leader>w"] = { name = "+windows" },
|
||||
["<leader>x"] = { name = "+diagnostics/quickfix" },
|
||||
["<leader>h"] = { name = "+harpoon" },
|
||||
["<leader>d"] = { name = "+DAP" },
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
local wk = require("which-key")
|
||||
wk.setup(opts)
|
||||
wk.register(opts.defaults)
|
||||
end,
|
||||
},
|
||||
{
|
||||
"f-person/git-blame.nvim",
|
||||
lazy = true,
|
||||
},
|
||||
{
|
||||
"mg979/vim-visual-multi",
|
||||
},
|
||||
{
|
||||
"barreiroleo/ltex_extra.nvim",
|
||||
ft = { "markdown", "tex", "typst", "typ" },
|
||||
lazy = true,
|
||||
},
|
||||
{
|
||||
"smjonas/inc-rename.nvim",
|
||||
lazy = true,
|
||||
event = "BufEnter",
|
||||
config = function()
|
||||
require("inc_rename").setup({
|
||||
cmd_name = "IncRename", -- the name of the command
|
||||
hl_group = "Substitute", -- the highlight group used for highlighting the identifier's new name
|
||||
preview_empty_name = true, -- whether an empty new name should be previewed; if false the command preview will be cancelled instead
|
||||
show_message = true, -- whether to display a `Renamed m instances in n files` message after a rename operation
|
||||
input_buffer_type = nil, -- the type of the external input buffer to use (the only supported value is currently "dressing")
|
||||
post_hook = nil, -- callback to run after renaming, receives the result table (from LSP handler) as an argument
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-neo-tree/neo-tree.nvim",
|
||||
opts = {
|
||||
window = {
|
||||
position = "right",
|
||||
mappings = {
|
||||
["l"] = "none",
|
||||
},
|
||||
},
|
||||
},
|
||||
keys = {
|
||||
{
|
||||
"<leader>fe",
|
||||
function()
|
||||
require("neo-tree.command").execute({ position = "right", toggle = true, dir = Util.root() })
|
||||
end,
|
||||
desc = "Explorer NeoTree (root dir)",
|
||||
},
|
||||
{
|
||||
"<leader>fE",
|
||||
function()
|
||||
require("neo-tree.command").execute({ position = "right", toggle = true, dir = vim.loop.cwd() })
|
||||
end,
|
||||
desc = "Explorer NeoTree (cwd)",
|
||||
},
|
||||
{ "<A-f>", "<leader>fe", desc = "Explorer NeoTree (root dir)", remap = true },
|
||||
{ "<A-F>", "<leader>fE", desc = "Explorer NeoTree (cwd)", remap = true },
|
||||
},
|
||||
},
|
||||
{
|
||||
"rcarriga/nvim-dap-ui",
|
||||
keys = {
|
||||
{
|
||||
"<leader>dk",
|
||||
function()
|
||||
require("dap").down()
|
||||
end,
|
||||
desc = "Down",
|
||||
},
|
||||
{
|
||||
"<leader>dl",
|
||||
function()
|
||||
require("dap").up()
|
||||
end,
|
||||
desc = "Up",
|
||||
},
|
||||
{
|
||||
"<leader>d;",
|
||||
function()
|
||||
require("dap").run_last()
|
||||
end,
|
||||
desc = "Run Last",
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"DashieTM/test_plugin",
|
||||
lazy = false,
|
||||
opts = {
|
||||
what = 0,
|
||||
},
|
||||
},
|
||||
{
|
||||
"DreamMaoMao/yazi.nvim",
|
||||
dependencies = {
|
||||
"nvim-telescope/telescope.nvim",
|
||||
"nvim-lua/plenary.nvim",
|
||||
},
|
||||
keys = {
|
||||
{ "<leader>fy", "<cmd>Yazi<CR>", desc = "Toggle Yazi" },
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
@ -2,6 +2,10 @@
|
|||
, ...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
../nvim/default.nix
|
||||
];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
git
|
||||
gcc
|
||||
|
|
@ -12,17 +16,12 @@
|
|||
nodejs_20
|
||||
deno
|
||||
python3
|
||||
neovim
|
||||
typst
|
||||
neovide
|
||||
tree-sitter
|
||||
dotnet-runtime_8
|
||||
unzip
|
||||
pkg-config
|
||||
lua-language-server
|
||||
nil
|
||||
nixpkgs-fmt
|
||||
crate2nix
|
||||
sqlite
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,11 +30,9 @@
|
|||
dbus
|
||||
killall
|
||||
adw-gtk3
|
||||
gradience
|
||||
qt5ct
|
||||
qt6ct
|
||||
libadwaita
|
||||
yazi
|
||||
gnutar
|
||||
fishPlugins.tide
|
||||
nix-index
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./common.nix
|
||||
|
|
@ -7,6 +6,8 @@
|
|||
./xdg.nix
|
||||
./media.nix
|
||||
./utils.nix
|
||||
./yazi.nix
|
||||
./oxi/default.nix
|
||||
#./gtk.nix
|
||||
#./cargo.nix
|
||||
];
|
||||
|
|
|
|||
|
|
@ -19,5 +19,18 @@
|
|||
};
|
||||
};
|
||||
|
||||
xsession.cursor = {
|
||||
name = "Bibata-Moder-Classic";
|
||||
package = pkgs.bibata-cursors;
|
||||
size = 24;
|
||||
};
|
||||
|
||||
home.pointerCursor = {
|
||||
gtk.enable = true;
|
||||
package = pkgs.bibata-cursors;
|
||||
name = "Bibata-Modern-Classic";
|
||||
size = 24;
|
||||
};
|
||||
|
||||
home.sessionVariables.GTK_THEME = "adw-gtk3";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,10 +1,12 @@
|
|||
{ lib
|
||||
, pkgs
|
||||
{ pkgs
|
||||
, ...
|
||||
}: {
|
||||
imports = [
|
||||
./anyrun.nix
|
||||
./config.nix
|
||||
./ironbar.nix
|
||||
./hyprpaper.nix
|
||||
./hyprgreet.nix
|
||||
];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
|
|
@ -15,7 +17,6 @@
|
|||
xdg-desktop-portal-gtk
|
||||
xdg-desktop-portal-hyprland
|
||||
hyprpaper
|
||||
ironbar
|
||||
copyq
|
||||
gnome.nautilus
|
||||
gnome.sushi
|
||||
|
|
|
|||
23
nix/programs/hyprland/hyprgreet.nix
Normal file
23
nix/programs/hyprland/hyprgreet.nix
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
{ ... }: {
|
||||
xdg.configFile."hypr/hyprgreet.conf" = {
|
||||
text =
|
||||
''
|
||||
exec-once=gsettings set org.gnome.desktop.interface color-scheme 'prefer-dark'
|
||||
|
||||
monitor=DP-1,3440x1440@180,0x0,1
|
||||
monitor=DP-2,disable
|
||||
monitor=HDMI-A-1,disable
|
||||
|
||||
input {
|
||||
force_no_accel = true
|
||||
}
|
||||
|
||||
misc {
|
||||
disable_splash_rendering = true
|
||||
disable_hyprland_logo = true
|
||||
}
|
||||
|
||||
exec-once=regreet --style /home/dashie/.config/gtk-3.0/gtk.css; hyprctl dispatch exit
|
||||
'';
|
||||
};
|
||||
}
|
||||
17
nix/programs/hyprland/hyprpaper.nix
Normal file
17
nix/programs/hyprland/hyprpaper.nix
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
xdg.configFile."hypr/hyprpaper.conf" = {
|
||||
text =
|
||||
''
|
||||
#load
|
||||
preload = /home/dashie/Pictures/backgrounds/shinobu_2k.jpg
|
||||
preload = /home/dashie/Pictures/backgrounds/shino_wide.png
|
||||
preload = /home/dashie/Pictures/backgrounds/shinobu_1200.jpg
|
||||
|
||||
#set
|
||||
wallpaper = DP-2,/home/dashie/Pictures/backgrounds/shinobu_2k.jpg
|
||||
wallpaper = DP-1,/home/dashie/Pictures/backgrounds/shino_wide.png
|
||||
wallpaper = HDMI-A-1,/home/dashie/Pictures/backgrounds/shinobu_1200.jpg
|
||||
splash = true
|
||||
'';
|
||||
};
|
||||
}
|
||||
255
nix/programs/hyprland/ironbar.nix
Normal file
255
nix/programs/hyprland/ironbar.nix
Normal file
|
|
@ -0,0 +1,255 @@
|
|||
{
|
||||
programs.ironbar = {
|
||||
enable = true;
|
||||
style = ''
|
||||
@import url("/home/dashie/.config/gtk-3.0/gtk.css");
|
||||
|
||||
* {
|
||||
color: #71bbe6;
|
||||
padding: 0px;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
.background {
|
||||
background-color: rgba(0, 0, 0, 0);
|
||||
}
|
||||
|
||||
.workspaces {
|
||||
margin: 2px 0px 0px 5px;
|
||||
border-radius: 10px;
|
||||
/* background-color: #2b2c3b; */
|
||||
background-color: #1E1E2E;
|
||||
padding: 2px 5px 2px 5px;
|
||||
}
|
||||
|
||||
.workspaces .item {
|
||||
margin: 0px 3px 0px 3px;
|
||||
font-size: 13px;
|
||||
border-radius: 100%;
|
||||
padding: 0px 2px 0px 3px;
|
||||
background-color: rgba(0, 0, 0, 0);
|
||||
}
|
||||
|
||||
.workspaces .item:hover {
|
||||
background-color: #3e4152;
|
||||
}
|
||||
|
||||
.workspaces .item.focused {
|
||||
background-color: #3e4152;
|
||||
}
|
||||
|
||||
.audio-box {
|
||||
padding: 2em;
|
||||
background-color: #1E1E2E;
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
.audio-slider {
|
||||
padding: 5px;
|
||||
margin: 5px;
|
||||
}
|
||||
|
||||
.audio-button {
|
||||
padding: 5px 10px 5px 10px;
|
||||
margin: 0px 1em 20px 1em;
|
||||
border-radius: 100%;
|
||||
font-size: 17px;
|
||||
}
|
||||
|
||||
.audio-button-box {
|
||||
padding: 0px 2.5em 0px 2.5em;
|
||||
}
|
||||
|
||||
.focused {
|
||||
/* margin: 2px 0px 0px 0px; */
|
||||
padding: 0px 5px 0px 5px;
|
||||
/* background-color: 1a1b26; */
|
||||
background-color: #1E1E2E;
|
||||
font-size: 17px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
#bar #end {
|
||||
margin: 0px 5px 0px 0px;
|
||||
padding: 0px 5px 0px 5px;
|
||||
background-color: #1E1E2E;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
.popup-button {
|
||||
padding: 0px 5px 0px 3px;
|
||||
margin: 0em 3px;
|
||||
border-radius: 100%;
|
||||
font-size: 13px;
|
||||
background-color: #1E1E2E;
|
||||
}
|
||||
|
||||
.popup-button-box {
|
||||
padding: 2px 0px 2px 0px;
|
||||
}
|
||||
|
||||
.clock {
|
||||
padding: 0px 5px 0px 5px;
|
||||
font-size: 17px;
|
||||
background-color: #1E1E2E;
|
||||
}
|
||||
|
||||
.clock:hover {
|
||||
background-color: #3e4152;
|
||||
}
|
||||
|
||||
.custom button {
|
||||
background-color: #1E1E2E;
|
||||
}
|
||||
|
||||
.custom button:hover {
|
||||
background-color: #3e4152;
|
||||
}
|
||||
|
||||
.memory-usage {
|
||||
font-size: 15px;
|
||||
margin: 0px 5px 0px 0px;
|
||||
}
|
||||
|
||||
.memory-usage:hover {
|
||||
background-color: #3e4152;
|
||||
}
|
||||
|
||||
.popup-clock {
|
||||
background-color: #1E1E2E;
|
||||
border-radius: 5px;
|
||||
padding: 2px 8px 10px 8px;
|
||||
}
|
||||
|
||||
.popup-clock .calendar-clock {
|
||||
font-size: 2.5em;
|
||||
padding-bottom: 0.1em;
|
||||
}
|
||||
|
||||
.popup-clock .calendar {
|
||||
border-radius: 5px;
|
||||
font-size: 1.05em;
|
||||
}
|
||||
|
||||
.popup-clock .calendar:selected {
|
||||
background-color: #3e4152;
|
||||
}
|
||||
'';
|
||||
features = [
|
||||
#"another_feature"
|
||||
];
|
||||
config = {
|
||||
monitors.DP-1 = {
|
||||
end = [
|
||||
{
|
||||
type = "sys_info";
|
||||
format = [
|
||||
" {memory_percent}"
|
||||
];
|
||||
interval.memory = 30;
|
||||
class = "memory-usage";
|
||||
}
|
||||
{
|
||||
type = "custom";
|
||||
bar = [
|
||||
{
|
||||
type = "button";
|
||||
class = "popup-button";
|
||||
label = "";
|
||||
on_click = "popup:toggle";
|
||||
}
|
||||
];
|
||||
class = "popup-button-box";
|
||||
popup = [
|
||||
{
|
||||
type = "box";
|
||||
orientation = "vertical";
|
||||
class = "audio-box";
|
||||
widgets = [
|
||||
{
|
||||
type = "box";
|
||||
orientation = "horizontal";
|
||||
widgets = [
|
||||
{
|
||||
type = "button";
|
||||
class = "audio-button";
|
||||
label = "";
|
||||
on_click = "!/home/dashie/.config/eww/scripts/audio_control.sh bluetooth";
|
||||
}
|
||||
{
|
||||
type = "button";
|
||||
class = "audio-button";
|
||||
label = "";
|
||||
on_click = "!/home/dashie/.config/eww/scripts/audio_control.sh internal";
|
||||
}
|
||||
];
|
||||
class = "audio-button-box";
|
||||
}
|
||||
{
|
||||
type = "label";
|
||||
label = "Output";
|
||||
}
|
||||
{
|
||||
type = "slider";
|
||||
class = "audio-slider";
|
||||
step = 1.0;
|
||||
length = 200;
|
||||
value = "pactl get-sink-volume @DEFAULT_SINK@ | awk -F'/' '{ print $2 }' | tr -d ' %'";
|
||||
on_change = "!pactl set-sink-volume @DEFAULT_SINK@ $0%";
|
||||
}
|
||||
{
|
||||
type = "label";
|
||||
label = "Input";
|
||||
}
|
||||
{
|
||||
type = "slider";
|
||||
class = "audio-slider";
|
||||
step = 1.0;
|
||||
length = 200;
|
||||
value = "pactl get-source-volume @DEFAULT_SOURCE@ | awk -F'/' '{ print $2 }' | tr -d ' %'";
|
||||
on_change = "!pactl set-source-volume @DEFAULT_SOURCE@ $0%";
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
type = "custom";
|
||||
bar = [
|
||||
{
|
||||
type = "button";
|
||||
class = "popup-button";
|
||||
label = "";
|
||||
on_click = "!oxidash --css /home/dashie/gits/oxidash/style.css";
|
||||
}
|
||||
];
|
||||
class = "popup-button-box";
|
||||
}
|
||||
{
|
||||
type = "clock";
|
||||
format = "%I:%M";
|
||||
format_popup = "%I:%M:%S";
|
||||
locale = "en_US";
|
||||
}
|
||||
{ type = "tray"; }
|
||||
];
|
||||
position = "top";
|
||||
height = 10;
|
||||
anchor_to_edges = true;
|
||||
start = [{
|
||||
type = "workspaces";
|
||||
all_monitors = true;
|
||||
}];
|
||||
center = [
|
||||
{
|
||||
type = "focused";
|
||||
show_icon = true;
|
||||
show_title = true;
|
||||
icon_size = 20;
|
||||
truncate = "end";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
9
nix/programs/oxi/default.nix
Normal file
9
nix/programs/oxi/default.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
imports = [
|
||||
./oxipaste.nix
|
||||
./oxinoti.nix
|
||||
./oxishut.nix
|
||||
./oxidash.nix
|
||||
];
|
||||
}
|
||||
|
||||
53
nix/programs/oxi/oxidash.nix
Normal file
53
nix/programs/oxi/oxidash.nix
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
{
|
||||
xdg.configFile."oxidash/style.css" = {
|
||||
text =
|
||||
''
|
||||
#MainWindow {
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
#MainBox {
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
#MainButtonBox {
|
||||
padding: 10px;
|
||||
margin: 5px 0px 5px 0px;
|
||||
border-radius: 5px;
|
||||
border: solid 2px #327cd5;
|
||||
}
|
||||
|
||||
#DoNotDisturbButton {
|
||||
}
|
||||
|
||||
#ExitButton {
|
||||
}
|
||||
|
||||
#ClearNotificationsButton {
|
||||
}
|
||||
|
||||
#NotificationsWindow {
|
||||
}
|
||||
|
||||
.debugimage {
|
||||
border: solid 3px blue;
|
||||
}
|
||||
|
||||
.Notification {
|
||||
padding: 10px;
|
||||
margin: 5px 0px 5px 0px;
|
||||
border: solid 2px #327cd5;
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
.CloseNotificationButton {
|
||||
margin: 0px 5px 0px 10px;
|
||||
}
|
||||
.PictureButtonBox {
|
||||
}
|
||||
.BaseBox {
|
||||
}
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
92
nix/programs/oxi/oxinoti.nix
Normal file
92
nix/programs/oxi/oxinoti.nix
Normal file
|
|
@ -0,0 +1,92 @@
|
|||
{
|
||||
xdg.configFile."oxinoti/style.css" = {
|
||||
text =
|
||||
''
|
||||
@import url("/home/dashie/.config/gtk-3.0/gtk.css");
|
||||
|
||||
#MainWindow {
|
||||
background-color: transparent;
|
||||
padding: 0px;
|
||||
/* opacity: 0; */
|
||||
}
|
||||
|
||||
.MainBox {
|
||||
background-color: transparent;
|
||||
padding: 0px;
|
||||
/* opacity: 0; */
|
||||
}
|
||||
|
||||
.NotificationBox {
|
||||
background-color: #353747;
|
||||
border-radius: 5px;
|
||||
border: solid 1px;
|
||||
margin: 0px;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
.NotificationLow {
|
||||
border-color: green;
|
||||
}
|
||||
|
||||
.NotificationNormal {
|
||||
border-color: purple;
|
||||
}
|
||||
|
||||
.NotificationUrgent {
|
||||
border-color: red;
|
||||
}
|
||||
|
||||
.miscbox {
|
||||
margin: 0px 10px 0px 0px;
|
||||
}
|
||||
|
||||
.bodybox {
|
||||
}
|
||||
|
||||
.imagebox {
|
||||
margin: 0px 0px 0px 10px;
|
||||
}
|
||||
|
||||
.appname {
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.timestamp {
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.summary {
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.body {
|
||||
font-size: 1.2rem;
|
||||
}
|
||||
|
||||
.icon {
|
||||
font-size: 2rem;
|
||||
}
|
||||
|
||||
.image {
|
||||
}
|
||||
|
||||
.bold {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.italic {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.underline {
|
||||
text-decoration-line: underline;
|
||||
}
|
||||
'';
|
||||
};
|
||||
xdg.configFile."oxinoti/oxinoti.toml" = {
|
||||
text = ''
|
||||
timeout = 3
|
||||
dnd_override = 2
|
||||
'';
|
||||
};
|
||||
}
|
||||
31
nix/programs/oxi/oxipaste.nix
Normal file
31
nix/programs/oxi/oxipaste.nix
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
{
|
||||
xdg.configFile."oxipaste/style.css" = {
|
||||
text =
|
||||
''
|
||||
.main-window {
|
||||
padding: 10px;
|
||||
border-radius: 10px;
|
||||
border: 2px solid #2AC3DE;
|
||||
}
|
||||
|
||||
.item-window {
|
||||
padding: 10px;
|
||||
border-radius: 10px;
|
||||
border: 2px solid #C0CAF5;
|
||||
}
|
||||
|
||||
.item-button {
|
||||
background-color: #1A1B26;
|
||||
border-radius: 5px;
|
||||
border: 1px solid #6D728D;
|
||||
}
|
||||
|
||||
.delete-button {
|
||||
margin: 5px 25px 5px 5px;
|
||||
}
|
||||
|
||||
.item-box {
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
25
nix/programs/oxi/oxishut.nix
Normal file
25
nix/programs/oxi/oxishut.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{
|
||||
xdg.configFile."oxishut/style.css" = {
|
||||
text =
|
||||
''
|
||||
#mainwindow {
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
.mainbox {
|
||||
border-radius: 5px;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.button {
|
||||
margin: 5px;
|
||||
background-color: #2b2c3b;
|
||||
-gtk-icon-size: 5rem;
|
||||
}
|
||||
|
||||
.button:hover {
|
||||
background-color: #3e4152;
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
1494
nix/programs/yazi.nix
Normal file
1494
nix/programs/yazi.nix
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue