diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2022-04-10 13:08:39 +0200 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2022-04-10 13:08:39 +0200 |
commit | 884063c1969bfc4a70b6ba7b997e7ed134570e6a (patch) | |
tree | 8aa9019cdf85253f9a78be71883c28dcabad2bb7 /.local/bin | |
parent | k (diff) | |
download | dotfiles-bsd-884063c1969bfc4a70b6ba7b997e7ed134570e6a.tar.gz dotfiles-bsd-884063c1969bfc4a70b6ba7b997e7ed134570e6a.tar.bz2 dotfiles-bsd-884063c1969bfc4a70b6ba7b997e7ed134570e6a.tar.xz dotfiles-bsd-884063c1969bfc4a70b6ba7b997e7ed134570e6a.tar.zst dotfiles-bsd-884063c1969bfc4a70b6ba7b997e7ed134570e6a.zip |
Mount scripts rework incoming
Diffstat (limited to '')
-rwxr-xr-x | .local/bin/hddmnt | 12 | ||||
-rwxr-xr-x | .local/bin/hddumnt | 6 |
2 files changed, 11 insertions, 7 deletions
diff --git a/.local/bin/hddmnt b/.local/bin/hddmnt index b2ccf77..8f7a515 100755 --- a/.local/bin/hddmnt +++ b/.local/bin/hddmnt @@ -1,5 +1,9 @@ -#!/usr/local/bin/dash +#!/usr/local/bin/dash -e -geli attach -k /root/geli_keys/hdd_ext.key /dev/da0 && - mkdir -p "$HOME"/hdd && - mount /dev/da0.eli "$HOME"/hdd +tmp=$(mktemp) + +dmenu -p "Enter password: " -nb '#1d2021' -nf '#1d2021' <&- >$tmp +geli attach -k /root/geli_keys/hdd_ext.key -j $tmp /dev/da0 +rm $tmp +mkdir -p "$HOME"/hdd +mount /dev/da0.eli "$HOME"/hdd diff --git a/.local/bin/hddumnt b/.local/bin/hddumnt index decd6d2..548c5bd 100755 --- a/.local/bin/hddumnt +++ b/.local/bin/hddumnt @@ -1,5 +1,5 @@ #!/usr/local/bin/dash -umount /dev/da0.eli && - geli detach da0.eli && - rmdir "$HOME"/hdd +umount /dev/da0.eli +geli detach da0.eli +rmdir "$HOME"/hdd |