buildr-iidea 0.0.6 → 0.0.7

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG CHANGED
@@ -1,8 +1,11 @@
1
- 0.0.6 (June 5, 2010)
1
+ 0.0.7 (July 7, 2010)
2
+ * Fixed: Regression involving source and exclude paths for nested projects.
3
+
4
+ 0.0.6 (July 5, 2010)
2
5
  * Fixed: Correctly fixed the default value of iml.local_repository_env_override setting to
3
6
  match documentation.
4
7
 
5
- 0.0.5 (June 5, 2010)
8
+ 0.0.5 (July 5, 2010)
6
9
  * Changed: The documentation indicated that the iml.local_repository_env_override value
7
10
  defaulted to nil while the code defaulted the value to M2_REPO. The code was changed to
8
11
  Use $MAVEN_REPOSITORY$ to match the behaviour of IDEA 9.x.
@@ -189,14 +189,17 @@ module Buildr
189
189
  :main => self.main_source_directories,
190
190
  :test => self.test_source_directories
191
191
  }.each do |kind, directories|
192
- directories.map { |dir| relative(dir) }.compact.sort.uniq.each do |dir|
192
+ directories.map { |dir| dir.to_s }.compact.sort.uniq.each do |dir|
193
193
  xml.sourceFolder :url => file_path(dir), :isTestSource => (kind == :test ? 'true' : 'false')
194
194
  end
195
195
  end
196
196
 
197
197
  # Exclude target directories
198
- self.net_excluded_directories.select{|dir| relative_dir_inside_dir?(dir)}.sort.each do |dir|
199
- xml.excludeFolder :url => file_path(dir)
198
+ self.net_excluded_directories.
199
+ collect { |dir| file_path(dir) }.
200
+ select{ |dir| relative_dir_inside_dir?(dir) }.
201
+ sort.each do |dir|
202
+ xml.excludeFolder :url => dir
200
203
  end
201
204
  end
202
205
  end
@@ -237,7 +240,7 @@ module Buildr
237
240
  # Don't exclude things that are subdirectories of other excluded things
238
241
  def net_excluded_directories
239
242
  net = []
240
- all = self.excluded_directories.map { |dir| relative(dir.to_s) }.sort_by { |d| d.size }
243
+ all = self.excluded_directories.map { |dir| buildr_project._(dir.to_s) }.sort_by { |d| d.size }
241
244
  all.each_with_index do |dir, i|
242
245
  unless all[0 ... i].find { |other| dir =~ /^#{other}/ }
243
246
  net << dir
@@ -3,7 +3,7 @@ module Buildr
3
3
  class Version
4
4
  MAJOR = "0"
5
5
  MINOR = "0"
6
- MICRO = "6"
6
+ MICRO = "7"
7
7
 
8
8
  STRING = "#{MAJOR}.#{MINOR}.#{MICRO}"
9
9
  end
@@ -35,6 +35,26 @@ describe "iidea:generate" do
35
35
  end
36
36
  end
37
37
 
38
+ describe "with subprojects" do
39
+ before do
40
+ @foo = define "foo" do
41
+ define "bar" do
42
+ compile.from _(:source, :main, :bar)
43
+ end
44
+ end
45
+ invoke_generate_task
46
+ @bar_doc = xml_document(project('foo:bar')._('bar.iml'))
47
+ end
48
+
49
+ it "generates the correct source directories" do
50
+ @bar_doc.should have_xpath("//content/sourceFolder[@url='file://$MODULE_DIR$/src/main/bar']")
51
+ end
52
+
53
+ it "generates the correct exclude directories" do
54
+ @bar_doc.should have_xpath("//content/excludeFolder[@url='file://$MODULE_DIR$/target']")
55
+ end
56
+ end
57
+
38
58
  describe "with report dir outside content" do
39
59
  before do
40
60
  layout = Layout::Default.new
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 6
9
- version: 0.0.6
8
+ - 7
9
+ version: 0.0.7
10
10
  platform: ruby
11
11
  authors:
12
12
  - Rhett Sutphin
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-07-05 00:00:00 +10:00
18
+ date: 2010-07-07 00:00:00 +10:00
19
19
  default_executable:
20
20
  dependencies: []
21
21
 
@@ -72,7 +72,7 @@ licenses: []
72
72
  post_install_message: Thanks for installing the Intellij IDEA extension for Buildr
73
73
  rdoc_options:
74
74
  - --title
75
- - buildr-iidea 0.0.6
75
+ - buildr-iidea 0.0.7
76
76
  - --main
77
77
  - README.rdoc
78
78
  require_paths: