From 9918b9daff89c4c67ac366df54785f256b022b76 Mon Sep 17 00:00:00 2001 From: Christopher James Hayward Date: Mon, 14 Jun 2021 20:46:38 -0400 Subject: [PATCH] Add missing outputs --- modules/emacs.nix | 112 ++++++++++++++++++++++++++++++++++++++++++++++ shells/cc.nix | 14 ++++++ shells/go.nix | 16 +++++++ shells/grpc.nix | 14 ++++++ shells/python.nix | 15 +++++++ 5 files changed, 171 insertions(+) create mode 100644 modules/emacs.nix create mode 100644 shells/cc.nix create mode 100644 shells/go.nix create mode 100644 shells/grpc.nix create mode 100644 shells/python.nix diff --git a/modules/emacs.nix b/modules/emacs.nix new file mode 100644 index 0000000..7a5c66a --- /dev/null +++ b/modules/emacs.nix @@ -0,0 +1,112 @@ +# This file is controlled by /etc/dotfiles/README.org +{ pkgs, ... }: + +let + myEmacs = pkgs.emacsWithPackagesFromUsePackage { + config = ../README.org; + package = pkgs.emacsGcc; + alwaysEnsure = true; + alwaysTangle = true; + extraEmacsPackages = epkgs: [ + # Required packages... + epkgs.exwm + epkgs.evil + epkgs.evil-collection + epkgs.evil-surround + epkgs.evil-nerd-commenter + epkgs.general + epkgs.which-key + + # Optional packages. + epkgs.org + epkgs.org-roam + epkgs.org-roam-server + epkgs.org-drill + epkgs.org-pomodoro + epkgs.writegood-mode + epkgs.ox-hugo + epkgs.ox-reveal + epkgs.password-store + epkgs.mu4e-alert + epkgs.dired-single + epkgs.all-the-icons + epkgs.all-the-icons-dired + epkgs.emojify + epkgs.eshell-prompt-extras + epkgs.vterm + epkgs.magit + epkgs.elfeed + epkgs.nix-mode + epkgs.projectile + epkgs.lsp-mode + epkgs.lsp-ui + epkgs.company + epkgs.go-mode + epkgs.pretty-mode + epkgs.plantuml-mode + epkgs.ivy + epkgs.counsel + epkgs.ivy-rich + epkgs.ivy-posframe + epkgs.ivy-prescient + epkgs.doom-themes + epkgs.doom-modeline + ]; + }; + +in { + home.packages = [ + pkgs.arandr + pkgs.autorandr + pkgs.hugo + pkgs.pass + pkgs.mu + pkgs.isync + pkgs.aspell + pkgs.aspellDicts.en + pkgs.aspellDicts.en-science + pkgs.aspellDicts.en-computers + pkgs.plantuml + pkgs.nixfmt + ]; + + programs.emacs = { + enable = true; + package = myEmacs; + }; + + xsession = { + enable = true; + windowManager.command = '' + ${myEmacs}/bin/emacs --daemon -f exwm-enable + ${myEmacs}/bin/emacsclient -c + ''; + }; + home.file.".xinitrc" = { + text = '' + exec ./.xsession + ''; + }; + home.file.".mbsyncrc" = { + text = '' + IMAPStore xyz-remote + Host mail.chrishayward.xyz + User chris@chrishayward.xyz + PassCmd "pass chrishayward.xyz/chris" + SSLType IMAPS + + MaildirStore xyz-local + Path ~/.cache/mail/ + Inbox ~/.cache/mail/inbox + SubFolders Verbatim + + Channel xyz + Far :xyz-remote: + Near :xyz-local: + Patterns * !Archives + Create Both + Expunge Both + SyncState * + ''; + }; +} diff --git a/shells/cc.nix b/shells/cc.nix new file mode 100644 index 0000000..6240e43 --- /dev/null +++ b/shells/cc.nix @@ -0,0 +1,14 @@ +# This file is controlled by /etc/dotfiles/README.org +{ pkgs ? import { } }: + +with pkgs; +mkShell { + buildInputs = [ + ccls + gnumake + libstdcxx5 + gcc-unwrapped + ]; + shellHook = '' + ''; +} diff --git a/shells/go.nix b/shells/go.nix new file mode 100644 index 0000000..704b895 --- /dev/null +++ b/shells/go.nix @@ -0,0 +1,16 @@ +# This file is controlled by /etc/dotfiles/README.org +{ pkgs ? import { } }: + +with pkgs; +mkShell { + buildInputs = [ + go + gopls + protoc-gen-go-grpc + ]; + shellHook = '' + export GO111MODULE=on + export GOPATH=$HOME/.go/ + export PATH=$GOPATH/bin:$PATH + ''; +} diff --git a/shells/grpc.nix b/shells/grpc.nix new file mode 100644 index 0000000..8dcdaf7 --- /dev/null +++ b/shells/grpc.nix @@ -0,0 +1,14 @@ +# This file is controlled by /etc/dotfiles/README.org +{ pkgs ? import { } }: + +with pkgs; +mkShell { + buildInputs = [ + grpc + grpc-tools + grpcui + grpcurl + ]; + shellHook = '' + ''; +} diff --git a/shells/python.nix b/shells/python.nix new file mode 100644 index 0000000..3da8bb7 --- /dev/null +++ b/shells/python.nix @@ -0,0 +1,15 @@ +# This file is controlled by /etc/dotfiles/README.org +{ pkgs ? import { } }: + +with pkgs; +mkShell { + buildInputs = [ + python39Packages.pip + python39Packages.pip-tools + python39Packages.pyls-mypy + python39Packages.pyls-isort + python39Packages.pyls-black + ]; + shellHook = '' + ''; +}