BREAKING-CHANGE: changed nixpkgs to stable 24.11 + structure change + fmt

This commit is contained in:
2024-12-31 16:18:38 +01:00
parent 8d0f158b98
commit e0d676b63d
81 changed files with 1250 additions and 1143 deletions

View File

@@ -0,0 +1,11 @@
{
programs.btop = {
enable = true;
settings = {
update_ms = 1000;
rounded_corners = false;
proc_sorting = "memory";
shown_boxes = "proc cpu ";
};
};
}

View File

@@ -0,0 +1,120 @@
{
programs.fastfetch = {
enable = true;
settings = {
"$schema" = "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json";
logo = {
type = "kitty";
height = 20;
padding = {
top = 0;
right = 2;
};
};
display = {
separator = " ";
};
modules = [
"break"
{
type = "os";
key = "OS ";
keyColor = "31";
format = "{2} {8}";
}
{
type = "kernel";
key = " ";
keyColor = "31";
format = "{2}";
}
{
type = "packages";
format = "{} (nixpkgs)";
key = " 󰏖 ";
keyColor = "31";
}
{
type = "shell";
key = " ";
keyColor = "31";
}
"break"
{
type = "wm";
key = "WM ";
keyColor = "32";
format = "{2}";
}
{
type = "wmtheme";
key = " 󰉼 ";
keyColor = "32";
}
{
type = "icons";
key = " 󰀻 ";
keyColor = "32";
}
{
type = "cursor";
key = " ";
keyColor = "32";
}
{
type = "terminal";
key = " ";
keyColor = "32";
}
{
type = "terminalfont";
key = " ";
keyColor = "32";
}
"break"
{
type = "host";
format = "{5} {1}";
key = "PC ";
keyColor = "33";
}
{
type = "cpu";
format = "AMD Ryzen 7 8845HS";
key = " ";
keyColor = "33";
}
{
type = "gpu";
format = "AMD Radeon 780M";
key = " 󰢮 ";
keyColor = "33";
}
{
type = "memory";
key = " ";
keyColor = "33";
}
{
type = "swap";
key = " 󰓡 ";
keyColor = "33";
}
{
type = "disk";
key = " 󰋊 ";
keyColor = "33";
}
{
type = "monitor";
key = " ";
keyColor = "33";
format = "{2}x{3} px";
}
];
};
};
}

View File

@@ -0,0 +1,41 @@
{
programs.foot = {
enable = true;
settings = {
main = {
pad = "5x0";
dpi-aware = "yes";
};
mouse = {
hide-when-typing = "yes";
};
tweak = {
font-monospace-warn = "no";
};
colors = {
foreground = "cdd6f4";
background = "1e1e2e";
regular0 = "1e1e2e"; # black
regular1 = "f38ba8"; # red
regular2 = "a6e3a1"; # green
regular3 = "f9e2af"; # yellow
regular4 = "89b4fa"; # blue
regular5 = "cba6f7"; # magenta
regular6 = "94e2d5"; # cyan
regular7 = "cdd6f4"; # white
bright0 = "45475a"; # bright black
bright1 = "f38ba8"; # bright red
bright2 = "a6e3a1"; # bright green
bright3 = "f9e2af"; # bright yellow
bright4 = "89b4fa"; # bright blue
bright5 = "cba6f7"; # bright magenta
bright6 = "94e2d5"; # bright cyan
bright7 = "b4befe"; # bright white
};
};
};
}

View File

@@ -0,0 +1,26 @@
{
programs.freetube = {
enable = true;
settings = {
allowDashAv1Formats = true;
defaultQuality = "1080";
useSponsorBlock = true;
backendFallback = true;
autoplayPlaylists = false;
autoplayVideos = false;
expandSideBar = false;
hideLabelsSideBar = true;
checkForBlogPosts = false;
checkForUpdates = false;
mainColor = "CatppuccinMochaMauve";
secColor = "CatppuccinMochaPink";
baseTheme = "catppuccinMocha";
barColor = false;
};
};
}

View File

@@ -0,0 +1,26 @@
{
programs.git = {
enable = true;
userName = "Michał Czyż";
userEmail = "mike@c2yz.com";
signing = {
key = "9745B9E27E2B1ABB";
signByDefault = true;
};
extraConfig = {
init.defaultBranch = "main";
push.autoSetupRemote = true;
commit.gpgsign = true;
push.enabled = true;
column.ui = "auto";
branch.sort = "-committerdate";
pull.rebase = "false";
rerere.enabled = true;
tag.gpgSign = true;
push.gpgsign = "if-asked";
};
};
}

