mattydebie / bitwarden-rofi

Wrapper for Bitwarden https://github.com/bitwarden/cli and Rofi
GNU General Public License v3.0
346 stars 56 forks source link

Improved error handling. #49

Closed Kestrer closed 1 year ago

Kestrer commented 4 years ago

This PR improved the implementation of ask_password by using bw --raw, which makes parsing the output unnecessary as it just gives us the raw data

I also use bw --nointeraction in some places which prevents bw from attempting to read the username and password from stdin.

I added more useful error messages that give the reason for the error (which comes from bw), and now when load_items fails the password storage will be cleared. This is so that users can't get caught in a situation like I did with an invalid BW_HASH but with no way to fix it.

mattydebie commented 1 year ago

Thanks! merged in 43dbb33e97d6