How do you record a macro that inserts a date stamp?
Answer
qaA <C-r>=strftime('%Y-%m-%d')\n<Esc>jq
Explanation
Record a macro that appends a date stamp using the expression register with strftime(). Moves to the next line for batch processing.
qaA <C-r>=strftime('%Y-%m-%d')\n<Esc>jq
Record a macro that appends a date stamp using the expression register with strftime(). Moves to the next line for batch processing.