Completed luna config for real this time
This commit is contained in:
parent
5ad8529721
commit
2c75ae213a
17 changed files with 357 additions and 62 deletions
|
|
@ -1,7 +1,10 @@
|
|||
{inputs, ...}: {
|
||||
imports = [
|
||||
./terminal.nix
|
||||
./visual.nix
|
||||
./dev.nix
|
||||
|
||||
./terminal.nix
|
||||
|
||||
./visual.nix
|
||||
./visual/firefox.nix
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@
|
|||
}: let
|
||||
inherit (lib) mkEnableOption mkIf mkOption types;
|
||||
cfg = config.horseman.apps.terminal;
|
||||
homeCfg = config.horseman;
|
||||
in {
|
||||
options = {
|
||||
horseman.apps.terminal = {
|
||||
|
|
@ -16,9 +17,20 @@ in {
|
|||
};
|
||||
|
||||
config = {
|
||||
home-manager.users.${homeCfg.username} = {
|
||||
imports = [./terminal/neovim.nix];
|
||||
};
|
||||
|
||||
services.lorri.enable = true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnupg
|
||||
neofetch
|
||||
sops
|
||||
sxiv
|
||||
termdown
|
||||
unzip
|
||||
wakeonlan
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
44
modules/apps/terminal/lualine.vim
Normal file
44
modules/apps/terminal/lualine.vim
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
lua << EOF
|
||||
|
||||
require('lualine').setup {
|
||||
options = {
|
||||
icons_enabled = true,
|
||||
theme = 'auto',
|
||||
component_separators = { left = '', right = ''},
|
||||
section_separators = { left = '', right = ''},
|
||||
disabled_filetypes = {
|
||||
statusline = {},
|
||||
winbar = {},
|
||||
},
|
||||
ignore_focus = {},
|
||||
always_divide_middle = true,
|
||||
globalstatus = false,
|
||||
refresh = {
|
||||
statusline = 1000,
|
||||
tabline = 1000,
|
||||
winbar = 1000,
|
||||
}
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {'mode'},
|
||||
lualine_b = {'branch', 'diff', 'diagnostics'},
|
||||
lualine_c = {'filename'},
|
||||
lualine_x = {'encoding', 'fileformat', 'filetype'},
|
||||
lualine_y = {'progress'},
|
||||
lualine_z = {'location'}
|
||||
},
|
||||
inactive_sections = {
|
||||
lualine_a = {},
|
||||
lualine_b = {},
|
||||
lualine_c = {'filename'},
|
||||
lualine_x = {'location'},
|
||||
lualine_y = {},
|
||||
lualine_z = {}
|
||||
},
|
||||
tabline = {},
|
||||
winbar = {},
|
||||
inactive_winbar = {},
|
||||
extensions = {}
|
||||
}
|
||||
|
||||
EOF
|
||||
149
modules/apps/terminal/neovim.nix
Normal file
149
modules/apps/terminal/neovim.nix
Normal file
|
|
@ -0,0 +1,149 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
viAlias = true;
|
||||
vimAlias = true;
|
||||
extraPackages = with pkgs; [
|
||||
# LazyVim
|
||||
lua-language-server
|
||||
stylua
|
||||
# Telescope
|
||||
ripgrep
|
||||
];
|
||||
|
||||
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" },
|
||||
-- The following configs are needed for fixing lazyvim on nix
|
||||
-- force enable telescope-fzf-native.nvim
|
||||
{ "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 = {} } },
|
||||
},
|
||||
})
|
||||
'';
|
||||
};
|
||||
|
||||
# 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";
|
||||
}
|
||||
|
|
@ -8,6 +8,7 @@
|
|||
}: let
|
||||
inherit (lib) mkEnableOption mkIf mkOption types;
|
||||
cfg = config.horseman.apps.visual;
|
||||
homeCfg = config.horseman;
|
||||
in {
|
||||
options = {
|
||||
horseman.apps.visual = {
|
||||
|
|
@ -16,7 +17,27 @@ in {
|
|||
};
|
||||
|
||||
config = {
|
||||
horseman.apps.visual = {
|
||||
firefox.enable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
alacritty
|
||||
albert
|
||||
bitwarden
|
||||
discord-ptb
|
||||
gnome-calculator
|
||||
inkscape
|
||||
keepassxc
|
||||
krita
|
||||
libreoffice
|
||||
mullvad-vpn
|
||||
parsec-bin
|
||||
qbittorrent
|
||||
reaper
|
||||
solaar
|
||||
spotify
|
||||
vlc
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,65 +1,88 @@
|
|||
{
|
||||
inputs,
|
||||
outputs,
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
policies = {
|
||||
DisableTelemetry = true;
|
||||
DisableFirefoxStudies = true;
|
||||
DisablePocket = true;
|
||||
DisableAccounts = true;
|
||||
DisableFirefoxScreenshots = true;
|
||||
DisplayBookmarksToolbar = "never";
|
||||
PasswordManagerEnabled = false;
|
||||
}: let
|
||||
inherit (lib) mkEnableOption mkIf mkOption types;
|
||||
cfg = config.horseman.apps.visual.firefox;
|
||||
|
||||
ExtensionSettings = {
|
||||
"*".installation_mode = "blocked";
|
||||
# uBlock Origin:
|
||||
"uBlock0@raymondhill.net" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Dark Reader
|
||||
"addon@darkreader.org" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/darkreader/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Advent of Code delta-rank
|
||||
"{78b07db2-25ed-4088-9c92-5c5dcfca3c3c}" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/advent-of-code-delta-score/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# SponsorBlock
|
||||
"sponsorBlocker@ajay.app" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/sponsorblock/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# KeepassXC
|
||||
"keepassxc-browser@keepassxc.org" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/keepassxc-browser/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Cookie Blocker
|
||||
"idcac-pub@guus.ninja" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/istilldontcareaboutcookies/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Ghostery
|
||||
"firefox@ghostery.com" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/ghostery/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
};
|
||||
lock-false = {
|
||||
Value = false;
|
||||
Status = "locked";
|
||||
};
|
||||
lock-true = {
|
||||
Value = true;
|
||||
Status = "locked";
|
||||
};
|
||||
in {
|
||||
options = {
|
||||
horseman.apps.visual.firefox = {
|
||||
enable = mkEnableOption "Firefox";
|
||||
};
|
||||
};
|
||||
|
||||
Preferences = {
|
||||
general = {
|
||||
autoScroll = true;
|
||||
config = {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
policies = {
|
||||
DisableTelemetry = true;
|
||||
DisableFirefoxStudies = true;
|
||||
DisablePocket = true;
|
||||
DisableAccounts = true;
|
||||
DisableFirefoxScreenshots = true;
|
||||
DisplayBookmarksToolbar = "never";
|
||||
PasswordManagerEnabled = false;
|
||||
|
||||
ExtensionSettings = {
|
||||
"*".installation_mode = "blocked";
|
||||
# uBlock Origin:
|
||||
"uBlock0@raymondhill.net" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Dark Reader
|
||||
"addon@darkreader.org" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/darkreader/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Advent of Code delta-rank
|
||||
"{78b07db2-25ed-4088-9c92-5c5dcfca3c3c}" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/advent-of-code-delta-score/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# SponsorBlock
|
||||
"sponsorBlocker@ajay.app" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/sponsorblock/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# KeepassXC
|
||||
"keepassxc-browser@keepassxc.org" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/keepassxc-browser/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Cookie Blocker
|
||||
"idcac-pub@guus.ninja" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/istilldontcareaboutcookies/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
# Ghostery
|
||||
"firefox@ghostery.com" = {
|
||||
install_url = "https://addons.mozilla.org/firefox/downloads/latest/ghostery/latest.xpi";
|
||||
installation_mode = "force_installed";
|
||||
};
|
||||
};
|
||||
|
||||
Preferences = {
|
||||
general = {
|
||||
autoScroll = true;
|
||||
};
|
||||
"browser.newtabpage.activity-stream.showSponsored" = lock-false;
|
||||
"browser.newtabpage.activity-stream.system.showSponsored" = lock-false;
|
||||
"browser.newtabpage.activity-stream.showSponsoredTopSites" = lock-false;
|
||||
};
|
||||
"browser.newtabpage.activity-stream.showSponsored" = lock-false;
|
||||
"browser.newtabpage.activity-stream.system.showSponsored" = lock-false;
|
||||
"browser.newtabpage.activity-stream.showSponsoredTopSites" = lock-false;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
in {
|
||||
options = {
|
||||
horseman = {
|
||||
username = mkOption { type = types.str; };
|
||||
username = mkOption {type = types.str;};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ in {
|
|||
|
||||
config = {
|
||||
home-manager = {
|
||||
extraSpecialArgs = { inherit inputs outputs; };
|
||||
extraSpecialArgs = {inherit inputs outputs;};
|
||||
users.horseman = {
|
||||
home = {
|
||||
username = "horseman";
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@
|
|||
}: let
|
||||
inherit (lib) mkEnableOption mkIf mkOption types;
|
||||
cfg = config.horseman.wm.plasma;
|
||||
homeCfg = config.horseman;
|
||||
in {
|
||||
options = {
|
||||
horseman.wm.plasma = {
|
||||
|
|
@ -32,7 +33,7 @@ in {
|
|||
konsole
|
||||
];
|
||||
|
||||
home-manager.users.horseman = {
|
||||
home-manager.users.${homeCfg.username} = {
|
||||
imports = [./config.nix];
|
||||
};
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue