From 24448888ce7b075940ca333bd954f1b86285de3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?benjamin=20melan=C3=A7on?= Date: Tue, 1 Jul 2025 16:10:29 -0400 Subject: [PATCH 1/3] Successfully add drivers for Brother printer, maybe successfully add scanner? And some other printer-realted programs that may or may not have been needed. --- configuration.nix | 29 +++++++++++++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/configuration.nix b/configuration.nix index 968e3ac..cc973a5 100644 --- a/configuration.nix +++ b/configuration.nix @@ -9,6 +9,8 @@ [ # Include the results of the hardware scan. ./hardware-configuration.nix + # Support Brother scanner + # Include Framework-specific tweaks supported by the NixOS community # This amazing script seems to cause the computer to not have a properly functioning screen @@ -34,6 +36,7 @@ calibre contrast # cruft + cups-brother-hll2375dw curl ddev diffr @@ -133,6 +136,7 @@ sly # simple image editing starship # fancy command line prompt strawberry-qt6 + system-config-printer tdf # Terminal PDF viewer textpieces tldr @@ -190,6 +194,20 @@ options = "--delete-older-than 60d"; }; + # Hardware + # hardware.sane.enable = true; # enables support for SANE scanners per https://wiki.nixos.org/wiki/Scanners + hardware = { + sane = { + enable = true; + brscan4 = { + enable = true; + netDevices = { + home = { model = "HL-L2380DW"; ip = "192.168.178.23"; }; + }; + }; + }; + }; + networking.hostName = "nixos"; # Define your hostname. # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. @@ -246,7 +264,14 @@ console.keyMap = "dvorak"; # Enable CUPS to print documents. - # services.printing.enable = true; + services.printing.enable = true; + + # Add Brother printer drivers, per https://nixos.wiki/wiki/Hardware/Brother + services.printing.drivers = [ + pkgs.brlaser + pkgs.brgenml1lpr + pkgs.brgenml1cupswrapper + ]; # Enable sound with pipewire. services.pulseaudio.enable = false; @@ -282,7 +307,7 @@ users.users.mlncn = { isNormalUser = true; description = "mlncn"; - extraGroups = [ "networkmanager" "wheel" "docker" ]; + extraGroups = [ "networkmanager" "wheel" "docker" "scanner" "lp" ]; packages = with pkgs; [ discord kdePackages.kate From 67ed0c6a09b16867949048c471dd421b81162c5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?benjamin=20melan=C3=A7on?= Date: Tue, 1 Jul 2025 21:07:20 -0400 Subject: [PATCH 2/3] Attempt but fail to get Pomodoro Prompt to run directly without a nix-shell --- configuration.nix | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/configuration.nix b/configuration.nix index cc973a5..ba13c38 100644 --- a/configuration.nix +++ b/configuration.nix @@ -57,8 +57,10 @@ # gimp-with-plugins # Currently breaks build, but works if in nix shell solo git git-open + gtk3 # for Pomodoro Prompt gnucash gnumake + gobject-introspection # for Pomodoro Prompt # handbrake # converting video, https://handbrake.fr/ htop hunspell @@ -115,7 +117,17 @@ php # does PHP 8.2 currently and there's php81, php83, and php84 alternatives php82Packages.composer # php84Packages.composer ansible_2_16 - (python3.withPackages(ps: with ps; [ numpy pandas python-dotenv ])) # https://github.com/NixOS/nixpkgs/blob/master/doc/languages-frameworks/python.section.md#environment-defined-in-etcnixosconfigurationnix-environment-defined-in-etcnixosconfigurationnix (note this is literally the last thing they wanted me to do, would rather it not be global) + pinta # simple image editing + (python3.withPackages(ps: with ps; [ + numpy + pandas + playsound + pycairo + pygobject3 + python-dotenv + pytz + tzlocal + ])) # https://github.com/NixOS/nixpkgs/blob/master/doc/languages-frameworks/python.section.md#environment-defined-in-etcnixosconfigurationnix-environment-defined-in-etcnixosconfigurationnix (note this is literally the last thing they wanted me to do, would rather it not be global) but i want Pomodoro Prompt and Parse Timelogs to be able to run directly. poppins postgresql qrscan @@ -156,6 +168,7 @@ vscodium # wcalc - command-line calculator but rink does that plus unit conversion! wl-clipboard-rs + wrapGAppsHook # for Pomodoro Prompt xorg.xkill # xpdf # Simple PDF viewer - currently marked insecure yt-dlp From 3dbc1a527bfb5678e55bb46c1b1a1aae4d3d2387 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?benjamin=20melan=C3=A7on?= Date: Tue, 1 Jul 2025 21:09:03 -0400 Subject: [PATCH 3/3] Add telnet, print and pomodoro prompt related things missed from before, and ditch incompat zulip-term --- configuration.nix | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/configuration.nix b/configuration.nix index ba13c38..180bcb2 100644 --- a/configuration.nix +++ b/configuration.nix @@ -66,7 +66,8 @@ hunspell hunspellDicts.en_US-large hunspellDicts.es_MX - # jitsi - this is unusuable with a regular Jitsi Meet server like May First? + inetutils # telnet among other things + # jitsi # - this is unusuable with a regular Jitsi Meet server like May First? # jitsi-meet-electron # currently breaks build jq just @@ -87,6 +88,8 @@ kdePackages.kweather # kdePackages.neochat # For matrix but relying on insecure olm-3.2.16 kdePackages.partitionmanager + kdePackages.print-manager + kdePackages.xdg-desktop-portal-kde keepassxc kirc # kiwix @@ -146,6 +149,7 @@ sioyek # Science-document-focused PDF viewer slack sly # simple image editing + spideroak # backups starship # fancy command line prompt strawberry-qt6 system-config-printer @@ -175,7 +179,7 @@ zed-editor zoxide zulip - zulip-term + # zulip-term ]; environment.pathsToLink = [ "/share/fish" ];