Search posterous

Search all posts and users. Type a name, type a favorite song title, whatever! See what comes up.
  

More posterous blogs











More recommended blogs »

Here are posterous posts filed under vim...

mistercam says...

Here is the contents of my current vimrc file. There's nothing special about it; I posted it here more for backup purposes, in case one day I lose my config file.

" Use Vim settings instead of Vi settings
set nocompatible

" 4 spaces for indenting
set shiftwidth=4

" How wide is a tab?
set tabstop=4

" How many columns to use when hitting tab?
set softtabstop=4

" Uses spaces instead of tabs
set expandtab

" Turn autoindenting on
set autoindent

" Turn on syntax highlighting
syntax on

" Show ruler
set ruler

" When typing a closing bracket, briefly
" highlight the matching opening bracket
set showmatch

" Change the colour scheme
colorscheme darkblue

" GUI Specific Stuff
if has('gui_running')
    " Text Width
    set textwidth=80

    " Width
    set columns=110

    " Height
    set lines=52

    " Use a mouse
    set mousa=a
endif

if has('gui')
    " GUI Options
    " g: grey inactive menu items
    " m: display menu bar
    " r: display right scrollbar
    " b: display bottom scrollbar
    " t: enable tearoff menus
    " T: enable toolbar
    set go=gm
    set guifont=Courier
endif

Filed under: vim

hdknr says...

Vim 7.2-20090321 for Windows (約5.7MB) 21-Mar-2009

7zを利用した自己解凍形式です。ダブルクリックして実行するとvim72-kaoriya-w32jというフォルダを作成し、その中に必要なファイルが展開されます。ファイルにはUNIXでのコンパイルに利用可能なパッチも含まれています。

Windows用Vim最新版でGUI,CUI同梱版です。必要なファイル(シンタックス定義・マクロ・英文マニュアル)が全てまとめてあるので、これ1つをダウンロードして解凍すればすぐにVimを使うことが出来ます。

Filed under: Vim, Windows

hdknr says...

後で読む。

Filed under: Vim

Spike^ekipS says...

VIM is my favorate editor even in Windows. The dream of every text editor, VIM. :)
 
http://feeds.feedburner.com/~r/ajaxian/~3/527167086/becoming-more-productive-with-javascript-and-vim-screencast
 
 
------------------------------
Sent from IPod Touch

Filed under: javascript, vim

fokizaki says...

Inspiron 9 Mini に Ruby on Rails on coLinux on WinXP を準備中。自分用備忘録。
いろいろ先人の知恵を拝借しながら。実にありがたい世の中ですね。
  • coLinux のインストール
WEB+DB Press Vol.40 を参考にしながらインストール。バージョンは 0.7.3。
Debian しか使ったことなかったんですが、今回は Fedora 7 にしてみました。

WLAN にブリッジしようとすると上手くいかないので NAT 接続にしました。
(理由はよくわかんない。気が向いたら調べるwww)

  coLinux 0.7.3
  Fedora 7


[参考]
http://d.hatena.ne.jp/wadap/20080121/1200922697

  パッケージは Debian を使ってますけど、Fedora 7 でもほぼ一緒。

http://scratchpad.fc2web.com/colinux/install/

  ネットワークの設定に困ったら、ここが一番参考になるかと。

http://bloghackers.net/~naoya/webdb40/

  screen とか zsh とか emacs とか。

http://d.hatena.ne.jp/shunsuk/20070909/1189415033

  Vista な方は。

  • MySQLのインストール
とりあえず Fedora 7 の設定を簡単に済ませて、さっそく MySQL をインストール。
MySQL インストール後に設定を済ませる。

  MySQL 5.0.45

ここからは su しといた方が楽。

  % yum install mysql-server ruby-mysql

[参考]
http://fedorasrv.com/mysql.shtml

あと、MySQL AB のサイトなどなど。

  • Ruby on Rails のインストール
まずは Ruby と、その他に必要なものをインストール。

  % yum install ruby rdoc ri rubygems

バージョンはこんなかんじ。

  ruby 1.8.6(patchlevel 114)
  rdoc 1.0.1
  ri 1.0.1
  rubygems 0.9.4


後述しますけど、vim-ruby を有効にして Vim をビルドするときに RDoc を入れてないと
上手くいかないので先に入れとく。

で、rails のインストール。
今回は「Rails によるアジャイル Web アプリケーション開発」に合わせて
バージョンは 1.2 系(1.2.6)に。gem でインストール。rake も入る(はず)。

  % gem install rails -v "=1.2.6"

  rails 1.2.6
  rake 0.8.3

[参考]
http://d.hatena.ne.jp/shunsuk/20070912/1189592518

  vim-ruby について…ですけど、Ruby on Rails on coLiunx の設定としても
とても参考になります。
  • Vim のインストール
ここまでであらかた済んでるんですが、あと Vim の設定だけ。Emacs使えないので…
とりあえず yum で Vim を入れてみる。

  % yum install vim


そんで、Ruby がオンになってるか調べてみると…

 % vim --version | grep ruby

オフってるじゃないか!(「-」が付いてる )なので、
yum で入れた Vim をいったんアンインストール。

 % yum remove vim


vim-enhanced のみアンインストールされる(はず)。
あとは、以下のサイトを参考にして、Vim を Ruby オンにしてビルド + インストール。

http://d.hatena.ne.jp/shunsuk/20070912/1189592518

その前に、必要なものを yum でインストールしておく。

  % yum install gcc make wget ncurses-devel ruby-devel

  % cd /usr/local/src/
  % wget ftp://ftp.vim.org/pub/vim/unix/vim
-7.1.tar.bz2
  % wget ftp://ftp.vim.org/pub/vim/extra/vim
-7.1-extra.tar.gz
  % wget ftp://ftp.vim.org/pub/vim/extra/vim
-7.1-lang.tar.gz
  % tar -jxf vim
-7.1.tar.bz2
  % tar -zxf vim
-7.1-extra.tar.gz
  % tar -zxf vim
-7.1-lang.tar.gz
  % cd vim71

  % ./configure --with-features=huge --enable-multibyte --enable-rubyinterp

  % make

  % make install


RDoc を事前に入れてないと ./configure で error が出るはず。

…ここまででおおよそセッティングできてるはず。
.vimrc とかはググってみればなんとかなる。
お金に余裕があるなら、オライリーの「vi 入門」が参考になるかも。
 
[参考]
http://d.hatena.ne.jp/shunsuk/20070913/1189678147post

  Vim で Rails 開発環境をセッティングするための参考。


つまずきそうなのは coLinux のネットワーク設定と、Vim のビルドかなぁ。


Filed under: colinux, rails, ruby, vim

ajani says...

Often, I find myself wanting to edit a file that is owned by root, and many times in these instances, I already have opened the file in vim for reading. It is rather annoying to have to close the file in vim and run a new vim with sudo in order to edit the file. Thanks to a recent post to the vim-mac mailing list, I found the sudo vim plugin.

Filed under: geek, sudo, vim