-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathupdate
executable file
·59 lines (51 loc) · 3.54 KB
/
update
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#!/usr/bin/env ruby
require 'open-uri'
TIME = Time.now
CONF = File.dirname(__FILE__) + '/.emacs.d/'
def download_file(url, name = nil)
fname = name || url.split("/").last
File.open(CONF + "vendor/#{fname}", 'w') { |f| f.write(open(url).read) }
end
def update(pkg, url)
print "-> #{pkg} update..."
result = download_file(url) rescue nil # to be improved
puts result ? 'OK' : 'FAIL!'
end
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
update 'Moz.el', 'http://download-mirror.savannah.gnu.org/releases/espresso/moz.el'
update 'Textile', 'https://github.com/emacsmirror/textile-mode/raw/master/textile-mode.el'
update 'Cheat.el', 'https://github.com/samsonjs/cheat.el/raw/master/cheat.el'
update 'Markdown', 'https://github.com/defunkt/markdown-mode/raw/master/markdown-mode.el'
update 'Cucumber', 'https://github.com/michaelklishin/cucumber.el/raw/master/feature-mode.el'
# update 'Textmate.el', 'https://github.com/defunkt/textmate.el/raw/master/textmate.el'
update 'CoffeeScript', 'https://github.com/nofxx/coffee-mode/raw/master/coffee-mode.el'
update 'Recursive Find', 'https://github.com/nealford/emacs/raw/master/find-recursive.el'
update 'howdoi', 'https://raw.githubusercontent.com/arthurnn/howdoi-emacs/master/howdoi.el'
# update 'Gist', 'https://github.com/defunkt/gist.el/raw/master/gist.el'
# Ruby
# update 'Ruby Mode', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/ruby-mode.el'
update 'Ruby Electric', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/ruby-electric.el'
update 'Ruby Style', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/ruby-style.el'
update 'Ruby Tools', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/ruby-electric.el'
update 'Ruby Rdoc', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/rdoc-mode.el'
update 'Ruby Inf', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/inf-ruby.el'
update 'Ruby db3x', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/rubydb3x.el'
update 'Ruby Add', 'https://raw.githubusercontent.com/ruby/ruby/trunk/misc/ruby-additional.el'
update 'Ruby Hash', 'https://raw.githubusercontent.com/purcell/ruby-hash-syntax/master/ruby-hash-syntax.el'
# update 'Rubocop', 'https://raw.githubusercontent.com/bbatsov/rubocop-emacs/master/rubocop.el'
# WEB
update 'HTML', 'https://raw.githubusercontent.com/fxbois/web-mode/master/web-mode.el'
update 'YAML', 'https://github.com/yoshiki/yaml-mode/raw/master/yaml-mode.el'
update 'Rspec Mode', 'https://github.com/pezra/rspec-mode/raw/master/rspec-mode.el'
update 'SLIM Mode', 'https://raw.github.com/slim-template/emacs-slim/master/slim-mode.el'
update 'HAML Mode', 'https://github.com/nex3/haml-mode/raw/master/haml-mode.el'
update 'SASS Mode', 'https://github.com/nex3/sass-mode/raw/master/sass-mode.el'
update 'SCSS Mode', 'https://github.com/antonj/scss-mode/raw/master/scss-mode.el'
# update 'Findr.el', 'http://www.emacswiki.org/emacs/download/findr.el'
update 'Yasnippet', 'https://raw.githubusercontent.com/capitaomorte/yasnippet/master/yasnippet.el'
# update 'Lua', 'http://luaforge.net/frs/download.php/4628/lua-mode.el'
# update 'Perspective', 'https://raw.github.com/leathekd/perspective-el/master/perspective.el'
#update 'CSS Mode', 'http://www.emacswiki.org/emacs/download/css-mode.el'
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
puts "Finished in #{(Time.now - TIME).to_i}s"
puts 'Dont forget to `M-x byte-recompile-home`'