From 49e0dc10749a34f66a0935c1ded8f6fa6c4b346c Mon Sep 17 00:00:00 2001 From: jdlugosz963 Date: Mon, 3 Jul 2023 14:12:58 +0200 Subject: Add guix manifests and channels. --- .bash_profile | 15 +++- .config/guix/channels.scm | 10 +++ .config/guix/manifests/desktop.scm | 54 +++++++++++++++ .config/guix/manifests/emacs.scm | 50 ++++++++++++++ guix/jd/desktops/base.scm | 136 +++++++++++++++++++++---------------- guix/jd/desktops/mimir.scm | 9 ++- guix/jd/desktops/viking.scm | 29 -------- 7 files changed, 212 insertions(+), 91 deletions(-) create mode 100755 .config/guix/channels.scm create mode 100644 .config/guix/manifests/desktop.scm create mode 100644 .config/guix/manifests/emacs.scm delete mode 100644 guix/jd/desktops/viking.scm diff --git a/.bash_profile b/.bash_profile index 8182e2b..608f031 100644 --- a/.bash_profile +++ b/.bash_profile @@ -1 +1,14 @@ -export PATH="$HOME/bin:$PATH" +# Honor per-interactive-shell startup file +if [ -f ~/.bashrc ]; then . ~/.bashrc; fi + +export PATH="$HOME/bin:$PATH +export GUIX_EXTRA_PROFILES=$HOME/.guix-extra-profiles + +for i in $GUIX_EXTRA_PROFILES/*; do + profile=$i/$(basename "$i") + if [ -f "$profile"/etc/profile ]; then + GUIX_PROFILE="$profile" + . "$GUIX_PROFILE"/etc/profile + fi + unset profile +done diff --git a/.config/guix/channels.scm b/.config/guix/channels.scm new file mode 100755 index 0000000..0554922 --- /dev/null +++ b/.config/guix/channels.scm @@ -0,0 +1,10 @@ +(cons* (channel + (name 'nonguix) + (url "https://gitlab.com/nonguix/nonguix") + ;; Enable signature verification: + (introduction + (make-channel-introduction + "897c1a470da759236cc11798f4e0a5f7d4d59fbc" + (openpgp-fingerprint + "2A39 3FFF 68F4 EF7A 3D29 12AF 6F51 20A0 22FB B2D5")))) + %default-channels) diff --git a/.config/guix/manifests/desktop.scm b/.config/guix/manifests/desktop.scm new file mode 100644 index 0000000..65f456e --- /dev/null +++ b/.config/guix/manifests/desktop.scm @@ -0,0 +1,54 @@ +(specifications->manifest + '("qutebrowser" + + "pulsemixer" + "pavucontrol-qt" + + "virt-manager" + + "flatpak" + "redshift" + "fontmanager" + + "polybar" + + "blueman" + + "xdg-utils" + "xdg-dbus-proxy" + "gtk+:bin" + "shared-mime-info" + + "gimp" + "inkscape" + + "mpv" + "youtube-dl" + + "pamixer" + "playerctl" + "scrot" + "brightnessctl" + "slock" + "upower" + "tlp" + + "curl" + "wget" + "zip" + "unzip" + "trash-cli" + "password-store" + "pinentry" + + "syncthing" + "syncthing-gtk" + + "xmodmap" + "xrandr" + "arandr" + "xss-lock" + "libinput" + "xinput" + + )) diff --git a/.config/guix/manifests/emacs.scm b/.config/guix/manifests/emacs.scm new file mode 100644 index 0000000..0668120 --- /dev/null +++ b/.config/guix/manifests/emacs.scm @@ -0,0 +1,50 @@ +;; This file is auto-generated by Emacs function: jd/manifest-generate-to-file +(specifications->manifest +'("emacs-guix" + "emacs-desktop-environment" + "emacs-exwm" + "emacs-mu4e-alert" + "mu" + "emacs-htmlize" + "emacs-mastodon" + "emacs-elfeed" + "emacs-pdf-tools" + "emacs-all-the-icons-dired" + "emacs-vterm" + "emacs-magit" + "emacs-neotree" + "emacs-projectile" + "emacs-company-box" + "emacs-company" + "emacs-docker" + "emacs-yaml-mode" + "emacs-web-mode" + "emacs-flycheck" + "emacs-tide" + "emacs-typescript-mode" + "emacs-pyvenv" + "emacs-geiser-guile" + "emacs-geiser" + "emacs-rainbow-delimiters" + "emacs-paredit" + "emacs-lsp-ivy" + "emacs-lsp-mode" + "emacs-org-roam" + "emacs-org-superstar" + "emacs-visual-fill-column" + "emacs-org" + "emacs-beacon" + "emacs-doom-modeline" + "emacs-all-the-icons" + "emacs-which-key" + "emacs-counsel" + "emacs-ivy" + "emacs-hl-todo" + "emacs-diminish" + "emacs-doom-themes" + "emacs-undo-tree" + "emacs-hydra" + "emacs-general" + "emacs" + "emacs-use-package" +)) diff --git a/guix/jd/desktops/base.scm b/guix/jd/desktops/base.scm index 7618257..b9fc286 100644 --- a/guix/jd/desktops/base.scm +++ b/guix/jd/desktops/base.scm @@ -8,75 +8,86 @@ (use-service-modules cups desktop networking ssh xorg docker virtualization pm sound) -;; Odin is a base operating system -(define-public odin - (operating-system - (kernel linux) - (initrd microcode-initrd) - (firmware (list linux-firmware)) +(define-public %jd-base-user-accounts + (cons* (user-account + (name "jakub") + (comment "Jakub Dlugosz") + (group "users") + (home-directory "/home/jakub") + (supplementary-groups '("wheel" + "netdev" + "audio" + "docker" + "kvm" + "libvirt" + "video"))) + %base-user-accounts)) - (locale "en_US.utf8") - (timezone "Europe/Warsaw") - (keyboard-layout (keyboard-layout "pl")) - (host-name "odin") - - (users (cons* (user-account - (name "jakub") - (comment "Jakub Dlugosz") - (group "users") - (home-directory "/home/jakub") - (supplementary-groups '("wheel" "netdev" "audio" "video"))) - %base-user-accounts)) +(define-public %jd-base-packages + (append + (specifications->packages '("emacs" + "emacs-exwm" + "stow" + "bluez" + "bluez-alsa" + "exfat-utils" + "git" + "xf86-input-libinput" + "intel-vaapi-driver" + "libva-utils" + "nss-certs")) + %base-packages)) - (packages (append (specifications->packages '("emacs" - "emacs-exwm" - - "brightnessctl" +(define-public %jd-base-services + (append (list + (service openssh-service-type) - "bluez" - "bluez-alsa" + (service network-manager-service-type + (network-manager-configuration + (vpn-plugins (list + network-manager-pptp)))) + + (service bluetooth-service-type + (bluetooth-configuration + (auto-enable? #t))) - "xf86-input-libinput" - - "nss-certs")) + (service docker-service-type) + (service libvirt-service-type + (libvirt-configuration + (unix-sock-group "libvirt") + (tls-port "16555"))) - %base-packages)) - - (services - (append (list - (service xfce-desktop-service-type) - (service openssh-service-type) - (set-xorg-configuration - (xorg-configuration (keyboard-layout keyboard-layout))) + (service sane-service-type) + (service cups-service-type + (cups-configuration + (web-interface? #t))) - (service network-manager-service-type - (network-manager-configuration - (vpn-plugins (list - network-manager-pptp)))) - - (service bluetooth-service-type - (bluetooth-configuration - (auto-enable? #t))) + (service thermald-service-type) + (service tlp-service-type + (tlp-configuration + (cpu-boost-on-ac? #t) + (wifi-pwr-on-bat? #t))) - (service docker-service-type) - (service libvirt-service-type - (libvirt-configuration - (unix-sock-group "libvirt") - (tls-port "16555"))) + (service slim-service-type (slim-configuration + (display ":0") + (vt "vt7")))) - (service sane-service-type) - (service cups-service-type - (cups-configuration - (web-interface? #t))) + (modify-services %desktop-services + (delete network-manager-service-type) + (delete gdm-service-type)))) - (service thermald-service-type) - (service tlp-service-type - (tlp-configuration - (cpu-boost-on-ac? #t) - (wifi-pwr-on-bat? #t)))) +;; Odin is a base operating system +(define-public odin-free + (operating-system + (locale "en_US.utf8") + (timezone "Europe/Warsaw") + (keyboard-layout (keyboard-layout "pl")) + (host-name "odin") + + (users %jd-base-user-accounts) + (packages %jd-base-packages) + (services %jd-base-services) - (modify-services %desktop-services - (delete network-manager-service-type)))) (bootloader (bootloader-configuration (bootloader grub-bootloader) (targets (list "/boot/efi")) @@ -88,3 +99,10 @@ (type "tmpfs") (check? #f)) %base-file-systems)))) + +(define-public odin-non-free + (operating-system + (inherit odin-free) + (kernel linux) + (initrd microcode-initrd) + (firmware (list linux-firmware)))) diff --git a/guix/jd/desktops/mimir.scm b/guix/jd/desktops/mimir.scm index a635831..185df08 100644 --- a/guix/jd/desktops/mimir.scm +++ b/guix/jd/desktops/mimir.scm @@ -1,11 +1,16 @@ (define-module (jd desktops mimir) #:use-module (jd desktops base) - #:use-module (gnu)) + #:use-module (gnu) + #:use-module (gnu services desktop)) (operating-system - (inherit odin) + (inherit odin-non-free) (host-name "mimir") + + (services (cons + (service xfce-desktop-service-type) + %jd-base-services)) (bootloader (bootloader-configuration (bootloader grub-efi-bootloader) diff --git a/guix/jd/desktops/viking.scm b/guix/jd/desktops/viking.scm deleted file mode 100644 index 80ddb88..0000000 --- a/guix/jd/desktops/viking.scm +++ /dev/null @@ -1,29 +0,0 @@ -(define-module (jd desktops mimir) - #:use-module (jd desktops base) - #:use-module (gnu)) - -(operating-system - (inherit odin) - (host-name "mimir") - - (bootloader (bootloader-configuration - (bootloader grub-efi-bootloader) - (targets (list "/boot/efi")))) - - - (swap-devices (list (swap-space - (target (uuid - "658793cb-d374-426e-bcd5-00d032b003a0"))))) - - (file-systems (cons* (file-system - (mount-point "/boot/efi") - (device (uuid "64D8-134F" - 'fat32)) - (type "vfat")) - (file-system - (mount-point "/") - (device (uuid - "1f9304b0-5623-4248-ab66-534b5ac85876" - 'ext4)) - (type "ext4")) %base-file-systems))) - -- cgit v1.2.3