home

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit d6975cd1b0acb703d1d437d7e87755dc5e2659be
parent 17f164d64b548e309184101bf3f614bb4b7976f0
Author: Vincent Demeester <vincent@sbr.pm>
Date:   Mon,  1 Jun 2020 11:44:36 +0200

systems: enable dev on hokkaido…

… and port some dev h-m modules to users/vincent

Signed-off-by: Vincent Demeester <vincent@sbr.pm>

Diffstat:
Amodules/profiles/assets/lib.mr | 2++
Amodules/profiles/assets/src.github.mr | 2++
Amodules/profiles/assets/src.github.openshift.mr | 2++
Amodules/profiles/assets/src.knative.dev.mr | 2++
Amodules/profiles/assets/src.mr | 2++
Amodules/profiles/assets/src.pkgs.devel.redhat.mr | 2++
Mmodules/profiles/dev.nix | 2--
Msystems/hokkaido.nix | 1+
Musers/vincent/core/default.nix | 11+++++++++++
Musers/vincent/desktop/default.nix | 5+++++
Ausers/vincent/desktop/xorg/capture.desktop | 2++
Ausers/vincent/desktop/xorg/ec.desktop | 2++
Ausers/vincent/desktop/xorg/org-protocol.desktop | 2++
Ausers/vincent/dev/default.nix | 49+++++++++++++++++++++++++++++++++++++++++++++++++
Ausers/vincent/dev/emacs.nix | 143+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Rusers/vincent/desktop/xorg/capture.desktop -> users/vincent/dev/emacs/capture.desktop | 0
Rusers/vincent/desktop/xorg/ec.desktop -> users/vincent/dev/emacs/ec.desktop | 0
Rusers/vincent/desktop/xorg/org-protocol.desktop -> users/vincent/dev/emacs/org-protocol.desktop | 0
Ausers/vincent/dev/go.nix | 37+++++++++++++++++++++++++++++++++++++
Ausers/vincent/dev/mr.nix | 10++++++++++
Rmodules/profiles/assets/lib.mr -> users/vincent/dev/mr/lib.mr | 0
Rmodules/profiles/assets/src.github.mr -> users/vincent/dev/mr/src.github.mr | 0
Rmodules/profiles/assets/src.github.openshift.mr -> users/vincent/dev/mr/src.github.openshift.mr | 0
Rmodules/profiles/assets/src.knative.dev.mr -> users/vincent/dev/mr/src.knative.dev.mr | 0
Rmodules/profiles/assets/src.mr -> users/vincent/dev/mr/src.mr | 0
Rmodules/profiles/assets/src.pkgs.devel.redhat.mr -> users/vincent/dev/mr/src.pkgs.devel.redhat.mr | 0
Ausers/vincent/dev/nix.nix | 16++++++++++++++++
Ausers/vincent/dev/python.nix | 11+++++++++++
28 files changed, 301 insertions(+), 2 deletions(-)

