Browse Source

vim: F8 now gets a simpler datestamp, ,F8 for more precision

Brennen Bearnes 2 months ago
parent
commit
9f6fd7249a
1 changed files with 5 additions and 3 deletions
  1. 5
    3
      home/.vimrc

+ 5
- 3
home/.vimrc View File

@@ -511,10 +511,12 @@ let mapleader = ","
511 511
   imap <F7> <Esc><F7>
512 512
   amenu Cheatsheet.Open\ \.vimrc<Tab>F7 <F7>
513 513
 
514
-  " F8 inserts a datestamp (eight rhymes with date)
514
+  " F8 inserts an ISO-8601 datestamp (eight rhymes with date)
515 515
   " (used to open the options window; use :options for that)
516
-  " map <F8> :r! date -Is<CR> " iso-8601
517
-  map <F8> :r! date -Is<CR>kJ
516
+  map <F8> :r !date -I<CR>kJ
517
+  " ,F8 inserts a date with seconds precision
518
+  map <Leader><F8> :r !date -Is<CR>kJ
519
+
518 520
   imap <F8> <Esc><F8>
519 521
   amenu Cheatsheet.Insert\ Datestamp<Tab>F8 <F8>
520 522
 

Loading…
Cancel
Save