View File

@@ -0,0 +1,16 @@
{
services.gpg-agent = {
enable = true;
defaultCacheTtl = 1800;
# enableSshSupport = true;
};
# programs.ssh = {
# startAgent = true;
# # agentTimeout = "1h";
# extraConfig = ''
# AddKeysToAgent yes
# IdentityFile ~/.ssh/senpai_ed25519;
# '';
# };
}

View File

@@ -0,0 +1,173 @@
{pkgs, ...}: {
programs.helix = {
enable = true;
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# languages Configuration
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
languages = {
language = [
{
name = "nix";
auto-format = true;
language-servers = ["nixd" "nil"];
formatter = {
command = "${pkgs.nixpkgs-fmt}/bin/nixpkgs-fmt";
# command = "${pkgs.nixfmt-rfc-style}/bin/nixfmt";
# command = "${pkgs.alejandra}/bin/alejandra";
};
}
{
name = "bash";
auto-format = true;
language-servers = ["bash-language-server"];
formatter = {
command = "${pkgs.shfmt}/bin/shfmt";
args = ["-i" "2" "-ci"];
};
}
{
name = "python";
auto-format = true;
language-servers = ["pyright"];
formatter = {
command = "${pkgs.black}/bin/black";
args = ["--quiet" "-"];
};
}
{
name = "rust";
auto-format = false;
file-types = ["rs"];
language-servers = ["rust-analyzer"];
formatter = {command = "${pkgs.rustfmt}/bin/rustfmt";};
}
{
name = "zig";
auto-format = true;
language-servers = ["zsl"];
formatter = {command = "${pkgs.zig}/bin/zig";};
}
{
name = "html";
auto-format = true;
language-servers = ["vscode-langservers-extracted"];
}
{
name = "javascript";
auto-format = true;
language-servers = ["typescript-language-server"];
}
];
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Language Server Protocol Configuration
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
language-servers = {
nil = {command = "${pkgs.nixd}/bin/nixd";};
rust-analyzer = {
config = {
check = {command = "${pkgs.clippy}/bin/cargo-clippy";};
# cargo.features = "all";
checkOnSave.command = "${pkgs.clippy}/bin/cargo-clippy";
completion.autoimport.enable = true;
};
};
typescript-language-server = {
command = "${pkgs.nodePackages_latest.typescript-language-server}/bin/typescript-language-server";
args = ["--stdio"];
};
};
};
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Needed Packages
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
extraPackages = with pkgs; [
# DEBUG
lldb_18
# lldb-vscode :
# c
# cpp
# = < NIX > =
# = Language Server Protocol =
nil
nixd
# = DAP =
# = Formatter =
# nixfmt
nixfmt-rfc-style
# alejandra
# = < Bash > =
# = Language Server Protocol =
nodePackages.bash-language-server
# = DAP =
# = Formatter =
shfmt
# = < Python > =
# = Language Server Protocol =
pyright
# = DAP =
# = Formatter =
black
# = < Rust > =
# = Language Server Protocol =
rust-analyzer
# = DAP =
lldb
# = Formatter =
# rust-fmt
clippy # Good place ?
# = < lua > =
# = Language Server Protocol =
lua-language-server
# = DAP =
# = Formatter =
# = < Zig > =
# = Language Server Protocol =
zls
# = DAP =
# lldb (commented because already called)
# = Formatter =
zig
# = < HTML > =
# = Language Server Protocol =
# vscode-html-language-server
vscode-langservers-extracted
# = DAP =
# = Formatter =
# = < CSS > =
# = Language Server Protocol =
nodePackages_latest.typescript-language-server
# = DAP =
# = Formatter =
# = Language Server Protocol =
docker-compose-language-service
dockerfile-language-server-nodejs
yaml-language-server
ansible-language-server
];
};
}

View File

@@ -0,0 +1,19 @@
{lib, ...}: {
programs.kitty = {
enable = true;
font = {
name = lib.mkForce "FiraCode Nerd Font";
size = 12;
};
themeFile = "rose-pine";
settings = {
confirm_os_window_close = 0;
window_padding_width = 10;
scrollback_lines = 10000;
enable_audio_bell = false;
mouse_hide_wait = 60;
};
};
}

View File

@@ -0,0 +1,10 @@
{
programs.librewolf = {
enable = true;
settings = {
"browser.sessionstore.resume_from_crash" = false;
"DisableSystemAddonUpdate" = true;
"DisableSetDesktopBackground" = true;
};
};
}

