I showed you my source code, pls respond
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

144 lines
3.3 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. # This file is controlled by /etc/dotfiles/README.org
  2. # This module MUST be included within home manager
  3. { pkgs, ... }:
  4. let
  5. myEmacs = pkgs.emacsWithPackagesFromUsePackage {
  6. config = ../README.org;
  7. package = pkgs.emacsNativeComp;
  8. alwaysEnsure = true;
  9. alwaysTangle = true;
  10. extraEmacsPackages = epkgs: [
  11. # Required packages...
  12. epkgs.exwm
  13. epkgs.evil
  14. epkgs.evil-collection
  15. epkgs.evil-surround
  16. epkgs.evil-nerd-commenter
  17. epkgs.general
  18. epkgs.which-key
  19. # Optional packages.
  20. epkgs.org
  21. epkgs.org-roam
  22. epkgs.org-roam-ui
  23. epkgs.websocket
  24. epkgs.simple-httpd
  25. epkgs.org-drill
  26. epkgs.org-pomodoro
  27. epkgs.writegood-mode
  28. epkgs.ob-http
  29. epkgs.ox-hugo
  30. epkgs.password-store
  31. epkgs.docker
  32. epkgs.dockerfile-mode
  33. epkgs.mu4e-alert
  34. epkgs.dired-single
  35. epkgs.all-the-icons
  36. epkgs.all-the-icons-dired
  37. epkgs.all-the-icons-ivy-rich
  38. epkgs.emojify
  39. epkgs.eshell-prompt-extras
  40. epkgs.vterm
  41. epkgs.magit
  42. epkgs.hydra
  43. epkgs.elfeed
  44. epkgs.nix-mode
  45. epkgs.projectile
  46. epkgs.lsp-mode
  47. epkgs.lsp-ui
  48. epkgs.company
  49. epkgs.gdscript-mode
  50. epkgs.ccls
  51. epkgs.go-mode
  52. epkgs.pretty-mode
  53. epkgs.rustic
  54. epkgs.protobuf-mode
  55. epkgs.typescript-mode
  56. epkgs.plantuml-mode
  57. # User interface packages.
  58. epkgs.ivy
  59. epkgs.counsel
  60. epkgs.ivy-rich
  61. epkgs.ivy-posframe
  62. epkgs.ivy-prescient
  63. epkgs.desktop-environment
  64. epkgs.doom-themes
  65. epkgs.doom-modeline
  66. ];
  67. };
  68. in {
  69. home.packages = [
  70. pkgs.nitrogen
  71. pkgs.autorandr
  72. pkgs.pass
  73. pkgs.mu
  74. pkgs.isync
  75. (pkgs.writeShellScriptBin "mail-init" ''
  76. ${pkgs.mu} init --maildir="~/.cache/mail" --my-address="chris@chrishayward.xyz"
  77. ${pkgs.mu} index
  78. '')
  79. (pkgs.writeShellScriptBin "mail-sync" ''
  80. ${pkgs.isync}/bin/mbsync -a
  81. '')
  82. pkgs.aspell
  83. pkgs.aspellDicts.en
  84. pkgs.aspellDicts.en-science
  85. pkgs.aspellDicts.en-computers
  86. # pkgs.texlive.combined.scheme-full
  87. pkgs.brightnessctl
  88. pkgs.plantuml
  89. pkgs.nixfmt
  90. pkgs.rnix-lsp
  91. (pkgs.writeShellScriptBin "dotfiles-theme" ''
  92. ${myEmacs}/bin/emacsclient --no-wait --eval '(json-encode (dotfiles/theme))' | sed "s/\\\\//g" | sed -e 's/^"//' -e 's/"$//'
  93. '')
  94. ];
  95. programs.emacs = {
  96. enable = true;
  97. package = myEmacs;
  98. };
  99. xsession = {
  100. enable = true;
  101. windowManager.command = ''
  102. ${pkgs.nitrogen}/bin/nitrogen --restore
  103. ${myEmacs}/bin/emacs --daemon -f exwm-enable
  104. ${myEmacs}/bin/emacsclient -c
  105. '';
  106. };
  107. home.file.".xinitrc" = {
  108. text = ''
  109. exec ./.xsession
  110. '';
  111. };
  112. # Deploy the authinfo file.
  113. home.file.".authinfo.gpg".source = ../config/authinfo.gpg;
  114. # Deploy the isync configuration file.
  115. home.file.".mbsyncrc" = {
  116. text = ''
  117. IMAPStore xyz-remote
  118. Host mail.chrishayward.xyz
  119. User chris@chrishayward.xyz
  120. PassCmd "pass chrishayward.xyz/chris"
  121. SSLType IMAPS
  122. MaildirStore xyz-local
  123. Path ~/.cache/mail/
  124. Inbox ~/.cache/mail/inbox
  125. SubFolders Verbatim
  126. Channel xyz
  127. Far :xyz-remote:
  128. Near :xyz-local:
  129. Patterns * !Archives
  130. Create Both
  131. Expunge Both
  132. SyncState *
  133. '';
  134. };
  135. }