#! /usr/bin/zsh FIREFOX=$(enpasscli -vault="$HOME/Documents/Enpass/Vaults/primary" -sort show "Firefox" 2>&1) FIREFOXUN=$(echo "$FIREFOX" | grep -Po "(?<=login: )[^\s]+") FIREFOXPW=$(echo "$FIREFOX" | grep -Po "(?<=pass : ).+(?=\")") firefox "https://ffprofile.com/" read -s -k $'?Press enter when you have downloaded the profile...\n' profile="$(find "$HOME/.mozilla/firefox" -type d -name '*.default-release')" rm -rf "$profile" unzip -o -qq "$HOME/Downloads/profile.zip" -d "$profile" echo "$FIREFOXUN" | xclip -selection clipboard -i setsid "$TERMINAL" -e firefox "https://accounts.firefox.com/signin?context=fx_desktop_v3&entrypoint=fxa_app_menu&action=email&service=sync" & clipnotify echo "$FIREFOXPW" | xclip -selection clipboard -i read -s -k $'?Press enter when you have synced Firefox...\n' echo "" | xclip -selection clipboard -i firefox "https://www.enpass.io/downloads/" "about:preferences#search"