Use modules
This commit is contained in:
parent
b93f4c3a5f
commit
95794c3bf6
9 changed files with 161 additions and 255 deletions
|
|
@ -3,7 +3,7 @@
|
|||
(url "https://git.guix.gnu.org/guix.git")
|
||||
(branch "master")
|
||||
(commit
|
||||
"97e9fad7d2b9458f7735a056843c46542651075b")
|
||||
"47df71794f7ee9fc09398382feac12a5d39e6ddd")
|
||||
(introduction
|
||||
(make-channel-introduction
|
||||
"9edb3f66fd807b096b48283debdcddccfea34bad"
|
||||
76
guix-config/home/workstation.scm
Normal file
76
guix-config/home/workstation.scm
Normal file
|
|
@ -0,0 +1,76 @@
|
|||
(define-module (guix-config home workstation)
|
||||
#:use-module (gnu home)
|
||||
#:use-module (gnu packages emacs)
|
||||
#:use-module (gnu packages gnuzilla)
|
||||
#:use-module (gnu packages mail)
|
||||
#:use-module (gnu packages messaging)
|
||||
#:use-module (gnu packages sync)
|
||||
#:use-module (gnu packages pdf)
|
||||
#:use-module (gnu packages gnome)
|
||||
#:use-module (gnu packages wm)
|
||||
#:use-module (gnu packages terminals)
|
||||
#:use-module (gnu packages xorg)
|
||||
#:use-module (gnu packages linux)
|
||||
#:use-module (gnu packages freedesktop)
|
||||
#:use-module (gnu packages rust-apps)
|
||||
#:use-module (gnu packages qt)
|
||||
#:use-module (gnu packages version-control)
|
||||
#:use-module (gnu packages librewolf)
|
||||
#:use-module (gnu packages audio)
|
||||
#:use-module (gnu packages xdisorg)
|
||||
#:use-module (gnu packages admin)
|
||||
#:use-module (gnu packages fonts)
|
||||
#:use-module (gnu services)
|
||||
#:use-module (guix gexp)
|
||||
#:use-module (gnu home services shells)
|
||||
#:use-module (gnu home services dotfiles)
|
||||
#:use-module (gnu home services sound)
|
||||
#:use-module (gnu home services desktop)
|
||||
#:use-module (gnu home services niri))
|
||||
|
||||
(home-environment
|
||||
;; Below is the list of packages that will show up in your
|
||||
;; Home profile, under ~/.guix-home/profile.
|
||||
(packages (list emacs-pgtk
|
||||
font-iosevka
|
||||
git
|
||||
kitty
|
||||
btop
|
||||
fastfetch
|
||||
librewolf
|
||||
icecat
|
||||
nheko
|
||||
;birdtray
|
||||
nextcloud-client
|
||||
nautilus
|
||||
xournalpp
|
||||
ripgrep
|
||||
quickshell
|
||||
cava
|
||||
wl-clipboard
|
||||
brightnessctl
|
||||
qtmultimedia
|
||||
accountsservice
|
||||
matugen
|
||||
wayland
|
||||
xwayland-satellite
|
||||
qtwayland))
|
||||
|
||||
;; Below is the list of Home services. To search for available
|
||||
;; services, run 'guix home search KEYWORD' in a terminal.
|
||||
(services
|
||||
(append (list (service home-niri-service-type)
|
||||
(service home-pipewire-service-type)
|
||||
(service home-dbus-service-type)
|
||||
(service home-bash-service-type
|
||||
(home-bash-configuration
|
||||
(environment-variables '(("PS1" . "\\[\\e[1;32m\\]\\u \\[\\e[1;34m\\]\\w \\[\\e[0m\\] ")
|
||||
("EDITOR" . "emacsclient -c")))
|
||||
(aliases '(("gs" . "git status")
|
||||
("system-reconfigure" . "sudo -E guix time-machine -C ~/dotfiles/guix-config/channels-lock.scm -- system -L ~/dotfiles reconfigure ~/dotfiles/guix-config/system/$(hostname).scm")
|
||||
("home-reconfigure" . "guix time-machine -C ~/dotfiles/guix-config/channels-lock.scm -- home -L ~/dotfiles reconfigure ~/dotfiles/guix-config/home/workstation.scm")
|
||||
("guix-pull" . "guix pull --channels=~/dotfiles/guix-system/channels.scm; guix describe --format=channels > ~/dotfiles/guix-system/channels-lock.scm")))))
|
||||
(service home-dotfiles-service-type
|
||||
(home-dotfiles-configuration
|
||||
(directories '("../../files")))))
|
||||
%base-home-services)))
|
||||
55
guix-config/system/base-system.scm
Normal file
55
guix-config/system/base-system.scm
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
(define-module (guix-config system base-system)
|
||||
#:use-module (gnu)
|
||||
#:use-module (guix)
|
||||
#:export (base-system))
|
||||
|
||||
(use-service-modules cups desktop networking ssh xorg pm)
|
||||
|
||||
(define %my-desktop-services
|
||||
(modify-services %desktop-services
|
||||
(delete gdm-service-type)))
|
||||
|
||||
(define base-system
|
||||
(operating-system
|
||||
(locale "ru_RU.utf8")
|
||||
(timezone "Europe/Berlin")
|
||||
(keyboard-layout (keyboard-layout "eu,ru"
|
||||
#:options '("grp:alt_shift_toggle")))
|
||||
(host-name "base-system")
|
||||
|
||||
(users (cons* (user-account
|
||||
(name "kylekrein")
|
||||
(comment "Aleksandr Lebedev")
|
||||
(group "users")
|
||||
(home-directory "/home/kylekrein")
|
||||
(supplementary-groups '("wheel" "netdev" "audio" "video")))
|
||||
%base-user-accounts))
|
||||
|
||||
;; Below is the list of system services. To search for available
|
||||
;; services, run 'guix system search KEYWORD' in a terminal.
|
||||
(services
|
||||
(append (list
|
||||
;; To configure OpenSSH, pass an 'openssh-configuration'
|
||||
;; record as a second argument to 'service' below.
|
||||
(service openssh-service-type)
|
||||
(service cups-service-type)
|
||||
(service gnome-keyring-service-type)
|
||||
(service bluetooth-service-type)
|
||||
(service power-profiles-daemon-service-type)
|
||||
(set-xorg-configuration
|
||||
(xorg-configuration (keyboard-layout keyboard-layout))))
|
||||
|
||||
;; This is the default list of services we
|
||||
;; are appending to.
|
||||
%my-desktop-services))
|
||||
(bootloader (bootloader-configuration
|
||||
(bootloader grub-bootloader)
|
||||
(targets '("/dev/vda"))
|
||||
(terminal-outputs '(console))
|
||||
(keyboard-layout keyboard-layout)))
|
||||
|
||||
(file-systems (cons (file-system
|
||||
(mount-point "/")
|
||||
(device "/dev/vda1")
|
||||
(type "ext4"))
|
||||
%base-file-systems))))
|
||||
29
guix-config/system/iuseguixbtw.scm
Normal file
29
guix-config/system/iuseguixbtw.scm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
(define-module (guix-config system iuseguixbtw)
|
||||
#:use-module (gnu)
|
||||
#:use-module (guix-config system base-system))
|
||||
|
||||
(operating-system
|
||||
(inherit base-system)
|
||||
(host-name "iuseguixbtw")
|
||||
(bootloader (bootloader-configuration
|
||||
(bootloader grub-efi-bootloader)
|
||||
(targets (list "/boot/efi"))))
|
||||
(mapped-devices (list (mapped-device
|
||||
(source (uuid
|
||||
"e6686154-def0-41d3-a724-c89a36a5b3ed"))
|
||||
(target "cryptroot")
|
||||
(type luks-device-mapping))))
|
||||
|
||||
;; The list of file systems that get "mounted". The unique
|
||||
;; file system identifiers there ("UUIDs") can be obtained
|
||||
;; by running 'blkid' in a terminal.
|
||||
(file-systems (cons* (file-system
|
||||
(mount-point "/")
|
||||
(device "/dev/mapper/cryptroot")
|
||||
(type "ext4")
|
||||
(dependencies mapped-devices))
|
||||
(file-system
|
||||
(mount-point "/boot/efi")
|
||||
(device (uuid "B677-E030"
|
||||
'fat32))
|
||||
(type "vfat")) %base-file-systems)))
|
||||
|
|
@ -1,76 +0,0 @@
|
|||
;; This "home-environment" file can be passed to 'guix home reconfigure'
|
||||
;; to reproduce the content of your profile. This is "symbolic": it only
|
||||
;; specifies package names. To reproduce the exact same profile, you also
|
||||
;; need to capture the channels being used, as returned by "guix describe".
|
||||
;; See the "Replicating Guix" section in the manual.
|
||||
|
||||
(use-modules (gnu home)
|
||||
(gnu packages emacs)
|
||||
(gnu packages gnuzilla)
|
||||
(gnu packages mail)
|
||||
(gnu packages messaging)
|
||||
(gnu packages sync)
|
||||
(gnu packages pdf)
|
||||
(gnu packages gnome)
|
||||
(gnu packages wm)
|
||||
(gnu packages terminals)
|
||||
(gnu packages xorg)
|
||||
(gnu packages linux)
|
||||
(gnu packages freedesktop)
|
||||
(gnu packages rust-apps)
|
||||
(gnu packages qt)
|
||||
(gnu packages version-control)
|
||||
(gnu packages librewolf)
|
||||
(gnu packages audio)
|
||||
(gnu packages xdisorg)
|
||||
(gnu packages admin)
|
||||
(gnu services)
|
||||
(guix gexp)
|
||||
(gnu home services shells)
|
||||
(gnu home services dotfiles)
|
||||
(gnu home services sound)
|
||||
(gnu home services desktop)
|
||||
(gnu home services niri))
|
||||
|
||||
(home-environment
|
||||
;; Below is the list of packages that will show up in your
|
||||
;; Home profile, under ~/.guix-home/profile.
|
||||
(packages (list emacs-pgtk
|
||||
git
|
||||
kitty
|
||||
btop
|
||||
fastfetch
|
||||
librewolf
|
||||
icecat
|
||||
nheko
|
||||
;birdtray
|
||||
nextcloud-client
|
||||
nautilus
|
||||
xournalpp
|
||||
ripgrep
|
||||
quickshell
|
||||
cava
|
||||
wl-clipboard
|
||||
brightnessctl
|
||||
qtmultimedia
|
||||
accountsservice
|
||||
matugen
|
||||
wayland
|
||||
xwayland-satellite
|
||||
qtwayland))
|
||||
|
||||
;; Below is the list of Home services. To search for available
|
||||
;; services, run 'guix home search KEYWORD' in a terminal.
|
||||
(services
|
||||
(append (list (service home-niri-service-type)
|
||||
(service home-pipewire-service-type)
|
||||
(service home-dbus-service-type)
|
||||
(service home-bash-service-type
|
||||
(home-bash-configuration
|
||||
(environment-variables '(("PS1" . "\\[\\e[1;32m\\]\\u \\[\\e[1;34m\\]\\w \\[\\e[0m\\] ")
|
||||
("EDITOR" . "emacsclient -c")))
|
||||
(aliases '(("gs" . "git status")))))
|
||||
(service home-dotfiles-service-type
|
||||
(home-dotfiles-configuration
|
||||
(directories '("../../../files")))))
|
||||
%base-home-services)))
|
||||
|
|
@ -1,30 +0,0 @@
|
|||
;; This "home-environment" file can be passed to 'guix home reconfigure'
|
||||
;; to reproduce the content of your profile. This is "symbolic": it only
|
||||
;; specifies package names. To reproduce the exact same profile, you also
|
||||
;; need to capture the channels being used, as returned by "guix describe".
|
||||
;; See the "Replicating Guix" section in the manual.
|
||||
|
||||
(use-modules (gnu home)
|
||||
(gnu packages emacs)
|
||||
(gnu packages version-control)
|
||||
(gnu services)
|
||||
(guix gexp)
|
||||
(gnu home services shells)
|
||||
(gnu home services niri))
|
||||
|
||||
(home-environment
|
||||
;; Below is the list of packages that will show up in your
|
||||
;; Home profile, under ~/.guix-home/profile.
|
||||
(packages (list emacs-pgtk
|
||||
git))
|
||||
|
||||
;; Below is the list of Home services. To search for available
|
||||
;; services, run 'guix home search KEYWORD' in a terminal.
|
||||
(services
|
||||
(append (list (service home-niri-service-type)
|
||||
(service home-bash-service-type
|
||||
(home-bash-configuration
|
||||
(bash-profile (list (local-file
|
||||
"./.bash_profile"
|
||||
"bash_profile"))))))
|
||||
%base-home-services)))
|
||||
|
|
@ -1,63 +0,0 @@
|
|||
;; This "home-environment" file can be passed to 'guix home reconfigure'
|
||||
;; to reproduce the content of your profile. This is "symbolic": it only
|
||||
;; specifies package names. To reproduce the exact same profile, you also
|
||||
;; need to capture the channels being used, as returned by "guix describe".
|
||||
;; See the "Replicating Guix" section in the manual.
|
||||
|
||||
(use-modules (gnu home)
|
||||
(gnu packages emacs)
|
||||
(gnu packages wm)
|
||||
(gnu packages terminals)
|
||||
(gnu packages xorg)
|
||||
(gnu packages linux)
|
||||
(gnu packages freedesktop)
|
||||
(gnu packages rust-apps)
|
||||
(gnu packages qt)
|
||||
(gnu packages version-control)
|
||||
(gnu packages librewolf)
|
||||
(gnu packages audio)
|
||||
(gnu packages xdisorg)
|
||||
(gnu packages admin)
|
||||
(gnu services)
|
||||
(guix gexp)
|
||||
(gnu home services shells)
|
||||
(gnu home services dotfiles)
|
||||
(gnu home services sound)
|
||||
(gnu home services desktop)
|
||||
(gnu home services niri))
|
||||
|
||||
(home-environment
|
||||
;; Below is the list of packages that will show up in your
|
||||
;; Home profile, under ~/.guix-home/profile.
|
||||
(packages (list emacs-pgtk
|
||||
git
|
||||
kitty
|
||||
btop
|
||||
fastfetch
|
||||
librewolf
|
||||
quickshell
|
||||
cava
|
||||
wl-clipboard
|
||||
brightnessctl
|
||||
qtmultimedia
|
||||
accountsservice
|
||||
matugen
|
||||
wayland
|
||||
xwayland-satellite
|
||||
qtwayland))
|
||||
|
||||
;; Below is the list of Home services. To search for available
|
||||
;; services, run 'guix home search KEYWORD' in a terminal.
|
||||
(services
|
||||
(append (list (service home-niri-service-type)
|
||||
(service home-pipewire-service-type)
|
||||
(service home-dbus-service-type)
|
||||
(service home-bash-service-type
|
||||
(home-bash-configuration
|
||||
(environment-variables '(("PS1" . "\\[\\e[1;32m\\]\\u \\[\\e[1;34m\\]\\w \\[\\e[0m\\] ")
|
||||
("EDITOR" . "emacsclient")))
|
||||
(aliases '(("gs" . "git status")))))
|
||||
(service home-dotfiles-service-type
|
||||
(home-dotfiles-configuration
|
||||
(directories '("../../../files")))))
|
||||
%base-home-services)))
|
||||
|
|
@ -1,85 +0,0 @@
|
|||
;; This is an operating system configuration generated
|
||||
;; by the graphical installer.
|
||||
;;
|
||||
;; Once installation is complete, you can learn and modify
|
||||
;; this file to tweak the system configuration, and pass it
|
||||
;; to the 'guix system reconfigure' command to effect your
|
||||
;; changes.
|
||||
|
||||
|
||||
;; Indicate which modules to import to access the variables
|
||||
;; used in this configuration.
|
||||
(use-modules (gnu))
|
||||
(use-service-modules cups desktop networking ssh xorg pm)
|
||||
(use-package-modules emacs-xyz wm xorg)
|
||||
|
||||
(define %my-desktop-services
|
||||
(modify-services %desktop-services
|
||||
(gdm-service-type config =>
|
||||
(gdm-configuration
|
||||
(inherit config)
|
||||
(wayland? #t)))))
|
||||
|
||||
(operating-system
|
||||
(locale "ru_RU.utf8")
|
||||
(timezone "Europe/Berlin")
|
||||
(keyboard-layout (keyboard-layout "eu,ru"
|
||||
#:options '("grp:alt_shift_toggle")))
|
||||
(host-name "iuseguixbtw")
|
||||
|
||||
;; Учетные записи пользователей ('root' не указывается).
|
||||
(users (cons* (user-account
|
||||
(name "kylekrein")
|
||||
(comment "Aleksandr Lebedev")
|
||||
(group "users")
|
||||
(home-directory "/home/kylekrein")
|
||||
(supplementary-groups '("wheel" "netdev" "audio" "video")))
|
||||
%base-user-accounts))
|
||||
|
||||
(packages (append (list
|
||||
niri
|
||||
;emacs emacs-exwm emacs-desktop-environment
|
||||
)
|
||||
%base-packages))
|
||||
|
||||
;; Below is the list of system services. To search for available
|
||||
;; services, run 'guix system search KEYWORD' in a terminal.
|
||||
(services
|
||||
(append (list ;(service gnome-desktop-service-type)
|
||||
|
||||
;; To configure OpenSSH, pass an 'openssh-configuration'
|
||||
;; record as a second argument to 'service' below.
|
||||
(service openssh-service-type)
|
||||
(service cups-service-type)
|
||||
(service gnome-keyring-service-type)
|
||||
(service bluetooth-service-type)
|
||||
(service power-profiles-daemon-service-type)
|
||||
(set-xorg-configuration
|
||||
(xorg-configuration (keyboard-layout keyboard-layout))))
|
||||
|
||||
;; This is the default list of services we
|
||||
;; are appending to.
|
||||
%my-desktop-services))
|
||||
(bootloader (bootloader-configuration
|
||||
(bootloader grub-efi-bootloader)
|
||||
(targets (list "/boot/efi"))
|
||||
(keyboard-layout keyboard-layout)))
|
||||
(mapped-devices (list (mapped-device
|
||||
(source (uuid
|
||||
"e6686154-def0-41d3-a724-c89a36a5b3ed"))
|
||||
(target "cryptroot")
|
||||
(type luks-device-mapping))))
|
||||
|
||||
;; The list of file systems that get "mounted". The unique
|
||||
;; file system identifiers there ("UUIDs") can be obtained
|
||||
;; by running 'blkid' in a terminal.
|
||||
(file-systems (cons* (file-system
|
||||
(mount-point "/")
|
||||
(device "/dev/mapper/cryptroot")
|
||||
(type "ext4")
|
||||
(dependencies mapped-devices))
|
||||
(file-system
|
||||
(mount-point "/boot/efi")
|
||||
(device (uuid "B677-E030"
|
||||
'fat32))
|
||||
(type "vfat")) %base-file-systems)))
|
||||
Loading…
Add table
Add a link
Reference in a new issue