Language:
Vim/Viminfo file     Change language:
Pastebin: 132679
Author: Intrepid {somian}
Subject: Re[final]: Function for date stamp
Created: 2010-02-08 21:45:36
Download and save
Toggle line numbers
1 " outputs as appended text, for example:  02/09/2010 02:44 UTC 
2func! GimmeADate() 
3    let utilpath = '/bin/' 
4    let SPECIALCHARS = 1 
5    let DS = substitute( system( utilpath .'date' ." -u " 
6           \ .'+'. shellescape('%A %m/%d/%Y %R UTC', SPECIALCHARS)) 
7           \ , '[\]\|[^[:cntrl:]]', '', 'g') 
8    exec 'normal A'.DS 
9  " As a Bash func this could be: 
10  " date -u '+%A %m/%d/%Y %R UTC'|xclip -sel cl -i 
11endfu 
12 
Thread:
[132670] Function for date stamp by Intrepid {somian} at 2010-02-08 20:03:07 (diff)
  [132677] Re: Function for date stamp by Intrepid {somian} at 2010-02-08 21:26:13 (diff)
    [132679] Re[final]: Function for date stamp by Intrepid {somian} at 2010-02-08 21:45:36
      [132680] Re: Re[final]: Function for date stamp by Intrepid {somian} at 2010-02-08 21:46:23 (diff)
Tip: Click the line numbers to toggle highliting on that line.

Paste followup:

Language:
Author:
Subject:


    Tabstop:     bigger biggest
Note: You can prefix a line with "@@@" to highlight it.