public
Description: Implementation of the core of Ruby's object system in JavaScript.
Homepage: http://jsclass.jcoglan.com
Clone URL: git://github.com/jcoglan/js.class.git
jcoglan (author)
Sat Oct 17 12:54:39 -0700 2009
commit  ed1c0e1c635e713c564b08474ccb54bd7188714a
tree    4cbfc751ed64bc6600ae7b043ef93279c2b0c1b8
parent  524a637b0b1388544d7f7361585dadee3efe2051 parent  c2b364002a2ee3e7504a3452dbc85120fe6d825c
js.class / Jakefile
100644 21 lines (16 sloc) 0.614 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# Reads the license file and returns its contents formatted as
# a multiline JavaScript comment for embedding in source code
jake_helper :license do
  "/**\n" + File.read('MIT-LICENSE').split(/\n/).map { |line|
    " * #{ line }"
  }.join("\n") + "\n */"
end
 
jake_hook :build_complete do |build|
  %w[CHANGELOG MIT-LICENSE].each do |doc|
    FileUtils.cp doc, "#{build.build_directory}/#{doc}"
  end
  
  FileUtils.cp 'README.markdown', "#{build.build_directory}/README"
  
  build.packages.each do |doc|
    FileUtils.cp build.package(doc).build_path(:min), "site/site/javascripts/js.class/#{doc}.js"
  end
end