A recurrent theme here at Irreal is that you really need to be using a password manager. Let it generate a long, unique, random key for each site and protect those keys with a secure master password (generated by, say, diceware).
Andy Moran used to use LastPass but didn’t like that all his data was stored on a remote sever that he didn’t control. There are lots of password managers that don’t have this problem—I use 1password but there are plenty of others. Moran has posted about one of them, the Pass password manager. Pass is open source and tries to adhere to the Unix philosophy. Basically, every password lives in a GPG-encrypted file named for the resource it’s protecting. The files can be manipulated with the usual Unix tools and except for being encrypted are plain text.
Moran’s post walks you through installing and setting the utility up. He also shows some examples of its use. If you’re looking for a good password manager that you control and that you can sync with Git, take a look at Moran’s post. I’m very happy with 1password but if I weren’t or if I become unhappy in the future, I would certainly give Pass a try.