Compare commits
27 Commits
0907481b8f
...
fe6455b4f2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fe6455b4f2 | ||
|
|
28f82915cf | ||
|
|
2ffb2b1ef5 | ||
|
|
0a52297be4 | ||
|
|
5c4712a5e2 | ||
|
|
e04aca77b3 | ||
|
|
cb5055363a | ||
|
|
4222f21a6d | ||
|
|
0dfc051591 | ||
|
|
6c857ee393 | ||
|
|
b84b427fca | ||
|
|
ac8bc15318 | ||
|
|
e87bf66688 | ||
|
|
19cc2796d0 | ||
|
|
a8f1d7e717 | ||
|
|
7a35643080 | ||
|
|
4225eea9bb | ||
|
|
6e60476521 | ||
|
|
62c029d3aa | ||
|
|
5ac628739e | ||
|
|
2eaa716f66 | ||
|
|
8fcccee072 | ||
|
|
43ffa50146 | ||
|
|
7b62ce1e32 | ||
|
|
516cd60e71 | ||
|
|
491b417827 | ||
|
|
8c7a786456 |
1129
flake.lock
1129
flake.lock
File diff suppressed because it is too large
Load Diff
39
flake.nix
39
flake.nix
@ -1,7 +1,6 @@
|
|||||||
{
|
{
|
||||||
description = ''
|
description = ''
|
||||||
Nixy is a NixOS configuration with home-manager, secrets and custom theming all in one place.
|
Dhimas config based on nixy
|
||||||
It's a simple way to manage your system configuration and dotfiles.
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
@ -19,40 +18,32 @@
|
|||||||
url = "github:Gerg-L/spicetify-nix";
|
url = "github:Gerg-L/spicetify-nix";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
sops-nix = {
|
hyprland.url = "github:/hyprwm/hyprland";
|
||||||
url = "github:Mic92/sops-nix";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
nixy-wallpapers = {
|
|
||||||
url = "github:anotherhadi/nixy-wallpapers";
|
|
||||||
flake = false;
|
|
||||||
};
|
|
||||||
hyprland.url = "github:/hyprwm/Hyprland?submodules=1";
|
|
||||||
hyprpolkitagent.url = "github:hyprwm/hyprpolkitagent";
|
hyprpolkitagent.url = "github:hyprwm/hyprpolkitagent";
|
||||||
hyprsunset.url = "github:hyprwm/hyprsunset";
|
|
||||||
hyprpanel = {
|
|
||||||
url = "github:Jas-SinghFSU/HyprPanel";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
stylix.url = "github:danth/stylix";
|
stylix.url = "github:danth/stylix";
|
||||||
apple-fonts.url = "github:Lyndeno/apple-fonts.nix";
|
|
||||||
firefox-addons = {
|
firefox-addons = {
|
||||||
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
|
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
zen-browser.url = "github:0xc000022070/zen-browser-flake";
|
nvf.url = "github:notashelf/nvf";
|
||||||
|
niri = {
|
||||||
|
url = "github:sodiboo/niri-flake";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
noctalia = {
|
||||||
|
url = "github:noctalia-dev/noctalia-shell";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs@{ nixpkgs, ... }: {
|
outputs = inputs @ {nixpkgs, ...}: {
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
dark = # CHANGEME: This should match the 'hostname' in your variables.nix file
|
dark =
|
||||||
|
# CHANGEME: This should match the 'hostname' in your variables.nix file
|
||||||
nixpkgs.lib.nixosSystem {
|
nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
modules = [
|
modules = [
|
||||||
{
|
{_module.args = {inherit inputs;};}
|
||||||
nixpkgs.overlays = [ inputs.hyprpanel.overlay ];
|
|
||||||
_module.args = { inherit inputs; };
|
|
||||||
}
|
|
||||||
inputs.nixos-hardware.nixosModules.lenovo-thinkpad-x270 # CHANGEME: check https://github.com/NixOS/nixos-hardware
|
inputs.nixos-hardware.nixosModules.lenovo-thinkpad-x270 # CHANGEME: check https://github.com/NixOS/nixos-hardware
|
||||||
inputs.home-manager.nixosModules.home-manager
|
inputs.home-manager.nixosModules.home-manager
|
||||||
inputs.stylix.nixosModules.stylix
|
inputs.stylix.nixosModules.stylix
|
||||||
|
|||||||
@ -1,4 +1,8 @@
|
|||||||
{ pkgs, inputs, ... }: {
|
{
|
||||||
|
pkgs,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
programs.firefox = {
|
programs.firefox = {
|
||||||
enable = true;
|
enable = true;
|
||||||
profiles.dark = {
|
profiles.dark = {
|
||||||
@ -49,10 +53,11 @@
|
|||||||
search = {
|
search = {
|
||||||
force = true;
|
force = true;
|
||||||
default = "Searx";
|
default = "Searx";
|
||||||
order = [ "Searx" "Google" ];
|
order = ["Searx" "google"];
|
||||||
engines = {
|
engines = {
|
||||||
"Nix Packages" = {
|
"Nix Packages" = {
|
||||||
urls = [{
|
urls = [
|
||||||
|
{
|
||||||
template = "https://search.nixos.org/packages";
|
template = "https://search.nixos.org/packages";
|
||||||
params = [
|
params = [
|
||||||
{
|
{
|
||||||
@ -64,34 +69,37 @@
|
|||||||
value = "{searchTerms}";
|
value = "{searchTerms}";
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
}];
|
}
|
||||||
icon =
|
];
|
||||||
"''${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
|
icon = "''${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
|
||||||
definedAliases = [ "@np" ];
|
definedAliases = ["@np"];
|
||||||
};
|
};
|
||||||
"NixOS Wiki" = {
|
"NixOS Wiki" = {
|
||||||
urls = [{
|
urls = [
|
||||||
|
{
|
||||||
template = "https://nixos.wiki/index.php?search={searchTerms}";
|
template = "https://nixos.wiki/index.php?search={searchTerms}";
|
||||||
}];
|
}
|
||||||
iconUpdateURL = "https://nixos.wiki/favicon.png";
|
];
|
||||||
|
icon = "https://nixos.wiki/favicon.png";
|
||||||
updateInterval = 24 * 60 * 60 * 1000; # every day
|
updateInterval = 24 * 60 * 60 * 1000; # every day
|
||||||
definedAliases = [ "@nw" ];
|
definedAliases = ["@nw"];
|
||||||
};
|
};
|
||||||
"Searx" = {
|
"Searx" = {
|
||||||
urls = [{
|
urls = [
|
||||||
|
{
|
||||||
template = "https://searx.aicampground.com/?q={searchTerms}";
|
template = "https://searx.aicampground.com/?q={searchTerms}";
|
||||||
}];
|
}
|
||||||
iconUpdateURL = "https://nixos.wiki/favicon.png";
|
];
|
||||||
|
icon = "https://nixos.wiki/favicon.png";
|
||||||
updateInterval = 24 * 60 * 60 * 1000; # every day
|
updateInterval = 24 * 60 * 60 * 1000; # every day
|
||||||
definedAliases = [ "@searx" ];
|
definedAliases = ["@searx"];
|
||||||
};
|
};
|
||||||
"Bing".metaData.hidden = true;
|
bing.metaData.hidden = true;
|
||||||
"Google".metaData.alias =
|
google.metaData.alias = "@g"; # builtin engines only support specifying one additional alias
|
||||||
"@g"; # builtin engines only support specifying one additional alias
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
extensions = with inputs.firefox-addons.packages.${pkgs.system}; [
|
extensions.packages = with inputs.firefox-addons.packages.${pkgs.stdenv.hostPlatform.system}; [
|
||||||
bitwarden
|
bitwarden
|
||||||
multi-account-containers
|
multi-account-containers
|
||||||
zotero-connector
|
zotero-connector
|
||||||
@ -99,4 +107,5 @@
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
stylix.targets.firefox.profileNames = ["dark"];
|
||||||
}
|
}
|
||||||
|
|||||||
8
home/programs/ghostty/default.nix
Normal file
8
home/programs/ghostty/default.nix
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
programs.ghostty = {
|
||||||
|
enable = true;
|
||||||
|
enableZshIntegration = true;
|
||||||
|
installVimSyntax = true;
|
||||||
|
installBatSyntax = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
@ -1,12 +1,12 @@
|
|||||||
{ config, ... }:
|
{ config, pkgs, ... }:
|
||||||
let
|
let
|
||||||
username = config.var.git.username;
|
username = config.var.git.username;
|
||||||
email = config.var.git.email;
|
email = config.var.git.email;
|
||||||
in {
|
in {
|
||||||
|
home.packages = with pkgs; [ tea ];
|
||||||
programs.git = {
|
programs.git = {
|
||||||
enable = true;
|
enable = true;
|
||||||
userName = username;
|
signing.key = "D8EDD65BCB54AC8719BE4EBD8D5D880EB08F1544";
|
||||||
userEmail = email;
|
|
||||||
ignores = [
|
ignores = [
|
||||||
".cache/"
|
".cache/"
|
||||||
".DS_Store"
|
".DS_Store"
|
||||||
@ -19,10 +19,10 @@ in {
|
|||||||
"result"
|
"result"
|
||||||
"result-*"
|
"result-*"
|
||||||
];
|
];
|
||||||
extraConfig = {
|
settings = {
|
||||||
init.defaultBranch = "main";
|
user = {
|
||||||
push.autoSetupRemote = true;
|
name = username;
|
||||||
color.ui = "1";
|
email = email;
|
||||||
};
|
};
|
||||||
aliases = {
|
aliases = {
|
||||||
essa = "push --force";
|
essa = "push --force";
|
||||||
@ -43,7 +43,8 @@ in {
|
|||||||
af = "!git add $(git ls-files -m -o --exclude-standard | sk -m)";
|
af = "!git add $(git ls-files -m -o --exclude-standard | sk -m)";
|
||||||
st = "status";
|
st = "status";
|
||||||
br = "branch";
|
br = "branch";
|
||||||
df = "!git hist | peco | awk '{print $2}' | xargs -I {} git diff {}^ {}";
|
df =
|
||||||
|
"!git hist | peco | awk '{print $2}' | xargs -I {} git diff {}^ {}";
|
||||||
hist = ''
|
hist = ''
|
||||||
log --pretty=format:"%Cgreen%h %Creset%cd %Cblue[%cn] %Creset%s%C(yellow)%d%C(reset)" --graph --date=relative --decorate --all'';
|
log --pretty=format:"%Cgreen%h %Creset%cd %Cblue[%cn] %Creset%s%C(yellow)%d%C(reset)" --graph --date=relative --decorate --all'';
|
||||||
llog = ''
|
llog = ''
|
||||||
@ -51,5 +52,11 @@ in {
|
|||||||
edit-unmerged =
|
edit-unmerged =
|
||||||
"!f() { git ls-files --unmerged | cut -f2 | sort -u ; }; hx `f`";
|
"!f() { git ls-files --unmerged | cut -f2 | sort -u ; }; hx `f`";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
init.defaultBranch = "main";
|
||||||
|
push.autoSetupRemote = true;
|
||||||
|
color.ui = "1";
|
||||||
|
commit.gpgSign = true;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
18
home/programs/helix/default.nix
Normal file
18
home/programs/helix/default.nix
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
inputs,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
programs.helix = {
|
||||||
|
enable = true;
|
||||||
|
languages = {
|
||||||
|
language = [
|
||||||
|
{
|
||||||
|
name = "nix";
|
||||||
|
auto-format = true;
|
||||||
|
formatter.command = "${pkgs.nixfmt}/bin/nixfmt";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@ -27,4 +27,5 @@
|
|||||||
tab_bar_style = "powerline";
|
tab_bar_style = "powerline";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
stylix.targets.kitty.variant256Colors = true;
|
||||||
}
|
}
|
||||||
|
|||||||
24
home/programs/nvf/default.nix
Normal file
24
home/programs/nvf/default.nix
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
{
|
||||||
|
inputs,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
inputs.nvf.homeManagerModules.default
|
||||||
|
./options.nix
|
||||||
|
./languages.nix
|
||||||
|
./picker.nix
|
||||||
|
./snacks.nix
|
||||||
|
./keymaps.nix
|
||||||
|
./utils.nix
|
||||||
|
./mini.nix
|
||||||
|
];
|
||||||
|
programs.nvf = {
|
||||||
|
enable = true;
|
||||||
|
settings.vim = {
|
||||||
|
startPlugins = [
|
||||||
|
pkgs.vimPlugins.vim-kitty-navigator
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
173
home/programs/nvf/keymaps.nix
Normal file
173
home/programs/nvf/keymaps.nix
Normal file
@ -0,0 +1,173 @@
|
|||||||
|
{
|
||||||
|
programs.nvf.settings.vim = {
|
||||||
|
globals.mapleader = " ";
|
||||||
|
binds = {
|
||||||
|
whichKey = {
|
||||||
|
enable = true;
|
||||||
|
# TODO: registers
|
||||||
|
register = { };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
keymaps = [
|
||||||
|
# General Mappings
|
||||||
|
{
|
||||||
|
key = "s";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua require('flash').jump()<cr>";
|
||||||
|
desc = "Flash";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "K";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua vim.lsp.buf.hover()<cr>";
|
||||||
|
desc = "LSP Hover";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<C-tab>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>bnext<cr>";
|
||||||
|
desc = "Next Buffer";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Kitty navigator
|
||||||
|
{
|
||||||
|
key = "<C-h>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>KittyNavigateLeft<cr>";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<C-j>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>KittyNavigateDown<cr>";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<C-k>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>KittyNavigateUp<cr>";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<C-l>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>KittyNavigateRight<cr>";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Disable Arrow Keys in Normal Mode
|
||||||
|
{
|
||||||
|
key = "<Up>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<Nop>";
|
||||||
|
desc = "Disable Up Arrow";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<Down>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<Nop>";
|
||||||
|
desc = "Disable Down Arrow";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<Left>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<Nop>";
|
||||||
|
desc = "Disable Left Arrow";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<Right>";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<Nop>";
|
||||||
|
desc = "Disable Right Arrow";
|
||||||
|
}
|
||||||
|
|
||||||
|
# UI
|
||||||
|
{
|
||||||
|
key = "<leader>uw";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set wrap!<cr>";
|
||||||
|
desc = "Toggle word wrapping";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>ul";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set linebreak!<cr>";
|
||||||
|
desc = "Toggle linebreak";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>us";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set spell!<cr>";
|
||||||
|
desc = "Toggle spellLazyGitcheck";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>uc";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set cursorline!<cr>";
|
||||||
|
desc = "Toggle cursorline";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>un";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set number!<cr>";
|
||||||
|
desc = "Toggle line numbers";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>ur";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set relativenumber!<cr>";
|
||||||
|
desc = "Toggle relative line numbers";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>ut";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set showtabline=2<cr>";
|
||||||
|
desc = "Show tabline";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>uT";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>set showtabline=0<cr>";
|
||||||
|
desc = "Hide tabline";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Windows
|
||||||
|
{
|
||||||
|
key = "<leader>ws";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>split<cr>";
|
||||||
|
desc = "Split";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>wv";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>vsplit<cr>";
|
||||||
|
desc = "VSplit";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>wd";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>close<cr>";
|
||||||
|
desc = "Close";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
99
home/programs/nvf/languages.nix
Normal file
99
home/programs/nvf/languages.nix
Normal file
@ -0,0 +1,99 @@
|
|||||||
|
{ lib, pkgs, ... }: {
|
||||||
|
programs.nvf.settings.vim = {
|
||||||
|
diagnostics = {
|
||||||
|
enable = true;
|
||||||
|
config = {
|
||||||
|
signs = {
|
||||||
|
text = {
|
||||||
|
"vim.diagnostic.severity.Error" = " ";
|
||||||
|
"vim.diagnostic.severity.Warn" = " ";
|
||||||
|
"vim.diagnostic.severity.Hint" = " ";
|
||||||
|
"vim.diagnostic.severity.Info" = " ";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
underline = true;
|
||||||
|
update_in_insert = true;
|
||||||
|
virtual_text = {
|
||||||
|
format = lib.generators.mkLuaInline
|
||||||
|
# lua
|
||||||
|
''
|
||||||
|
function(diagnostic)
|
||||||
|
return string.format("%s", diagnostic.message)
|
||||||
|
--return string.format("%s (%s)", diagnostic.message, diagnostic.source)
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
nvim-lint = { enable = true; };
|
||||||
|
};
|
||||||
|
syntaxHighlighting = true;
|
||||||
|
treesitter = {
|
||||||
|
enable = true;
|
||||||
|
autotagHtml = true;
|
||||||
|
context.enable = true;
|
||||||
|
highlight.enable = true;
|
||||||
|
grammars = with pkgs.vimPlugins.nvim-treesitter.builtGrammars;
|
||||||
|
[
|
||||||
|
typescript # in language settings only tsx gets enabled, not typescript
|
||||||
|
];
|
||||||
|
};
|
||||||
|
lsp = {
|
||||||
|
enable = true;
|
||||||
|
trouble.enable = true;
|
||||||
|
lspSignature.enable = true;
|
||||||
|
lspconfig.enable = true;
|
||||||
|
formatOnSave = true;
|
||||||
|
inlayHints.enable = true;
|
||||||
|
null-ls.enable = true;
|
||||||
|
servers.nixd.settings.nil.nix.autoArchive = true;
|
||||||
|
otter-nvim = {
|
||||||
|
enable = true;
|
||||||
|
setupOpts = {
|
||||||
|
buffers.set_filetype = true;
|
||||||
|
lsp = { diagnostic_update_event = [ "BufWritePost" "InsertLeave" ]; };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
lspkind.enable = true;
|
||||||
|
lspsaga = {
|
||||||
|
enable = true;
|
||||||
|
setupOpts = {
|
||||||
|
ui = { code_action = ""; };
|
||||||
|
lightbulb = {
|
||||||
|
sign = false;
|
||||||
|
virtual_text = true;
|
||||||
|
};
|
||||||
|
breadcrumbs.enable = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
languages = {
|
||||||
|
enableDAP = true;
|
||||||
|
enableExtraDiagnostics = true;
|
||||||
|
enableFormat = true;
|
||||||
|
enableTreesitter = true;
|
||||||
|
|
||||||
|
php = {
|
||||||
|
enable = true;
|
||||||
|
lsp.server = "intelephense";
|
||||||
|
};
|
||||||
|
go.enable = true;
|
||||||
|
markdown = {
|
||||||
|
enable = true;
|
||||||
|
format.type = "prettierd";
|
||||||
|
extensions = { markview-nvim = { enable = true; }; };
|
||||||
|
extraDiagnostics.enable = true;
|
||||||
|
};
|
||||||
|
ts = {
|
||||||
|
enable = false;
|
||||||
|
extensions.ts-error-translator.enable = true;
|
||||||
|
};
|
||||||
|
css.enable = true;
|
||||||
|
sql.enable = true;
|
||||||
|
html.enable = true;
|
||||||
|
bash.enable = true;
|
||||||
|
nix.enable = true;
|
||||||
|
tailwind.enable = true;
|
||||||
|
};
|
||||||
|
formatter = { conform-nvim = { enable = true; }; };
|
||||||
|
};
|
||||||
|
}
|
||||||
13
home/programs/nvf/mini.nix
Normal file
13
home/programs/nvf/mini.nix
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
{
|
||||||
|
programs.nvf.settings.vim.mini = {
|
||||||
|
starter.enable = true;
|
||||||
|
comment.enable = true;
|
||||||
|
# cursorword.enable = true;
|
||||||
|
icons.enable = true;
|
||||||
|
indentscope.enable = true;
|
||||||
|
notify.enable = true;
|
||||||
|
pairs.enable = true;
|
||||||
|
diff.enable = true;
|
||||||
|
git.enable = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
40
home/programs/nvf/options.nix
Normal file
40
home/programs/nvf/options.nix
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
{ lib, ... }: {
|
||||||
|
programs.nvf.settings.vim = {
|
||||||
|
viAlias = false;
|
||||||
|
vimAlias = true;
|
||||||
|
withNodeJs = true;
|
||||||
|
# syntaxHighlighting = true;
|
||||||
|
options = {
|
||||||
|
autoindent = true;
|
||||||
|
smartindent = true;
|
||||||
|
shiftwidth = 2;
|
||||||
|
foldlevel = 99;
|
||||||
|
foldcolumn = "auto:1";
|
||||||
|
mousescroll = "ver:1,hor:1";
|
||||||
|
mousemoveevent = true;
|
||||||
|
fillchars = "eob:‿,fold: ,foldopen:▼,foldsep:⸽,foldclose:⏵";
|
||||||
|
signcolumn = "yes";
|
||||||
|
tabstop = 2;
|
||||||
|
softtabstop = 2;
|
||||||
|
wrap = false;
|
||||||
|
};
|
||||||
|
globals = {
|
||||||
|
navic_silence = true; # navic tries to attach multiple LSPs and fails
|
||||||
|
suda_smart_edit = 1; # use super user write automatically
|
||||||
|
neovide_scale_factor = 0.7;
|
||||||
|
neovide_cursor_animation_length = 0.1;
|
||||||
|
neovide_cursor_short_animation_length = 0;
|
||||||
|
};
|
||||||
|
clipboard = {
|
||||||
|
enable = true;
|
||||||
|
registers = "unnamedplus";
|
||||||
|
providers.wl-copy.enable = true;
|
||||||
|
};
|
||||||
|
theme = {
|
||||||
|
enable = true;
|
||||||
|
name = lib.mkForce "catppuccin";
|
||||||
|
style = lib.mkForce "mocha";
|
||||||
|
transparent = lib.mkForce true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
257
home/programs/nvf/picker.nix
Normal file
257
home/programs/nvf/picker.nix
Normal file
@ -0,0 +1,257 @@
|
|||||||
|
{
|
||||||
|
programs.nvf.settings.vim = {
|
||||||
|
utility = {
|
||||||
|
oil-nvim.enable = true;
|
||||||
|
snacks-nvim = {
|
||||||
|
setupOpts = {
|
||||||
|
picker.enabled = true;
|
||||||
|
explorer.enabled = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
keymaps = [
|
||||||
|
# Top Pickers & Explorer
|
||||||
|
{
|
||||||
|
key = "<leader> ";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.smart()<cr>";
|
||||||
|
desc = "Smart Find Files";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>,";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.buffers()<cr>";
|
||||||
|
desc = "Buffers";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>/";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.grep()<cr>";
|
||||||
|
desc = "Grep";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>:";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.command_history()<cr>";
|
||||||
|
desc = "Command History";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>e";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.explorer()<cr>";
|
||||||
|
desc = "File Explorer";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "-";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>Oil<cr>";
|
||||||
|
desc = "Oil";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Find
|
||||||
|
{
|
||||||
|
key = "<leader>fb";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.buffers()<cr>";
|
||||||
|
desc = "Buffers";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>fc";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = ''
|
||||||
|
<cmd>lua Snacks.picker.files({ cwd = vim.fn.stdpath("config") })<cr>'';
|
||||||
|
desc = "Find Config File";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>ff";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.files()<cr>";
|
||||||
|
desc = "Find Files";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>fg";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.git_files()<cr>";
|
||||||
|
desc = "Find Git Files";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>fp";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.projects()<cr>";
|
||||||
|
desc = "Projects";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>fr";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.recent()<cr>";
|
||||||
|
desc = "Recent";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>fn";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.notifications()<cr>";
|
||||||
|
desc = "Notification History";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>fe";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.icons()<cr>";
|
||||||
|
desc = "Emoji";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Git
|
||||||
|
{
|
||||||
|
key = "<leader>gb";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.git_branches()<cr>";
|
||||||
|
desc = "Git Branches";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>gL";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.git_log()<cr>";
|
||||||
|
desc = "Git Log Line";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>gs";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.git_status()<cr>";
|
||||||
|
desc = "Git Status";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>gS";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.git_stash()<cr>";
|
||||||
|
desc = "Git Stash";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>gd";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.git_diff()<cr>";
|
||||||
|
desc = "Git Diff (Hunks)";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>gf";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.git_log_file()<cr>";
|
||||||
|
desc = "Git Log File";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Grep
|
||||||
|
{
|
||||||
|
key = "<leader>sb";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lines()<cr>";
|
||||||
|
desc = "Buffer Lines";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>st";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.todo_comments()<cr>";
|
||||||
|
desc = "Todos";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>sB";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.grep_buffers()<cr>";
|
||||||
|
desc = "Grep Open Buffers";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>sg";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.grep()<cr>";
|
||||||
|
desc = "Grep";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>sw";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.grep_word()<cr>";
|
||||||
|
desc = "Visual selection or word";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>sr";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>nohlsearch<cr>";
|
||||||
|
desc = "Reset search";
|
||||||
|
}
|
||||||
|
|
||||||
|
# LSP
|
||||||
|
{
|
||||||
|
key = "gd";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lsp_definitions()<cr>";
|
||||||
|
desc = "Goto Definition";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "gD";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lsp_declarations()<cr>";
|
||||||
|
desc = "Goto Declaration";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "gr";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lsp_references()<cr>";
|
||||||
|
desc = "References";
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "gI";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lsp_implementations()<cr>";
|
||||||
|
desc = "Goto Implementation";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "gy";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lsp_type_definitions()<cr>";
|
||||||
|
desc = "Goto Type Definition";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>ss";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lsp_symbols()<cr>";
|
||||||
|
desc = "LSP Symbols";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<leader>sS";
|
||||||
|
mode = "n";
|
||||||
|
silent = true;
|
||||||
|
action = "<cmd>lua Snacks.picker.lsp_workspace_symbols()<cr>";
|
||||||
|
desc = "LSP Workspace Symbols";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
19
home/programs/nvf/snacks.nix
Normal file
19
home/programs/nvf/snacks.nix
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
{
|
||||||
|
programs.nvf.settings.vim.utility.snacks-nvim = {
|
||||||
|
enable = true;
|
||||||
|
setupOpts = {
|
||||||
|
image = {
|
||||||
|
enabled = true;
|
||||||
|
doc = {
|
||||||
|
inline = false;
|
||||||
|
float = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
quickfile.enabled = true;
|
||||||
|
statuscolumn.enabled = true;
|
||||||
|
zen.enabled = true;
|
||||||
|
bufdelete.enabled = true;
|
||||||
|
gitsigns.enabled = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
49
home/programs/nvf/utils.nix
Normal file
49
home/programs/nvf/utils.nix
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
{ pkgs, ... }: {
|
||||||
|
programs.nvf.settings.vim = {
|
||||||
|
undoFile.enable = true;
|
||||||
|
utility = {
|
||||||
|
motion.flash-nvim.enable = true;
|
||||||
|
outline.aerial-nvim.enable = true;
|
||||||
|
};
|
||||||
|
tabline.nvimBufferline.enable = true;
|
||||||
|
notes.todo-comments.enable = true;
|
||||||
|
assistant.copilot = {
|
||||||
|
enable = false;
|
||||||
|
cmp.enable = true;
|
||||||
|
};
|
||||||
|
statusline.lualine.enable = true;
|
||||||
|
|
||||||
|
autocomplete = {
|
||||||
|
nvim-cmp = {
|
||||||
|
enable = true;
|
||||||
|
sources = {
|
||||||
|
buffer = "[Buffer]";
|
||||||
|
nvim-cmp = null;
|
||||||
|
path = "[Path]";
|
||||||
|
};
|
||||||
|
sourcePlugins = [ pkgs.vimPlugins.cmp-cmdline ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
snippets.luasnip.enable = true;
|
||||||
|
ui = {
|
||||||
|
noice.enable = true;
|
||||||
|
colorizer.enable = true;
|
||||||
|
};
|
||||||
|
git = {
|
||||||
|
enable = true;
|
||||||
|
gitsigns.enable = true;
|
||||||
|
};
|
||||||
|
terminal.toggleterm = {
|
||||||
|
enable = true;
|
||||||
|
lazygit = {
|
||||||
|
enable = true;
|
||||||
|
mappings.open = "<leader>gl";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
visuals = {
|
||||||
|
rainbow-delimiters.enable = true;
|
||||||
|
nvim-scrollbar = { enable = false; };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
186
home/programs/nvim/autocmds.nix
Normal file
186
home/programs/nvim/autocmds.nix
Normal file
@ -0,0 +1,186 @@
|
|||||||
|
{
|
||||||
|
programs.nixvim = {
|
||||||
|
autoGroups = {
|
||||||
|
auto_quit.clear = true;
|
||||||
|
autoview.clear = true;
|
||||||
|
checktime.clear = true;
|
||||||
|
create_dir.clear = true;
|
||||||
|
editorconfig_filetype.clear = true;
|
||||||
|
file_user_events.clear = true;
|
||||||
|
highlighturl.clear = true;
|
||||||
|
highlightyank.clear = true;
|
||||||
|
large_buf_settings.clear = true;
|
||||||
|
q_close_windows.clear = true;
|
||||||
|
terminal_settings.clear = true;
|
||||||
|
unlist_quickfix.clear = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
autoCmd = [
|
||||||
|
# auto_quit
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L18-L46
|
||||||
|
{
|
||||||
|
desc =
|
||||||
|
"Quit neovim if more than one window is open and only sidebar windows are list";
|
||||||
|
event = "BufEnter";
|
||||||
|
group = "auto_quit";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function()
|
||||||
|
local wins = vim.api.nvim_tabpage_list_wins(0)
|
||||||
|
-- Both neo-tree and aerial will auto-quit if there is only a single window left
|
||||||
|
if #wins <= 1 then return end
|
||||||
|
local sidebar_fts = { aerial = true, ["neo-tree"] = true }
|
||||||
|
for _, winid in ipairs(wins) do
|
||||||
|
if vim.api.nvim_win_is_valid(winid) then
|
||||||
|
local bufnr = vim.api.nvim_win_get_buf(winid)
|
||||||
|
local filetype = vim.bo[bufnr].filetype
|
||||||
|
-- If any visible windows are not sidebars, early return
|
||||||
|
if not sidebar_fts[filetype] then
|
||||||
|
return
|
||||||
|
-- If the visible window is a sidebar
|
||||||
|
else
|
||||||
|
-- only count filetypes once, so remove a found sidebar from the detection
|
||||||
|
sidebar_fts[filetype] = nil
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if #vim.api.nvim_list_tabpages() > 1 then
|
||||||
|
vim.cmd.tabclose()
|
||||||
|
else
|
||||||
|
vim.cmd.qall()
|
||||||
|
end
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
||||||
|
# autoview
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L49-L70
|
||||||
|
{
|
||||||
|
desc = "Save view with mkview for real files";
|
||||||
|
event = [ "BufWinLeave" "BufWritePost" "WinLeave" ];
|
||||||
|
group = "autoview";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function(event)
|
||||||
|
if vim.b[event.buf].view_activated then vim.cmd.mkview { mods = { emsg_silent = true } } end
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
{
|
||||||
|
desc =
|
||||||
|
"Try to load file view if available and enable view saving for real files";
|
||||||
|
event = "BufWinEnter";
|
||||||
|
group = "autoview";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function(event)
|
||||||
|
if not vim.b[event.buf].view_activated then
|
||||||
|
local filetype = vim.bo[event.buf].filetype
|
||||||
|
local buftype = vim.bo[event.buf].buftype
|
||||||
|
local ignore_filetypes = { "gitcommit", "gitrebase", "svg", "hgcommit" }
|
||||||
|
if buftype == "" and filetype and filetype ~= "" and not vim.tbl_contains(ignore_filetypes, filetype) then
|
||||||
|
vim.b[event.buf].view_activated = true
|
||||||
|
vim.cmd.loadview { mods = { emsg_silent = true } }
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
||||||
|
# checktime
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L118-L122
|
||||||
|
{
|
||||||
|
desc = "Check if buffers changed on editor focus";
|
||||||
|
event = [ "FocusGained" "TermClose" "TermLeave" ];
|
||||||
|
group = "checktime";
|
||||||
|
command = "checktime";
|
||||||
|
}
|
||||||
|
|
||||||
|
# editorconfig_filetype
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L135-L144
|
||||||
|
{
|
||||||
|
desc =
|
||||||
|
"Configure editorconfig after filetype detection to override `ftplugin`s";
|
||||||
|
event = "FileType";
|
||||||
|
group = "editorconfig_filetype";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function(args)
|
||||||
|
if vim.F.if_nil(vim.b.editorconfig, vim.g.editorconfig, true) then
|
||||||
|
local editorconfig_avail, editorconfig = pcall(require, "editorconfig")
|
||||||
|
if editorconfig_avail then editorconfig.config(args.buf) end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
||||||
|
# highlightyank
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L206-L211
|
||||||
|
{
|
||||||
|
desc = "Highlight yanked text";
|
||||||
|
event = "TextYankPost";
|
||||||
|
group = "highlightyank";
|
||||||
|
pattern = "*";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function()
|
||||||
|
vim.highlight.on_yank()
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
||||||
|
# q_close_windows
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L242-L255
|
||||||
|
{
|
||||||
|
desc = "Make q close help, man, quickfix, dap floats";
|
||||||
|
event = "BufWinEnter";
|
||||||
|
group = "q_close_windows";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function(event)
|
||||||
|
if vim.tbl_contains({ "help", "nofile", "quickfix" }, vim.bo[event.buf].buftype) then
|
||||||
|
vim.keymap.set("n", "q", "<Cmd>close<CR>", {
|
||||||
|
desc = "Close window",
|
||||||
|
buffer = event.buf,
|
||||||
|
silent = true,
|
||||||
|
nowait = true,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
||||||
|
# terminal_settings
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L258-L266
|
||||||
|
{
|
||||||
|
desc = "Disable line number/fold column/sign column for terminals";
|
||||||
|
event = "TermOpen";
|
||||||
|
group = "terminal_settings";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function()
|
||||||
|
vim.opt_local.number = false
|
||||||
|
vim.opt_local.relativenumber = false
|
||||||
|
vim.opt_local.foldcolumn = "0"
|
||||||
|
vim.opt_local.signcolumn = "no"
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
||||||
|
# unlist_quickfix
|
||||||
|
# https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/_astrocore_autocmds.lua#L270-L275
|
||||||
|
{
|
||||||
|
desc = "Unlist quickfix buffers";
|
||||||
|
event = "FileType";
|
||||||
|
group = "unlist_quickfix";
|
||||||
|
pattern = "qf";
|
||||||
|
|
||||||
|
callback.__raw = ''
|
||||||
|
function()
|
||||||
|
vim.opt_local.buflisted = false
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
@ -1,13 +1,14 @@
|
|||||||
# Nixvim is a NixOS module that installs and configures Neovim
|
# Nixvim is a NixOS module that installs and configures Neovim
|
||||||
{ inputs, ... }: {
|
{ inputs, ... }: {
|
||||||
imports = [
|
imports = [
|
||||||
inputs.nixvim.homeManagerModules.nixvim
|
inputs.nixvim.homeModules.nixvim
|
||||||
./plugins/cmp.nix
|
./plugins/cmp.nix
|
||||||
./plugins/dashboard.nix
|
./plugins/dashboard.nix
|
||||||
./plugins/lsp.nix
|
./plugins/lsp.nix
|
||||||
./plugins/markdown.nix
|
./plugins/markdown.nix
|
||||||
./plugins/tree.nix
|
./plugins/tree.nix
|
||||||
./plugins/ui.nix
|
./plugins/ui.nix
|
||||||
|
./plugins/lualine.nix
|
||||||
./plugins/utils.nix
|
./plugins/utils.nix
|
||||||
./plugins/dap.nix
|
./plugins/dap.nix
|
||||||
./plugins/telescope.nix
|
./plugins/telescope.nix
|
||||||
@ -17,6 +18,7 @@
|
|||||||
|
|
||||||
./options.nix
|
./options.nix
|
||||||
./keymaps.nix
|
./keymaps.nix
|
||||||
|
./autocmds.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.nixvim.enable = true;
|
programs.nixvim.enable = true;
|
||||||
|
|||||||
@ -313,6 +313,16 @@
|
|||||||
action = "<cmd>lua require('dap').toggle_breakpoint()<CR>";
|
action = "<cmd>lua require('dap').toggle_breakpoint()<CR>";
|
||||||
options.desc = "Toggle breakpoint";
|
options.desc = "Toggle breakpoint";
|
||||||
}
|
}
|
||||||
|
{
|
||||||
|
key = "<S-l>";
|
||||||
|
action = "<cmd>BufferLineCycleNext<CR>";
|
||||||
|
options.desc = "Go to next buffer";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "<S-h>";
|
||||||
|
action = "<cmd>BufferLineCyclePrev<CR>";
|
||||||
|
options.desc = "Go to previous buffer";
|
||||||
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,40 +1,149 @@
|
|||||||
{
|
{
|
||||||
programs.nixvim.globals.mapleader = " ";
|
programs.nixvim = {
|
||||||
programs.nixvim.opts = {
|
globals.mapleader = " ";
|
||||||
updatetime = 50; # Faster completion
|
opts = {
|
||||||
|
|
||||||
number = true;
|
|
||||||
relativenumber = true;
|
|
||||||
|
|
||||||
autoindent = true;
|
autoindent = true;
|
||||||
clipboard = "unnamed,unnamedplus";
|
|
||||||
|
|
||||||
expandtab = true;
|
|
||||||
tabstop = 2;
|
|
||||||
softtabstop = 2;
|
|
||||||
shiftwidth = 2;
|
|
||||||
smartindent = true;
|
smartindent = true;
|
||||||
breakindent = true;
|
|
||||||
|
|
||||||
ignorecase = true;
|
|
||||||
incsearch = true;
|
incsearch = true;
|
||||||
hlsearch = true;
|
hlsearch = true;
|
||||||
smartcase = true;
|
|
||||||
wildmode = "list:longest";
|
wildmode = "list:longest";
|
||||||
completeopt = [ "menuone" "noselect" "noinsert" ];
|
|
||||||
signcolumn = "yes";
|
|
||||||
cursorline = false;
|
|
||||||
scrolloff = 8;
|
scrolloff = 8;
|
||||||
mouse = "a";
|
|
||||||
termguicolors = true;
|
|
||||||
showmode = false;
|
|
||||||
|
|
||||||
wrap = false;
|
|
||||||
linebreak = true;
|
|
||||||
|
|
||||||
swapfile = false;
|
swapfile = false;
|
||||||
undofile = true;
|
|
||||||
conceallevel = 3;
|
conceallevel = 3;
|
||||||
|
clipboard = "unnamed,unnamedplus";
|
||||||
|
|
||||||
|
# Don't stop backspace at insert
|
||||||
|
backspace.__raw = ''
|
||||||
|
vim.list_extend(vim.opt.backspace:get(), { "nostop" })
|
||||||
|
'';
|
||||||
|
|
||||||
|
# Keep visual indentation on wrapped lines
|
||||||
|
breakindent = true;
|
||||||
|
|
||||||
|
# Hide command line unless needed
|
||||||
|
cmdheight = 0;
|
||||||
|
|
||||||
|
# Insert mode completion options
|
||||||
|
completeopt = [ "menu" "menuone" "noselect" ];
|
||||||
|
|
||||||
|
# Raise a dialog asking if you wish to save the current file(s)
|
||||||
|
confirm = true;
|
||||||
|
|
||||||
|
# Copy previous indentation on autoindenting
|
||||||
|
copyindent = true;
|
||||||
|
|
||||||
|
# Highlight current line
|
||||||
|
cursorline = true;
|
||||||
|
|
||||||
|
# Enable linematch diff algorithm
|
||||||
|
diffopt.__raw = ''
|
||||||
|
vim.list_extend(vim.opt.diffopt:get(), { "algorithm:histogram", "linematch:60" })
|
||||||
|
'';
|
||||||
|
|
||||||
|
# Expand <Tab> to spaces
|
||||||
|
expandtab = true;
|
||||||
|
|
||||||
|
# Disable `~` on nonexistent lines
|
||||||
|
fillchars = { eob = " "; };
|
||||||
|
|
||||||
|
# Enable fold with all code unfolded
|
||||||
|
foldcolumn = "1";
|
||||||
|
foldenable = true;
|
||||||
|
foldlevel = 99;
|
||||||
|
foldlevelstart = 99;
|
||||||
|
|
||||||
|
# Ignore case in search patterns
|
||||||
|
ignorecase = true;
|
||||||
|
|
||||||
|
# Show substitution preview in split window
|
||||||
|
inccommand = "split";
|
||||||
|
|
||||||
|
# Infer casing on word completion
|
||||||
|
infercase = true;
|
||||||
|
|
||||||
|
# Global statusline
|
||||||
|
laststatus = 3;
|
||||||
|
|
||||||
|
# Wrap lines at 'breakat'
|
||||||
|
linebreak = true;
|
||||||
|
|
||||||
|
# Enable mouse support
|
||||||
|
mouse = "a";
|
||||||
|
|
||||||
|
# Show line numbers
|
||||||
|
number = true;
|
||||||
|
|
||||||
|
# Preserve indentation as much as possible
|
||||||
|
preserveindent = true;
|
||||||
|
|
||||||
|
# Height of the popup menu
|
||||||
|
pumheight = 10;
|
||||||
|
|
||||||
|
# Display line numbers relative to current line
|
||||||
|
relativenumber = true;
|
||||||
|
|
||||||
|
# Minimal number of lines to keep around the cursor
|
||||||
|
# This has the effect to move the view along with current line
|
||||||
|
#scrolloff = 999;
|
||||||
|
|
||||||
|
# Number of spaces to use for indentation
|
||||||
|
shiftwidth = 2;
|
||||||
|
|
||||||
|
# Disable search count wrap and startup messages
|
||||||
|
shortmess.__raw = ''
|
||||||
|
vim.tbl_deep_extend("force", vim.opt.shortmess:get(), { s = true, I = true })
|
||||||
|
'';
|
||||||
|
|
||||||
|
# Disable showing modes in command line
|
||||||
|
showmode = false;
|
||||||
|
|
||||||
|
# Show signs column
|
||||||
|
signcolumn = "yes";
|
||||||
|
|
||||||
|
# Override ignorecase if search pattern contains uppercase characters
|
||||||
|
smartcase = true;
|
||||||
|
|
||||||
|
# Number of spaces input on <Tab>
|
||||||
|
softtabstop = 2;
|
||||||
|
|
||||||
|
# Open horizontal split below (:split)
|
||||||
|
splitbelow = true;
|
||||||
|
|
||||||
|
# Open vertical split to the right (:vsplit)
|
||||||
|
splitright = true;
|
||||||
|
|
||||||
|
# Number of spaces to represent a <Tab>
|
||||||
|
tabstop = 2;
|
||||||
|
|
||||||
|
# Enables 24-bit RGB color
|
||||||
|
termguicolors = true;
|
||||||
|
|
||||||
|
# Shorter timeout duration
|
||||||
|
timeoutlen = 500;
|
||||||
|
|
||||||
|
# Set window title to the filename
|
||||||
|
title = true;
|
||||||
|
|
||||||
|
# Save undo history to undo file (in $XDG_STATE_HOME/nvim/undo)
|
||||||
|
undofile = true;
|
||||||
|
|
||||||
|
viewoptions.__raw = ''
|
||||||
|
vim.tbl_filter(function(val) return val ~= "curdir" end, vim.opt.viewoptions:get())
|
||||||
|
'';
|
||||||
|
|
||||||
|
# Enable virtual edit in visual block mode
|
||||||
|
# This has the effect of selecting empty cells beyond lines boundaries
|
||||||
|
virtualedit = "block";
|
||||||
|
|
||||||
|
# Disable line wrapping
|
||||||
|
wrap = false;
|
||||||
|
|
||||||
|
# Disable making a backup before overwriting a file
|
||||||
|
writebackup = false;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
programs.nixvim.extraConfigLuaPost = ''
|
programs.nixvim.extraConfigLuaPost = ''
|
||||||
vim.g.neovide_scale_factor = 1.0
|
vim.g.neovide_scale_factor = 1.0
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
{
|
{
|
||||||
programs.nixvim.plugins = {
|
programs.nixvim.plugins = {
|
||||||
luasnip.enable = true;
|
luasnip.enable = true;
|
||||||
|
friendly-snippets.enable = true;
|
||||||
cmp-buffer = { enable = true; };
|
cmp-buffer = { enable = true; };
|
||||||
cmp-emoji = { enable = true; };
|
cmp-emoji = { enable = true; };
|
||||||
cmp-nvim-lsp = { enable = true; };
|
cmp-nvim-lsp = { enable = true; };
|
||||||
@ -68,7 +69,6 @@
|
|||||||
Calendar = "",
|
Calendar = "",
|
||||||
Watch = "",
|
Watch = "",
|
||||||
Package = "",
|
Package = "",
|
||||||
Copilot = "",
|
|
||||||
Codeium = "",
|
Codeium = "",
|
||||||
TabNine = "",
|
TabNine = "",
|
||||||
}
|
}
|
||||||
@ -112,6 +112,5 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -16,13 +16,9 @@
|
|||||||
texthl = "DapLogPoint";
|
texthl = "DapLogPoint";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
extensions = {
|
|
||||||
dap-go = {
|
|
||||||
enable = true;
|
|
||||||
delve.path = "${pkgs.delve}/bin/dlv";
|
|
||||||
};
|
|
||||||
dap-ui = { enable = true; };
|
|
||||||
dap-virtual-text = { enable = true; };
|
|
||||||
};
|
};
|
||||||
|
programs.nixvim.plugins = {
|
||||||
|
dap-virtual-text.enable = true;
|
||||||
|
dap-ui.enable = true;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -50,7 +50,17 @@ in {
|
|||||||
val = " Find file";
|
val = " Find file";
|
||||||
on_press.__raw = "function() vim.cmd[[Telescope find_files]] end";
|
on_press.__raw = "function() vim.cmd[[Telescope find_files]] end";
|
||||||
opts = {
|
opts = {
|
||||||
shortcut = "nf";
|
keymap = [
|
||||||
|
"n"
|
||||||
|
"f"
|
||||||
|
":Telescope find_files <CR>"
|
||||||
|
{
|
||||||
|
noremap = true;
|
||||||
|
silent = true;
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
shortcut = "f";
|
||||||
position = "center";
|
position = "center";
|
||||||
cursor = 3;
|
cursor = 3;
|
||||||
width = 50;
|
width = 50;
|
||||||
@ -64,7 +74,17 @@ in {
|
|||||||
val = " New file";
|
val = " New file";
|
||||||
on_press.__raw = "function() vim.cmd[[ene]] end";
|
on_press.__raw = "function() vim.cmd[[ene]] end";
|
||||||
opts = {
|
opts = {
|
||||||
shortcut = "nn";
|
keymap = [
|
||||||
|
"n"
|
||||||
|
"n"
|
||||||
|
":ene <CR>"
|
||||||
|
{
|
||||||
|
noremap = true;
|
||||||
|
silent = true;
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
shortcut = "n";
|
||||||
position = "center";
|
position = "center";
|
||||||
cursor = 3;
|
cursor = 3;
|
||||||
width = 50;
|
width = 50;
|
||||||
@ -78,7 +98,17 @@ in {
|
|||||||
val = " NixOs Config";
|
val = " NixOs Config";
|
||||||
on_press.__raw = "function() vim.cmd[[Neotree ${configDir}]] end";
|
on_press.__raw = "function() vim.cmd[[Neotree ${configDir}]] end";
|
||||||
opts = {
|
opts = {
|
||||||
shortcut = "nc";
|
keymap = [
|
||||||
|
"n"
|
||||||
|
"c"
|
||||||
|
":Neotree ${configDir} <CR>"
|
||||||
|
{
|
||||||
|
noremap = true;
|
||||||
|
silent = true;
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
shortcut = "c";
|
||||||
position = "center";
|
position = "center";
|
||||||
cursor = 3;
|
cursor = 3;
|
||||||
width = 50;
|
width = 50;
|
||||||
@ -93,7 +123,17 @@ in {
|
|||||||
on_press.__raw =
|
on_press.__raw =
|
||||||
"function() vim.cmd[[e ${configDir}/docs/KEYBINDINGS.md]] end";
|
"function() vim.cmd[[e ${configDir}/docs/KEYBINDINGS.md]] end";
|
||||||
opts = {
|
opts = {
|
||||||
shortcut = "nc";
|
keymap = [
|
||||||
|
"n"
|
||||||
|
"b"
|
||||||
|
":e ${configDir}/docs/KEYBINDINGS.md <CR>"
|
||||||
|
{
|
||||||
|
noremap = true;
|
||||||
|
silent = true;
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
shortcut = "b";
|
||||||
position = "center";
|
position = "center";
|
||||||
cursor = 3;
|
cursor = 3;
|
||||||
width = 50;
|
width = 50;
|
||||||
@ -107,7 +147,17 @@ in {
|
|||||||
val = " Recently used";
|
val = " Recently used";
|
||||||
on_press.__raw = "function() vim.cmd[[Telescope oldfiles]] end";
|
on_press.__raw = "function() vim.cmd[[Telescope oldfiles]] end";
|
||||||
opts = {
|
opts = {
|
||||||
shortcut = "no";
|
keymap = [
|
||||||
|
"n"
|
||||||
|
"o"
|
||||||
|
":Telescope oldfiles <CR>"
|
||||||
|
{
|
||||||
|
noremap = true;
|
||||||
|
silent = true;
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
shortcut = "o";
|
||||||
position = "center";
|
position = "center";
|
||||||
cursor = 3;
|
cursor = 3;
|
||||||
width = 50;
|
width = 50;
|
||||||
@ -121,7 +171,17 @@ in {
|
|||||||
val = " Find text";
|
val = " Find text";
|
||||||
on_press.__raw = "function() vim.cmd[[Telescope live_grep]] end";
|
on_press.__raw = "function() vim.cmd[[Telescope live_grep]] end";
|
||||||
opts = {
|
opts = {
|
||||||
shortcut = "nt";
|
keymap = [
|
||||||
|
"n"
|
||||||
|
"t"
|
||||||
|
":Telescope live_grep <CR>"
|
||||||
|
{
|
||||||
|
noremap = true;
|
||||||
|
silent = true;
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
shortcut = "t";
|
||||||
position = "center";
|
position = "center";
|
||||||
cursor = 3;
|
cursor = 3;
|
||||||
width = 50;
|
width = 50;
|
||||||
@ -135,7 +195,17 @@ in {
|
|||||||
val = " Quit Neovim";
|
val = " Quit Neovim";
|
||||||
on_press.__raw = "function() vim.cmd[[qa]] end";
|
on_press.__raw = "function() vim.cmd[[qa]] end";
|
||||||
opts = {
|
opts = {
|
||||||
shortcut = "nq";
|
keymap = [
|
||||||
|
"n"
|
||||||
|
"q"
|
||||||
|
":qa <CR>"
|
||||||
|
{
|
||||||
|
noremap = true;
|
||||||
|
silent = true;
|
||||||
|
nowait = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
shortcut = "q";
|
||||||
position = "center";
|
position = "center";
|
||||||
cursor = 3;
|
cursor = 3;
|
||||||
width = 50;
|
width = 50;
|
||||||
|
|||||||
@ -40,7 +40,7 @@
|
|||||||
enable = true;
|
enable = true;
|
||||||
sources = {
|
sources = {
|
||||||
diagnostics = {
|
diagnostics = {
|
||||||
golangci_lint.enable = true;
|
golangci_lint.enable = false;
|
||||||
statix.enable = true;
|
statix.enable = true;
|
||||||
};
|
};
|
||||||
formatting = {
|
formatting = {
|
||||||
@ -53,7 +53,7 @@
|
|||||||
shfmt.enable = true;
|
shfmt.enable = true;
|
||||||
# golines.enable = true;
|
# golines.enable = true;
|
||||||
# gofumpt.enable = true;
|
# gofumpt.enable = true;
|
||||||
phpcsfixer.enable = true;
|
# phpcsfixer.enable = true;
|
||||||
elm_format.enable = true;
|
elm_format.enable = true;
|
||||||
blade_formatter = {
|
blade_formatter = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|||||||
32
home/programs/nvim/plugins/lualine.nix
Normal file
32
home/programs/nvim/plugins/lualine.nix
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
{
|
||||||
|
programs.nixvim.plugins.lualine = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
options.disabled_filetypes.statusline =
|
||||||
|
[ "dashboard" "alpha" "neo-tree" ];
|
||||||
|
|
||||||
|
options = { show_filename_only = false; };
|
||||||
|
alwaysDivideMiddle = true;
|
||||||
|
globalstatus = true;
|
||||||
|
ignoreFocus = [ "neo-tree" ];
|
||||||
|
extensions = [ "fzf" ];
|
||||||
|
theme = "auto";
|
||||||
|
componentSeparators = {
|
||||||
|
left = "|";
|
||||||
|
right = "|";
|
||||||
|
};
|
||||||
|
sectionSeparators = {
|
||||||
|
left = ""; #
|
||||||
|
right = ""; #
|
||||||
|
};
|
||||||
|
sections = {
|
||||||
|
lualine_a = [ "mode" ];
|
||||||
|
lualine_b = [ "branch" "diff" "diagnostics" ];
|
||||||
|
lualine_c = [ "filename" ];
|
||||||
|
lualine_x = [ "filetype" ];
|
||||||
|
lualine_y = [ "progress" "selectioncount" ];
|
||||||
|
lualine_z = [ ''" " .. os.date("%R")'' ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@ -1,4 +1,3 @@
|
|||||||
# The render-markdown.nvim plugin is a plugin that renders markdown files in a neovim in a more readable way.
|
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
let
|
let
|
||||||
accent = "#${config.lib.stylix.colors.base0D}";
|
accent = "#${config.lib.stylix.colors.base0D}";
|
||||||
@ -9,114 +8,115 @@ in {
|
|||||||
|
|
||||||
programs.nixvim = {
|
programs.nixvim = {
|
||||||
plugins.mkdnflow = {
|
plugins.mkdnflow = {
|
||||||
enable = true;
|
enable = false;
|
||||||
|
settings = {
|
||||||
modules = { conceal = false; };
|
modules = { conceal = false; };
|
||||||
|
to_do.symbols = [ " " "-" "x" "!" "/" ];
|
||||||
toDo.symbols = [ " " "-" "x" "!" "/" ];
|
# mappings = {
|
||||||
mappings = {
|
# MkdnCreateLink = false;
|
||||||
MkdnCreateLink = false;
|
# MkdnCreateLinkFromClipboard = {
|
||||||
MkdnCreateLinkFromClipboard = {
|
# key = "<leader>ml";
|
||||||
key = "<leader>ml";
|
# modes = [ "n" "v" ];
|
||||||
modes = [ "n" "v" ];
|
# };
|
||||||
};
|
# MkdnDecreaseHeading = {
|
||||||
MkdnDecreaseHeading = {
|
# key = "<leader>m-";
|
||||||
key = "<leader>m-";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnDestroyLink = false;
|
||||||
MkdnDestroyLink = false;
|
# MkdnEnter = {
|
||||||
MkdnEnter = {
|
# key = "<CR>";
|
||||||
key = "<CR>";
|
# modes = [ "v" ];
|
||||||
modes = [ "v" ];
|
# };
|
||||||
};
|
# MkdnExtendList = false;
|
||||||
MkdnExtendList = false;
|
# MkdnFoldSection = {
|
||||||
MkdnFoldSection = {
|
# key = "<leader>mf";
|
||||||
key = "<leader>mf";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnUnfoldSection = {
|
||||||
MkdnUnfoldSection = {
|
# key = "<leader>mF";
|
||||||
key = "<leader>mF";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnFollowLink = {
|
||||||
MkdnFollowLink = {
|
# key = "gd";
|
||||||
key = "gd";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnGoBack = false;
|
||||||
MkdnGoBack = false;
|
# MkdnGoForward = false;
|
||||||
MkdnGoForward = false;
|
# MkdnIncreaseHeading = {
|
||||||
MkdnIncreaseHeading = {
|
# key = "<leader>m+";
|
||||||
key = "<leader>m+";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnMoveSource = false;
|
||||||
MkdnMoveSource = false;
|
# MkdnNewListItem = false;
|
||||||
MkdnNewListItem = false;
|
# MkdnNewListItemAboveInsert = {
|
||||||
MkdnNewListItemAboveInsert = {
|
# key = "O";
|
||||||
key = "O";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnNewListItemBelowInsert = {
|
||||||
MkdnNewListItemBelowInsert = {
|
# key = "o";
|
||||||
key = "o";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnNextHeading = {
|
||||||
MkdnNextHeading = {
|
# key = "<leader>m#";
|
||||||
key = "<leader>m#";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnNextLink = false;
|
||||||
MkdnNextLink = false;
|
# MkdnPrevLink = false;
|
||||||
MkdnPrevLink = false;
|
# MkdnPrevHeading = {
|
||||||
MkdnPrevHeading = {
|
# key = "<leader>m*";
|
||||||
key = "<leader>m*";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnSTab = false;
|
||||||
MkdnSTab = false;
|
# MkdnTab = false;
|
||||||
MkdnTab = false;
|
# MkdnTableNewColAfter = {
|
||||||
MkdnTableNewColAfter = {
|
# key = "<leader>mc";
|
||||||
key = "<leader>mc";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnTableNewColBefore = {
|
||||||
MkdnTableNewColBefore = {
|
# key = "<leader>mC";
|
||||||
key = "<leader>mC";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnTableNewRowAbove = {
|
||||||
MkdnTableNewRowAbove = {
|
# key = "<leader>mR";
|
||||||
key = "<leader>mR";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnTableNewRowBelow = {
|
||||||
MkdnTableNewRowBelow = {
|
# key = "<leader>mr";
|
||||||
key = "<leader>mr";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnTableNextCell = {
|
||||||
MkdnTableNextCell = {
|
# key = "<S-Tab>";
|
||||||
key = "<S-Tab>";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnTableNextRow = false;
|
||||||
MkdnTableNextRow = false;
|
# MkdnTablePrevCell = {
|
||||||
MkdnTablePrevCell = {
|
# key = "<S-Tab>";
|
||||||
key = "<S-Tab>";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnTablePrevRow = false;
|
||||||
MkdnTablePrevRow = false;
|
# MkdnToggleToDo = {
|
||||||
MkdnToggleToDo = {
|
# key = "<C-Space>";
|
||||||
key = "<C-Space>";
|
# modes = [ "n" "v" ];
|
||||||
modes = [ "n" "v" ];
|
# };
|
||||||
};
|
# MkdnUpdateNumbering = {
|
||||||
MkdnUpdateNumbering = {
|
# key = "<leader>mn";
|
||||||
key = "<leader>mn";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnYankAnchorLink = {
|
||||||
MkdnYankAnchorLink = {
|
# key = "ya";
|
||||||
key = "ya";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# MkdnYankFileAnchorLink = {
|
||||||
MkdnYankFileAnchorLink = {
|
# key = "yfa";
|
||||||
key = "yfa";
|
# modes = "n";
|
||||||
modes = "n";
|
# };
|
||||||
};
|
# };
|
||||||
};
|
|
||||||
tables = {
|
tables = {
|
||||||
formatOnMove = true;
|
formatOnMove = true;
|
||||||
trimWhitespace = true;
|
trimWhitespace = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
};
|
||||||
extraFiles = {
|
extraFiles = {
|
||||||
"after/ftplugin/markdown.lua".text = ''
|
"after/ftplugin/markdown.lua".text = ''
|
||||||
vim.bo.tabstop = 2
|
vim.bo.tabstop = 2
|
||||||
@ -132,8 +132,9 @@ in {
|
|||||||
RenderMarkdownH4.fg = accent-alt;
|
RenderMarkdownH4.fg = accent-alt;
|
||||||
RenderMarkdownH5.fg = accent-alt;
|
RenderMarkdownH5.fg = accent-alt;
|
||||||
RenderMarkdownH6.fg = accent-alt;
|
RenderMarkdownH6.fg = accent-alt;
|
||||||
RenderMarkdownTodo.fg = muted;
|
RenderMarkdownTodo.fg = "#f78c6c";
|
||||||
RenderMarkdownWarning.fg = accent;
|
RenderMarkdownWarning.fg = "#ff5370";
|
||||||
|
RenderMarkdownDone.fg = muted;
|
||||||
};
|
};
|
||||||
plugins.headlines = {
|
plugins.headlines = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@ -156,6 +157,7 @@ in {
|
|||||||
settings = {
|
settings = {
|
||||||
heading = {
|
heading = {
|
||||||
icons = [ "# " " " " " " " " " " " ];
|
icons = [ "# " " " " " " " " " " " ];
|
||||||
|
sign = false;
|
||||||
backgrounds = [ "RenderMarkdownBg" ];
|
backgrounds = [ "RenderMarkdownBg" ];
|
||||||
foregrounds = [
|
foregrounds = [
|
||||||
"RenderMarkdownH1"
|
"RenderMarkdownH1"
|
||||||
@ -168,7 +170,7 @@ in {
|
|||||||
};
|
};
|
||||||
checkbox = {
|
checkbox = {
|
||||||
unchecked = { highlight = "RenderMarkdownTodo"; };
|
unchecked = { highlight = "RenderMarkdownTodo"; };
|
||||||
checked = { highlight = "RenderMarkdownTodo"; };
|
checked = { highlight = "RenderMarkdownDone"; };
|
||||||
custom = {
|
custom = {
|
||||||
pending = {
|
pending = {
|
||||||
raw = "[-]";
|
raw = "[-]";
|
||||||
@ -177,13 +179,13 @@ in {
|
|||||||
};
|
};
|
||||||
important = {
|
important = {
|
||||||
raw = "[!]";
|
raw = "[!]";
|
||||||
rendered = " ";
|
rendered = " ";
|
||||||
highlight = "RenderMarkdownWarning";
|
highlight = "RenderMarkdownWarning";
|
||||||
};
|
};
|
||||||
cancel = {
|
cancel = {
|
||||||
raw = "[/]";
|
raw = "[/]";
|
||||||
rendered = " ";
|
rendered = " ";
|
||||||
highlight = "RenderMarkdownTodo";
|
highlight = "RenderMarkdownWarning";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -1,54 +1,13 @@
|
|||||||
{ pkgs, ... }: {
|
{ pkgs, ... }: {
|
||||||
home.packages = with pkgs; [ ctags ];
|
home.packages = with pkgs; [ ctags ];
|
||||||
|
programs.nixvim.plugins = {
|
||||||
programs.nixvim = {
|
|
||||||
plugins = {
|
|
||||||
lualine = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
options.disabled_filetypes.statusline =
|
|
||||||
[ "dashboard" "alpha" "neo-tree" ];
|
|
||||||
|
|
||||||
alwaysDivideMiddle = true;
|
|
||||||
globalstatus = true;
|
|
||||||
ignoreFocus = [ "neo-tree" ];
|
|
||||||
extensions = [ "fzf" ];
|
|
||||||
theme = "auto";
|
|
||||||
componentSeparators = {
|
|
||||||
left = "|";
|
|
||||||
right = "|";
|
|
||||||
};
|
|
||||||
sectionSeparators = {
|
|
||||||
left = ""; #
|
|
||||||
right = ""; #
|
|
||||||
};
|
|
||||||
sections = {
|
|
||||||
lualine_a = [ "mode" ];
|
|
||||||
lualine_b = [ "branch" "diff" "diagnostics" ];
|
|
||||||
lualine_c = [ "filename" ];
|
|
||||||
lualine_x = [ "filetype" ];
|
|
||||||
lualine_y = [ "progress" "selectioncount" ];
|
|
||||||
lualine_z = [ ''" " .. os.date("%R")'' ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
web-devicons.enable = true;
|
web-devicons.enable = true;
|
||||||
noice.enable = true;
|
noice.enable = true;
|
||||||
notify = {
|
glance.enable = true;
|
||||||
enable = true;
|
|
||||||
level = "warn";
|
|
||||||
};
|
|
||||||
gitsigns = {
|
gitsigns = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings.current_line_blame = false;
|
settings.current_line_blame = false;
|
||||||
};
|
};
|
||||||
trouble.enable = true;
|
trouble.enable = true;
|
||||||
indent-blankline.enable = true;
|
|
||||||
colorizer.enable = true;
|
|
||||||
tagbar = {
|
|
||||||
enable = true;
|
|
||||||
tagsPackage = pkgs.universal-ctags;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -4,11 +4,11 @@
|
|||||||
FloatBorder.fg = "#${config.lib.stylix.colors.base0D}";
|
FloatBorder.fg = "#${config.lib.stylix.colors.base0D}";
|
||||||
};
|
};
|
||||||
plugins = {
|
plugins = {
|
||||||
copilot-vim.enable = true;
|
copilot-vim.enable = false;
|
||||||
flash.enable = true;
|
flash.enable = true;
|
||||||
image = {
|
image = {
|
||||||
enable = false;
|
enable = false;
|
||||||
integrations.markdown = {
|
settings.integrations.markdown = {
|
||||||
clearInInsertMode = true;
|
clearInInsertMode = true;
|
||||||
onlyRenderImageAtCursor = true;
|
onlyRenderImageAtCursor = true;
|
||||||
};
|
};
|
||||||
@ -16,26 +16,8 @@
|
|||||||
tmux-navigator.enable = true;
|
tmux-navigator.enable = true;
|
||||||
comment.enable = true;
|
comment.enable = true;
|
||||||
nvim-autopairs.enable = true;
|
nvim-autopairs.enable = true;
|
||||||
friendly-snippets.enable = true;
|
|
||||||
todo-comments.enable = true;
|
todo-comments.enable = true;
|
||||||
harpoon = {
|
orgmode.enable = false;
|
||||||
enable = true;
|
|
||||||
enableTelescope = true;
|
|
||||||
keymapsSilent = true;
|
|
||||||
keymaps = {
|
|
||||||
addFile = "<leader>ha";
|
|
||||||
toggleQuickMenu = "<leader>hu";
|
|
||||||
navNext = "<leader>hl";
|
|
||||||
navPrev = "<leader>hh";
|
|
||||||
navFile = {
|
|
||||||
"1" = "<leader>h1";
|
|
||||||
"2" = "<leader>h2";
|
|
||||||
"3" = "<leader>h3";
|
|
||||||
"4" = "<leader>h4";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
orgmode.enable = true;
|
|
||||||
treesitter-context.enable = true;
|
treesitter-context.enable = true;
|
||||||
nvim-surround.enable = true;
|
nvim-surround.enable = true;
|
||||||
vim-suda.enable = true;
|
vim-suda.enable = true;
|
||||||
|
|||||||
@ -1,3 +1,14 @@
|
|||||||
{ pkgs, ... }: {
|
{ pkgs, ... }: {
|
||||||
home.packages = with pkgs; [ libreoffice thunderbird marp-cli ];
|
home.packages = with pkgs; [
|
||||||
|
libreoffice
|
||||||
|
hunspell
|
||||||
|
hunspellDicts.id_ID
|
||||||
|
hunspellDicts.en_US
|
||||||
|
thunderbird
|
||||||
|
marp-cli
|
||||||
|
qpdf
|
||||||
|
qrencode
|
||||||
|
temurin-jre-bin
|
||||||
|
librsvg
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
@ -11,6 +11,6 @@
|
|||||||
enableZshIntegration = true;
|
enableZshIntegration = true;
|
||||||
verbose = true;
|
verbose = true;
|
||||||
enableScDaemon = false;
|
enableScDaemon = false;
|
||||||
pinentryPackage = pkgs.pinentry-all;
|
pinentry.package = pkgs.pinentry-all;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -55,7 +55,7 @@ in {
|
|||||||
|
|
||||||
plugins = with pkgs; [
|
plugins = with pkgs; [
|
||||||
tmuxPlugins.vim-tmux-navigator
|
tmuxPlugins.vim-tmux-navigator
|
||||||
tmuxPlugins.resurrect
|
# tmuxPlugins.resurrect
|
||||||
tmuxPlugins.sensible
|
tmuxPlugins.sensible
|
||||||
# tmuxPlugins.tokyo-night-tmux
|
# tmuxPlugins.tokyo-night-tmux
|
||||||
];
|
];
|
||||||
|
|||||||
@ -12,9 +12,9 @@ in {
|
|||||||
extraPackages = with pkgs.bat-extras; [
|
extraPackages = with pkgs.bat-extras; [
|
||||||
batman
|
batman
|
||||||
batdiff
|
batdiff
|
||||||
batgrep
|
# batgrep
|
||||||
batwatch
|
batwatch
|
||||||
prettybat
|
# prettybat
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -26,7 +26,7 @@ in {
|
|||||||
syntaxHighlighting.enable = true;
|
syntaxHighlighting.enable = true;
|
||||||
historySubstringSearch.enable = true;
|
historySubstringSearch.enable = true;
|
||||||
|
|
||||||
initExtraFirst = ''
|
initContent = lib.mkBefore ''
|
||||||
bindkey -e
|
bindkey -e
|
||||||
${if fetch == "neofetch" then
|
${if fetch == "neofetch" then
|
||||||
pkgs.neofetch + "/bin/neofetch"
|
pkgs.neofetch + "/bin/neofetch"
|
||||||
@ -95,7 +95,7 @@ in {
|
|||||||
gcu = "git add . && git commit -m 'Update'";
|
gcu = "git add . && git commit -m 'Update'";
|
||||||
gp = "git push";
|
gp = "git push";
|
||||||
gpl = "git pull";
|
gpl = "git pull";
|
||||||
gs = "git status";
|
gst = "git status";
|
||||||
gd = "git diff";
|
gd = "git diff";
|
||||||
gco = "git checkout";
|
gco = "git checkout";
|
||||||
gcb = "git checkout -b";
|
gcb = "git checkout -b";
|
||||||
|
|||||||
@ -1,13 +1,16 @@
|
|||||||
# Spicetify is a spotify client customizer
|
# Spicetify is a spotify client customizer
|
||||||
{ pkgs, config, lib, inputs, ... }:
|
{
|
||||||
let
|
pkgs,
|
||||||
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system};
|
config,
|
||||||
|
lib,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.stdenv.hostPlatform.system};
|
||||||
accent = "${config.lib.stylix.colors.base0D}";
|
accent = "${config.lib.stylix.colors.base0D}";
|
||||||
|
background = "${config.lib.stylix.colors.base00}";
|
||||||
in {
|
in {
|
||||||
imports = [ inputs.spicetify-nix.homeManagerModules.default ];
|
imports = [inputs.spicetify-nix.homeManagerModules.default];
|
||||||
|
|
||||||
nixpkgs.config.allowUnfreePredicate = pkg:
|
|
||||||
builtins.elem (lib.getName pkg) [ "spotify" ];
|
|
||||||
|
|
||||||
stylix.targets.spicetify.enable = false;
|
stylix.targets.spicetify.enable = false;
|
||||||
|
|
||||||
@ -21,6 +24,9 @@ in {
|
|||||||
button = accent;
|
button = accent;
|
||||||
button-active = accent;
|
button-active = accent;
|
||||||
tab-active = accent;
|
tab-active = accent;
|
||||||
|
player = background;
|
||||||
|
main = background;
|
||||||
|
sidebar = background;
|
||||||
};
|
};
|
||||||
|
|
||||||
enabledExtensions = with spicePkgs.extensions; [
|
enabledExtensions = with spicePkgs.extensions; [
|
||||||
@ -31,6 +37,7 @@ in {
|
|||||||
adblock
|
adblock
|
||||||
fullAppDisplay
|
fullAppDisplay
|
||||||
shuffle
|
shuffle
|
||||||
|
keyboardShortcut
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,48 +1,10 @@
|
|||||||
# Thunar is a file explorer
|
# Thunar is a file explorer
|
||||||
{ pkgs, ... }: {
|
{ pkgs, ... }: {
|
||||||
# ctrl + m to toggle the menubar
|
# ctrl + m to toggle the menubar
|
||||||
home.packages = with pkgs.xfce; [
|
home.packages = with pkgs; [
|
||||||
thunar
|
xfce.thunar
|
||||||
xfconf
|
xfce.xfconf
|
||||||
tumbler
|
xfce.tumbler
|
||||||
thunar-archive-plugin
|
file-roller
|
||||||
thunar-volman
|
|
||||||
];
|
];
|
||||||
|
|
||||||
# home.file.".config/xfce4/xfconf/xfce-perchannel-xml/thunar.xml".text = ''
|
|
||||||
# <?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
#
|
|
||||||
# <channel name="thunar" version="1.0">
|
|
||||||
# <property name="last-view" type="string" value="ThunarIconView"/>
|
|
||||||
# <property name="last-icon-view-zoom-level" type="string" value="THUNAR_ZOOM_LEVEL_100_PERCENT"/>
|
|
||||||
# <property name="last-window-maximized" type="bool" value="true"/>
|
|
||||||
# <property name="last-separator-position" type="int" value="170"/>
|
|
||||||
# <property name="last-statusbar-visible" type="bool" value="false"/>
|
|
||||||
# <property name="last-menubar-visible" type="bool" value="false"/>
|
|
||||||
# <property name="misc-single-click" type="bool" value="false"/>
|
|
||||||
# <property name="shortcuts-icon-emblems" type="bool" value="true"/>
|
|
||||||
# <property name="tree-icon-emblems" type="bool" value="true"/>
|
|
||||||
# <property name="misc-file-size-binary" type="bool" value="true"/>
|
|
||||||
# <property name="misc-thumbnail-draw-frames" type="bool" value="false"/>
|
|
||||||
# <property name="misc-text-beside-icons" type="bool" value="true"/>
|
|
||||||
# <property name="misc-change-window-icon" type="bool" value="true"/>
|
|
||||||
# <property name="hidden-bookmarks" type="array">
|
|
||||||
# <value type="string" value="computer:///"/>
|
|
||||||
# <value type="string" value="recent:///"/>
|
|
||||||
# <value type="string" value="file:///"/>
|
|
||||||
# <value type="string" value="network:///"/>
|
|
||||||
# </property>
|
|
||||||
# <property name="hidden-devices" type="array">
|
|
||||||
# <value type="string" value="52FEA905FEA8E309"/>
|
|
||||||
# </property>
|
|
||||||
# <property name="last-toolbar-item-order" type="string" value="0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17"/>
|
|
||||||
# <property name="last-toolbar-visible-buttons" type="string" value="0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0"/>
|
|
||||||
# <property name="last-location-bar" type="string" value="ThunarLocationButtons"/>
|
|
||||||
# <property name="last-show-hidden" type="bool" value="false"/>
|
|
||||||
# <property name="last-details-view-zoom-level" type="string" value="THUNAR_ZOOM_LEVEL_38_PERCENT"/>
|
|
||||||
# <property name="last-details-view-column-widths" type="string" value="50,50,127,50,50,50,50,50,751,50,50,75,50,145"/>
|
|
||||||
# <property name="misc-middle-click-in-tab" type="bool" value="true"/>
|
|
||||||
# <property name="last-details-view-visible-columns" type="string" value="THUNAR_COLUMN_DATE_MODIFIED,THUNAR_COLUMN_NAME,THUNAR_COLUMN_SIZE,THUNAR_COLUMN_TYPE"/>
|
|
||||||
# </channel>
|
|
||||||
# '';
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -4,8 +4,6 @@
|
|||||||
./sounds
|
./sounds
|
||||||
./brightness
|
./brightness
|
||||||
./caffeine
|
./caffeine
|
||||||
./hyprpanel
|
|
||||||
./hyprfocus
|
|
||||||
./night-shift
|
./night-shift
|
||||||
./screenshot
|
./screenshot
|
||||||
./nerdfont_fzf
|
./nerdfont_fzf
|
||||||
|
|||||||
@ -8,36 +8,36 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
let
|
let
|
||||||
hyprpanel-toggle = pkgs.writeShellScriptBin "hyprpanel-toggle" ''
|
hyprpanel-toggle = pkgs.writeShellScriptBin "hyprpanel-toggle" ''
|
||||||
hyprpanel -t bar-0
|
hyprpanel toggleWindow bar-0
|
||||||
hyprpanel -t bar-1
|
hyprpanel toggleWindow bar-1
|
||||||
hyprpanel -t bar-2
|
hyprpanel toggleWindow bar-2
|
||||||
hyprpanel -t bar-3
|
hyprpanel toggleWindow bar-3
|
||||||
'';
|
'';
|
||||||
|
|
||||||
hyprpanel-hide = pkgs.writeShellScriptBin "hyprpanel-hide" ''
|
hyprpanel-hide = pkgs.writeShellScriptBin "hyprpanel-hide" ''
|
||||||
status=$(hyprpanel -r "isWindowVisible('bar-0')")
|
status=$(hyprpanel isWindowVisible bar-0)
|
||||||
if [[ $status == "true" ]]; then
|
if [[ $status == "true" ]]; then
|
||||||
hyprpanel -t bar-0
|
hyprpanel toggleWindow bar-0
|
||||||
fi
|
fi
|
||||||
status=$(hyprpanel -r "isWindowVisible('bar-1')")
|
status=$(hyprpanel isWindowVisible bar-1)
|
||||||
if [[ $status == "true" ]]; then
|
if [[ $status == "true" ]]; then
|
||||||
hyprpanel -t bar-1
|
hyprpanel toggleWindow bar-1
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|
||||||
hyprpanel-show = pkgs.writeShellScriptBin "hyprpanel-show" ''
|
hyprpanel-show = pkgs.writeShellScriptBin "hyprpanel-show" ''
|
||||||
status=$(hyprpanel -r "isWindowVisible('bar-0')")
|
status=$(hyprpanel isWindowVisible bar-0)
|
||||||
if [[ $status == "false" ]]; then
|
if [[ $status == "false" ]]; then
|
||||||
hyprpanel -t bar-0
|
hyprpanel toggleWindow bar-0
|
||||||
fi
|
fi
|
||||||
status=$(hyprpanel -r "isWindowVisible('bar-1')")
|
status=$(hyprpanel isWindowVisible bar-1)
|
||||||
if [[ $status == "false" ]]; then
|
if [[ $status == "false" ]]; then
|
||||||
hyprpanel -t bar-1
|
hyprpanel toggleWindow bar-1
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|
||||||
hyprpanel-reload = pkgs.writeShellScriptBin "hyprpanel-reload" ''
|
hyprpanel-reload = pkgs.writeShellScriptBin "hyprpanel-reload" ''
|
||||||
[ $(pgrep "ags") ] && pkill ags
|
[ $(pgrep "hyprpanel") ] && pkill hyprpanel
|
||||||
hyprctl dispatch exec hyprpanel
|
hyprctl dispatch exec hyprpanel
|
||||||
'';
|
'';
|
||||||
in {
|
in {
|
||||||
|
|||||||
@ -29,7 +29,6 @@ let
|
|||||||
";Collect Garbage;nixy gc"
|
";Collect Garbage;nixy gc"
|
||||||
";Clean Boot Menu;nixy cb"
|
";Clean Boot Menu;nixy cb"
|
||||||
";Hyprland Keybindings;nvim ${configDirectory}/docs/KEYBINDINGS-HYPRLAND.md"
|
";Hyprland Keybindings;nvim ${configDirectory}/docs/KEYBINDINGS-HYPRLAND.md"
|
||||||
";Wallpapers;nvim ${inputs.nixy-wallpapers}/docs/MOBILE-VIEW.md"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
# Apply default icons if empty:
|
# Apply default icons if empty:
|
||||||
|
|||||||
36
home/system/dunst/default.nix
Normal file
36
home/system/dunst/default.nix
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
{ config, lib, ... }:
|
||||||
|
let
|
||||||
|
accent = "#${config.lib.stylix.colors.base0D}";
|
||||||
|
accent-alt = "#${config.lib.stylix.colors.base03}";
|
||||||
|
background = "#${config.lib.stylix.colors.base00}";
|
||||||
|
background-alt = "#${config.lib.stylix.colors.base01}";
|
||||||
|
foreground = "#${config.lib.stylix.colors.base05}";
|
||||||
|
font = "${config.stylix.fonts.sansSerif.name}";
|
||||||
|
font-size = "${toString config.stylix.fonts.sizes.desktop}";
|
||||||
|
|
||||||
|
inherit (config.var.theme) rounding border-size gaps-in gaps-out;
|
||||||
|
in {
|
||||||
|
|
||||||
|
services.dunst = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
global = {
|
||||||
|
height = 300;
|
||||||
|
offset = "15x15";
|
||||||
|
origin = "top-right";
|
||||||
|
follow = "keyboard";
|
||||||
|
shrink = "no";
|
||||||
|
transparency = 0;
|
||||||
|
separator_height = 2;
|
||||||
|
padding = gaps-in;
|
||||||
|
horizontal_padding = gaps-in;
|
||||||
|
corner_radius = rounding;
|
||||||
|
gap_size = gaps-out;
|
||||||
|
frame_width = border-size;
|
||||||
|
markup = "full";
|
||||||
|
word_wrap = "yes";
|
||||||
|
ellipsize = "middle";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@ -1,11 +1,10 @@
|
|||||||
{ pkgs, ... }: {
|
{ pkgs, ... }: {
|
||||||
wayland.windowManager.hyprland.settings = {
|
wayland.windowManager.hyprland.settings = {
|
||||||
bind = [
|
bind = [
|
||||||
"$mod,RETURN, exec, ${pkgs.kitty}/bin/kitty" # Kitty
|
"$mod,RETURN, exec, ${pkgs.kitty}/bin/kitty" # Terminal
|
||||||
"$mod,E, exec, ${pkgs.xfce.thunar}/bin/thunar" # Thunar
|
"$mod,E, exec, ${pkgs.xfce.thunar}/bin/thunar" # Thunar
|
||||||
# "$mod,B, exec, ${pkgs.qutebrowser}/bin/qutebrowser" # Qutebrowser
|
|
||||||
"$mod,U, exec, ${pkgs.firefox}/bin/firefox" # Firefox
|
"$mod,U, exec, ${pkgs.firefox}/bin/firefox" # Firefox
|
||||||
# "$shiftMod,B, exec, ${pkgs.bitwarden}/bin/bitwarden" # Bitwarden
|
"$mod,M, exec, ${pkgs.emacs-pgtk}/bin/emacs" # Emacs
|
||||||
"$shiftMod,Q, exec, ${pkgs.hyprlock}/bin/hyprlock" # Lock
|
"$shiftMod,Q, exec, ${pkgs.hyprlock}/bin/hyprlock" # Lock
|
||||||
"$mod,X, exec, powermenu" # Powermenu
|
"$mod,X, exec, powermenu" # Powermenu
|
||||||
"$mod,SPACE, exec, menu" # Launcher
|
"$mod,SPACE, exec, menu" # Launcher
|
||||||
@ -32,14 +31,16 @@
|
|||||||
"$mod,l, movefocus, r" # Move focus Right
|
"$mod,l, movefocus, r" # Move focus Right
|
||||||
"$mod,k, movefocus, u" # Move focus Up
|
"$mod,k, movefocus, u" # Move focus Up
|
||||||
"$mod,j, movefocus, d" # Move focus Down
|
"$mod,j, movefocus, d" # Move focus Down
|
||||||
|
"$shiftMod,j, swapnext" # Swap with next client
|
||||||
|
"$shiftMod,k, swapnext, prev" # Swap with previous client
|
||||||
"$ctrlMod,k, focusmonitor, -1" # Focus previous monitor
|
"$ctrlMod,k, focusmonitor, -1" # Focus previous monitor
|
||||||
"$ctrlMod,j, focusmonitor, 1" # Focus next monitor
|
"$ctrlMod,j, focusmonitor, 1" # Focus next monitor
|
||||||
"$ctrlMod,h, layoutmsg, addmaster" # Add to master
|
"$ctrlMod,h, layoutmsg, addmaster" # Add to master
|
||||||
"$ctrlMod,l, layoutmsg, removemaster" # Remove from master
|
"$ctrlMod,l, layoutmsg, removemaster" # Remove from master
|
||||||
|
|
||||||
"$mod,PRINT, exec, screenshot window" # Screenshot window
|
"$mod,PRINT, exec, screenshot window swappy" # Screenshot window
|
||||||
",PRINT, exec, screenshot monitor" # Screenshot monitor
|
",PRINT, exec, screenshot monitor swappy" # Screenshot monitor
|
||||||
"$shiftMod,PRINT, exec, screenshot region" # Screenshot region
|
"$shiftMod,PRINT, exec, screenshot region swappy" # Screenshot region
|
||||||
"ALT,PRINT, exec, screenshot region swappy" # Screenshot region then edit
|
"ALT,PRINT, exec, screenshot region swappy" # Screenshot region then edit
|
||||||
|
|
||||||
# "$shiftMod,S, exec, ${pkgs.qutebrowser}/bin/qutebrowser :open $(wofi --show dmenu -L 1 -p ' Search on internet')" # Search on internet with wofi
|
# "$shiftMod,S, exec, ${pkgs.qutebrowser}/bin/qutebrowser :open $(wofi --show dmenu -L 1 -p ' Search on internet')" # Search on internet with wofi
|
||||||
|
|||||||
@ -13,7 +13,7 @@ in {
|
|||||||
qt5.qtwayland
|
qt5.qtwayland
|
||||||
qt6.qtwayland
|
qt6.qtwayland
|
||||||
libsForQt5.qt5ct
|
libsForQt5.qt5ct
|
||||||
qt6ct
|
qt6Packages.qt6ct
|
||||||
hyprshot
|
hyprshot
|
||||||
hyprpicker
|
hyprpicker
|
||||||
swappy
|
swappy
|
||||||
@ -34,12 +34,12 @@ in {
|
|||||||
|
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
xwayland.enable = true;
|
systemd.enable = true;
|
||||||
systemd = {
|
systemd.variables = [ "--all" ];
|
||||||
enable = true;
|
package =
|
||||||
variables = [ "--all" ];
|
inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
|
||||||
};
|
portalPackage =
|
||||||
package = inputs.hyprland.packages."${pkgs.system}".hyprland;
|
inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland;
|
||||||
|
|
||||||
settings = {
|
settings = {
|
||||||
"$mod" = "SUPER";
|
"$mod" = "SUPER";
|
||||||
@ -47,8 +47,11 @@ in {
|
|||||||
"$ctrlMod" = "SUPER_CTRL";
|
"$ctrlMod" = "SUPER_CTRL";
|
||||||
|
|
||||||
exec-once = [
|
exec-once = [
|
||||||
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP"
|
"systemctl --user import-environment"
|
||||||
|
"hash dbus-update-activation-environment 2>/dev/null"
|
||||||
|
"dbus-update-activation-environment --systemd --all"
|
||||||
];
|
];
|
||||||
|
ecosystem = { no_update_news = true; };
|
||||||
|
|
||||||
plugin = { overview = { autoDrag = false; }; };
|
plugin = { overview = { autoDrag = false; }; };
|
||||||
|
|
||||||
@ -102,12 +105,14 @@ in {
|
|||||||
gaps_in = gaps-in;
|
gaps_in = gaps-in;
|
||||||
gaps_out = gaps-out;
|
gaps_out = gaps-out;
|
||||||
border_size = border-size;
|
border_size = border-size;
|
||||||
border_part_of_window = true;
|
|
||||||
layout = "master";
|
layout = "master";
|
||||||
};
|
};
|
||||||
|
|
||||||
decoration = {
|
decoration = {
|
||||||
blur = { enabled = if blur then "true" else "false"; };
|
blur = {
|
||||||
|
enabled = if blur then "true" else "false";
|
||||||
|
size = 18;
|
||||||
|
};
|
||||||
shadow = {
|
shadow = {
|
||||||
enabled = true;
|
enabled = true;
|
||||||
range = 20;
|
range = 20;
|
||||||
@ -121,10 +126,10 @@ in {
|
|||||||
master = {
|
master = {
|
||||||
new_status = true;
|
new_status = true;
|
||||||
allow_small_split = true;
|
allow_small_split = true;
|
||||||
mfact = 0.5;
|
mfact = 0.6;
|
||||||
};
|
};
|
||||||
|
|
||||||
gestures = { workspace_swipe = true; };
|
gesture = [ "3, horizontal, workspace" ];
|
||||||
|
|
||||||
misc = {
|
misc = {
|
||||||
vfr = true;
|
vfr = true;
|
||||||
@ -135,8 +140,34 @@ in {
|
|||||||
new_window_takes_over_fullscreen = 2;
|
new_window_takes_over_fullscreen = 2;
|
||||||
};
|
};
|
||||||
|
|
||||||
windowrulev2 =
|
windowrulev2 = [
|
||||||
[ "float, tag:modal" "pin, tag:modal" "center, tag:modal" ];
|
"float, tag:modal"
|
||||||
|
"pin, tag:modal"
|
||||||
|
"center, tag:modal"
|
||||||
|
"float, title:^(Media viewer)$"
|
||||||
|
|
||||||
|
# Bitwarden extension
|
||||||
|
"float, title:^(.*Bitwarden Password Manager.*)$"
|
||||||
|
|
||||||
|
# make Firefox/Zen PiP window floating and sticky
|
||||||
|
"float, title:^(Picture-in-Picture)$"
|
||||||
|
"pin, title:^(Picture-in-Picture)$"
|
||||||
|
|
||||||
|
# idle inhibit while watching videos
|
||||||
|
"idleinhibit focus, class:^(mpv|.+exe|celluloid)$"
|
||||||
|
"idleinhibit focus, class:^(zen)$, title:^(.*YouTube.*)$"
|
||||||
|
"idleinhibit fullscreen, class:^(zen)$"
|
||||||
|
|
||||||
|
"dimaround, class:^(gcr-prompter)$"
|
||||||
|
"dimaround, class:^(xdg-desktop-portal-gtk)$"
|
||||||
|
"dimaround, class:^(polkit-gnome-authentication-agent-1)$"
|
||||||
|
"dimaround, class:^(zen)$, title:^(File Upload)$"
|
||||||
|
|
||||||
|
# fix xwayland apps
|
||||||
|
"rounding 0, xwayland:1"
|
||||||
|
"center, class:^(.*jetbrains.*)$, title:^(Confirm Exit|Open Project|win424|win201|splash)$"
|
||||||
|
"size 640 400, class:^(.*jetbrains.*)$, title:^(splash)$"
|
||||||
|
];
|
||||||
|
|
||||||
layerrule = [ "noanim, launcher" "noanim, ^ags-.*" ];
|
layerrule = [ "noanim, launcher" "noanim, ^ags-.*" ];
|
||||||
|
|
||||||
@ -156,6 +187,6 @@ in {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
systemd.user.targets.hyprland-session.Unit.Wants =
|
# systemd.user.targets.hyprland-session.Unit.Wants =
|
||||||
[ "xdg-desktop-autostart.target" ];
|
# [ "xdg-desktop-autostart.target" ];
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,7 +1,8 @@
|
|||||||
{ inputs, pkgs, ... }: {
|
{
|
||||||
home.packages =
|
inputs,
|
||||||
[ inputs.hyprpolkitagent.packages."${pkgs.system}".hyprpolkitagent ];
|
pkgs,
|
||||||
|
...
|
||||||
wayland.windowManager.hyprland.settings.exec-once =
|
}: {
|
||||||
[ "systemctl --user start hyprpolkitagent" ];
|
home.packages = [inputs.hyprpolkitagent.packages."${pkgs.stdenv.hostyPlatform.system}".hyprpolkitagent];
|
||||||
|
wayland.windowManager.hyprland.settings.exec-once = ["systemctl --user start hyprpolkitagent"];
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,33 +1,52 @@
|
|||||||
{ pkgs, ... }: {
|
{ pkgs, ... }: {
|
||||||
wayland.windowManager.hyprland.settings = {
|
wayland.windowManager.hyprland.settings = {
|
||||||
windowrulev2 = [
|
windowrule = [
|
||||||
"workspace 2, class:^(emacs)$"
|
"workspace 2, class:^(emacs)$"
|
||||||
"workspace 3, class:^(kitty)$"
|
"workspace 3, class:^(kitty)$"
|
||||||
|
"workspace 3, class:^(com.mitchellh.ghostty)$"
|
||||||
"workspace 9, class:^(org.qutebrowser.qutebrowser)$"
|
"workspace 9, class:^(org.qutebrowser.qutebrowser)$"
|
||||||
"workspace 9, title:^(Chromium)$"
|
"workspace 9, title:^(Chromium)$"
|
||||||
"fullscreen, class:^(wlogout)$"
|
"fullscreen, class:^(wlogout)$"
|
||||||
"float, class:^(Zotero)$"
|
"float, class:^(Zotero)$"
|
||||||
"float, class:^(firefox)$,title:^(Certificate for )*$"
|
"float, class:^(firefox)$"
|
||||||
"float, class:^(firefox)$,title:^(.*Firefox — Sharing Indicator.*)$"
|
"center, class:^(firefox)$"
|
||||||
"float, class:^(firefox)$,title:^(.*Presensi Mahasiswa.*)$"
|
"size 620 720, class:^(firefox)$"
|
||||||
"float, class:(firefox),title:^(Extension)(.*)$"
|
"size 810 200, class:^(Zotero)$, title:^(Quick Format Citation)*$"
|
||||||
"float, class:^(pcmanfm)$,title:^(Confirm File Replacing)$"
|
"tag +dialog, class:^(firefox)$, title:^(Certificate for )*$"
|
||||||
"float, class:^(nemo)$,title:^(Confirm File Replacing)$"
|
"tag +dialog, class:^(firefox)$, title:^(Extension: )*$"
|
||||||
|
"float, class:^(firefox)$, title:^(.*Firefox — Sharing Indicator.*)$"
|
||||||
|
"tag +dialog, class:^(firefox)$, title:^(Presensi Mahasiswa)*$"
|
||||||
|
"float, class:^(firefox)$, title:^(Extension)(.*)$"
|
||||||
|
"float, class:^(pcmanfm)$, title:^(Confirm File Replacing)$"
|
||||||
|
"float, class:^(nemo)$, title:^(Confirm File Replacing)$"
|
||||||
"float, title:^(Confirm File Replacing)$"
|
"float, title:^(Confirm File Replacing)$"
|
||||||
|
"float, class:thunar, title:^(Rename.*)$"
|
||||||
|
"float, class:^(org.inkscape.Inkscape)$"
|
||||||
"float, class:^(nm-connection-editor)$"
|
"float, class:^(nm-connection-editor)$"
|
||||||
"float, class:^(.*blueman-manager.*)$"
|
"float, class:^(.*blueman-manager.*)$"
|
||||||
|
"float, title:^(Picture-in-Picture)$"
|
||||||
|
"size 960 540, title:^(Picture-in-Picture)$"
|
||||||
|
"move 25%-, title:^(Picture-in-Picture)$"
|
||||||
|
"float, title:^(imv|mpv|danmufloat|termfloat|nemo|ncmpcpp)$"
|
||||||
|
"move 25%-, title:^(imv|mpv|danmufloat|termfloat|nemo|ncmpcpp)$"
|
||||||
|
"size 960 540, title:^(imv|mpv|danmufloat|termfloat|nemo|ncmpcpp)$"
|
||||||
|
"pin, title:^(danmufloat)$"
|
||||||
|
"noblur, class:^(org.mozilla.firefox)$"
|
||||||
"size 530 300, class:^(.*blueman-manager.*)$"
|
"size 530 300, class:^(.*blueman-manager.*)$"
|
||||||
"move 100%-w-20 40, class:^(.*blueman-manager.*)$"
|
"move 100%-w-20 40, class:^(.*blueman-manager.*)$"
|
||||||
"noborder, class:^(.*dg-desktop-portal-.*)$"
|
"tag +portal, class:^(.*desktop-portal.*)$"
|
||||||
"noblur, class:^(.*dg-desktop-portal-.*)$"
|
"tag +dialog, initialTitle:^.(Calendar Reminders).*$"
|
||||||
"noshadow, class:^(.*dg-desktop-portal-.*)$"
|
"noborder, tag:portal"
|
||||||
"float, class:^(*.dg-desktop-portal-.*)$"
|
"noblur, tag:portal"
|
||||||
"pin, class:^(*.dg-desktop-portal-.*)$"
|
"noshadow, tag:portal"
|
||||||
|
"float, tag:portal"
|
||||||
|
"float, tag:dialog"
|
||||||
|
"pin, tag:portal"
|
||||||
"pin, class:^(gcr-prompter)$"
|
"pin, class:^(gcr-prompter)$"
|
||||||
"float, title:^(Volume Control)$"
|
"float, title:^(Volume Control)$"
|
||||||
"pin, title:^(Volume Control)$"
|
"pin, title:^(Volume Control)$"
|
||||||
"size 560 340, title:^(Volume Control)$"
|
"size 560 340, title:^(Volume Control)$"
|
||||||
"move 100%-w-30 30, title:^(Volume Control)$"
|
"move 100%-w-40 40, title:^(Volume Control)$"
|
||||||
"float, class:^(spotube)$"
|
"float, class:^(spotube)$"
|
||||||
"size 660 700, class:^(spotube)$"
|
"size 660 700, class:^(spotube)$"
|
||||||
"move 100%-w-20 40, class:^(spotube)$"
|
"move 100%-w-20 40, class:^(spotube)$"
|
||||||
@ -43,6 +62,9 @@
|
|||||||
"float, class:^(virt-manager)$,title:^(Virtual Machine Manager)$"
|
"float, class:^(virt-manager)$,title:^(Virtual Machine Manager)$"
|
||||||
"size 440 220, class:^(virt-manager)$,title:^(Virtual Machine Manager)$"
|
"size 440 220, class:^(virt-manager)$,title:^(Virtual Machine Manager)$"
|
||||||
"center, class:^(virt-manager)$,title:^(Virtual Machine Manager)$"
|
"center, class:^(virt-manager)$,title:^(Virtual Machine Manager)$"
|
||||||
|
"stayfocused, class:(pinentry-)(.*)" # fix pinentry losing focus
|
||||||
|
"rounding 10, class:kitty"
|
||||||
|
# "float, class:.*xdg-desktop-portal.*"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,88 +2,98 @@
|
|||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
let
|
let
|
||||||
foreground = "rgba(216, 222, 233, 0.70)";
|
foreground = "rgba(216, 222, 233, 0.70)";
|
||||||
imageStr = "screenshow"; # toString config.stylix.image;
|
imageStr = toString config.stylix.image;
|
||||||
font = config.stylix.fonts.serif.name;
|
font = config.stylix.fonts.sansSerif.name;
|
||||||
in {
|
in {
|
||||||
programs.hyprlock = {
|
programs.hyprlock = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
general = {
|
general = {
|
||||||
grace = 5;
|
grace = 3;
|
||||||
no_fade_in = false;
|
no_fade_in = false;
|
||||||
disable_loading_bar = false;
|
disable_loading_bar = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
# # BACKGROUND
|
background = {
|
||||||
# background = {
|
path = "screenshot";
|
||||||
# monitor = "";
|
blur_passes = 3;
|
||||||
# path = imageStr;
|
blur_size = 6;
|
||||||
# blur_passes = 0;
|
noise = 1.17e-2;
|
||||||
# contrast = 0.8916;
|
contrast = 1.3; # Vibrant!!!
|
||||||
# brightness = 0.7172;
|
brightness = 0.8;
|
||||||
# vibrancy = 0.1696;
|
vibrancy = 0.21;
|
||||||
# vibrancy_darkness = 0.0;
|
vibrancy_darkness = 0.0;
|
||||||
# };
|
};
|
||||||
#
|
|
||||||
# label = [
|
label = [
|
||||||
# {
|
# Hour
|
||||||
# # Day-Month-Date
|
{
|
||||||
# monitor = "";
|
text = ''cmd[update:1000] echo "<b><big> $(date +"%H") </big></b>"'';
|
||||||
# text = ''cmd[update:1000] echo -e "$(date +"%A, %B %d")"'';
|
color = "#${config.lib.stylix.colors.base06}";
|
||||||
# color = foreground;
|
font_size = 112;
|
||||||
# font_size = 28;
|
font_family = font;
|
||||||
# font_family = font + " Bold";
|
shadow_passes = 2;
|
||||||
# position = "0, 490";
|
shadow_boost = 0.4;
|
||||||
# halign = "center";
|
shadow_size = 4;
|
||||||
# valign = "center";
|
position = "0, 220";
|
||||||
# }
|
halign = "center";
|
||||||
# # Time
|
valign = "center";
|
||||||
# {
|
}
|
||||||
# monitor = "";
|
{
|
||||||
# text = ''cmd[update:1000] echo "<span>$(date +"%I:%M")</span>"'';
|
monitor = "";
|
||||||
# color = foreground;
|
text = ''cmd[update:1000] echo "<b><big> $(date +"%M") </big></b>"'';
|
||||||
# font_size = 160;
|
color = "#${config.lib.stylix.colors.base06}";
|
||||||
# font_family = "steelfish outline regular";
|
font_size = 112;
|
||||||
# position = "0, 370";
|
font_family = font;
|
||||||
# halign = "center";
|
shadow_passes = 2;
|
||||||
# valign = "center";
|
shadow_boost = 0.4;
|
||||||
# }
|
shadow_size = 4;
|
||||||
# # USER
|
position = "0, 80";
|
||||||
# {
|
halign = "center";
|
||||||
# monitor = "";
|
valign = "center";
|
||||||
# text = " $USER";
|
}
|
||||||
# color = foreground;
|
{
|
||||||
# outline_thickness = 2;
|
monitor = "";
|
||||||
# dots_size = 0.2; # Scale of input-field height, 0.2 - 0.8
|
text =
|
||||||
# dots_spacing = 0.2; # Scale of dots' absolute size, 0.0 - 1.0
|
''cmd[update:18000000] echo "<b><big> "$(date +'%A')" </big></b>"'';
|
||||||
# dots_center = true;
|
color = "#${config.lib.stylix.colors.base07}";
|
||||||
# font_size = 18;
|
font_size = 22;
|
||||||
# font_family = font + " Bold";
|
font_family = font;
|
||||||
# position = "0, -180";
|
position = "0, -10";
|
||||||
# halign = "center";
|
halign = "center";
|
||||||
# valign = "center";
|
valign = "center";
|
||||||
# }
|
}
|
||||||
# ];
|
{
|
||||||
#
|
monitor = "";
|
||||||
# # INPUT FIELD
|
text = ''cmd[update:18000000] echo "<b> "$(date +'%d %b')" </b>"'';
|
||||||
# input-field = [{
|
color = "#${config.lib.stylix.colors.base07}";
|
||||||
# monitor = "";
|
font_size = 18;
|
||||||
# size = "300, 60";
|
font_family = font;
|
||||||
# outline_thickness = 2;
|
position = "0, -40";
|
||||||
# dots_size = 0.2; # Scale of input-field height, 0.2 - 0.8
|
halign = "center";
|
||||||
# dots_spacing = 0.2; # Scale of dots' absolute size, 0.0 - 1.0
|
valign = "center";
|
||||||
# dots_center = true;
|
}
|
||||||
# outer_color = "rgba(255, 255, 255, 0)";
|
];
|
||||||
# inner_color = "rgba(255, 255, 255, 0.1)";
|
|
||||||
# font_color = foreground;
|
input-field = [{
|
||||||
# fade_on_empty = false;
|
monitor = "";
|
||||||
# font_family = font + " Bold";
|
size = "250, 50";
|
||||||
# placeholder_text = "<i>🔒 Enter Password</i>";
|
outline_thickness = 3;
|
||||||
# hide_input = false;
|
dots_size = 0.26; # Scale of input-field height, 0.2 - 0.8
|
||||||
# position = "0, -250";
|
dots_spacing = 0.64; # Scale of dots' absolute size, 0.0 - 1.0
|
||||||
# halign = "center";
|
dots_center = true;
|
||||||
# valign = "center";
|
dots_rouding = -1;
|
||||||
# }];
|
rounding = 22;
|
||||||
|
outer_color = "#${config.lib.stylix.colors.base00}";
|
||||||
|
inner_color = "#${config.lib.stylix.colors.base00}";
|
||||||
|
font_color = "#${config.lib.stylix.colors.base06}";
|
||||||
|
fade_on_empty = true;
|
||||||
|
placeholder_text =
|
||||||
|
"<i>Password...</i>"; # Text rendered in the input box when it's empty.
|
||||||
|
position = "0, 120";
|
||||||
|
halign = "center";
|
||||||
|
valign = "bottom";
|
||||||
|
}];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -7,34 +7,36 @@ let
|
|||||||
background = "#${config.lib.stylix.colors.base00}";
|
background = "#${config.lib.stylix.colors.base00}";
|
||||||
background-alt = "#${config.lib.stylix.colors.base01}";
|
background-alt = "#${config.lib.stylix.colors.base01}";
|
||||||
foreground = "#${config.lib.stylix.colors.base05}";
|
foreground = "#${config.lib.stylix.colors.base05}";
|
||||||
font = "${config.stylix.fonts.serif.name}";
|
font = "${config.stylix.fonts.sansSerif.name}";
|
||||||
fontSize = "${toString config.stylix.fonts.sizes.desktop}px";
|
fontSize = "${toString config.stylix.fonts.sizes.desktop}px";
|
||||||
|
|
||||||
inherit (config.var.theme) rounding border-size gaps-in gaps-out;
|
inherit (config.var.theme) rounding border-size gaps-in gaps-out;
|
||||||
inherit (config.var.theme.bar)
|
inherit (config.var.theme.bar)
|
||||||
floating transparentButtons transparent position;
|
floating transparentButtons transparent position;
|
||||||
inherit (config.var) cpuTempSensor location username weatherapikey;
|
inherit (config.var) location username weatherapikey;
|
||||||
in {
|
in {
|
||||||
imports = [ inputs.hyprpanel.homeManagerModules.hyprpanel ];
|
imports = [ inputs.hyprpanel.homeManagerModules.hyprpanel ];
|
||||||
|
|
||||||
programs.hyprpanel = {
|
programs.hyprpanel = {
|
||||||
enable = true;
|
enable = true;
|
||||||
systemd.enable = true;
|
overlay.enable = true;
|
||||||
hyprland.enable = true;
|
hyprland.enable = true;
|
||||||
overwrite.enable = true;
|
overwrite.enable = true;
|
||||||
|
settings = {
|
||||||
layout = {
|
layout = {
|
||||||
"bar.layouts" = {
|
bar.layouts = {
|
||||||
"0" = {
|
"0" = {
|
||||||
left = [ "dashboard" "hypridle" "workspaces" "windowtitle" ];
|
left = [ "dashboard" "hypridle" "workspaces" "windowtitle" ];
|
||||||
middle = [ "media" ];
|
middle = [ "media" ];
|
||||||
right = [
|
right = [
|
||||||
"systray"
|
|
||||||
"volume"
|
"volume"
|
||||||
"hyprsunset"
|
"hyprsunset"
|
||||||
"battery"
|
"battery"
|
||||||
"network"
|
"network"
|
||||||
"cputemp"
|
"bluetooth"
|
||||||
|
"cpu"
|
||||||
"clock"
|
"clock"
|
||||||
|
"systray"
|
||||||
"notifications"
|
"notifications"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
@ -45,52 +47,11 @@ in {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
};
|
||||||
|
|
||||||
override = {
|
override = {
|
||||||
bar.battery.hideLabelWhenFull = true;
|
|
||||||
bar.bluetooth.label = false;
|
|
||||||
bar.clock.format = "%a, %d %b %H:%M";
|
|
||||||
bar.customModules.cpuTemp.sensor = cpuTempSensor;
|
|
||||||
bar.customModules.hypridle.label = false;
|
|
||||||
bar.customModules.hyprsunset.label = false;
|
|
||||||
bar.launcher.icon = "";
|
|
||||||
bar.media.show_active_only = true;
|
|
||||||
bar.network.label = false;
|
|
||||||
bar.network.truncation_size = 12;
|
|
||||||
bar.volume.label = false;
|
|
||||||
bar.windowtitle.label = true;
|
|
||||||
bar.workspaces.hideUnoccupied = false;
|
|
||||||
bar.workspaces.monitorSpecific = true;
|
|
||||||
menus.clock.time.hideSeconds = true;
|
|
||||||
menus.clock.time.military = true;
|
|
||||||
menus.clock.weather.key = weatherapikey;
|
|
||||||
menus.clock.weather.location = location;
|
|
||||||
menus.clock.weather.unit = "metric";
|
|
||||||
menus.dashboard.powermenu.avatar.image =
|
|
||||||
"/home/${username}/.profile_picture.png";
|
|
||||||
menus.dashboard.powermenu.confirmation = false;
|
|
||||||
menus.dashboard.shortcuts.left.shortcut1.command = "firefox";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut1.icon = "";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut1.tooltip = "Firefox";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut2.command = "caffeine";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut2.icon = "";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut2.tooltip = "Caffeine";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut3.command = "night-shift";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut3.icon = "";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut3.tooltip = "Night-shift";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut4.command = "menu";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut4.icon = "";
|
|
||||||
menus.dashboard.shortcuts.left.shortcut4.tooltip = "Search Apps";
|
|
||||||
menus.dashboard.shortcuts.right.shortcut1.command = "hyprpicker -a";
|
|
||||||
menus.dashboard.shortcuts.right.shortcut1.icon = "";
|
|
||||||
menus.dashboard.shortcuts.right.shortcut1.tooltip = "Color Picker";
|
|
||||||
menus.dashboard.shortcuts.right.shortcut3.command =
|
|
||||||
"screenshot region swappy";
|
|
||||||
menus.dashboard.shortcuts.right.shortcut3.icon = "";
|
|
||||||
menus.dashboard.shortcuts.right.shortcut3.tooltip = "Screenshot";
|
|
||||||
menus.dashboard.stats.enabled = false;
|
|
||||||
theme.bar.background =
|
theme.bar.background =
|
||||||
"${background + (if transparentButtons then "00" else "")}";
|
"${background + (if transparent then "00" else "")}";
|
||||||
theme.bar.border_radius = "${toString rounding}px";
|
theme.bar.border_radius = "${toString rounding}px";
|
||||||
theme.bar.buttons.background =
|
theme.bar.buttons.background =
|
||||||
"${(if transparent then background else background-alt)
|
"${(if transparent then background else background-alt)
|
||||||
@ -111,9 +72,9 @@ in {
|
|||||||
theme.bar.buttons.workspaces.available = accent-alt;
|
theme.bar.buttons.workspaces.available = accent-alt;
|
||||||
theme.bar.buttons.workspaces.hover = accent-alt;
|
theme.bar.buttons.workspaces.hover = accent-alt;
|
||||||
theme.bar.buttons.workspaces.occupied = accent;
|
theme.bar.buttons.workspaces.occupied = accent;
|
||||||
theme.bar.buttons.y_margins =
|
theme.bar.buttons.y_margins = if transparentButtons then "0" else "8";
|
||||||
if floating && transparent then "0" else "8";
|
theme.bar.dropdownGap = "3em";
|
||||||
theme.bar.floating = if floating then "true" else "false";
|
theme.bar.floating = floating;
|
||||||
theme.bar.location = position;
|
theme.bar.location = position;
|
||||||
theme.bar.margin_bottom =
|
theme.bar.margin_bottom =
|
||||||
"${if position == "top" then "0" else toString (gaps-in * 2)}px";
|
"${if position == "top" then "0" else toString (gaps-in * 2)}px";
|
||||||
@ -169,6 +130,56 @@ in {
|
|||||||
theme.osd.muted_zero = true;
|
theme.osd.muted_zero = true;
|
||||||
theme.osd.orientation = "vertical";
|
theme.osd.orientation = "vertical";
|
||||||
theme.osd.radius = "${toString rounding}px";
|
theme.osd.radius = "${toString rounding}px";
|
||||||
|
|
||||||
|
bar.workspaces.reverse_scroll = true;
|
||||||
|
bar.battery.hideLabelWhenFull = true;
|
||||||
|
bar.bluetooth.label = false;
|
||||||
|
bar.clock.format = "%a, %d %b %H:%M";
|
||||||
|
bar.customModules.hypridle.label = false;
|
||||||
|
bar.customModules.hyprsunset.label = false;
|
||||||
|
bar.customModules.hyprsunset.temperature = "4500k";
|
||||||
|
bar.launcher.icon = "";
|
||||||
|
bar.media.show_active_only = true;
|
||||||
|
bar.network.label = false;
|
||||||
|
bar.network.truncation_size = 12;
|
||||||
|
bar.volume.label = false;
|
||||||
|
bar.windowtitle.label = true;
|
||||||
|
# bar.workspaces.applicationIconEmptyWorkspace = "";
|
||||||
|
# bar.workspaces.hideUnoccupied = false;
|
||||||
|
bar.workspaces.monitorSpecific = false;
|
||||||
|
# bar.workspaces.numbered_active_indicator = "underline";
|
||||||
|
# bar.workspaces.showApplicationIcons = false;
|
||||||
|
bar.workspaces.show_icons = false;
|
||||||
|
bar.workspaces.workspaces = 5;
|
||||||
|
bar.workspaces.show_numbered = true;
|
||||||
|
menus.clock.time.hideSeconds = true;
|
||||||
|
menus.clock.time.military = true;
|
||||||
|
menus.clock.weather.key = weatherapikey;
|
||||||
|
menus.clock.weather.location = location;
|
||||||
|
menus.clock.weather.unit = "metric";
|
||||||
|
menus.dashboard.powermenu.avatar.image =
|
||||||
|
"/home/${username}/.profile_picture.png";
|
||||||
|
menus.dashboard.powermenu.confirmation = false;
|
||||||
|
menus.dashboard.shortcuts.left.shortcut1.command = "firefox";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut1.icon = "";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut1.tooltip = "Firefox";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut2.command = "caffeine";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut2.icon = "";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut2.tooltip = "Caffeine";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut3.command = "night-shift";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut3.icon = "";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut3.tooltip = "Night-shift";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut4.command = "menu";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut4.icon = "";
|
||||||
|
menus.dashboard.shortcuts.left.shortcut4.tooltip = "Search Apps";
|
||||||
|
menus.dashboard.shortcuts.right.shortcut1.command = "hyprpicker -a";
|
||||||
|
menus.dashboard.shortcuts.right.shortcut1.icon = "";
|
||||||
|
menus.dashboard.shortcuts.right.shortcut1.tooltip = "Color Picker";
|
||||||
|
menus.dashboard.shortcuts.right.shortcut3.command =
|
||||||
|
"screenshot region swappy";
|
||||||
|
menus.dashboard.shortcuts.right.shortcut3.icon = "";
|
||||||
|
menus.dashboard.shortcuts.right.shortcut3.tooltip = "Screenshot";
|
||||||
|
menus.dashboard.stats.enabled = false;
|
||||||
wallpaper.enable = false;
|
wallpaper.enable = false;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -31,5 +31,7 @@
|
|||||||
"application/pdf" = "org.pwmt.zathura.desktop";
|
"application/pdf" = "org.pwmt.zathura.desktop";
|
||||||
"inode/directory" = "Thunar.desktop";
|
"inode/directory" = "Thunar.desktop";
|
||||||
};
|
};
|
||||||
|
associations.added = { "x-scheme-handler/mailto" = "thunderbird.desktop"; };
|
||||||
};
|
};
|
||||||
|
xdg.configFile."mimeapps.list".force = true;
|
||||||
}
|
}
|
||||||
|
|||||||
244
home/system/niri/default.nix
Normal file
244
home/system/niri/default.nix
Normal file
@ -0,0 +1,244 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
config,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
noctalia = cmd:
|
||||||
|
["noctalia-shell" "ipc" "call"]
|
||||||
|
++ (pkgs.lib.splitString " " cmd);
|
||||||
|
in {
|
||||||
|
imports = [inputs.niri.homeModules.niri inputs.noctalia.homeModules.default];
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
wayland-utils
|
||||||
|
libsecret
|
||||||
|
cage
|
||||||
|
xwayland-satellite
|
||||||
|
libnotify
|
||||||
|
cliphist
|
||||||
|
cava
|
||||||
|
kdePackages.polkit-kde-agent-1
|
||||||
|
nautilus
|
||||||
|
direnv
|
||||||
|
imv
|
||||||
|
];
|
||||||
|
|
||||||
|
programs.niri = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
prefer-no-csd = true;
|
||||||
|
hotkey-overlay.skip-at-startup = true;
|
||||||
|
environment = {
|
||||||
|
NIXOS_OZONE_WL = "1";
|
||||||
|
QT_QPA_PLATFORM = "wayland";
|
||||||
|
ELECTRON_OZON_PLATFORM_HINT = "wayland";
|
||||||
|
DISPLAY = ":0"; # Or null
|
||||||
|
_JAVA_AWT_WM_NONREPARENTING = "1";
|
||||||
|
};
|
||||||
|
cursor = {
|
||||||
|
hide-when-typing = true;
|
||||||
|
hide-after-inactive-ms = 1000;
|
||||||
|
};
|
||||||
|
|
||||||
|
binds = with config.lib.niri.actions; {
|
||||||
|
"Mod+Space".action.spawn = noctalia "launcher toggle";
|
||||||
|
"Mod+P".action.spawn = noctalia "sessionMenu toggle";
|
||||||
|
"Mod+V".action.spawn = noctalia "launcher clipboard";
|
||||||
|
"Mod+Shift+C".action.spawn = noctalia "launcher calculator";
|
||||||
|
"Mod+C".action.spawn = noctalia "calendar toggle";
|
||||||
|
"Mod+S".action.spawn = noctalia "controlCenter toggle";
|
||||||
|
"Mod+F12".action.spawn = noctalia "powerProfile cycle";
|
||||||
|
"XF86AudioLowerVolume".action.spawn = noctalia "volume decrease";
|
||||||
|
"XF86AudioRaiseVolume".action.spawn = noctalia "volume increase";
|
||||||
|
"XF86AudioMute".action.spawn = noctalia "volume muteOutput";
|
||||||
|
"XF86MonBrightnessUp".action.spawn = noctalia "brightness increase";
|
||||||
|
"XF86MonBrightnessDown".action.spawn = noctalia "brightness decrease";
|
||||||
|
"XF86AudioPlay".action.spawn = noctalia "media playPause";
|
||||||
|
"XF86AudioNext".action.spawn = noctalia "media next";
|
||||||
|
"XF86AudioPrev".action.spawn = noctalia "media previous";
|
||||||
|
"Mod+Shift+Q".action.spawn = noctalia "lockScreen lock";
|
||||||
|
"Mod+Return".action.spawn = ["alacritty"];
|
||||||
|
"Mod+E".action.spawn = ["nautilus"];
|
||||||
|
"Mod+B".action.spawn = ["firefox"];
|
||||||
|
"Mod+U".action = move-workspace-up;
|
||||||
|
"Mod+I".action = move-workspace-down;
|
||||||
|
"Mod+Shift+Slash".action = show-hotkey-overlay;
|
||||||
|
"Mod+Q".action = close-window;
|
||||||
|
"Mod+H".action = focus-column-or-monitor-left;
|
||||||
|
"Mod+L".action = focus-column-or-monitor-right;
|
||||||
|
"Mod+J".action = focus-window-or-monitor-down;
|
||||||
|
"Mod+K".action = focus-window-or-monitor-up;
|
||||||
|
"Mod+Shift+H".action = move-column-left-or-to-monitor-left;
|
||||||
|
"Mod+Shift+L".action = move-column-right-or-to-monitor-right;
|
||||||
|
"Mod+Shift+J".action = move-window-down-or-to-workspace-down;
|
||||||
|
"Mod+Shift+K".action = move-window-up-or-to-workspace-up;
|
||||||
|
"Mod+Ctrl+K".action = move-window-to-workspace-up;
|
||||||
|
"Mod+Ctrl+J".action = move-window-to-workspace-down;
|
||||||
|
"Mod+0".action = focus-workspace 0;
|
||||||
|
"Mod+1".action = focus-workspace 1;
|
||||||
|
"Mod+2".action = focus-workspace 2;
|
||||||
|
"Mod+3".action = focus-workspace 3;
|
||||||
|
"Mod+4".action = focus-workspace 4;
|
||||||
|
"Mod+5".action = focus-workspace 5;
|
||||||
|
"Mod+6".action = focus-workspace 6;
|
||||||
|
"Mod+7".action = focus-workspace 7;
|
||||||
|
"Mod+8".action = focus-workspace 8;
|
||||||
|
"Mod+9".action = focus-workspace 9;
|
||||||
|
"Mod+Shift+Period".action = move-workspace-to-monitor-next;
|
||||||
|
"Mod+Shift+Comma".action = move-workspace-to-monitor-previous;
|
||||||
|
"Mod+Comma".action = consume-or-expel-window-left;
|
||||||
|
"Mod+Period".action = consume-or-expel-window-right;
|
||||||
|
"Mod+Grave".action = toggle-overview;
|
||||||
|
"Mod+Tab".action = focus-workspace-previous;
|
||||||
|
"Mod+Equal".action = set-column-width "+5%";
|
||||||
|
"Mod+Minus".action = set-column-width "-5%";
|
||||||
|
"Mod+Shift+Equal".action = set-window-height "+5%";
|
||||||
|
"Mod+Shift+Minus".action = set-window-height "-5%";
|
||||||
|
"Mod+F".action = maximize-column;
|
||||||
|
"Mod+Shift+F".action = fullscreen-window;
|
||||||
|
"Mod+Ctrl+Shift+F".action = toggle-windowed-fullscreen;
|
||||||
|
"Mod+Y".action = toggle-window-floating;
|
||||||
|
"Mod+Shift+Y".action = switch-focus-between-floating-and-tiling;
|
||||||
|
"Mod+W".action = toggle-column-tabbed-display;
|
||||||
|
"Mod+Parenright".action = switch-layout "next";
|
||||||
|
"Mod+Parenleft".action = switch-layout "prev";
|
||||||
|
"Mod+Shift+E".action = quit;
|
||||||
|
};
|
||||||
|
|
||||||
|
input = {
|
||||||
|
warp-mouse-to-focus.enable = true;
|
||||||
|
focus-follows-mouse.enable = false;
|
||||||
|
trackpoint = {
|
||||||
|
accel-profile = "adaptive";
|
||||||
|
accel-speed = 0.6;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
layout = {
|
||||||
|
focus-ring = {
|
||||||
|
width = 2;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
window-rules = [
|
||||||
|
{
|
||||||
|
geometry-corner-radius = let
|
||||||
|
r = 4.0;
|
||||||
|
in {
|
||||||
|
top-left = r;
|
||||||
|
top-right = r;
|
||||||
|
bottom-left = r;
|
||||||
|
bottom-right = r;
|
||||||
|
};
|
||||||
|
clip-to-geometry = true;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
matches = [{app-id = "firefox";}];
|
||||||
|
open-maximized = true;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
matches = [{app-id = "chromium-browser";}];
|
||||||
|
open-maximized = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
# debug = {
|
||||||
|
# honor-xdg-activation-with-invalid-serial = 1;
|
||||||
|
# };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.noctalia-shell = {
|
||||||
|
enable = true;
|
||||||
|
systemd.enable = true;
|
||||||
|
settings = {
|
||||||
|
general = {
|
||||||
|
animationSpeed = 2;
|
||||||
|
compactLockScreen = true;
|
||||||
|
};
|
||||||
|
wallpaper = {
|
||||||
|
enabled = false;
|
||||||
|
directory = "~/Pictures/wallpapers";
|
||||||
|
};
|
||||||
|
dock.enabled = false;
|
||||||
|
bar = {
|
||||||
|
density = "compact";
|
||||||
|
position = "right";
|
||||||
|
showCapsule = false;
|
||||||
|
widgets = {
|
||||||
|
left = [
|
||||||
|
{
|
||||||
|
id = "SidePanelToggle";
|
||||||
|
useDistroLogo = true;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
id = "WiFi";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
id = "Bluetooth";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
center = [
|
||||||
|
{
|
||||||
|
hideUnoccupied = false;
|
||||||
|
id = "Workspace";
|
||||||
|
labelMode = "none";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
right = [
|
||||||
|
{
|
||||||
|
colorizeIcons = true;
|
||||||
|
drawerEnabled = true;
|
||||||
|
id = "Tray";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alwaysShowPercentage = false;
|
||||||
|
id = "Battery";
|
||||||
|
warningThreshold = 30;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
formatHorizontal = "HH:mm";
|
||||||
|
formatVertical = "HH mm";
|
||||||
|
id = "Clock";
|
||||||
|
useMonospacedFont = true;
|
||||||
|
usePrimaryColor = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
colorSchemes.predefinedScheme = "Monochrome";
|
||||||
|
general = {
|
||||||
|
avatarImage = "/home/dim/.face";
|
||||||
|
radiusRatio = 0.2;
|
||||||
|
};
|
||||||
|
location = {
|
||||||
|
monthBeforeDay = false;
|
||||||
|
name = "Tangerang";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
# this may also be a string or a path to a JSON file,
|
||||||
|
# but in this case must include *all* settings.
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.alacritty = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
window.decorations = "None";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.kanshi = {
|
||||||
|
enable = true;
|
||||||
|
profiles = {
|
||||||
|
rumah = {
|
||||||
|
outputs = [
|
||||||
|
{
|
||||||
|
criteria = "LG Electronics 16EN33 305INKH5P181";
|
||||||
|
position = "0,0";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
criteria = "eDP-1";
|
||||||
|
position = "0,768";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
225
home/system/waybar/default.nix
Normal file
225
home/system/waybar/default.nix
Normal file
@ -0,0 +1,225 @@
|
|||||||
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
inherit (config.var.theme.bar) position;
|
||||||
|
inherit (config.var.theme) rounding border-size gaps-in gaps-out;
|
||||||
|
in {
|
||||||
|
home.packages = with pkgs; [playerctl];
|
||||||
|
programs.waybar = {
|
||||||
|
enable = true;
|
||||||
|
systemd = {
|
||||||
|
enable = true;
|
||||||
|
target = "hyprland-session";
|
||||||
|
};
|
||||||
|
settings = [
|
||||||
|
{
|
||||||
|
layer = "top";
|
||||||
|
position = position;
|
||||||
|
modules-left = ["hyprland/workspaces" "mpris"];
|
||||||
|
modules-center = [];
|
||||||
|
modules-right = [
|
||||||
|
"idle_inhibitor"
|
||||||
|
"backlight"
|
||||||
|
"battery#1"
|
||||||
|
"battery#2"
|
||||||
|
"cpu"
|
||||||
|
"memory"
|
||||||
|
"temperature"
|
||||||
|
"clock"
|
||||||
|
"privacy"
|
||||||
|
"wireplumber"
|
||||||
|
"tray"
|
||||||
|
];
|
||||||
|
clock = {
|
||||||
|
"format" = "{:%d %b %H:%M} ";
|
||||||
|
"format-alt" = "{:%A, %d %B %Y (%R)} ";
|
||||||
|
"tooltip-format" = ''
|
||||||
|
<big>{:%Y %B}</big>
|
||||||
|
<tt><small>{calendar}</small></tt>'';
|
||||||
|
"calendar" = {
|
||||||
|
"mode" = "year";
|
||||||
|
"mode-mon-col" = 3;
|
||||||
|
"weeks-pos" = "right";
|
||||||
|
"on-scroll" = 1;
|
||||||
|
"format" = {
|
||||||
|
"months" = "<span color='#ffead3'><b>{}</b></span>";
|
||||||
|
"days" = "<span color='#ecc6d9'><b>{}</b></span>";
|
||||||
|
"weeks" = "<span color='#99ffdd'><b>W{}</b></span>";
|
||||||
|
"weekdays" = "<span color='#ffcc66'><b>{}</b></span>";
|
||||||
|
"today" = "<span color='#ff6699'><b><u>{}</u></b></span>";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
actions = {
|
||||||
|
"on-click-right" = "mode";
|
||||||
|
"on-scroll-up" = "shift_up";
|
||||||
|
"on-scroll-down" = "shift_down";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
tray = {spacing = gaps-in;};
|
||||||
|
cpu = {format = " {usage}";};
|
||||||
|
memory = {format = " {}";};
|
||||||
|
idle_inhibitor = {
|
||||||
|
format = "{icon}";
|
||||||
|
format-icons = {
|
||||||
|
activated = "";
|
||||||
|
deactivated = "";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
network = {
|
||||||
|
format = "{ifname}";
|
||||||
|
format-wifi = "{essid} ({signalStrength}%) ";
|
||||||
|
format-ethernet = "{ipaddr}/{cidr} ";
|
||||||
|
format-disconnected = "";
|
||||||
|
tooltip-format = "{ifname} via {gwaddr} ";
|
||||||
|
tooltip-format-wifi = "{essid} ({signalStrength}%) ";
|
||||||
|
tooltip-format-ethernet = "{ifname} ";
|
||||||
|
tooltip-format-disconnected = "Disconnected";
|
||||||
|
max-length = 50;
|
||||||
|
};
|
||||||
|
temperature = {format = "{temperatureC} ";};
|
||||||
|
backlight = {
|
||||||
|
device = "intel_backlight";
|
||||||
|
format = "{icon}";
|
||||||
|
format-icons = ["" "" "" "" "" "" "" "" ""];
|
||||||
|
};
|
||||||
|
"battery#1" = {
|
||||||
|
bat = "BAT0";
|
||||||
|
interval = 90;
|
||||||
|
states = {
|
||||||
|
warning = 30;
|
||||||
|
critical = 15;
|
||||||
|
};
|
||||||
|
format = "{capacity}";
|
||||||
|
max-length = 2;
|
||||||
|
};
|
||||||
|
"battery#2" = {
|
||||||
|
bat = "BAT1";
|
||||||
|
interval = 90;
|
||||||
|
states = {
|
||||||
|
warning = 30;
|
||||||
|
critical = 15;
|
||||||
|
};
|
||||||
|
format = "{capacity} {icon}";
|
||||||
|
format-icons = ["" "" "" "" ""];
|
||||||
|
max-length = 25;
|
||||||
|
};
|
||||||
|
"hyprland/window" = {
|
||||||
|
format = "{}";
|
||||||
|
max-length = 32;
|
||||||
|
rewrite = {
|
||||||
|
"(.*) — Mozilla Firefox" = " $1";
|
||||||
|
"(.*) - kitty" = " [$1]";
|
||||||
|
};
|
||||||
|
separate-outputs = true;
|
||||||
|
};
|
||||||
|
"hyprland/workspaces" = {format = "<small>{name}</small>";};
|
||||||
|
mpris = {
|
||||||
|
"format" = "{player_icon} {dynamic}";
|
||||||
|
"format-paused" = "{status_icon} <i>{dynamic}</i>";
|
||||||
|
"player-icons" = {
|
||||||
|
"default" = "";
|
||||||
|
"mpv" = "";
|
||||||
|
};
|
||||||
|
"dynamic-len" = 30;
|
||||||
|
"status-icons" = {"paused" = "";};
|
||||||
|
"ignored-players" = ["firefox"];
|
||||||
|
};
|
||||||
|
privacy = {
|
||||||
|
"icon-spacing" = 4;
|
||||||
|
"icon-size" = 18;
|
||||||
|
"transition-duration" = 250;
|
||||||
|
"modules" = [
|
||||||
|
{
|
||||||
|
"type" = "screenshare";
|
||||||
|
"tooltip" = true;
|
||||||
|
"tooltip-icon-size" = 24;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"type" = "audio-out";
|
||||||
|
"tooltip" = true;
|
||||||
|
"tooltip-icon-size" = 24;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"type" = "audio-in";
|
||||||
|
"tooltip" = true;
|
||||||
|
"tooltip-icon-size" = 24;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
pulseaudio = {
|
||||||
|
"format" = "{volume}%{icon}";
|
||||||
|
"format-bluetooth" = "{volume}%{icon}";
|
||||||
|
"format-muted" = "";
|
||||||
|
"format-icons" = {
|
||||||
|
"headphone" = "";
|
||||||
|
"phone" = "";
|
||||||
|
"portable" = "";
|
||||||
|
"car" = "";
|
||||||
|
"default" = ["" ""];
|
||||||
|
};
|
||||||
|
"scroll-step" = 1;
|
||||||
|
"on-click" = "pavucontrol";
|
||||||
|
"ignored-sinks" = ["Easy Effects Sink"];
|
||||||
|
};
|
||||||
|
"wireplumber" = {
|
||||||
|
"on-click" = "pavucontrol";
|
||||||
|
"on-click-right" = "amixer sset Master toggle 1>/dev/null";
|
||||||
|
"format" = "<span foreground='#fab387'>{icon}</span>{volume}%";
|
||||||
|
"format-muted" = " ";
|
||||||
|
"format-source" = "";
|
||||||
|
"format-source-muted" = "";
|
||||||
|
"format-icons" = {
|
||||||
|
"headphone" = " ";
|
||||||
|
"hands-free" = " ";
|
||||||
|
"headset" = " ";
|
||||||
|
"phone" = " ";
|
||||||
|
"portable" = " ";
|
||||||
|
"car" = " ";
|
||||||
|
"default" = [" " " " " "];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
"custom/cuaca" = {
|
||||||
|
"format" = "{}";
|
||||||
|
"format-alt" = "{alt}: {}";
|
||||||
|
"format-alt-click" = "click-right";
|
||||||
|
"interval" = 3600;
|
||||||
|
"exec" = "curl -s 'https://wttr.in/Tangerang?format=1'";
|
||||||
|
"exec-if" = "ping wttr.in -c1";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
style = ''
|
||||||
|
* { border: none; border-radius: 0; }
|
||||||
|
window#waybar { background-color: transparent; color: @base05; transition-property: background-color; transition-duration: 0.5s; }
|
||||||
|
window#waybar.hidden { opacity: 0.2; }
|
||||||
|
label.module { padding: 0 0.5em; }
|
||||||
|
#workspaces {
|
||||||
|
background-color: @base03;
|
||||||
|
border-radius: 1em;
|
||||||
|
margin: 0 1em;
|
||||||
|
}
|
||||||
|
#workspaces button {
|
||||||
|
padding: 0 .3em;
|
||||||
|
border-radius: 1em;
|
||||||
|
background-color: @base03;
|
||||||
|
}
|
||||||
|
#workspaces button.urgent { background-color: @base09; }
|
||||||
|
#workspaces button.empty { background-color: @base03; }
|
||||||
|
#workspaces button.visible { background-color: @base04; color: @base01 }
|
||||||
|
#workspaces button.active { background-color: @base0A; }
|
||||||
|
#window { font-weight:800; color: @base06; background-color: @base00; margin: 0 .5em; padding: 0 1em; border-radius: 0 0 1em 1em;}
|
||||||
|
.modules-left { background-color: transparent; border-radius: 0 1em 1em 0; padding-right: 1em; }
|
||||||
|
.modules-right { background-color: @base00; border-radius: 0 0 0 1em; padding-left: 1em; }
|
||||||
|
label#battery.1 { padding-right: 0; }
|
||||||
|
label#battery.2 { padding-left: ${toString gaps-in}px; }
|
||||||
|
#privacy, #tray { padding: 0 ${toString gaps-in}px; }
|
||||||
|
#tray { background-color: @base03; border-radius: 1em 0 0 1em; }
|
||||||
|
#tray > .passive { -gtk-icon-effect: dim; }
|
||||||
|
#tray > .needs-attention { -gtk-icon-effect: highlight; background-color: @base08; }
|
||||||
|
tooltip { border-radius: ${toString rounding}px; }
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
||||||
@ -5,7 +5,7 @@ let
|
|||||||
background = "#${config.lib.stylix.colors.base00}";
|
background = "#${config.lib.stylix.colors.base00}";
|
||||||
background-alt = "#${config.lib.stylix.colors.base01}";
|
background-alt = "#${config.lib.stylix.colors.base01}";
|
||||||
foreground = "#${config.lib.stylix.colors.base05}";
|
foreground = "#${config.lib.stylix.colors.base05}";
|
||||||
font = config.stylix.fonts.serif.name;
|
font = config.stylix.fonts.sansSerif.name;
|
||||||
rounding = config.var.theme.rounding;
|
rounding = config.var.theme.rounding;
|
||||||
font-size = config.stylix.fonts.sizes.popups;
|
font-size = config.stylix.fonts.sizes.popups;
|
||||||
in {
|
in {
|
||||||
|
|||||||
@ -1,8 +1,9 @@
|
|||||||
{ config, pkgs, ... }: {
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
imports = [
|
imports = [
|
||||||
# ../../nixos/nvidia.nix # CHANGEME: Remove this line if you don't have an Nvidia GPU
|
|
||||||
# ../../nixos/prime.nix # CHANGEME: Remove this line if you don't have an Nvidia GPU
|
|
||||||
|
|
||||||
../../nixos/audio.nix
|
../../nixos/audio.nix
|
||||||
../../nixos/auto-upgrade.nix
|
../../nixos/auto-upgrade.nix
|
||||||
../../nixos/bluetooth.nix
|
../../nixos/bluetooth.nix
|
||||||
@ -13,6 +14,8 @@
|
|||||||
../../nixos/systemd-boot.nix
|
../../nixos/systemd-boot.nix
|
||||||
../../nixos/timezone.nix
|
../../nixos/timezone.nix
|
||||||
../../nixos/tuigreet.nix
|
../../nixos/tuigreet.nix
|
||||||
|
# ../../nixos/tlp.nix
|
||||||
|
../../nixos/upower.nix
|
||||||
../../nixos/users.nix
|
../../nixos/users.nix
|
||||||
../../nixos/utils.nix
|
../../nixos/utils.nix
|
||||||
../../nixos/virtualisation.nix
|
../../nixos/virtualisation.nix
|
||||||
@ -31,7 +34,14 @@
|
|||||||
# users.users."${config.var.username}".extraGroups = [ "scanner" "lp" ];
|
# users.users."${config.var.username}".extraGroups = [ "scanner" "lp" ];
|
||||||
# hardware.sane.enable = true;
|
# hardware.sane.enable = true;
|
||||||
|
|
||||||
networking.hosts = { "192.168.122.52" = [ "websiteku.lokal" ]; };
|
programs.nm-applet.enable = true;
|
||||||
|
networking.hosts = {
|
||||||
|
"192.168.122.52" = ["websiteku.lokal"];
|
||||||
|
"127.0.0.1" = ["dimensi.lokal" "sisfokampus.ddev.site"];
|
||||||
|
# "10.230.4.15" = [ "www.yapeim.my" ];
|
||||||
|
# "43.239.205.20" = [ "dimensi.my" ];
|
||||||
|
# "103.106.6.124" = [ "dimensi.my" ];
|
||||||
|
};
|
||||||
|
|
||||||
# Don't touch this
|
# Don't touch this
|
||||||
system.stateVersion = "24.05";
|
system.stateVersion = "24.05";
|
||||||
|
|||||||
@ -1,11 +1,16 @@
|
|||||||
{ pkgs, config, inputs, ... }: {
|
{
|
||||||
|
pkgs,
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
imports = [
|
imports = [
|
||||||
./variables.nix
|
./variables.nix
|
||||||
|
|
||||||
# Programs
|
# Programs
|
||||||
../../home/programs/kitty
|
../../home/programs/kitty
|
||||||
../../home/programs/nvim
|
../../home/programs/nvf
|
||||||
|
../../home/programs/helix
|
||||||
../../home/programs/shell
|
../../home/programs/shell
|
||||||
../../home/programs/pass
|
../../home/programs/pass
|
||||||
../../home/programs/fetch
|
../../home/programs/fetch
|
||||||
@ -23,46 +28,49 @@
|
|||||||
../../home/scripts # All scripts
|
../../home/scripts # All scripts
|
||||||
|
|
||||||
# System (Desktop environment like stuff)
|
# System (Desktop environment like stuff)
|
||||||
../../home/system/hyprland
|
# ../../home/system/hyprland
|
||||||
../../home/system/hypridle
|
# ../../home/system/hypridle
|
||||||
../../home/system/hyprlock
|
# ../../home/system/hyprlock
|
||||||
../../home/system/hyprpanel
|
# ../../home/system/hyprpaper
|
||||||
../../home/system/hyprpaper
|
# ../../home/system/wofi
|
||||||
../../home/system/wofi
|
# ../../home/system/waybar
|
||||||
|
# ../../home/system/dunst
|
||||||
../../home/system/batsignal
|
../../home/system/batsignal
|
||||||
../../home/system/zathura
|
../../home/system/zathura
|
||||||
../../home/system/mime
|
../../home/system/mime
|
||||||
../../home/system/udiskie
|
../../home/system/udiskie
|
||||||
../../home/system/clipman
|
../../home/system/clipman
|
||||||
|
../../home/system/niri
|
||||||
|
|
||||||
# ./secrets # CHANGEME: You should probably remove this line, this is where I store my secrets
|
# ./secrets # CHANGEME: You should probably remove this line, this is where I store my secrets
|
||||||
];
|
];
|
||||||
|
|
||||||
stylix = {
|
stylix = {
|
||||||
targets.gtk.flatpakSupport.enable = false;
|
targets.gtk.flatpakSupport.enable = false;
|
||||||
|
targets.hyprlock.enable = false;
|
||||||
|
targets.waybar.addCss = false;
|
||||||
iconTheme = {
|
iconTheme = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.tela-icon-theme;
|
package = pkgs.qogir-icon-theme;
|
||||||
dark = "Tela-dark";
|
dark = "Qogir-Dark";
|
||||||
light = "Tela-light";
|
light = "Qogir";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
nixpkgs.config.allowUnfreePredicate = pkg:
|
||||||
|
builtins.elem (lib.getName pkg) ["intelephense" "spotify"];
|
||||||
home = {
|
home = {
|
||||||
inherit (config.var) username;
|
inherit (config.var) username;
|
||||||
homeDirectory = "/home/" + config.var.username;
|
homeDirectory = "/home/" + config.var.username;
|
||||||
|
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
# Apps
|
# Apps
|
||||||
#discord # Chat
|
|
||||||
# bitwarden # Password manager
|
|
||||||
mpv # Video player
|
mpv # Video player
|
||||||
pcmanfm
|
# pcmanfm
|
||||||
xarchiver
|
# xarchiver
|
||||||
#blanket # White-noise app
|
|
||||||
|
|
||||||
# Dev
|
# Dev
|
||||||
go
|
# go
|
||||||
nodejs
|
nodejs
|
||||||
(python3.withPackages (ps:
|
(python3.withPackages (ps:
|
||||||
with ps; [
|
with ps; [
|
||||||
@ -79,7 +87,8 @@
|
|||||||
sha256 = "sha256-caff7K4++eQJE/7kbKJb8DgI6aWJdiHBbdV1+46aFMs=";
|
sha256 = "sha256-caff7K4++eQJE/7kbKJb8DgI6aWJdiHBbdV1+46aFMs=";
|
||||||
};
|
};
|
||||||
doCheck = false;
|
doCheck = false;
|
||||||
buildInputs = [ pip ];
|
pyproject = true;
|
||||||
|
propagatedBuildInputs = [pip setuptools pyyaml mypy];
|
||||||
})
|
})
|
||||||
]))
|
]))
|
||||||
jq
|
jq
|
||||||
@ -87,13 +96,13 @@
|
|||||||
just
|
just
|
||||||
ddev
|
ddev
|
||||||
mkcert
|
mkcert
|
||||||
|
devenv
|
||||||
|
|
||||||
# Utils
|
# Utils
|
||||||
zip
|
zip
|
||||||
xz
|
xz
|
||||||
unzip
|
unzip
|
||||||
p7zip
|
p7zip
|
||||||
unrar
|
|
||||||
optipng
|
optipng
|
||||||
pfetch
|
pfetch
|
||||||
pandoc
|
pandoc
|
||||||
@ -111,12 +120,12 @@
|
|||||||
inetutils
|
inetutils
|
||||||
gdu
|
gdu
|
||||||
enchant
|
enchant
|
||||||
|
inxi
|
||||||
|
|
||||||
# Just cool
|
# Just cool
|
||||||
peaclock
|
# peaclock
|
||||||
cbonsai
|
# cbonsai
|
||||||
pipes
|
# cmatrix
|
||||||
cmatrix
|
|
||||||
# cava
|
# cava
|
||||||
|
|
||||||
# Backup
|
# Backup
|
||||||
@ -127,14 +136,24 @@
|
|||||||
gimp
|
gimp
|
||||||
sqlitebrowser
|
sqlitebrowser
|
||||||
sqlite
|
sqlite
|
||||||
emacs29-pgtk
|
emacs-pgtk
|
||||||
|
php
|
||||||
|
phpPackages.composer
|
||||||
|
aspell
|
||||||
|
aspellDicts.id
|
||||||
|
aspellDicts.en
|
||||||
|
html-tidy
|
||||||
|
stylelint
|
||||||
|
jsbeautifier
|
||||||
zotero_7
|
zotero_7
|
||||||
chromium
|
chromium
|
||||||
# inputs.zen-browser.packages."${pkgs.system}"
|
remmina
|
||||||
|
exercism
|
||||||
|
elixir
|
||||||
];
|
];
|
||||||
|
|
||||||
# Import my profile picture, used by the hyprpanel dashboard
|
# Import my profile picture, used by the hyprpanel dashboard
|
||||||
file.".profile_picture.png" = { source = ./profile_picture.png; };
|
file.".profile_picture.png" = {source = ./profile_picture.png;};
|
||||||
|
|
||||||
# Don't touch this
|
# Don't touch this
|
||||||
stateVersion = "24.05";
|
stateVersion = "24.05";
|
||||||
|
|||||||
@ -1,14 +1,13 @@
|
|||||||
{ config, ... }: {
|
{config, ...}: {
|
||||||
imports = [ ../../nixos/variables-config.nix ];
|
imports = [../../nixos/variables-config.nix];
|
||||||
|
|
||||||
config.var = {
|
config.var = {
|
||||||
hostname = "dark";
|
hostname = "dark";
|
||||||
username = "dim";
|
username = "dim";
|
||||||
|
fullname = "Dhimas Widrayato";
|
||||||
uid = 1000;
|
uid = 1000;
|
||||||
hashedPassword =
|
hashedPassword = "$y$j9T$OqKMt8etf8DgTrZhN9jzy/$biMoM3P.WPZMpk0DAK.QhaHjGOL23pEgxlSvfu9LEPD";
|
||||||
"$y$j9T$OqKMt8etf8DgTrZhN9jzy/$biMoM3P.WPZMpk0DAK.QhaHjGOL23pEgxlSvfu9LEPD";
|
configDirectory = "/home/" + config.var.username + "/.config/nixos"; # The path of the nixos configuration directory
|
||||||
configDirectory = "/home/" + config.var.username
|
|
||||||
+ "/.config/nixos"; # The path of the nixos configuration directory
|
|
||||||
|
|
||||||
keyboardLayout = "us";
|
keyboardLayout = "us";
|
||||||
|
|
||||||
@ -29,8 +28,7 @@
|
|||||||
|
|
||||||
autoUpgrade = false;
|
autoUpgrade = false;
|
||||||
autoGarbageCollector = false;
|
autoGarbageCollector = false;
|
||||||
cpuTempSensor =
|
cpuTempSensor = "/sys/devices/platform/thinkpad_hwmon/hwmon/hwmon5/temp1_input";
|
||||||
"/sys/devices/platform/thinkpad_hwmon/hwmon/hwmon5/temp1_input";
|
|
||||||
|
|
||||||
theme = import ../../themes/var/nixy.nix;
|
theme = import ../../themes/var/nixy.nix;
|
||||||
};
|
};
|
||||||
|
|||||||
@ -1,6 +1,8 @@
|
|||||||
{
|
{ pkgs, ... }: {
|
||||||
|
environment.systemPackages = with pkgs; [ pavucontrol ];
|
||||||
|
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
hardware.pulseaudio.enable = false;
|
services.pulseaudio.enable = false;
|
||||||
|
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@ -16,5 +18,13 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
extraConfig.pipewire = {
|
||||||
|
"92-clock-rate" = {
|
||||||
|
"context.properties" = {
|
||||||
|
"default.clock.quantum" = 2048;
|
||||||
|
"default.clock.force-quantum" = 2048;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -14,15 +14,13 @@
|
|||||||
dejavu_fonts
|
dejavu_fonts
|
||||||
noto-fonts
|
noto-fonts
|
||||||
noto-fonts-cjk-sans
|
noto-fonts-cjk-sans
|
||||||
noto-fonts-emoji
|
noto-fonts-color-emoji
|
||||||
victor-mono
|
victor-mono
|
||||||
# (nerdfonts.override { fonts = [ "FiraCode" "Meslo" "VictorMono" ]; })
|
|
||||||
nerd-fonts.victor-mono
|
nerd-fonts.victor-mono
|
||||||
nerd-fonts.fira-code
|
nerd-fonts.fira-code
|
||||||
nerd-fonts.meslo-lg
|
nerd-fonts.meslo-lg
|
||||||
openmoji-color
|
openmoji-color
|
||||||
twemoji-color-font
|
twemoji-color-font
|
||||||
inputs.apple-fonts.packages.${pkgs.system}.sf-pro-nerd
|
|
||||||
];
|
];
|
||||||
|
|
||||||
enableDefaultPackages = false;
|
enableDefaultPackages = false;
|
||||||
@ -30,8 +28,8 @@
|
|||||||
fontconfig = {
|
fontconfig = {
|
||||||
defaultFonts = {
|
defaultFonts = {
|
||||||
monospace = [ "FiraCode Nerd Font Mono" "Noto Color Emoji" ];
|
monospace = [ "FiraCode Nerd Font Mono" "Noto Color Emoji" ];
|
||||||
sansSerif = [ "SFProDisplay Nerd Font" "Noto Color Emoji" ];
|
sansSerif = [ "Inter Display" "Noto Color Emoji" ];
|
||||||
serif = [ "SFProDisplay Nerd Font" "Noto Color Emoji" ];
|
serif = [ "Noto Serif" "Noto Color Emoji" ];
|
||||||
emoji = [ "Noto Color Emoji" ];
|
emoji = [ "Noto Color Emoji" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{ inputs, ... }: {
|
{ inputs, ... }: {
|
||||||
home-manager = {
|
home-manager = {
|
||||||
useGlobalPkgs = true;
|
useGlobalPkgs = false;
|
||||||
useUserPackages = true;
|
useUserPackages = true;
|
||||||
backupFileExtension = "hm-backup";
|
backupFileExtension = "hm-backup";
|
||||||
extraSpecialArgs = { inherit inputs; };
|
extraSpecialArgs = { inherit inputs; };
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
{
|
{
|
||||||
networking.networkmanager.enable = true;
|
networking.networkmanager.enable = true;
|
||||||
systemd.services.NetworkManager-wait-online.enable = false;
|
systemd.services.NetworkManager-wait-online.enable = false;
|
||||||
|
networking.firewall.checkReversePath = "loose";
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,6 +1,13 @@
|
|||||||
{ config, inputs, ... }:
|
{ config, inputs, ... }:
|
||||||
let autoGarbageCollector = config.var.autoGarbageCollector;
|
let autoGarbageCollector = config.var.autoGarbageCollector;
|
||||||
in {
|
in {
|
||||||
|
security.sudo.extraRules = [{
|
||||||
|
users = [ config.var.username ];
|
||||||
|
commands = [{
|
||||||
|
command = "/run/current-system/sw/bin/nixos-rebuild";
|
||||||
|
options = [ "NOPASSWD" ];
|
||||||
|
}];
|
||||||
|
}];
|
||||||
nixpkgs.config = {
|
nixpkgs.config = {
|
||||||
allowUnfree = true;
|
allowUnfree = true;
|
||||||
allowBroken = true;
|
allowBroken = true;
|
||||||
@ -8,15 +15,24 @@ in {
|
|||||||
nix = {
|
nix = {
|
||||||
nixPath = [ "nixpkgs=${inputs.nixpkgs}" ];
|
nixPath = [ "nixpkgs=${inputs.nixpkgs}" ];
|
||||||
channel.enable = false;
|
channel.enable = false;
|
||||||
|
|
||||||
extraOptions = ''
|
extraOptions = ''
|
||||||
warn-dirty = false
|
warn-dirty = false
|
||||||
'';
|
'';
|
||||||
settings = {
|
settings = {
|
||||||
auto-optimise-store = true;
|
auto-optimise-store = true;
|
||||||
experimental-features = [ "nix-command" "flakes" ];
|
experimental-features = [ "nix-command" "flakes" ];
|
||||||
substituters = [ "https://hyprland.cachix.org" ];
|
substituters = [
|
||||||
|
"https://cache.nixos.org/?priority=10"
|
||||||
|
"https://nix-community.cachix.org"
|
||||||
|
"https://hyprland.cachix.org"
|
||||||
|
"https://devenv.cachix.org"
|
||||||
|
];
|
||||||
trusted-public-keys = [
|
trusted-public-keys = [
|
||||||
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
||||||
|
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||||
|
"devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw="
|
||||||
|
"nixpkgs-python.cachix.org-1:hxjI7pFxTyuTHn2NkvWCrAUcNZLNS3ZAvfYNuYifcEU="
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
gc = {
|
gc = {
|
||||||
|
|||||||
@ -25,4 +25,9 @@
|
|||||||
consoleLogLevel = 0;
|
consoleLogLevel = 0;
|
||||||
initrd.verbose = false;
|
initrd.verbose = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.kmscon = {
|
||||||
|
enable = true;
|
||||||
|
hwRender = true;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
28
nixos/tlp.nix
Normal file
28
nixos/tlp.nix
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
{
|
||||||
|
services.tlp = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
CPU_SCALING_GOVERNOR_ON_AC = "performance";
|
||||||
|
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
|
||||||
|
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
|
||||||
|
|
||||||
|
CPU_MIN_PERF_ON_AC = 0;
|
||||||
|
CPU_MAX_PERF_ON_AC = 100;
|
||||||
|
CPU_MIN_PERF_ON_BAT = 0;
|
||||||
|
CPU_MAX_PERF_ON_BAT = 60;
|
||||||
|
|
||||||
|
# Optional helps save long term battery health
|
||||||
|
START_CHARGE_THRESH_BAT0 = 40; # 40 and bellow it starts to charge
|
||||||
|
STOP_CHARGE_THRESH_BAT0 = 80; # 80 and above it stops charging
|
||||||
|
START_CHARGE_THRESH_BAT1 = 40; # 40 and bellow it starts to charge
|
||||||
|
STOP_CHARGE_THRESH_BAT1 = 80; # 80 and above it stops charging
|
||||||
|
RESTORE_THRESHOLD_ON_BAT = 1;
|
||||||
|
|
||||||
|
# Networking powersave
|
||||||
|
DEVICES_TO_DISABLE_ON_LAN_CONNECT = "wifi";
|
||||||
|
DEVICES_TO_ENABLE_ON_UNDOCK = "wifi";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@ -1,17 +1,16 @@
|
|||||||
{ pkgs, ... }: {
|
{pkgs, ...}: {
|
||||||
services.greetd = {
|
services.greetd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
default_session = {
|
default_session = {
|
||||||
command =
|
command = "${pkgs.tuigreet}/bin/tuigreet --remember --asterisks --container-padding 2 --time --time-format '%I:%M %p | %a • %h | %F' --cmd niri-session";
|
||||||
"${pkgs.greetd.tuigreet}/bin/tuigreet --remember --asterisks --container-padding 2 --time --time-format '%I:%M %p | %a • %h | %F' --cmd Hyprland";
|
|
||||||
user = "greeter";
|
user = "greeter";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
security.pam.services.greetd.enableGnomeKeyring = true;
|
security.pam.services.greetd.enableGnomeKeyring = true;
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [ greetd.tuigreet ];
|
environment.systemPackages = with pkgs; [tuigreet];
|
||||||
|
|
||||||
# this is a life saver.
|
# this is a life saver.
|
||||||
# literally no documentation about this anywhere.
|
# literally no documentation about this anywhere.
|
||||||
@ -29,6 +28,12 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
# To prevent getting stuck at shutdown
|
# To prevent getting stuck at shutdown
|
||||||
systemd.extraConfig = "DefaultTimeoutStopSec=10s";
|
# systemd.extraConfig = "DefaultTimeoutStopSec=10s";
|
||||||
|
systemd.settings.Manager = {
|
||||||
|
# KExecWatchdogSec = "5min";
|
||||||
|
# RebootWatchdogSec = "10min";
|
||||||
|
# RuntimeWatchdogSec = "30s";
|
||||||
|
# WatchdogDevice = "/dev/watchdog";
|
||||||
|
DefaultTimeoutStopSec = "10s";
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
5
nixos/upower.nix
Normal file
5
nixos/upower.nix
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
services.tlp.enable = false;
|
||||||
|
services.tuned.enable = true;
|
||||||
|
services.upower.enable = true;
|
||||||
|
}
|
||||||
@ -1,18 +1,36 @@
|
|||||||
{ config, pkgs, ... }:
|
{
|
||||||
let
|
config,
|
||||||
|
pkgs,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
username = config.var.username;
|
username = config.var.username;
|
||||||
hashedPassword = config.var.hashedPassword;
|
hashedPassword = config.var.hashedPassword;
|
||||||
userId = config.var.uid;
|
userId = config.var.uid;
|
||||||
in {
|
in {
|
||||||
programs.zsh.enable = true;
|
programs.zsh.enable = true;
|
||||||
|
|
||||||
|
# Thunar plugins and services
|
||||||
|
programs.thunar.plugins = with pkgs.xfce; [
|
||||||
|
thunar-archive-plugin
|
||||||
|
thunar-volman
|
||||||
|
];
|
||||||
|
programs.xfconf.enable = true;
|
||||||
|
services.tumbler.enable = true;
|
||||||
|
|
||||||
|
# hardware.graphics = {
|
||||||
|
# package =
|
||||||
|
# inputs.hyprland.inputs.nixpkgs.legacyPackages.${pkgs.stdenv.hostPlatform.system}.mesa;
|
||||||
|
# };
|
||||||
|
|
||||||
users = {
|
users = {
|
||||||
defaultUserShell = pkgs.zsh;
|
defaultUserShell = pkgs.zsh;
|
||||||
users.${username} = {
|
users.${username} = {
|
||||||
hashedPassword = "${hashedPassword}";
|
hashedPassword = "${hashedPassword}";
|
||||||
uid = userId;
|
uid = userId;
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
description = "${username} account";
|
description = config.var.fullname;
|
||||||
extraGroups = [ "networkmanager" "wheel" "audio" "video" "input" ];
|
extraGroups = ["networkmanager" "wheel" "audio" "video" "input"];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -14,15 +14,18 @@ in {
|
|||||||
EDITOR = "nvim";
|
EDITOR = "nvim";
|
||||||
};
|
};
|
||||||
|
|
||||||
services.libinput.enable = true;
|
|
||||||
programs.dconf.enable = true;
|
programs.dconf.enable = true;
|
||||||
services = {
|
services = {
|
||||||
|
libinput.enable = true;
|
||||||
dbus.enable = true;
|
dbus.enable = true;
|
||||||
gvfs.enable = true;
|
gvfs.enable = true;
|
||||||
upower.enable = true;
|
upower.enable = true;
|
||||||
power-profiles-daemon.enable = true;
|
# power-profiles-daemon.enable = true;
|
||||||
udisks2.enable = true;
|
udisks2.enable = true;
|
||||||
devmon.enable = true;
|
devmon.enable = true;
|
||||||
|
journald.extraConfig = ''
|
||||||
|
SystemMaxUse=1G
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
# Faster rebuilding
|
# Faster rebuilding
|
||||||
@ -59,10 +62,11 @@ in {
|
|||||||
nix-tree
|
nix-tree
|
||||||
stevenblack-blocklist
|
stevenblack-blocklist
|
||||||
wlay
|
wlay
|
||||||
|
ldns
|
||||||
];
|
];
|
||||||
|
|
||||||
services.logind.extraConfig = ''
|
# services.logind.settings.Login = ''
|
||||||
# don’t shutdown when power button is short-pressed
|
# # don’t shutdown when power button is short-pressed
|
||||||
HandlePowerKey=ignore
|
# HandlePowerKey=ignore
|
||||||
'';
|
# '';
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,7 +1,14 @@
|
|||||||
{ pkgs, config, inputs, ... }: {
|
{
|
||||||
virtualisation.docker.enable = true;
|
pkgs,
|
||||||
virtualisation.libvirtd.enable = true;
|
config,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
virtualisation = {
|
||||||
|
docker.enable = true;
|
||||||
|
docker.extraPackages = [pkgs.docker-buildx];
|
||||||
|
libvirtd.enable = true;
|
||||||
|
};
|
||||||
programs.virt-manager.enable = true;
|
programs.virt-manager.enable = true;
|
||||||
environment.systemPackages = with pkgs; [ virtiofsd ];
|
environment.systemPackages = with pkgs; [virtiofsd];
|
||||||
users.users."${config.var.username}".extraGroups = [ "docker" "libvirtd" ];
|
users.users."${config.var.username}".extraGroups = ["docker" "libvirtd"];
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,10 +1,29 @@
|
|||||||
{ pkgs, ... }: {
|
{pkgs, ...}: {
|
||||||
|
# xdg.portal = {
|
||||||
|
# enable = true;
|
||||||
|
# config.common.default = "*";
|
||||||
|
# wlr.enable = true;
|
||||||
|
# xdgOpenUsePortal = true;
|
||||||
|
# extraPortals = [ pkgs.xdg-desktop-portal pkgs.xdg-desktop-portal-gtk ];
|
||||||
|
# };
|
||||||
xdg.portal = {
|
xdg.portal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
config.common.default = "*";
|
|
||||||
wlr.enable = true;
|
|
||||||
xdgOpenUsePortal = true;
|
xdgOpenUsePortal = true;
|
||||||
extraPortals =
|
wlr.enable = true;
|
||||||
[ pkgs.xdg-desktop-portal-hyprland pkgs.xdg-desktop-portal-gtk ];
|
config = {
|
||||||
|
common = {
|
||||||
|
default = [
|
||||||
|
"gtk"
|
||||||
|
"gnome"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
niri = {
|
||||||
|
default = [
|
||||||
|
"gtk"
|
||||||
|
"gnome"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
xdg.portal.extraPortals = [pkgs.xdg-desktop-portal-wlr pkgs.xdg-desktop-portal-gtk];
|
||||||
}
|
}
|
||||||
|
|||||||
@ -44,27 +44,31 @@
|
|||||||
name = "JetBrains Mono Nerd Font";
|
name = "JetBrains Mono Nerd Font";
|
||||||
};
|
};
|
||||||
sansSerif = {
|
sansSerif = {
|
||||||
package = inputs.apple-fonts.packages.${pkgs.system}.sf-pro-nerd;
|
package = pkgs.inter;
|
||||||
name = "SFProDisplay Nerd Font";
|
name = "Inter Display";
|
||||||
};
|
};
|
||||||
serif = {
|
serif = {
|
||||||
package = inputs.apple-fonts.packages.${pkgs.system}.sf-pro-nerd;
|
package = pkgs.noto-fonts;
|
||||||
name = "SFProDisplay Nerd Font";
|
name = "Noto Serif";
|
||||||
};
|
};
|
||||||
emoji = {
|
emoji = {
|
||||||
package = pkgs.noto-fonts-emoji;
|
package = pkgs.noto-fonts-color-emoji;
|
||||||
name = "Noto Color Emoji";
|
name = "Noto Color Emoji";
|
||||||
};
|
};
|
||||||
sizes = {
|
sizes = {
|
||||||
applications = 11;
|
applications = 11;
|
||||||
desktop = 12;
|
desktop = 10;
|
||||||
popups = 12;
|
popups = 10;
|
||||||
terminal = 11;
|
terminal = 10;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
polarity = "dark";
|
polarity = "dark";
|
||||||
image = inputs.nixy-wallpapers + "/wallpapers/dark.png";
|
image = pkgs.fetchurl {
|
||||||
|
url =
|
||||||
|
"https://www.pixelstalk.net/wp-content/uploads/images3/Cute_Owl_HD_Background.jpg";
|
||||||
|
hash = "sha256-pqeVSfJgR9e5mCln6c+WDojAXDRujUSl2n+TS3agWdw=";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -11,8 +11,8 @@
|
|||||||
|
|
||||||
bar = {
|
bar = {
|
||||||
position = "top"; # "top" | "bottom"
|
position = "top"; # "top" | "bottom"
|
||||||
transparent = true;
|
transparent = false;
|
||||||
transparentButtons = false;
|
transparentButtons = true;
|
||||||
floating = true;
|
floating = false;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user