summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbin/extra/aivpn30
-rwxr-xr-xbin/menuscripts/mpass-otp2
-rw-r--r--config/essentials/shell/aliases.sh3
-rw-r--r--config/essentials/shell/functions.sh11
-rw-r--r--config/essentials/zsh/.zshrc2
-rw-r--r--config/wayland/gammastep/config.ini2
6 files changed, 37 insertions, 13 deletions
diff --git a/bin/extra/aivpn b/bin/extra/aivpn
new file mode 100755
index 0000000..841d926
--- /dev/null
+++ b/bin/extra/aivpn
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+err() { printf "%s\n" "$@"; }
+
+if [ "$1" = "-k" ]
+then
+ pgrep -f -- "ssh.*-L.*vm" | xargs kill
+ exit
+fi
+
+err "I: Waiting for connectivity..."
+while ! ssh -o ConnectTimeout=1 -o BatchMode=yes vm 2>&1 | grep "Permission denied" > /dev/null
+do sleep 1
+done
+
+
+export SSH_ASKPASS="sshpass"
+export SSH_ASKPASS_REQUIRE="prefer"
+export PASSWORD="zot/quickemu"
+
+err "I: Activating vpn"
+ssh vm "rasdial \"vpn.student.ehb.be\""
+
+keyadd ehb/ai
+ssh -f -N -L 2222:10.2.160.41:22 vm
+
+keyadd ehb/vm_int
+ssh -f -N -L 2223:10.2.160.9:22 vm
+ssh -f -N -L 2224:10.2.160.10:22 vm
+ssh -f -N -L 2225:10.2.160.11:22 vm
diff --git a/bin/menuscripts/mpass-otp b/bin/menuscripts/mpass-otp
index 52d1341..2be6186 100755
--- a/bin/menuscripts/mpass-otp
+++ b/bin/menuscripts/mpass-otp
@@ -1,7 +1,7 @@
#!/bin/sh
pass="$(find "$PASSWORD_STORE_DIR"/keys/otp -iname "*.gpg" |
sed "/^\./d;s#^$PASSWORD_STORE_DIR/keys/otp/##;s/\.gpg$//" |
- commander -c)"
+ dmenu -c)"
[ "$pass" ] || exit 1
pass otp -c keys/otp/"$pass"
notify-send -t 1000 "mpass" "copied $pass"
diff --git a/config/essentials/shell/aliases.sh b/config/essentials/shell/aliases.sh
index de441a5..44aa7bc 100644
--- a/config/essentials/shell/aliases.sh
+++ b/config/essentials/shell/aliases.sh
@@ -53,7 +53,8 @@ alias pf='profanity'
alias f='fg'
-alias gurk='pgrep gurk > /dev/null && printf "Already Running.\n" || gurk'
+which gurk > /dev/null 2>&1 &&
+ alias gurk='pgrep gurk > /dev/null && printf "Already Running.\n" || gurk'
alias arduino-cli='arduino-cli --config-file $XDG_CONFIG_HOME/arduino15/arduino-cli.yaml'
diff --git a/config/essentials/shell/functions.sh b/config/essentials/shell/functions.sh
index 1eca57c..3676f26 100644
--- a/config/essentials/shell/functions.sh
+++ b/config/essentials/shell/functions.sh
@@ -317,17 +317,10 @@ serve() {
if [ "$1" ]
then
logn "Serving $1"
- docker container run \
- --rm \
- --volume "$(readlink -f "$1")":/data \
- --publish 80:5000 sigoden/dufs /data
+ dufs "$1"
else
-
logn "Receiving files.."
- docker container run \
- --rm \
- --volume /tmp/data:/data \
- --publish 80:5000 sigoden/dufs /data --allow-upload
+ dufs /tmp/data --alow-upload
fi
}
diff --git a/config/essentials/zsh/.zshrc b/config/essentials/zsh/.zshrc
index 91a1618..6e28602 100644
--- a/config/essentials/zsh/.zshrc
+++ b/config/essentials/zsh/.zshrc
@@ -31,7 +31,7 @@ eval "$(zoxide init zsh)"
### Plugins
[ -f "$HOME/.local/share/zap/zap.zsh" ] && source "$HOME/.local/share/zap/zap.zsh"
-plug "MichaelAquilina/zsh-you-should-use"
+# plug "MichaelAquilina/zsh-you-should-use"
plug "chivalryq/git-alias"
plug "kutsan/zsh-system-clipboard"
# plug "marlonrichert/zsh-autocomplete"
diff --git a/config/wayland/gammastep/config.ini b/config/wayland/gammastep/config.ini
index 3a80417..e0699ac 100644
--- a/config/wayland/gammastep/config.ini
+++ b/config/wayland/gammastep/config.ini
@@ -1,7 +1,7 @@
[general]
fade=0
location-provider=manual
-adjustment-method=wayland
+# adjustment-method=wayland
gamma=0.8
temp-day=5700
temp-night=3600