dotfiles

My personal shell configs and stuff
git clone git://git.alex.balgavy.eu/dotfiles.git
Log | Files | Refs | Submodules | README | LICENSE

commit bb4263975ffbe42af4737cf953416f345d4e4d29
parent 4dbf16a359e9d94bb41491c7de25e04474f0ee6f
Author: Alex Balgavy <a.balgavy@gmail.com>
Date:   Wed,  5 Jun 2019 17:16:37 +0200

commonprofile: make otp more secure

So that the key isn't stored in history or even shown in the terminal.


Former-commit-id: 62a820919fea8852ca4611bd3b864ab53acb10d1
Diffstat:
Mshell/commonprofile | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/shell/commonprofile b/shell/commonprofile @@ -156,7 +156,7 @@ todos() { if [ -z "$1" ]; then 1="."; fi; grep -rnw "$1" -e "TODO"; } # Fi find_in_files() { grep -rnw "$1" -e "$2"; } # Search for text in files hr() { for ((i=0; i<$(tput cols); i++)); do echo -n "#"; done; echo; } # Insert a <hr> in the terminal vimq() { vim -q <($(fc -nl -1)); } # Load results of last command (often ag) in vim quickfix -otp() { oathtool --totp --base32 "$1"; } # Generate OTP passwords (google authenticator alternative) +otp() { command read -sp "Key: " k && oathtool --totp --base32 "$k"; } # Generate OTP passwords (google authenticator alternative) # Pip3 upgrade packages pip3_upgrade() { pip3 list --outdated | cut -d ' ' -f1 | xargs -n1 pip3 install -U; }