forked from mirrors_public/oddlama_nix-config
feat: add separate neovim config for manpager use
This commit is contained in:
parent
ccba5306de
commit
ea63eea40b
6 changed files with 31 additions and 2 deletions
|
@ -1,9 +1,10 @@
|
||||||
{...}: {
|
{pkgs, ...}: {
|
||||||
imports = [
|
imports = [
|
||||||
./documentation.nix
|
./documentation.nix
|
||||||
./yubikey.nix
|
./yubikey.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
environment.systemPackages = [pkgs.man-pages pkgs.man-pages-posix];
|
||||||
environment.enableDebugInfo = true;
|
environment.enableDebugInfo = true;
|
||||||
services.nixseparatedebuginfod.enable = true;
|
services.nixseparatedebuginfod.enable = true;
|
||||||
}
|
}
|
||||||
|
|
14
users/modules/config/manpager/default.nix
Normal file
14
users/modules/config/manpager/default.nix
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
{pkgs, ...}: let
|
||||||
|
nvimPager = pkgs.wrapNeovimUnstable pkgs.neovim-unwrapped nvimConfig;
|
||||||
|
nvimConfig =
|
||||||
|
pkgs.neovimUtils.makeNeovimConfig {
|
||||||
|
wrapRc = false;
|
||||||
|
withPython3 = false;
|
||||||
|
withRuby = false;
|
||||||
|
}
|
||||||
|
// {
|
||||||
|
wrapperArgs = ["--add-flags" "--clean -u ${./init.lua}"];
|
||||||
|
};
|
||||||
|
in {
|
||||||
|
home.sessionVariables.MANPAGER = "${nvimPager}/bin/nvim '+Man!'";
|
||||||
|
}
|
11
users/modules/config/manpager/init.lua
Normal file
11
users/modules/config/manpager/init.lua
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
vim.opt.buftype = "nowrite"
|
||||||
|
vim.opt.backup = false
|
||||||
|
vim.opt.modeline = false
|
||||||
|
vim.opt.shelltemp = false
|
||||||
|
vim.opt.swapfile = false
|
||||||
|
vim.opt.undofile = false
|
||||||
|
vim.opt.writebackup = false
|
||||||
|
vim.opt.shadafile = vim.fn.stdpath "state" .. "/shada/man.shada"
|
||||||
|
|
||||||
|
-- Make sure to use ANSI colors
|
||||||
|
vim.opt.termguicolors = false
|
|
@ -5,6 +5,7 @@
|
||||||
|
|
||||||
./config/htop.nix
|
./config/htop.nix
|
||||||
./config/impermanence.nix
|
./config/impermanence.nix
|
||||||
|
./config/manpager
|
||||||
./config/neovim.nix
|
./config/neovim.nix
|
||||||
./config/shell
|
./config/shell
|
||||||
./config/utils.nix
|
./config/utils.nix
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
home = {
|
home = {
|
||||||
extraOutputsToInstall = ["doc" "devdoc"];
|
extraOutputsToInstall = ["man" "doc" "devdoc"];
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
git-lfs
|
git-lfs
|
||||||
d2
|
d2
|
||||||
|
|
|
@ -37,6 +37,8 @@
|
||||||
zathura
|
zathura
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# TODO neovim directtly opening file has different syntax
|
||||||
|
# TODO neovim reopening file should continue at the previous position
|
||||||
# TODO thunderbird doesn't use passwords from password command
|
# TODO thunderbird doesn't use passwords from password command
|
||||||
# TODO rotating wallpaper
|
# TODO rotating wallpaper
|
||||||
# TODO thunderbird date time format is wrong even though this is C.utf8
|
# TODO thunderbird date time format is wrong even though this is C.utf8
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue