home.scm 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. (add-to-load-path (dirname (current-filename)))
  2. (use-modules (gnu home)
  3. (gnu home-services)
  4. (gnu home-services ssh)
  5. (gnu home-services shells)
  6. (gnu home-services files)
  7. (gnu services)
  8. (gnu packages admin)
  9. (guix gexp)
  10. (my-home packages) ;; %defines %my-packages
  11. )
  12. (home-environment
  13. ;; the below is deprecated.
  14. ;; (home-directory "/home/joshua")
  15. ;; (symlink-name ".guix-home-env")
  16. (packages (map specification->package+output
  17. %my-packages))
  18. (services
  19. (list
  20. ;; (service sway-service-type
  21. ;; (sway-configuration
  22. ;; (user "joshua")
  23. ;; (group "users")
  24. ;; (variables
  25. ;; (sway-variables-configuration
  26. ;; (letter-left "n")
  27. ;; (letter-right "s")
  28. ;; (letter-up "t")
  29. ;; (letter-down "h")
  30. ;; (default-terminal "termite")
  31. ;; (keyboard-layout (list "dvorak"))
  32. ;; (xkb-options (list "ctrl:swapcaps"))
  33. ;; (tap-to-click? #t)
  34. ;; (natural-scroll? #t)
  35. ;; ))
  36. ;; (bindsyms
  37. ;; (list %sway-basic-bindsyms
  38. ;; %sway-moving-around-bindsyms
  39. ;; %sway-layout-bindsyms
  40. ;; %sway-scratchpad-bindsyms
  41. ;; (sway-bindsym
  42. ;; (command "exec pactl set-sink-volume @DEFAULT_SINK@ +10%")
  43. ;; (key-combo "XF86AudioRaiseVolume"))
  44. ;; (sway-bindsym
  45. ;; (command "exec pactl set-sink-volume @DEFAULT_SINK@ -10%")
  46. ;; (key-combo "XF86AudioLowerVolume"))
  47. ;; (sway-bindsym
  48. ;; (command "exec pactl set-sink-mute @DEFAULT_SINK@ toggle")
  49. ;; (key-combo "XF86AudioMute"))
  50. ;; (sway-bindsym
  51. ;; (command "exec eject")
  52. ;; (key-combo "f9"))))))
  53. (service home-keyboard-service-type
  54. (keyboard-layout (keyboard-layout "us" "dvorak"
  55. #:model "thinkpad"
  56. #:options '("ctrl:swapcaps"))))
  57. ;; I should check out the home-state-service type to let me sync up my git repos:
  58. ;; https://git.sr.ht/~abcdw/rde/tree/master/item/gnu/home/examples/home-environment.tmpl
  59. ;; (service home-state-service-type
  60. ;; (append
  61. ;; (list
  62. ;; (state-rsync "/home/bob/tmp/example-rsync-state/"
  63. ;; "abcdw@olorin.lan:/var/services/homes/abcdw/tmp-state/")
  64. ;; (state-git "/home/bob/tmp/talkes/"
  65. ;; "git@git.sr.ht:~abcdw/rde"))))
  66. (service home-bash-service-type
  67. (home-bash-configuration
  68. (guix-defaults? #t)
  69. (bash-profile '("\ export HISTFILE=$XDG_CACHE_HOME/.bash_history;\n"
  70. "if [[ -z $DISPLAY ]] && [[ $(tty) = /dev/tty3 ]]; then\n"
  71. "# this may fix a bug that I have with termite confusing backspace as space in guix environment\n"
  72. "# export TERM=linux\n"
  73. "# shepherd -c /home/joshua/.config/shepherd/init.scm &\n"
  74. "export MOZ_ENABLE_WAYLAND=1;\n"
  75. "export GUIX_PACKAGE_PATH=/home/joshua/prog/gnu/guix/guix-packages/;\n"
  76. "export XDG_DATA_DIRS=/var/lib/flatpak/exports/share:/home/joshua/.local/share/flatpak/exports/share:$XDG_DATA_DIRS;\n"
  77. "exec dbus-run-session sway;\n"
  78. "fi"
  79. ))
  80. (bashrc
  81. '("alias lamora='ssh -p 63355 lamora'"))))
  82. (simple-service 'various-config-files
  83. home-files-service-type
  84. (list
  85. ;; termite config
  86. `("config/termite/config"
  87. ,(local-file "config-files/termite-config"
  88. "config"))
  89. ;; sway config file
  90. `("config/sway/config"
  91. ,(local-file "config-files/sway-config"
  92. "config"))
  93. ;; sway status.sh file
  94. `("config/sway/status.sh"
  95. ,(local-file "config-files/sway-status.sh"
  96. "status.sh"))
  97. ))
  98. )))