This commit is contained in:
Samuel Vasko 2013-12-09 18:48:30 +01:00
parent fcea0b5b49
commit cbe2f25dcb

12
pack.rb
View File

@ -5,12 +5,13 @@ require "fileutils"
def create_archive name, exclude def create_archive name, exclude
if exclude if exclude
exclude = " -x!" + exclude exclude = " -x!cmder\\" + exclude
else else
exclude = "" exclude = ""
end end
system('ls')
puts "Running 7z a -x@cmder\\packignore" + exclude + " " + name + " cmder" puts "Running 7z a -x@cmder\\packignore" + exclude + " " + name + " cmder"
system("7z a -x@cmder\packignore + "+ name +" cmder") system("7z a -x@cmder\\packignore" + exclude + " " + name + " cmder")
end end
targets = [ targets = [
@ -24,11 +25,16 @@ unless system("git describe --abbrev=0 --tags")
end end
version = `git describe --abbrev=0 --tags` version = `git describe --abbrev=0 --tags`
FileUtils.touch('Version ' + version) FileUtils.touch('Version ' + version)
FileUtils.rm('config/.history')
Dir.chdir('..')
targets.each do |ar| targets.each do |ar|
create_archive ar[0], ar[1] create_archive ar[0], ar[1]
end end
FileUtils.rm('Version ' + version) Dir.chdir('cmder')
FileUtils.rm('Version ' + version.chomp)