iron_hammer 0.3.3 → 0.3.4

Sign up to get free protection for your applications and to get access to all the features.
data/PostInstall.txt CHANGED
@@ -1,5 +1,26 @@
1
- ============================================
1
+ ========================================================================================
2
2
 
3
- Thanks for installing Iron-Hammer
3
+ Thanks for installing Iron-Hammer (c) 2010 Mozair Alves do Carmo Junior - MACSkeptic
4
4
 
5
- ============================================
5
+ # You can now use Hammer tasks on your Rakefile with ease #
6
+
7
+ --- rakefile.rb
8
+ VISUAL_STUDIO_PATH = 'f:\\Program Files (x86)\\Microsoft Visual Studio 2008\\Common7\\IDE'
9
+ require 'iron_hammer/tasks'
10
+
11
+ --- Calling the custom iron hammer tasks
12
+ $ rake iron:build
13
+ $ rake iron:test:unit
14
+
15
+ # If you prefer, you can still do it by yourself #
16
+
17
+ --- rakefile.rb
18
+ require 'iron_hammer'
19
+
20
+ @anvil = Anvil.load_solution_from '.'
21
+ @anvil.load_projects_from_solution
22
+ @hammer = Hammer.new :visual_studio_path => VISUAL_STUDIO_PATH
23
+ sh @hammer.build @anvil.solution
24
+ sh @hammer.test *@anvil.test_projects
25
+
26
+ ========================================================================================
data/README.rdoc CHANGED
File without changes
data/Rakefile CHANGED
@@ -11,7 +11,7 @@ $hoe = Hoe.spec 'iron_hammer' do
11
11
  self.post_install_message = File.read('PostInstall.txt')
12
12
  self.rubyforge_name = self.name
13
13
  self.extra_deps = [['rubyzip2','>= 2.0.1']]
14
- self.version = '0.3.3'
14
+ self.version = '0.3.4'
15
15
  end
16
16
 
17
17
  require 'newgem/tasks'
data/lib/iron_hammer.rb CHANGED
@@ -22,6 +22,7 @@ require 'iron_hammer/hammer'
22
22
  require 'iron_hammer/package'
23
23
  require 'iron_hammer/projects/asp_net_mvc_project'
24
24
  require 'iron_hammer/projects/asp_net_project'
25
+ require 'iron_hammer/projects/dependency'
25
26
  require 'iron_hammer/projects/dll_project'
26
27
  require 'iron_hammer/projects/generic_project'
27
28
  require 'iron_hammer/projects/project_file'
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -4,6 +4,7 @@ require 'iron_hammer/projects/asp_net_project'
4
4
  require 'iron_hammer/projects/asp_net_mvc_project'
5
5
  require 'iron_hammer/projects/test_project'
6
6
  require 'iron_hammer/projects/dll_project'
7
+ require 'iron_hammer/projects/dependency'
7
8
  require 'iron_hammer/utils/file_system'
8
9
 
9
10
  module IronHammer
@@ -13,6 +14,7 @@ module IronHammer
13
14
 
14
15
  GUID_EVALUATION_ORDER = [AspNetMvcProject, AspNetProject, TestProject]
15
16
  GUID_PATH = '//Project/PropertyGroup/ProjectTypeGuids'
17
+ REFERENCE_PATH = '//Reference[not(starts_with(@Include, "System"))]'
16
18
 
17
19
  def initialize params={}
18
20
  @type = params[:type] || DllProject
@@ -35,6 +37,20 @@ module IronHammer
35
37
  elem = doc && doc.elements[GUID_PATH]
36
38
  guids = ((elem && elem.text) || '').split(';').collect { |e| e.upcase }
37
39
  end
40
+
41
+ def self.dependencies_of xml
42
+ doc = REXML::Document.new xml
43
+ references = doc && doc.get_elements(REFERENCE_PATH)
44
+ references.map do |reference|
45
+ includes = reference.attribute(:Include).value
46
+ name = includes.split(', ')[0]
47
+ match = includes.match /Version=(.+?),/
48
+ version = match[1] if match
49
+ Dependency.new :name => name, :version => version
50
+ end
51
+
52
+ end
38
53
  end unless defined? ProjectFile
39
54
  end
40
55
  end
56
+
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -1,3 +1,4 @@
1
+ require 'rubygems'
1
2
  require 'zip/zipfilesystem'
2
3
 
3
4
  module IronHammer
File without changes
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: iron_hammer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.3.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mozair Alves do Carmo Junior
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2010-01-23 00:00:00 -02:00
12
+ date: 2010-01-27 00:00:00 -02:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
@@ -93,12 +93,34 @@ has_rdoc: true
93
93
  homepage: http://github.com/MACSkeptic/Iron-Hammer
94
94
  licenses: []
95
95
 
96
- post_install_message: |-
97
- ============================================
96
+ post_install_message: |
97
+ ========================================================================================
98
98
 
99
- Thanks for installing Iron-Hammer
99
+ Thanks for installing Iron-Hammer (c) 2010 Mozair Alves do Carmo Junior - MACSkeptic
100
100
 
101
- ============================================
101
+ # You can now use Hammer tasks on your Rakefile with ease #
102
+
103
+ --- rakefile.rb
104
+ VISUAL_STUDIO_PATH = 'f:\\Program Files (x86)\\Microsoft Visual Studio 2008\\Common7\\IDE'
105
+ require 'iron_hammer/tasks'
106
+
107
+ --- Calling the custom iron hammer tasks
108
+ $ rake iron:build
109
+ $ rake iron:test:unit
110
+
111
+ # If you prefer, you can still do it by yourself #
112
+
113
+ --- rakefile.rb
114
+ require 'iron_hammer'
115
+
116
+ @anvil = Anvil.load_solution_from '.'
117
+ @anvil.load_projects_from_solution
118
+ @hammer = Hammer.new :visual_studio_path => VISUAL_STUDIO_PATH
119
+ sh @hammer.build @anvil.solution
120
+ sh @hammer.test *@anvil.test_projects
121
+
122
+ ========================================================================================
123
+
102
124
  rdoc_options:
103
125
  - --main
104
126
  - README.rdoc