vimmy 0.0.2 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Gemfile.lock +1 -1
- data/lib/vimmy/cli.rb +11 -1
- data/lib/vimmy/version.rb +1 -1
- metadata +2 -2
data/Gemfile.lock
CHANGED
data/lib/vimmy/cli.rb
CHANGED
@@ -28,6 +28,15 @@ class Vimmy::CLI < Thor
|
|
28
28
|
url = choose(matching(term), "Choose a plugin to install")
|
29
29
|
end
|
30
30
|
|
31
|
+
desc "update", "Update all vim plugins"
|
32
|
+
|
33
|
+
def update
|
34
|
+
Dir[File.expand_path("~/.vim/bundle/*")].each do |plugin|
|
35
|
+
puts "Updating: #{plugin}"
|
36
|
+
system "cd #{plugin} && git pull"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
31
40
|
private ######################################################################
|
32
41
|
|
33
42
|
def backup(file)
|
@@ -47,7 +56,7 @@ private ######################################################################
|
|
47
56
|
print "#{prompt}: "
|
48
57
|
|
49
58
|
if (index = STDIN.gets.to_i) > 0
|
50
|
-
return unless plugin = sort(plugins)[index-1]
|
59
|
+
return unless plugin = sort(plugins)[index-1]
|
51
60
|
install_plugin plugin.first
|
52
61
|
end
|
53
62
|
end
|
@@ -64,6 +73,7 @@ private ######################################################################
|
|
64
73
|
end
|
65
74
|
|
66
75
|
def install_plugin(url)
|
76
|
+
puts "Installing: #{url}"
|
67
77
|
system %{ cd ~/.vim/bundle && git clone #{url}.git }
|
68
78
|
end
|
69
79
|
|
data/lib/vimmy/version.rb
CHANGED