Yesterday I decided to encrypt my diary since it has some info that is private. My diary was a plain text doc called diary
. There was no file called d
so I did the following:
$ vi -x d
Enter password: **********
Repeat password: **********
:r diary
:wq
$ vi d
Enter password: **********
:set cm=blowfish2
:wq
$ mv d diary
All seemed fine, but today I tried vi diary
and entered the same password, and I get garbage. What in the world could have happened?!
I doubt I could have mistyped my intended password 3 times (see above). But perhaps I did... so I ran a script (https://gist.github.com/lnolte/4135705) that generated about 65 perturbations of my password in case I somehow mistyped it. Then I tried all of these variants with a script I wrote, but nothing worked. I also tried renaming diary
back to d
to see if the filename itself somehow mattered.
I know that the above sequence of commands is really what I typed because they are still in my bash history. What else could be wrong?! Perhaps the file is corrupted, but that's hard to imagine.
VIM - Vi IMproved 8.0 (2016 Sep 12, compiled Nov 29 2017 18:37:46)
Mac OS X