Compare commits

...

3 commits

Author SHA1 Message Date
4723d6b75b hello wireguard 2020-06-14 11:09:48 +02:00
5ef2f3b1c6 add openssl 2020-06-14 11:09:32 +02:00
b8597f51a0 set window title 2020-06-14 11:09:06 +02:00
3 changed files with 16 additions and 2 deletions

View file

@ -18,6 +18,7 @@
./roles/base.nix
./roles/desktop.nix
./roles/wireless.nix
./roles/vpn.nix
];
boot.loader.systemd-boot.enable = true;

View file

@ -14,6 +14,7 @@ in {
htop
jq
ncdu
openssl
ripgrep
z-lua
unstable.starship
@ -38,15 +39,20 @@ in {
eval $(ssh-agent)
fi
pw () {
set_win_title() {
echo -ne "\033]0;$USER@$HOSTNAME: $PWD\007"
}
starship_precmd_user_func=set_win_title
pw() {
len=''${1:-$(( $RANDOM % 24 + 8 ))}
tr -dc a-zA-Z0-9 < /dev/urandom | head -c $len
echo
}
cdg() {
gitroot=$(until [ -d .git ]; do [ "$PWD" == "/" ] && exit 1; cd ..; done; echo $PWD)
if [ $? == 0 ]; then
precmd_user_func = "title"
cd $gitroot
else
echo "gitroot not found."

7
roles/vpn.nix Normal file
View file

@ -0,0 +1,7 @@
{ config, lib, pkgs, ... }:
{
environment.systemPackages = with pkgs; [
wireguard
];
}