Why not run sed and pipe to diff to preview changes?
You’d still have to manually copy out the command line to a notes file, but I don’t think that that’s too terrible. You could use a terminal-integrated snippets palette to make it a little smoother.
I’m not aware of any program that does exactly everything you want it to, so you might write your own or extend an existing one, as mentioned.