Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 51 lines (43 sloc) 1.591 kb
f97a0740 »
2009-06-12 initial commit
1 require 'rubygems'
2 require 'fileutils'
3
4 rubyforge_name = "textpow"
5
6 begin
7 require 'hoe'
8
9 class Hoe
10 # Dirty hack to eliminate Hoe from gem dependencies
11 def extra_deps
12 @extra_deps.delete_if{ |x| x.first == 'hoe' }
13 end
14 end
15
16 version = /^== *(\d+\.\d+\.\d+)/.match( File.read( 'History.txt' ) )[1]
17
18 h = Hoe.new('textpow', version) do |p|
19 p.rubyforge_name = rubyforge_name
20 p.author = ['Dizan Vasquez']
21 p.email = ['dichodaemon@gmail.com']
22 p.email = 'dichodaemon@gmail.com'
23 p.summary = 'An engine for parsing Textmate bundles'
24 p.description = p.paragraphs_of('README.txt', 1 ).join('\n\n')
25 p.url = 'http://textpow.rubyforge.org'
26 p.rdoc_pattern = /^(lib|bin|ext)|txt$/
27 p.changes = p.paragraphs_of('History.txt', 0).join("\n\n")
28 p.clean_globs = ["manual/*"]
29 p.extra_deps << ['plist', '>= 3.0.0']
30 end
31
32 desc 'Create MaMa documentation'
33 task :mama => :clean do
34 system "mm -c -t refresh -o manual mm/manual.mm"
35 end
36
37 desc 'Publish MaMa documentation to RubyForge'
38 task :mama_publish => [:clean, :mama] do
39 config = YAML.load(File.read(File.expand_path("~/.rubyforge/user-config.yml")))
40 host = "#{config["username"]}@rubyforge.org"
41 remote_dir = "/var/www/gforge-projects/#{h.rubyforge_name}"
42 local_dir = 'manual'
43 system "rsync -av --delete #{local_dir}/ #{host}:#{remote_dir}"
44 end
45
46 rescue LoadError => e
47 desc 'Run the test suite.'
48 task :test do
49 system "ruby -Ibin:lib:test test_#{rubyforge_name}.rb"
50 end
51 end
Something went wrong with that request. Please try again.