View File

@@ -0,0 +1,17 @@
{pkgs, ...}: {
home.packages = with pkgs; [
neovide
];
home.file = {
".config/neovide/config.toml" = {
text = ''
vsync = true
[font]
normal = ["FiraCode Nerd Font"]
size = 14
'';
};
};
}

View File

@@ -0,0 +1,20 @@
{
inputs,
pkgs,
...
}: {
# programs.neovim = {
# enable = true;
# # package = pkgs.neovim;
# # viAlias = true;
# # vimAlias = true;
# # vimdiffAlias = true;
# # defaultEditor = true;
# };
home.packages = with pkgs; [
neovim
];
}

View File

@@ -0,0 +1,90 @@
{
inputs,
pkgs,
...
}: {
programs.direnv.enable = true;
programs.direnv.nix-direnv.enable = true;
home.packages = with pkgs; [
# > graphics < #
tuxpaint
# krita
gimp
# > terminal < #
kitty
kitty-themes
# > tools < #
git
wget
eza
yt-dlp
ffmpeg
texlive.combined.scheme-full
fastfetch
zoxide
btop
htop
killall
woeusb
pavucontrol
steam-run
unzip
openvpn
wol
direnv
p7zip
hoppscotch
networkmanagerapplet
protonvpn-cli_2
python3
pwvucontrol
# > media < #
spotify
vlc
mpv
obs-studio
okular
# > desktop < #
# firefox
whatsapp-for-linux
telegram-desktop
google-chrome
chromium
evolution
obsidian
foliate
helio-workstation
# vesktop
equibop
inputs.zen-browser.packages."${system}".default
# > gaming < #
prismlauncher
classicube
# > development < #
android-studio
seahorse
iwgtk
imv
feh
zed-editor
zint
zip
unzip
pavucontrol
libreoffice
qalculate-gtk
file-roller
vim
# nixfmt-rfc-style
nemo
nixd
glfw-wayland-minecraft
];
}

View File

@@ -0,0 +1,61 @@
{
programs.qutebrowser = {
enable = false;
searchEngines = {
"DEFAULT" = "https://priv.au/search?q={}";
"d" = "https://duckduckgo.com/?q={}&ia=web";
"n" = "https://mynixos.com/search?q={}";
"nixo" = "https://search.nixos.org/options?channel=unstable&query={}";
"nixp" = "https://search.nixos.org/packages?channel=unstable&query={}";
"gt" = "https://github.com/search?q={}&type=repositories";
};
quickmarks = {
nwiki = "https://wiki.nixos.org/wiki/NixOS_Wiki";
nflake = "https://nixos-and-flakes.thiscute.world/introduction/";
nixy = "https://github.com/anotherhadi/nixy?tab=readme-ov-file";
nca = "https://github.com/nix-community/awesome-nix";
nc = "https://github.com/nix-community";
yb = "https://youatb.unibocconi.it/";
bk = "https://blackboard.unibocconi.it/ultra/stream";
pz = "https://piazza.com/class/m0nl57y6g4z1wh";
om = "https://outlook.office.com/mail/";
pm = "https://mail.proton.me/u/0/inbox";
tm = "https://app.tuta.com/mail/";
mai = "https://chat.mistral.ai/chat";
cai = "https://claude.ai/new";
chess = "https://www.chess.com/home";
lichess = "https://lichess.org/";
git = "https://github.com/dashboard";
berg = "https://codeberg.org/PyNEL/Dotfiles";
box = "http://192.168.1.254/#";
};
settings = {
content = {
autoplay = false;
javascript.clipboard = "access";
prefers_reduced_motion = true;
cookies.accept = "no-3rdparty";
pdfjs = true;
};
qt = {
highdpi = true;
};
scrolling = {
bar = "never";
smooth = true;
};
};
};
}

View File

@@ -0,0 +1,72 @@
{pkgs, ...}: let
cli = import ../configs/aliases.nix;
in {
programs = {
zoxide.enable = true;
eza = {
enable = true;
icons = "auto";
extraOptions = [
"--group-directories-first"
"--header"
"--icons"
];
};
starship = {
enable = true;
settings = {
add_newline = true;
};
};
zellij = {
enable = true;
settings = {
ui = {
pane_frames.hide_session_name = true;
pane_borderless = true;
};
};
};
bash = {
enable = true;
enableCompletion = true;
shellAliases = cli.myAliases;
};
zsh = {
enable = true;
enableCompletion = true;
history.size = 10000000;
shellAliases = cli.myAliases;
# plugins = [
# {
# name = "powerlevel10k";
# src = pkgs.zsh-powerlevel10k;
# file = "share/zsh-powerlevel10k/powerlevel10k.zsh-theme";
# }
# ];
autosuggestion = {
enable = true;
};
syntaxHighlighting = {
enable = true;
};
historySubstringSearch = {
enable = true;
};
initExtra = ''
eval "$(zoxide init --cmd cd zsh)"
'';
};
};
}

