From f6e5bf6e2f3fa5226a0084214121740e1f9de165 Mon Sep 17 00:00:00 2001 From: Pierre MARTIN Date: Tue, 13 Oct 2026 01:27:02 +0200 Subject: [PATCH] feat: reprise de choix d'Omarchy (outils CLI, git, polices) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - git : rerere, tri des branches/tags, commit.verbose, column.ui, diff.mnemonicPrefix - CLI : eza (alias ls/ll/lt), fd, lazygit, lazydocker, alias ff (fzf + aperçu bat), lzg/lzd - tmux : config de base (vi, souris, index 1, splits dans le cwd) - système : polices JetBrains Mono Nerd Font, Noto, emoji et CJK Non testé : pas de Nix sur la machine où ces changements ont été écrits. Co-Authored-By: Claude Opus 5.5 --- home.nix | 26 ++++++++++++++++++++++++++ nixos/configuration.nix | 8 ++++++++ packages.nix | 1 + programs/git.nix | 11 +++++++++++ programs/zsh.nix | 3 +++ 5 files changed, 49 insertions(+) diff --git a/home.nix b/home.nix index 6b273ca..ca35ed1 100644 --- a/home.nix +++ b/home.nix @@ -60,6 +60,32 @@ programs.btop.enable = true; programs.vim.enable = true; + + # Outils CLI repris d'Omarchy - https://github.com/basecamp/omarchy + programs.eza = { + enable = true; # alias ls, ll, la, lt… + enableZshIntegration = true; + git = true; + icons = "auto"; + }; + programs.fd.enable = true; + programs.lazygit.enable = true; + programs.tmux = { + enable = true; + keyMode = "vi"; + mouse = true; + baseIndex = 1; + escapeTime = 0; + historyLimit = 50000; + extraConfig = '' + # Nouveaux panneaux et fenêtres dans le répertoire courant + bind '"' split-window -v -c "#{pane_current_path}" + bind % split-window -h -c "#{pane_current_path}" + bind c new-window -c "#{pane_current_path}" + set -g renumber-windows on + ''; + }; + programs.vscode = { enable = true; package = pkgs.vscode.fhs; diff --git a/nixos/configuration.nix b/nixos/configuration.nix index 5d50be2..191c5d4 100644 --- a/nixos/configuration.nix +++ b/nixos/configuration.nix @@ -125,6 +125,14 @@ ]; virtualisation.docker.enable = true; + # Polices reprises d'Omarchy : Nerd Font pour les icônes (eza, starship) + emoji et CJK + fonts.packages = with pkgs; [ + nerd-fonts.jetbrains-mono + noto-fonts + noto-fonts-cjk-sans + noto-fonts-color-emoji + ]; + # Some programs need SUID wrappers, can be configured further or are # started in user sessions. # programs.mtr.enable = true; diff --git a/packages.nix b/packages.nix index b57a5a2..b57231b 100644 --- a/packages.nix +++ b/packages.nix @@ -144,6 +144,7 @@ in bun docker docker-compose + lazydocker kubectl kubernetes-helm stern diff --git a/programs/git.nix b/programs/git.nix index 13d810c..3b08acf 100644 --- a/programs/git.nix +++ b/programs/git.nix @@ -66,6 +66,17 @@ # see https://adamj.eu/tech/2022/10/15/how-to-rebase-stacked-git-branches/ rebase.updateRefs = true; + # Repris d'Omarchy - https://github.com/basecamp/omarchy/blob/master/config/git/config + rerere = { + enabled = true; # mémorise la résolution des conflits… + autoupdate = true; # … et la réapplique automatiquement + }; + branch.sort = "-committerdate"; # branches les plus récentes en premier + tag.sort = "-version:refname"; # tri des tags par version (v1.10 après v1.9) + column.ui = "auto"; + commit.verbose = true; # diff affiché dans l'éditeur du message de commit + diff.mnemonicPrefix = true; # préfixes i/ w/ c/ au lieu de a/ b/ + "url \"git@gitlab.lundimatin.app:\"" = { insteadOf = "https://gitlab.lundimatin.app/"; }; diff --git a/programs/zsh.nix b/programs/zsh.nix index 8133a47..250565e 100644 --- a/programs/zsh.nix +++ b/programs/zsh.nix @@ -116,10 +116,13 @@ s = "fzf"; # show / search / select f = "fzf"; # file sf = "fzf"; # interactive file selection + ff = "fzf --preview 'bat --style=numbers --color=always {}'"; # fzf avec aperçu (Omarchy) dc = "docker compose"; dcr = "docker compose run --rm"; dcrm = "docker compose rm -fsv"; + lzd = "lazydocker"; + lzg = "lazygit"; copy = "xclip -selection c"; bepo = "setxkbmap -layout fr -variant bepo";