-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit_bundle.rb
More file actions
35 lines (30 loc) · 1.06 KB
/
init_bundle.rb
File metadata and controls
35 lines (30 loc) · 1.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
git_bundles = [
"git://github.com/msanders/snipmate.vim.git",
"git://github.com/scrooloose/nerdtree.git",
"git://github.com/timcharper/textile.vim.git",
"git://github.com/tpope/vim-fugitive.git",
"git://github.com/tpope/vim-haml.git",
"git://github.com/tpope/vim-markdown.git",
"git://github.com/tpope/vim-rails.git",
"git://github.com/tpope/vim-repeat.git",
"git://github.com/tpope/vim-surround.git",
"git://github.com/tpope/vim-vividchalk.git",
"git://github.com/tsaleh/vim-align.git",
"git://github.com/tsaleh/vim-supertab.git",
"git://github.com/tsaleh/vim-tcomment.git",
"git://github.com/vim-ruby/vim-ruby.git",
"git://github.com/vim-scripts/peaksea.git",
]
require 'fileutils'
require 'open-uri'
`git init`
`git add .`
`git commit -am "Initial commit."`
bundles_dir = File.join(File.dirname(__FILE__), "bundle")
git_bundles.each do |url|
dir = File.join bundles_dir, url.split('/').last.sub(/\.git$/, '')
puts " Unpacking #{url} into #{dir}"
`git submodule add #{url} #{dir}`
`git add .`
`git commit -m "Install submodule #{url}."`
end