Reputation: 243
Dates
=======
Name | Date
-------------------------------------------------
* Battle of the Plains of Abraham | September 13, 1759
* Proclamation Act | October 07, 1763
* Stamp Act | March 22, 1765
* Guy Carleton becomes Governor | April 07, 1766
* Boston Tea Party | December 16, 1773
* Quebec Act |
* Declaration of Independance | <====== # How do I insert this bar character
* Treaty of Paris # along the whole column?
* Constitutional Act
* French Revolution
* War of 1812
I want to be able to insert that bar character without having to manually go and insert it. While this is not syntactically correct, this is supposed to be markdown.
Upvotes: 16
Views: 8835
Reputation: 146053
%s/$/ /
v/|/s/^\(........................................\)/\1|/
%s/ *$//
Some notes:
:
in front of each line if you are in vi's normal visual mode$ ex file < cmds
but in that case add an x
as the fourth lineUpvotes: 4
Reputation: 182619
I'm only a beginner, but here's what I do:
C-v
to enter Visual Block
(Use C-q
on windows)hjkl
)I
Esc
Upvotes: 22