diff --git a/modules/profiles/assets/lib.mr b/modules/profiles/assets/lib.mr @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/mr/lib.mr+ \ No newline at end of file diff --git a/modules/profiles/assets/src.github.mr b/modules/profiles/assets/src.github.mr @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/mr/src.github.mr+ \ No newline at end of file diff --git a/modules/profiles/assets/src.github.openshift.mr b/modules/profiles/assets/src.github.openshift.mr @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/mr/src.github.openshift.mr+ \ No newline at end of file diff --git a/modules/profiles/assets/src.knative.dev.mr b/modules/profiles/assets/src.knative.dev.mr @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/mr/src.knative.dev.mr+ \ No newline at end of file diff --git a/modules/profiles/assets/src.mr b/modules/profiles/assets/src.mr @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/mr/src.mr+ \ No newline at end of file diff --git a/modules/profiles/assets/src.pkgs.devel.redhat.mr b/modules/profiles/assets/src.pkgs.devel.redhat.mr @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/mr/src.pkgs.devel.redhat.mr+ \ No newline at end of file diff --git a/modules/profiles/dev.nix b/modules/profiles/dev.nix @@ -33,8 +33,6 @@ in gnumake jq mercurial - niv - ripgrep shfmt ]; xdg.configFile."nr/dev" = { diff --git a/systems/hokkaido.nix b/systems/hokkaido.nix @@ -37,6 +37,7 @@ in avahi.enable = true; git.enable = true; ssh.enable = true; + dev.enable = true; users.enable = false; users.withMachines = enableHome; mail.enable = enableHome; diff --git a/users/vincent/core/default.nix b/users/vincent/core/default.nix @@ -31,4 +31,15 @@ }; xdg.configFile."nixpkgs/config.nix".text = "{ allowUnfree = true; }"; + xdg.configFile."nr/default" = { + text = builtins.toJSON [ + { cmd = "ncdu"; } + { cmd = "sshfs"; } + { cmd = "lspci"; pkg = "pciutils"; } + { cmd = "lsusb"; pkg = "usbutils"; } + { cmd = "9"; pkg = "plan9port"; } + { cmd = "wakeonlan"; pkg = "python36Packages.wakeonlan"; } + ]; + onChange = "${pkgs.my.nr}/bin/nr default"; + }; } diff --git a/users/vincent/desktop/default.nix b/users/vincent/desktop/default.nix @@ -17,8 +17,13 @@ aspell aspellDicts.en aspellDicts.fr + hunspell + hunspellDicts.en_US-large + hunspellDicts.en_GB-ize + hunspellDicts.fr-any gnome3.defaultIconTheme gnome3.gnome_themes_standard + wmctrl xclip xdg-user-dirs xdg_utils diff --git a/users/vincent/desktop/xorg/capture.desktop b/users/vincent/desktop/xorg/capture.desktop @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/emacs/capture.desktop+ \ No newline at end of file diff --git a/users/vincent/desktop/xorg/ec.desktop b/users/vincent/desktop/xorg/ec.desktop @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/emacs/ec.desktop+ \ No newline at end of file diff --git a/users/vincent/desktop/xorg/org-protocol.desktop b/users/vincent/desktop/xorg/org-protocol.desktop @@ -0,0 +1 @@ +/home/vincent/src/home/users/vincent/dev/emacs/org-protocol.desktop+ \ No newline at end of file diff --git a/users/vincent/dev/default.nix b/users/vincent/dev/default.nix @@ -0,0 +1,49 @@ +{ pkgs, ... }: + +{ + imports = [ + emacs.nix + go.nix + python.nix + mr.nix + nix.nix + ]; + + home.extraOutputsToInstall = [ "doc" "info" "devdoc" ]; + + home.packages = with pkgs; [ + binutils + cmake + fswatch + gnumake + jq + mercurial + shfmt + ]; + + home.file.".ignore".text = '' + *.swp + *~ + **/VENDOR-LICENSE + ''; + + home.file.gdbinit = { + target = ".gdbinit"; + text = '' + set auto-load safe-path / + ''; + }; + + xdg.configFile."nr/dev" = { + text = builtins.toJSON [ + { cmd = "yq"; } + { cmd = "lnav"; } + { cmd = "miniserve"; } + { cmd = "licensor"; } + { cmd = "yamllint"; pkg = "python37Packages.yamllint"; } + { cmd = "http"; pkg = "httpie"; } + ]; + onChange = "${pkgs.my.nr}/bin/nr dev"; + }; + +} diff --git a/users/vincent/dev/emacs.nix b/users/vincent/dev/emacs.nix @@ -0,0 +1,143 @@ +{ config, lib, pkgs, ... }: + +with lib; +let + capture = pkgs.writeScriptBin "capture" '' + #!${pkgs.stdenv.shell} + emacsclient -s /run/user/1000/emacs/org -n -F '((name . "capture") (width . 150) (height . 90))' -e '(org-capture)' + ''; + myEmacs = pkgs.emacs27.override { inherit (pkgs) imagemagick; withXwidgets = true; }; +in +{ + home.file.".local/share/applications/org-protocol.desktop".source = ./emacs/org-protocol.desktop; + home.file.".local/share/applications/ec.desktop".source = ./emacs/ec.desktop; + home.file.".local/share/applications/capture.desktop".source = ./emacs/capture.desktop; + home.packages = with pkgs; [ + ditaa + graphviz + pandoc + zip + # See if I can hide this under an option + capture + ]; + home.sessionVariables = { + EDITOR = "et"; + ALTERNATE_EDITOR = "et"; + }; + programs.emacs = { + enable = true; + package = myEmacs; + extraPackages = epkgs: with epkgs; [ + ace-window + aggressive-indent + async + avy + bbdb + beginend + pkgs.bookmark-plus + company + company-emoji + company-go + dash + delight + dired-collapse + dired-git-info + dired-quick-sort + dired-narrow + dired-rsync + pkgs.dired-plus + direnv + dockerfile-mode + easy-kill + esup + expand-region + flycheck + flycheck-golangci-lint + git-annex + git-commit + gitattributes-mode + gitconfig-mode + gitignore-mode + github-review + goto-last-change + hardhat + helpful + highlight + highlight-indentation + highlight-numbers + ibuffer-vc + icomplete-vertical + iedit + json-mode + markdown-mode + mpdel + multiple-cursors + nixpkgs-fmt + no-littering + ob-async + ob-go + ob-http + orderless + orgit + org-plus-contrib + org-capture-pop-frame + org-gcal + org-ql + org-ref + org-super-agenda + org-web-tools + ox-pandoc + pandoc-mode + projectile + projectile-ripgrep + pdf-tools + python-mode + rainbow-delimiters + rainbow-mode + region-bindings-mode + ripgrep + rg + try + visual-fill-column + visual-regexp + web-mode + wgrep + with-editor + xterm-color + yaml-mode + darkroom + eshell-prompt-extras + esh-autosuggest + forge + go-mode + magit + magit-annex + magit-popup + magit-todos + minions + moody + mwim + nix-buffer + nix-mode + org-super-agenda + org-tree-slide + shr-tag-pre-highlight + ssh-config-mode + smartparens + symbol-overlay + undo-tree + use-package + # Highly experimental + vterm + gotest + ]; + }; + services.emacs-server = { + enable = true; + package = myEmacs; + name = "org"; + shell = pkgs.zsh + "/bin/zsh -i -c"; + # FIXME do this in the derivation :) + extraOptions = "--dump-file=${config.home.homeDirectory}/.config/emacs/emacs.pdmp"; + }; +} diff --git a/users/vincent/desktop/xorg/capture.desktop b/users/vincent/dev/emacs/capture.desktop diff --git a/users/vincent/desktop/xorg/ec.desktop b/users/vincent/dev/emacs/ec.desktop diff --git a/users/vincent/desktop/xorg/org-protocol.desktop b/users/vincent/dev/emacs/org-protocol.desktop diff --git a/users/vincent/dev/go.nix b/users/vincent/dev/go.nix @@ -0,0 +1,37 @@ +{ pkgs, ... }: + +{ + home.sessionVariables = { + GOPATH = "${config.home.homeDirectory}"; + }; + home.packages = with pkgs; [ + gcc + go + godef + golangci-lint + golint + gopkgs + go-outline + go-symbols + delve + goimports + # vendoring tools + dep + # misc + protobuf + my.protobuild + my.ram + my.sec + my.esc + my.yaspell + ]; + xdg.configFile."nr/dev.go" = { + text = builtins.toJSON [ + { cmd = "pprof"; chan = "unstable"; } + { cmd = "vndr"; chan = "unstable"; } + { cmd = "go2nix"; } + { cmd = "dep2nix"; } + ]; + onChange = "${pkgs.my.nr}/bin/nr dev.go"; + }; +} diff --git a/users/vincent/dev/mr.nix b/users/vincent/dev/mr.nix @@ -0,0 +1,10 @@ +{ pkgs, ... }: + +{ + xdg.configFile."mr".source = ./mr/lib.mr; + home.file."src/.mrconfig".source = ./mr/src.mr; + home.file."src/knative.dev/.mrconfig".source = ./mr/src.knative.dev.mr; + home.file."src/github.com/.mrconfig".source = ./mr/src.github.mr; + home.file."src/github.com/openshift/.mrconfig".source = ./mr/src.github.openshift.mr; + home.file."src/pkgs.devel.redhat.com/.mrconfig".source = ./mr/src.pkgs.devel.redhat.mr; +} diff --git a/modules/profiles/assets/lib.mr b/users/vincent/dev/mr/lib.mr diff --git a/modules/profiles/assets/src.github.mr b/users/vincent/dev/mr/src.github.mr diff --git a/modules/profiles/assets/src.github.openshift.mr b/users/vincent/dev/mr/src.github.openshift.mr diff --git a/modules/profiles/assets/src.knative.dev.mr b/users/vincent/dev/mr/src.knative.dev.mr diff --git a/modules/profiles/assets/src.mr b/users/vincent/dev/mr/src.mr diff --git a/modules/profiles/assets/src.pkgs.devel.redhat.mr b/users/vincent/dev/mr/src.pkgs.devel.redhat.mr diff --git a/users/vincent/dev/nix.nix b/users/vincent/dev/nix.nix @@ -0,0 +1,16 @@ +{ pkgs, ... }: + +{ + home.packages = with pkgs; [ + niv + nixpkgs-fmt + ]; + xdg.configFile."nr/dev.nix" = { + text = builtins.toJSON [ + { cmd = "nix-review"; } + { cmd = "nix-prefetch-git"; pkg = "nix-prefetch-scripts"; } + { cmd = "nix-prefetch-hg"; pkg = "nix-prefetch-scripts"; } + ]; + onChange = "${pkgs.my.nr}/bin/nr dev.nix"; + }; +} diff --git a/users/vincent/dev/python.nix b/users/vincent/dev/python.nix @@ -0,0 +1,11 @@ +{ pkgs, ... }: + +{ + home.packages = with pkgs; [ + python3 + python36Packages.virtualenv + python36Packages.pip-tools + python36Packages.tox + pipenv + ]; +}