rakejava 1.1.4 → 1.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.markdown +76 -0
- metadata +16 -7
- data/README +0 -25
data/README.markdown
ADDED
@@ -0,0 +1,76 @@
|
|
1
|
+
RakeJava is a ruby gem for use with Rake. It lets you compile and jar Java files.
|
2
|
+
|
3
|
+
### Simple Example:
|
4
|
+
|
5
|
+
require 'rakejava'
|
6
|
+
require 'rake/clean'
|
7
|
+
|
8
|
+
CLEAN.include 'build'
|
9
|
+
|
10
|
+
task :default => "myproj.jar"
|
11
|
+
|
12
|
+
jar "myproj.jar" => :compile do |t|
|
13
|
+
t.files << JarFiles["build", "**/*.class"]
|
14
|
+
t.main_class = 'org.whathaveyou.Main'
|
15
|
+
t.manifest = {:version => '1.0.0'}
|
16
|
+
end
|
17
|
+
|
18
|
+
javac :compile => "build" do |t|
|
19
|
+
t.src << Sources["src", "**/*.java"]
|
20
|
+
t.src << Sources["test", "*.java"]
|
21
|
+
t.classpath << Dir["lib/**/*.{zip,jar}"]
|
22
|
+
t.dest = 'build'
|
23
|
+
end
|
24
|
+
|
25
|
+
directory "build"
|
26
|
+
|
27
|
+
-------------------------
|
28
|
+
|
29
|
+
# javac #
|
30
|
+
|
31
|
+
This task is a wrapper around Java's javac command and it supports most of the useful arguments. Here are the attributes you can set:
|
32
|
+
|
33
|
+
* __src__ - a list of `Sources` objects. See `Sources` below.
|
34
|
+
* __classpath__ - a list of directories and jar files. You can use Dir.glob output.
|
35
|
+
* __dest__ - a list of `JarFiles` objects. See `JarFiles` below.
|
36
|
+
* __bootpath__ - javac's bootclasspath. It's a list like classpath.
|
37
|
+
* __src_ver__ - the JDK version of the source files.
|
38
|
+
* __target_ver__ - the target JDK you want the class files to be compatible with.
|
39
|
+
* __debug__ - if you want debug class files
|
40
|
+
* __args__ - a string containing any args you want to pass to javac.
|
41
|
+
|
42
|
+
### Sources ###
|
43
|
+
|
44
|
+
A `Rake::FileList` where the first argument specified is the top of a source tree. Example:
|
45
|
+
|
46
|
+
task.src << Sources["src", "**/*.java"]
|
47
|
+
|
48
|
+
-------------------------
|
49
|
+
# jar #
|
50
|
+
|
51
|
+
This task is a wrapper around Java's jar command and it supports all of its arguments. The name of jar task is the jar file to emit. Here are the attributes you can set:
|
52
|
+
|
53
|
+
* __files__ - a list of `JarFiles` objects. See `JarFiles` below.
|
54
|
+
* __main_class__ - The main class for use with java -jar myapp.jar.
|
55
|
+
* __manifest__ - either a hash of key-value pairs to put into the manifest or a path to a manifest file.
|
56
|
+
* __sign_info__ - a hash detailing your signing information. See `sign_info` below.
|
57
|
+
|
58
|
+
### JarFiles ###
|
59
|
+
|
60
|
+
A `Rake::FileList` where the first argument specified is the top directory of a source of files to jar.
|
61
|
+
|
62
|
+
t.files << JarFiles["build", "**/*.class", "**/*.properties"]
|
63
|
+
|
64
|
+
### sign_info ###
|
65
|
+
|
66
|
+
Here's an example of using sign_info with the jar task:
|
67
|
+
|
68
|
+
jar "myproj.jar" => :compile do |t|
|
69
|
+
t.files << JarFiles["build", "**/*.class"]
|
70
|
+
t.sign_info = {
|
71
|
+
:store_type => 'pkcs12',
|
72
|
+
:key_store => 'certs/keystore.p12',
|
73
|
+
:store_pass => 'you-know-yours',
|
74
|
+
:alias => 'you-know-yours'
|
75
|
+
}
|
76
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rakejava
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tom Santos
|
@@ -9,11 +9,20 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2010-01
|
12
|
+
date: 2010-02-01 00:00:00 -08:00
|
13
13
|
default_executable:
|
14
|
-
dependencies:
|
15
|
-
|
16
|
-
|
14
|
+
dependencies:
|
15
|
+
- !ruby/object:Gem::Dependency
|
16
|
+
name: rake
|
17
|
+
type: :runtime
|
18
|
+
version_requirement:
|
19
|
+
version_requirements: !ruby/object:Gem::Requirement
|
20
|
+
requirements:
|
21
|
+
- - ">="
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: "0"
|
24
|
+
version:
|
25
|
+
description: Rake tasks for building Java stuff (java and jar)
|
17
26
|
email: santos.tom@gmail.com
|
18
27
|
executables: []
|
19
28
|
|
@@ -22,7 +31,7 @@ extensions: []
|
|
22
31
|
extra_rdoc_files: []
|
23
32
|
|
24
33
|
files:
|
25
|
-
- README
|
34
|
+
- README.markdown
|
26
35
|
- lib/rakejava.rb
|
27
36
|
has_rdoc: true
|
28
37
|
homepage: http://github.com/tsantos/rakejava
|
@@ -51,6 +60,6 @@ rubyforge_project:
|
|
51
60
|
rubygems_version: 1.3.5
|
52
61
|
signing_key:
|
53
62
|
specification_version: 3
|
54
|
-
summary: Rake tasks for building Java stuff
|
63
|
+
summary: Rake tasks for building Java stuff (java and jar)
|
55
64
|
test_files: []
|
56
65
|
|
data/README
DELETED
@@ -1,25 +0,0 @@
|
|
1
|
-
RakeJava is a ruby gem for use with Rake. It lets you compile and jar Java files.
|
2
|
-
|
3
|
-
Simple Example:
|
4
|
-
|
5
|
-
require 'rakejava'
|
6
|
-
require 'rake/clean'
|
7
|
-
|
8
|
-
CLEAN.include 'build'
|
9
|
-
|
10
|
-
task :default => "myproj.jar"
|
11
|
-
|
12
|
-
jar "myproj.jar" => :compile do |t|
|
13
|
-
t.files << JarFiles["build", "**/*.class"]
|
14
|
-
t.manifest = {:version => '1.0.0'}
|
15
|
-
end
|
16
|
-
|
17
|
-
javac :compile => "build" do |t|
|
18
|
-
t.src << Sources["src", "**/*.java"]
|
19
|
-
t.src << Sources["test", "*.java"]
|
20
|
-
t.classpath << Dir["lib/**/*.{zip,jar}"]
|
21
|
-
t.dest = 'build'
|
22
|
-
end
|
23
|
-
|
24
|
-
directory "build"
|
25
|
-
|