From 12eb60167671998d2bbfa33da59389a479f2d774 Mon Sep 17 00:00:00 2001 From: Nickiel12 Date: Thu, 21 Sep 2023 10:37:37 -0700 Subject: [PATCH] flake update; switched many programs to stable --- flake.lock | 19 +++++++++++++++++- flake.nix | 41 +++++++++++++++++++++++++++++-------- modules/yazi.nix | 17 ++++++++++++++++ users/nixolas.nix | 51 +++++++++++++++++++++++------------------------ 4 files changed, 93 insertions(+), 35 deletions(-) create mode 100644 modules/yazi.nix diff --git a/flake.lock b/flake.lock index e4f0d9f..a62c975 100644 --- a/flake.lock +++ b/flake.lock @@ -191,6 +191,22 @@ } }, "nixpkgs-stable": { + "locked": { + "lastModified": 1695283060, + "narHash": "sha256-CJz71xhCLlRkdFUSQEL0pIAAfcnWFXMzd9vXhPrnrEg=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "31ed632c692e6a36cfc18083b88ece892f863ed4", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "release-23.05", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs-stable_2": { "locked": { "lastModified": 1685801374, "narHash": "sha256-otaSUoFEMM+LjBI1XL/xGB5ao6IwnZOXc47qhIgJe8U=", @@ -327,7 +343,7 @@ "nixvim", "nixpkgs" ], - "nixpkgs-stable": "nixpkgs-stable" + "nixpkgs-stable": "nixpkgs-stable_2" }, "locked": { "lastModified": 1694364351, @@ -349,6 +365,7 @@ "kmonad": "kmonad", "nicks_nextcloud_integrations": "nicks_nextcloud_integrations", "nixpkgs": "nixpkgs_4", + "nixpkgs-stable": "nixpkgs-stable", "nixvim": "nixvim" } }, diff --git a/flake.nix b/flake.nix index 7cae362..c398f05 100644 --- a/flake.nix +++ b/flake.nix @@ -4,10 +4,10 @@ inputs = { nixvim.url = "github:nix-community/nixvim"; nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; + nixpkgs-stable.url = "github:NixOS/nixpkgs/release-23.05"; kmonad.url = "github:kmonad/kmonad?dir=nix"; nicks_nextcloud_integrations.url = "git+https://git.nickiel.net/Nickiel/nicks_nextcloud_integrations.git"; - # dead code? home-manager = { url = github:nix-community/home-manager; inputs.nixpkgs.follows = "nixpkgs"; @@ -16,24 +16,29 @@ }; - outputs = inputs@{ self, nixpkgs, home-manager, kmonad, ... }: + outputs = inputs@{ self, nixpkgs, nixpkgs-stable, home-manager, kmonad, ... }: let user = "nixolas"; system = "x86_64-linux"; + pkgs = import nixpkgs { inherit system; config.allowUnfree = true; }; + lib = nixpkgs.lib; in { nixosConfigurations = { inherit (nixpkgs) lib; - inherit inputs nixpkgs home-manager user kmonad; + inherit inputs home-manager user kmonad; # Home server Alaska = lib.nixosSystem { inherit system; - specialArgs = { inherit user; }; + specialArgs = { + inherit user; + pkgs-stable = inputs.nixpkgs-stable; + }; modules = [ inputs.nicks_nextcloud_integrations.nixosModules.default @@ -46,7 +51,13 @@ home-manager = { useGlobalPkgs = true; useUserPackages = true; - extraSpecialArgs = { inherit user; }; + extraSpecialArgs = { + inherit user; + pkgs-stable = import inputs.nixpkgs { + inherit system; + config.allowUnfree = true; + }; + }; users.${user} = { imports = [ (import ./users/${user}.nix) @@ -61,7 +72,9 @@ NicksNixLaptop = lib.nixosSystem { inherit system; - specialArgs = { inherit user; }; + specialArgs = { + inherit user; + }; modules = [ { @@ -75,7 +88,13 @@ home-manager = { useGlobalPkgs = true; useUserPackages = true; - extraSpecialArgs = { inherit user; }; + extraSpecialArgs = { + inherit user; + pkgs-stable = import inputs.nixpkgs { + inherit system; + config.allowUnfree = true; + }; + }; users.${user} = { imports = [ (import ./users/${user}.nix) @@ -105,7 +124,13 @@ home-manager = { useGlobalPkgs = true; useUserPackages = true; - extraSpecialArgs = { inherit user; }; + extraSpecialArgs = { + inherit user; + pkgs-stable = import inputs.nixpkgs { + inherit system; + config.allowUnfree = true; + }; + }; users.${user} = { imports = [ (import ./users/${user}.nix) diff --git a/modules/yazi.nix b/modules/yazi.nix new file mode 100644 index 0000000..586bf75 --- /dev/null +++ b/modules/yazi.nix @@ -0,0 +1,17 @@ +{ config, lib, pkgs, home-manager, ... }: + +{ + + programs.yazi = { + enable = true; + enableZshIntegration = true; + settings = { + sort_by = "natural"; + sort_sensitive = false; + sort_dir_first = true; + show_hidden = true; + show_symlink = true; + }; + }; + +} diff --git a/users/nixolas.nix b/users/nixolas.nix index b24fb1d..4067661 100644 --- a/users/nixolas.nix +++ b/users/nixolas.nix @@ -1,4 +1,4 @@ -{ inputs, config, pkgs, user, ... }: +{ inputs, config, pkgs, pkgs-stable, user, ... }: let moz_overlay = import (builtins.fetchTarball https://github.com/mozilla/nixpkgs-mozilla/archive/master.tar.gz); @@ -26,6 +26,7 @@ in ../modules/rofi.nix ../modules/wezterm.nix ../modules/xdg.nix + ../modules/yazi.nix ../modules/zsh.nix ]; @@ -77,48 +78,45 @@ in bottom # system monitor du-dust # directory disk-space analyzer ffmpeg-full # ffmpeg for video/audio rendering - frei0r # kdenlive video plugins - flameshot # screenshot utility - fontpreview # utility to preview fonts + pkgs-stable.frei0r # kdenlive video plugins + pkgs-stable.flameshot # screenshot utility + pkgs-stable.fontpreview # utility to preview fonts gitui # command line git tui - helvum # audio sink gui control - pandoc # utility for converting between document types - qmk # QMK utility for compiling qmk firmware + pkgs-stable.helvum # audio sink gui control + pkgs-stable.pandoc # utility for converting between document types + pkgs-stable.qmk # QMK utility for compiling qmk firmware nextcloud-client # Nextcloud private syncing hddtemp - texlive.combined.scheme-medium + pkgs-stable.texlive.combined.scheme-medium # commandline utils eza fd fortune neofetch - pandoc pfetch - ripgrep rmtrash testdisk # file recovery https://itsfoss.com/recover-deleted-files-linux/ xdotool - yazi - vhs + pkgs-stable.vhs - nodejs # required for coc-nvim + pkgs-stable.nodejs # required for coc-nvim # Gui application - darktable # RAW processing - dbeaver # SQL management tool + pkgs-stable.darktable # RAW processing + pkgs-stable.dbeaver # SQL management tool firefox # Internet access - handbrake # dvd ripping - inkscape # Vector drawing - kicad # PCB design + pkgs-stable.handbrake # dvd ripping + pkgs-stable.inkscape # Vector drawing + pkgs-stable.kicad # PCB design krita # Raster drawing - libreoffice-fresh # Office editing - makemkv # blue-ray + dvd -> mkv - obsidian # Markdown and notes + pkgs-stable.libreoffice-fresh # Office editing + pkgs-stable.makemkv # blue-ray + dvd -> mkv + pkgs-stable.obsidian # Markdown and notes qalculate-gtk # unit-friendly calculator - vscodium # when vim and emacs (somehow) isn't enough - dragon # simple audio player + pkgs-stable.vscodium # when vim and emacs (somehow) isn't enough + pkgs-stable.dragon # simple audio player obs-studio # for video recording and virtual camera libsForQt5.kate # kate/kwrite @@ -128,9 +126,9 @@ in libsForQt5.soundkonverter # audio cd ripping # Kdenlive and deps - libsForQt5.kdenlive - mediainfo - mlt + pkgs-stable.libsForQt5.kdenlive + pkgs-stable.mediainfo + pkgs-stable.mlt # Drawing tablet driver opentabletdriver @@ -138,6 +136,7 @@ in sessionVariables = { NIX_SHELL_PRESERVE_PROMPT = 1; + EDITOR = "nvim"; }; };