Things
This commit is contained in:
parent
aa7650e975
commit
7d02c94366
13 changed files with 117 additions and 10 deletions
|
@ -160,6 +160,7 @@
|
|||
profiles = digga.lib.rakeLeaves ./users/profiles;
|
||||
suites = with profiles; rec {
|
||||
base = [ direnv git zsh gpg password-store ];
|
||||
emails = [ mails ];
|
||||
shell = [ zsh exa fzf ];
|
||||
gui = [ sway xdg gtk foot bat ];
|
||||
browser = [ firefox chromium qutebrowser ];
|
||||
|
|
|
@ -21,7 +21,7 @@ channels: final: prev: {
|
|||
in
|
||||
{
|
||||
# same for haskell packages, matching ghc versions
|
||||
inherit (channels.latest.haskell.packages."ghc${version}")
|
||||
inherit (channels.unstable.haskell.packages."ghc${version}")
|
||||
haskell-language-server;
|
||||
});
|
||||
});
|
||||
|
|
|
@ -16,11 +16,13 @@ emacsWithPackages (
|
|||
evil-collection
|
||||
fira-code-mode
|
||||
haskell-mode
|
||||
notmuch
|
||||
helm
|
||||
helm-ag
|
||||
helm-company
|
||||
helm-projectile
|
||||
lispy
|
||||
lsp-haskell
|
||||
lsp-mode
|
||||
lsp-python-ms
|
||||
magit
|
||||
|
@ -31,6 +33,7 @@ emacsWithPackages (
|
|||
org-superstar
|
||||
projectile
|
||||
rainbow-delimiters
|
||||
rainbow-identifiers
|
||||
sudo-utils
|
||||
treemacs
|
||||
treemacs-evil
|
||||
|
|
10
profiles/cachix/haskell.nix
Normal file
10
profiles/cachix/haskell.nix
Normal file
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
nix = {
|
||||
binaryCaches = [
|
||||
"https://hydra.iohk.io"
|
||||
];
|
||||
binaryCachePublicKeys = [
|
||||
"hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ="
|
||||
];
|
||||
};
|
||||
}
|
|
@ -1,7 +1,7 @@
|
|||
{ pkgs, suites, lib, ... }:
|
||||
{
|
||||
home-manager.users.ccr = { suites, ... }: {
|
||||
imports = with suites; shell ++ gui ++ browser ++ multimedia ++ dev ++ base;
|
||||
imports = with suites; shell ++ gui ++ browser ++ multimedia ++ emails ++ dev ++ base;
|
||||
home.packages = with pkgs; [
|
||||
ack
|
||||
ranger
|
||||
|
@ -20,7 +20,7 @@
|
|||
|
||||
users.users.ccr = {
|
||||
uid = 1000;
|
||||
hashedPassword = "$6$JGOefuRk7kL$fK9.5DFnLLoW08GL4eKRyf958jyZdw//hLMaz4pp28jJuSFb24H6R3dgt1.sMs0huPY85rludSw4dnQJG5xSw1"; #mkpasswd -m sha-512
|
||||
hashedPassword = "$6$JGOefuRk7kL$fK9.5DFnLLoW08GL4eKRyf958jyZdw//hLMaz4pp28jJuSFb24H6R3dgt1.sMs0huPY85rludSw4dnQJG5xSw1"; # mkpasswd -m sha-512
|
||||
description = "Andrea Ciceri";
|
||||
isNormalUser = true;
|
||||
extraGroups = [
|
||||
|
|
|
@ -23,6 +23,8 @@
|
|||
ag
|
||||
nixpkgs-fmt
|
||||
rnix-lsp
|
||||
haskell-language-server
|
||||
stylish-haskell
|
||||
graphviz-nox
|
||||
hunspell
|
||||
hunspellDicts.en_US
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
)
|
||||
|
||||
(use-package fira-code-mode
|
||||
:custom (fira-code-mode-disabled-ligatures '()) ;; List of ligatures to turn off
|
||||
:custom (fira-code-mode-disabled-ligatures '("x")) ;; List of ligatures to turn off
|
||||
:config
|
||||
(fira-code-mode-set-font)
|
||||
(global-fira-code-mode))
|
||||
|
@ -31,6 +31,9 @@
|
|||
|
||||
(use-package minimap)
|
||||
|
||||
(use-package rainbow-identifiers
|
||||
:hook ((prog-mode . rainbow-identifiers-mode)))
|
||||
|
||||
;; To move in a different config file
|
||||
(when (string-equal system-type "darwin")
|
||||
(setq mac-command-modifier 'ctrl))
|
||||
|
|
23
users/profiles/emacs/emacs.d/config/config-emails.el
Normal file
23
users/profiles/emacs/emacs.d/config/config-emails.el
Normal file
|
@ -0,0 +1,23 @@
|
|||
(use-package notmuch
|
||||
:custom
|
||||
(notmuch-archive-tags '("-unread"))
|
||||
(notmuch-show-indent-content nil)
|
||||
(notmuch-hello-sections
|
||||
'(notmuch-hello-insert-header
|
||||
notmuch-hello-insert-saved-searches
|
||||
notmuch-hello-insert-search
|
||||
notmuch-hello-insert-alltags
|
||||
notmuch-hello-insert-recent-searches
|
||||
notmuch-hello-insert-footer
|
||||
))
|
||||
(notmuch-tagging-keys
|
||||
'(("a" notmuch-archive-tags "Archive")
|
||||
("u" notmuch-show-
|
||||
mark-read-tags "Mark read")
|
||||
("m" ("+muted") "Mute")
|
||||
("f" ("+flagged") "Flag")
|
||||
("s" ("+spam" "-inbox") "Mark as spam")
|
||||
("d" ("+deleted" "-inbox") "Delete")))
|
||||
)
|
||||
|
||||
(provide 'config-emails)
|
|
@ -2,9 +2,12 @@
|
|||
:init
|
||||
;; set prefix for lsp-command-keymap (few alternatives - "C-l", "C-c l")
|
||||
(setq lsp-keymap-prefix "C-c l")
|
||||
:custom
|
||||
(lsp-haskell-server-path "haskell-language-server-wrapper")
|
||||
:hook (;; replace XXX-mode with concrete major-mode(e. g. python-mode)
|
||||
(nix-mode . lsp)
|
||||
(python-mode . lsp)
|
||||
(haskell-mode . lsp)
|
||||
;; if you want which-key integration
|
||||
(lsp-mode . lsp-enable-which-key-integration))
|
||||
:commands lsp)
|
||||
|
|
|
@ -16,6 +16,7 @@ Return nil if COMMAND is not found anywhere in `exec-path'."
|
|||
(require 'config-evil)
|
||||
(require 'config-helm)
|
||||
(require 'config-org)
|
||||
(require 'config-emails)
|
||||
(require 'config-projectile)
|
||||
(require 'config-company)
|
||||
(require 'config-magit)
|
||||
|
|
45
users/profiles/mails/default.nix
Normal file
45
users/profiles/mails/default.nix
Normal file
|
@ -0,0 +1,45 @@
|
|||
{ pkgs, lib, ... }:
|
||||
let
|
||||
maildir = "mail";
|
||||
in
|
||||
{
|
||||
programs.msmtp.enable = true; # For sending emails
|
||||
|
||||
# For fetching emails
|
||||
accounts.email.maildirBasePath = maildir;
|
||||
programs.mbsync = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
# For email browsing, tagging, and searching
|
||||
programs.notmuch.enable = true;
|
||||
|
||||
accounts.email.accounts = {
|
||||
personal = {
|
||||
address = "andrea.ciceri@autistici.org";
|
||||
#gpg = {
|
||||
# key = "";
|
||||
# signByDefault = true;
|
||||
#};
|
||||
imap.host = "mail.autistici.org";
|
||||
mbsync = {
|
||||
enable = true;
|
||||
create = "maildir";
|
||||
};
|
||||
msmtp.enable = true;
|
||||
notmuch.enable = true;
|
||||
primary = true;
|
||||
realName = "Andrea Ciceri";
|
||||
#signature = {
|
||||
# text = ''
|
||||
# '';
|
||||
# showSignature = "append";
|
||||
#};
|
||||
passwordCommand = "pass show autistici/password";
|
||||
smtp = {
|
||||
host = "smtp.autistici.org";
|
||||
};
|
||||
userName = "andrea.ciceri@autistici.org";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -47,10 +47,19 @@
|
|||
xkb_variant = "intl";
|
||||
};
|
||||
};
|
||||
keybindings = lib.mkOptionDefault {
|
||||
keybindings =
|
||||
let
|
||||
screenshotScript = pkgs.writeShellScript "screenshot.sh" ''
|
||||
filename="~/shots/$(date --iso-8601=seconds).png"
|
||||
coords="$(${pkgs.slurp}/bin/slurp)"
|
||||
${pkgs.grim}/bin/grim -t png -g "$coords" $filename
|
||||
wl-copy -t image/png < $filename
|
||||
'';
|
||||
in
|
||||
lib.mkOptionDefault {
|
||||
"${modifier}+x" = "exec ${pkgs.customEmacs}/bin/emacs";
|
||||
"${modifier}+b" = "exec ${pkgs.firefox}/bin/firefox";
|
||||
"${modifier}+s" = "exec \'file=\"~/shots/\$(date --iso-8601=seconds).png\"; ${pkgs.grim}/bin/grim -t png -g \"\$(${pkgs.slurp}/bin/slurp)\" \$file; wl-copy -t image/png < \$file\'";
|
||||
"${modifier}+s" = "exec ${screenshotScript}";
|
||||
};
|
||||
};
|
||||
extraConfig = ''
|
||||
|
@ -77,7 +86,6 @@
|
|||
];
|
||||
modules-center = [ "sway/window" ];
|
||||
modules-right = [
|
||||
"idle_inhibitor"
|
||||
"tray"
|
||||
"network"
|
||||
"cpu"
|
||||
|
|
|
@ -18,6 +18,14 @@
|
|||
extensions = with pkgs.vscode-extensions; [
|
||||
eamodio.gitlens
|
||||
jnoortheen.nix-ide
|
||||
haskell.haskell
|
||||
justusadam.language-haskell
|
||||
];
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
haskell-language-server
|
||||
stylish-haskell
|
||||
ghc
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue