Live data from Hacker News

Steve Losh's .vimrc

bitbucket.org

31–40 of 103 posts

Re: Steve Losh's .vimrc

#32

Earlier quoted context omitted.

Actually I'm planning on splicing it into MakeGreen, so instead of getting a green bar when my tests pass I get Nyan Cat flying across my window. Maybe over Thanksgiving weekend I'll get around to it. Edit: Also, if anyone can show me how to draw an ASCII-art Nyan Cat in one line of text that would be awesome. Nothing I tried looked recognizable.

This plugin[0] apparently plays an ascii version 'bad apple' music video. Inside vim. Go figure. [0] http://www.vim.org/scripts/script.php?script_id=3477

1.9 MB compressed...

Re: Steve Losh's .vimrc

#33
post #22

That's one thing that worries me about using vim full-time: if I become reliant on a .vimrc or a set of plugins to use vim effectively, but I'm on a computer that doesn't have my .vimrc on it, I'm doomed.

On all my machines ~/.vimrc and friends are symlinked out from my Dropbox folder.

This is what I do as well. To make thinks simpler, I use this script to automatically create the symlinks (if they are not already existant). If you put it in your `.zshrc`, you can run the command `dropbox-update-dotfiles` to make or update the symlinks. Not that this makes use of `zsh` extensions, so it requires adaptation to use with bash.

  dropbox-update-dotfiles () {
    src="$HOME/Dropbox/dotfiles"
    dst="$HOME"
  
    if [[ ! -d "$src" ]]; then
      print "Directory $src not found."
    fi
  
    for f in "$src"/*~*(.swp|~|.pyc)(D); do
      if [[ -h "$dst/${f:t}" ]]; then
        # exists as symlink
      elif [[ -e "$dst/${f:t}" ]]; then
        print "WARNING: ${f:t} exists, but is not a symlink."
      else
        ln -sv "$f" "$dst"
      fi
    done
  }

Re: Steve Losh's .vimrc

#34
post #13

function! NyanMe() " {{{ ... I very much hope that's just there as an easter egg for those of us who read to the bottom.

Actually I'm planning on splicing it into MakeGreen, so instead of getting a green bar when my tests pass I get Nyan Cat flying across my window. Maybe over Thanksgiving weekend I'll get around to it. Edit: Also, if anyone can show me how to draw an ASCII-art Nyan Cat in one line of text that would be awesome. Nothing I tried looked recognizable.

how bout 2 lines? http://jsfiddle.net/MHj9N/

Re: Steve Losh's .vimrc

#35

That's one thing that worries me about using vim full-time: if I become reliant on a .vimrc or a set of plugins to use vim effectively, but I'm on a computer that doesn't have my .vimrc on it, I'm doomed.

On foreign machines I'm rarely doing anything complicated enough where not having my .vimrc is noticeable. If I'm going to be spending a lot of time working on something, then it isn't a problem to either use my local machine or sshfs the remote server and work on it from my local editor.

I try and keep my .vimrc limited to configuration and enhancement and not change how the core works. Things like rebinding builtin actions will never be seen in my .vimrc.

Re: Steve Losh's .vimrc

#38
post #22

Earlier quoted context omitted.

On all my machines ~/.vimrc and friends are symlinked out from my Dropbox folder.

This is what I do as well. To make thinks simpler, I use this script to automatically create the symlinks (if they are not already existant). If you put it in your `.zshrc`, you can run the command `dropbox-update-dotfiles` to make or update the symlinks. Not that this makes use of `zsh` extensions, so it requires adaptation to use with bash. dropbox-update-dotfiles () { src="$HOME/Dropbox/dotfiles" dst="$HOME" if [[…

I use zsh too, but did something similar that should also work in bash: http://naleid.com/blog/2011/10/03/using-dropbox-to-share-you...

I link my dot files as well as Documents, Pictures, Music, and Desktop directories that are also normally controlled by OSX. Having those shared across multiple computers is awesome. Sit down at a computer, and it's there.

I also have my zsh files checked in to bitbucket (https://bitbucket.org/tednaleid/shared-zshrc/) so even if the computer doesn't have dropbox (like many of the linux servers I have access to), as long as it has mercurial, I can clone the repo and be ready to go.

Re: Steve Losh's .vimrc

#39

That's one thing that worries me about using vim full-time: if I become reliant on a .vimrc or a set of plugins to use vim effectively, but I'm on a computer that doesn't have my .vimrc on it, I'm doomed.

echo set ts=3 > ~/.vimrc echo "Toggle search highlighting on and off with F5 >> ~/.vimrc echo map " : set hls\!set hsl?" >> ~/.vimrc

Everything else is gravy for me. While an extended rc is handy and I often store one where I can get to it, if I'm just editing a couple of files, vanilla + the tab size I want and a shortcut to highlighting search terms gets me going. YMMV

I tried to get into emacs, but I kept coming back to vim. Probably because the first editor I really used was a version of 'ed' back when I played MUDs.

Post reply on HN