Skip to content

Commit

Permalink
Version 0.5: Initial upload
Browse files Browse the repository at this point in the history
  • Loading branch information
adam seyfarth authored and vim-scripts committed Oct 18, 2010
0 parents commit 1de699d
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
10 changes: 10 additions & 0 deletions README
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
This is a mirror of http://www.vim.org/scripts/script.php?script_id=10

This macro will add a signature (from
~/.fortunes) to the end of a file.
(preferably an e-mail) This script
was copied from a macro from:
http://www.moolenaar.net which was
made by Bram Moolenaar. I changed it
so it would stick on the sig then
quit.
10 changes: 10 additions & 0 deletions plugin/fortune.vim
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
" ZZ..................Add a fortune and advance to the next one then quit editor
" :sp ~/.fortunes<CR>.open a window on ~/.fortunes
" d/^--/<CR>..........delete until the next line starting with "--"
" Gp..................Go to the end and put the just deleted text there
" :wq<CR>.............Write the ~/.fortunes file and close the window
" GA<CR><Esc>.........go to the end Add an empty line
" p...................put the fortune text
" :x<CR>..............quit the editor

map ZZ :sp ~/.fortunes<CR>d/^--/<CR>Gp:wq<CR>GA<CR><Esc>p:x<CR>

0 comments on commit 1de699d

Please sign in to comment.