You've been typing the wrong commands for years. Linux moved on, and nobody bothered to tell you.
The Ctrl-x-e key sequence provides a quick and easy way to save commands you've recently used on the command line into files.