I have a script that functions very similarly, called `jot`[1].
I also have one for rapid steam-of-conscious thoughts[2] and organized journaling[3].
Personally, I'm a fan of the "plaintext files in a directory" pattern for notes, thoughts, and writing.
[1]: https://github.com/Pinjasaur/jot