View File

@@ -0,0 +1,18 @@
{
inputs,
pkgs,
...
}: {
imports = [inputs.spicetify-nix.homeManagerModules.default];
programs.spicetify = {
enable = true;
#theme = spicePkgs.themes.catppuccin;
#colorScheme = "mocha";
enabledExtensions = with inputs.spicetify-nix.legacyPackages.${pkgs.system}.extensions; [
fullAppDisplay
shuffle
hidePodcasts
];
};
}

View File

@@ -0,0 +1,49 @@
{pkgs, ...}: {
programs.tmux = {
enable = true;
mouse = true;
prefix = "C-Space";
keyMode = "vi";
terminal = "screen-256color";
baseIndex = 1;
plugins = with pkgs.tmuxPlugins; [
sensible
vim-tmux-navigator
rose-pine
yank
];
extraConfig = ''
# history limit
set -g history-limit 5000
# increase repeat time
set -g repeat-time 1000
# decrese command delay
set -sg escape-time 1
# faster key repetition
set -s escape-time 0
setw -g aggressive-resize on
# reload tmux while using tmux
bind r source-file ~/.config/tmux/tmux.conf \; display "Reloaded!"
# Shift Alt vim keys to switch windows
bind -n M-H previous-window
bind -n M-L next-window
# Vim like yank
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
# Open panes in current directory
bind '"' split-window -v -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
'';
};
}

View File

@@ -0,0 +1,74 @@
{pkgs, ...}: {
programs.vscode = {
enable = true;
package = pkgs.vscode.fhsWithPackages (
ps:
with ps; [
rustup
zlib
openssl.dev
pkg-config
# nixfmt-rfc-style
python3
]
);
extensions = with pkgs.vscode-extensions; [
ms-python.python
ms-python.debugpy
jnoortheen.nix-ide
mkhl.direnv
arrterian.nix-env-selector
mvllow.rose-pine
github.copilot
# github.copilot-chat
ms-vsliveshare.vsliveshare
rust-lang.rust-analyzer
];
userSettings = {
"editor.fontSize" = 16;
"editor.fontFamily" = "FiraCode Nerd Font";
"explorer.confirmDelete" = false;
"disable-hardware-acceleration" = true;
"explorer.confirmDragAndDrop" = true;
"git.openRepositoryInParentFolders" = "never";
"[python]" = {
"editor.defaultFormatter" = "ms-python.black-formatter";
"editor.formatOnSave" = true;
};
"nix.enableLanguageServer" = true;
"nix.serverPath" = "${pkgs.nixd}/bin/nixd";
"nix.serverSettings" = {
"nixd" = {
"formatting" = {
"command" = ["${pkgs.nixpkgs-fmt}/bin/nixpkgs-fmt"];
};
"nixpkgs" = {
"expr" = "import <nixpkgs> { }";
"options" = {
"nixos" = {
"expr" = ''(builtins.getFlake "/home/mike/.files").nixosConfigurations.zion.options'';
};
};
};
};
};
"editor.formatOnSave" = true;
"editor.fontLigatures" = true;
"editor.formatOnPaste" = true;
"editor.minimap.enabled" = false;
# "symbols.hidesExplorerArrows" = false;
"workbench.iconTheme" = "rose-pine-icons";
"workbench.colorTheme" = "Rosé Pine";
"workbench.preferredDarkColorTheme" = "Rosé Pine";
"workbench.preferredHighContrastColorTheme" = "Rosé Pine";
};
};
}

View File

@@ -0,0 +1,12 @@
{
programs.yazi = {
enable = true;
settings = {
manager = {
sort_by = "alphabetical";
show_hidden = true;
show_symlink = true;
};
};
};
}

View File

@@ -0,0 +1,14 @@
# Zathura is a PDF viewer
{
programs.zathura = {
enable = true;
options = {
guioptions = "v";
adjust-open = "width";
statusbar-basename = true;
render-loading = false;
scroll-step = 120;
};
};
}