From ac0ecdb0ed7317a0de5db930bf3b000779460086 Mon Sep 17 00:00:00 2001 From: atagen Date: Wed, 17 Aug 2022 21:49:53 +1000 Subject: [PATCH] rust and half of zsh --- home/home.nix | 44 +++++++++++++++++++++++++++++----------- system/configuration.nix | 43 +++++++-------------------------------- 2 files changed, 39 insertions(+), 48 deletions(-) diff --git a/home/home.nix b/home/home.nix index 86b5910..fcbc540 100644 --- a/home/home.nix +++ b/home/home.nix @@ -1,6 +1,9 @@ { config, pkgs, ... }: { + nixpkgs.overlays = [ + (import "${fetchTarball "https://github.com/nix-community/fenix/archive/main.tar.gz"}/overlay.nix") + ]; home.username = "fossil"; home.homeDirectory = "/home/fossil"; @@ -9,22 +12,39 @@ firefox thunderbird cmus - zellij - - zsh - zoxide - zsh-vi-mode - zsh-autopair - zsh-nix-shell - oh-my-zsh - zsh-completions + zellij + btop + + rust-analyzer-nightly + (fenix.complete.withComponents [ + "cargo" + "clippy" + "rust-src" + "rustc" + "rustfmt" + ]) + zsh-powerlevel10k - zsh-autocomplete - zsh-fast-syntax-highlighting - zsh-history-search-multi-word nix-zsh-completions + ]; + programs.zsh = { + enableAutosuggestions = true; + enableCompletion = true; + enableSyntaxHighlighting = true; + enableVteIntegration = true; + autocd = true; + defaultKeymap = "viins"; + dotDir = ".nix"; + oh-my-zsh = { + enable = true; + plugins = [ "git" "sudo" "zoxide" "powerlevel10k" "zsh-nix-shell" "zsh-history-search-multi-word" "zsh-vi-mode" "zsh-completions" "zsh-autopair" "zsh-autocomplete" "zsh-fast-syntax-highlighting" ]; + theme = "powerlevel10k/powerlevel10k"; + }; + }; + + home.stateVersion = "22.05"; programs.home-manager.enable = true; diff --git a/system/configuration.nix b/system/configuration.nix index bdce9ee..0cc7533 100644 --- a/system/configuration.nix +++ b/system/configuration.nix @@ -6,9 +6,6 @@ { -# nixpkgs.overlays = [ -# (import "${fetchTarball "https://github.com/nix-community/fenix/archive/main.tar.gz"}/overlay.nix") -# ]; imports = [ # Include the results of the hardware scan. @@ -87,46 +84,20 @@ isNormalUser = true; extraGroups = [ "wheel" ]; # Enable ‘sudo’ for the user. }; - # packages here - # home-manager.users.fossil = { - # home.packages = with pkgs; [ - # kitty - # firefox - # thunderbird - # cmus - # - # zsh - # zoxide - # zsh-vi-mode - # zsh-autopair - # zsh-nix-shell - # oh-my-zsh - # zsh-completions - # zsh-powerlevel10k - # zsh-autocomplete - # zsh-fast-syntax-highlighting - # zsh-history-search-multi-word - # nix-zsh-completions - - # ]; - # }; + + programs.zsh.enable = true; + users.defaultUserShell = pkgs.zsh; # List packages installed in system profile. To search, run: # $ nix search wget environment.systemPackages = with pkgs; [ helix + rnix-lsp + home-manager git - # gcc - # llvm - # rust-analyzer-nightly - # (fenix.complete.withComponents [ - # "cargo" - # "clippy" - # "rust-src" - # "rustc" - # "rustfmt" - # ]) + + zsh ]; # Some programs need SUID wrappers, can be configured further or are