1
0
mirror of https://github.com/kmein/niveum synced 2026-03-16 10:11:08 +01:00
~ move ghci dotfile
+ vim: black as python formatter
+ openvpn
+ wpa_supplicant_gui
+ dot2tex
+ graphviz
+ hlint
~ nix-shell: use zsh
~ zsh: show whether in nix-shell
~ ghci: hoogle with haddock links
~ ssh: login with hu id (no passphrase)
~ terminal: Source Code Pro
This commit is contained in:
Kierán Meinhardt
2018-10-31 00:48:32 +01:00
parent 234d624042
commit 93c497961a
8 changed files with 32 additions and 11 deletions

View File

@@ -187,7 +187,7 @@ in {
".config/mpv/input.conf".text = import ./dot/mpv.nix;
".config/xfce4/terminal/terminalrc".text = import ./dot/terminal.nix;
".config/zathura/zathurarc".text = "set selection-clipboard clipboard";
".ghci".text = import ./dot/ghci.nix { inherit pkgs; };
".ghc/ghci.conf".text = import ./dot/ghci.nix { inherit pkgs; };
".ssh/config".text = import ./dot/ssh.nix { inherit lib; };
".stack/config.yaml".text = import ./dot/stack.nix { user = config.constants.user; };
".zshrc".text = "# nothing to see here";

View File

@@ -96,10 +96,11 @@ let vim_conf = ''
autocmd bufnewfile,bufread *.rust :packadd rust-vim deoplete-rust
autocmd bufnewfile,bufread *.tex :packadd vimtex | set filetype=tex
autocmd bufnewfile,bufread *.ts :packadd vim-typescript
autocmd bufnewfile,bufread *.graphql :packadd vim-graphql | set filetype=graphql
autocmd bufnewfile,bufread *.graphql :packadd vim-graphql
autocmd bufnewfile,bufread config set filetype=conf
autocmd filetype haskell :packadd Hoogle
autocmd filetype haskell set formatprg=hindent
autocmd filetype python set formatprg=black
autocmd filetype javascript *.js :packadd vim-javascript
autocmd filetype make setlocal noexpandtab
autocmd filetype markdown,text set formatoptions+=t

View File

@@ -33,4 +33,19 @@ in {
"FlixBus" = {};
"FlixBus Wi-Fi" = {};
};
services.openvpn.servers = {
hu-berlin = {
config = ''config ${pkgs.fetchurl {
url = https://www.cms.hu-berlin.de/de/dl/netze/vpn/openvpn/hu-berlin.ovpn;
sha256 = "d61a644b1e8bd313a8c4bdf1024d8445d56d1fb4a85d2574d597fc020c4901dc";
}}
route-nopull
route 141.20.0.0 255.255.0.0'';
authUserPass = {
username = eduroam.identity;
password = eduroam.password;
};
};
};
}

View File

@@ -59,6 +59,7 @@ with pkgs;
xorg.xbacklight
xorg.xcursorthemes
xorg.xkill
wpa_supplicant_gui
youtubeDL
zathura
];
@@ -75,11 +76,13 @@ with pkgs;
cloc
clojure
ctags
dot2tex
dropbox-cli
fsharp
gcc
ghc
gnuplot
graphviz
grive2
haskellPackages.ghcid
haskellPackages.hakyll
@@ -88,6 +91,7 @@ with pkgs;
haskellPackages.hoogle
haskellPackages.pandoc
haskellPackages.pandoc-citeproc
hlint
idris
inkscape
jo
@@ -101,6 +105,7 @@ with pkgs;
par
perl
python3
python36Packages.black
python36Packages.flake8
racket-minimal
ruby

View File

@@ -5,7 +5,7 @@ in {
let rlwrap = cmd: "${pkgs.rlwrap}/bin/rlwrap ${cmd}";
in {
o = "xdg-open";
n = "nix-shell";
n = "nix-shell --command zsh";
":r" = ''echo "You stupid!"'';
clipboard = "${pkgs.xclip}/bin/xclip -se c";
external-ip = "${pkgs.dnsutils}/bin/dig +short myip.opendns.com @resolver1.opendns.com";
@@ -29,7 +29,7 @@ in {
setopt PUSHD_MINUS PUSHD_TO_HOME AUTO_PUSHD
'';
promptInit = ''
PROMPT="%{$fg_bold[white]%}%~ \$([[ \$? == 0 ]] && echo \"%{$fg_bold[green]%}\" || echo \"%{$fg_bold[red]%}\")%#%{$reset_color%} "
PROMPT="%{$fg_bold[white]%}%~ \$([[ \$? == 0 ]] && echo \"%{$fg_bold[green]%}\" || echo \"%{$fg_bold[red]%}\")\$(test $IN_NIX_SHELL && echo λ || echo %#)%{$reset_color%} "
RPROMPT='$(git_prompt_info)'
ZSH_THEME_GIT_PROMPT_PREFIX="%{$reset_color%}%{$fg[cyan]%}"
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"

View File

@@ -1,9 +1,8 @@
{ pkgs }:
''
:set editor vim
:def hoogle \x -> return $ ":!${pkgs.haskellPackages.hoogle}/bin/hoogle --color \"" ++ x ++ "\" "
:def doc \x -> return $ ":!${pkgs.haskellPackages.hoogle}/bin/hoogle --info --color \"" ++ x ++ "\""
:def search \x -> return $ ":!${pkgs.haskellPackages.hoogle}/bin/hoogle --color \"" ++ x ++ "\" | head"
:def hoogle \s -> return $ ":!${pkgs.haskellPackages.hoogle}/bin/hoogle search --color -l --count=15 \"" ++ s ++ "\""
:def doc \s -> return $ ":!${pkgs.haskellPackages.hoogle}/bin/hoogle search --color -l --info \"" ++ s ++ "\""
:def pl \x -> return $ ":!${pkgs.haskellPackages.pointfree}/bin/pointfree -v \"" ++ x ++ "\""
:def unpl \x -> return $ ":!${pkgs.haskellPackages.pointful}/bin/pointful \"" ++ x ++ "\""
:set prompt "\o033[1m%s\o033[1;34m λ\o033[0m "

View File

@@ -4,6 +4,7 @@ let huServer = name: ''
Host ${name}
User ${(import ../secrets.nix).eduroam.identity}
HostName ${name}.informatik.hu-berlin.de
IdentityFile ~/.ssh/hu
'';
in ''
Host github

View File

@@ -1,10 +1,10 @@
rec {
uiFont = { name = "Roboto"; size = 10; };
terminalFont = {
regular = { name = "Roboto Mono for Powerline"; };
bold = { name = "Roboto Mono Bold for Powerline"; };
italic = { name = "Roboto Mono Italic for Powerline"; };
boldItalic = { name = "Roboto Mono Bold Italic for Powerline"; };
regular = { name = "Source Code Pro for Powerline"; };
bold = { name = "Source Code Pro Bold for Powerline"; };
italic = { name = "Source Code Pro Italic for Powerline"; };
boldItalic = { name = "Source Code Pro Bold Italic for Powerline"; };
size = 10;
};