Last active
December 30, 2024 13:26
-
-
Save nejdetckenobi/c8624cb16ef892c6c487f241a35b4a66 to your computer and use it in GitHub Desktop.
Bu `rofi` kullanan bir script. Çalıştırdığında, kategorize ettiğin şifrelerini seçebileceğin ve seçtiğin şifreyi panoya kopyalayan bir menü oluşacak. Önce `rofi` kurmalısın
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| cd ~/.password-store | |
| PASS="$(find -path ./.git -prune -o -type f -printf "%P\n" | grep -v '/\.' | grep -v '^\.' | rofi -dmenu -p 'Choice' | cut -d . -f 1)" | |
| if [[ "$1" == "otp" ]]; then | |
| pass otp show --clip "$PASS" | |
| else | |
| pass show --clip=1 "$PASS" | |
| fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| cd ~/.password-store | |
| CATEGORY="$(ls -1 ~/.password-store | rofi -dmenu -p 'Choice')" | |
| PASS="$(ls -1 ~/.password-store/$CATEGORY | rofi -dmenu -p 'Choice' | cut -d. -f 1)" | |
| TYPE="$(echo -e 'password\notp' | rofi -dmenu -p 'Choice')" | |
| if [[ "$TYPE" == "otp" ]]; then | |
| pass otp show --clip "$CATEGORY/$PASS" | |
| else | |
| pass show --clip=1 "$CATEGORY/$PASS" | |
| fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment