-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
32 lines (26 loc) · 712 Bytes
/
Rakefile
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
require 'rake/clean'
CLEAN.include( 'pnote.vba' )
COMPONENTS =
"plugin/pnote.vim" ,
"ftplugin/pnote.vim",
"syntax/pnote.vim"
VIMDIR = (ENV['VIMRUNTIME'] || ENV['HOME'] + "/.vim")
abort if not File.directory? VIMDIR
desc "Get PNOTE files from Vim folder"
task :get do
COMPONENTS.each do |target|
source = VIMDIR + target
unless uptodate?(target, source)
copy source, target
end
end
end
desc "Pack all files into a VBA file (release)"
task :vba => :clean do
abort("ERROR Temporal file already exists!") if File.exist? 'f.tmp'
File.open('f.tmp', 'w') do |out|
out.puts COMPONENTS
end
sh %{VIM -s build.vim}
#rm f.tmp
end