Tagged: vim RSS

  • Tyler 9:36 am on March 16, 2010 Permalink
    Tags: vim   

    Vim Casts 

    http://vimcasts.org/ – So good.

     
  • Tyler 1:17 pm on October 30, 2009 Permalink
    Tags: , , , vim   

    Using MacVim as your git mergetool 

    Install MacVim and the command line tool, mvim.

    Then in your ~/.gitconfig add this, thusly (replacing the path to mvim with the correct one):

    [merge]
    tool = mvim
    [mergetool “mvim”]
    cmd=/Users/tjweir/bin/mvim -d -g $LOCAL $MERGED $REMOTE
    keepbackup=false

    Then you can “git mergetool” all you’d like.

     
  • Tyler 4:47 pm on August 31, 2008 Permalink
    Tags: vim   

    Vim Tips: window splits 

    I use Vim for pretty much everything on every machine I use. Using Vim requires constant learning of all the commands. Sometimes commands that I use get pushed out of my head by newer commands. Such is the case with splits. Here are a few commands that I find useful:

    (You can find all the them here as well.)

    :split – splits the current file into two panes
    :split filename.c – splits the the window into 2 panes, one with filename.c, one with the current file.

    CTRL-W + embiggens the pane by one line
    CTRL-W – deembiggens the pane by one line

    :close – close the current pane
    :only – close all but the current pane

     
  • Tyler 2:12 pm on May 16, 2008 Permalink
    Tags: ctags, , tags, vim   

    Liftweb + ctags + vim 

    [Updated: 2008/12/10]

    This is how I set up /Lift/, ctags, and vim (on OS X and Ubuntu):

    Add some scala definition to ctags:

    ty@Astra:~$ cat /home/ty/.ctags
    --langdef=scala
    --langmap=scala:.scala
    --regex-scala=/^[ \t]*class[ \t]+([a-zA-Z0-9_]+)/\1/c,classes/
    --regex-scala=/^[ \t]*trait[ \t]+([a-zA-Z0-9_]+)/\1/t,traits/
    --regex-scala=/^[ \t]*type[ \t]+([a-zA-Z0-9_]+)/\1/T,types/
    --regex-scala=/^[ \t]*def[ \t]+([a-zA-Z0-9_\?]+)/\1/m,methods/
    --regex-scala=/^[ \t]*val[ \t]+([a-zA-Z0-9_]+)/\1/C,constants/
    --regex-scala=/^[ \t]*var[ \t]+([a-zA-Z0-9_]+)/\1/l,local variables/
    --regex-scala=/^[ \t]*package[ \t]+([a-zA-Z0-9_.]+)/\1/p,packages/
    --regex-scala=/^[ \t]*case class[ \t]+([a-zA-Z0-9_]+)/\1/c,case classes/
    --regex-scala=/^[ \t]*final case class[ \t]+([a-zA-Z0-9_]+)/\1/c,case classes/
    --regex-scala=/^[ \t]*object[ \t]+([a-zA-Z0-9_]+)/\1/o,objects/
    --regex-scala=/^[ \t]*private def[ \t]+([a-zA-Z0-9_]+)/\1/pd,defs/
    

    Build the tags file:

    ty@Astra:~$ /opt/local/bin/ctags -h ".scala" -R --exclude=*.js -f liftags /Users/tjweir/g/clean/liftweb/
    

    I prefer to keep the tags file, in this case liftags, in the root of home. Put it where you want.

    Add the tags location to ~/.vimrc

    set tags=/home/ty/liftags
    

    Now you can open a file and execute

    :tag LiftSession

    and jump to the file.

     
  • Tyler 2:55 pm on April 5, 2008 Permalink
    Tags: vim   

    Presentation on Vim 

    Vim has been my editor of choice for a long time and I try to expand my knowledge of commands all the time. I was particularly impressed with “Vim for PHP Programmers” by Andrei Zmievski.

    It’s well worth a read as a refresher and as an introduction to new commands.

     
  • Tyler 7:28 pm on January 23, 2008 Permalink
    Tags: blogging, vim, vimpress   

    Vim blogging plugin 

    I’ve switched to vimpress as my blogging utility.

    I like it more than the web interface of wordpress. Plus is one more thing that I can do from the comfort of Vim. Beautiful vim.

     
  • Tyler 12:56 pm on November 6, 2007 Permalink
    Tags: GTD, os x, Taskpaper, useful, vim   

    Taskpaper and Vim. 

    Taskpaper is for “…Mac users who want a simpler way to stay organized and get things done. TaskPaper is a simple to-do list that’s surprisingly adept. Unlike the competition, TaskPaper’s text based interface is focused on paper-like simplicity.”

    It’s cool, simple to use and quite useful. What is more useful is the vim plugin that replicates the Taskpaper idea. [Link fixed]

    It’s so good, I bought a copy of Taskpaper.

    P.S. If you’re going to use taskpaper.vim I would highly recommend editing your favourite colourscheme to highlight the taskpaper bits.
    I use vibrantInk and added this:

        hi taskpaperDone guifg=#444444
        hi taskpaperProject guifg=#66FF00
        hi taskpaperTodo gui=NONE guifg=#F0E68C guibg=#FF00FF (Line break)
           cterm=NONE ctermfg=lightyellow ctermbg=lightmagenta
        hi taskpaperListItem guifg=#FF6600
        hi taskpaperContext guifg=#33999
    
     
c
compose new post
j
next post/next comment
k
previous post/previous comment
r
reply
e
edit
o
show/hide comments
t
go to top
l
go to login
h
show/hide help
shift + esc
cancel