occi-core 4.0.0 → 4.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -9,55 +9,61 @@ rOCCI-core - A Ruby OCCI Framework
9
9
  Requirements
10
10
  ------------
11
11
 
12
- Ruby
12
+ ### Ruby
13
13
  * at least version 1.8.7 is required
14
-
15
- The following setup is recommended
16
-
17
- * Ruby 1.9.3+
14
+ * Ruby 1.9.3+ is recommended
18
15
  * RubyGems installed
16
+ * rake installed (e.g., `gem install rake`)
19
17
 
20
- The following libraries / packages may be required to use rOCCI
18
+ ### Libraries/packages
19
+ * libxslt1-dev/libxslt-devel
20
+ * libxml2-dev/libxml2-devel
21
+ * **only if using Ruby 1.8.7:** libonig-dev/oniguruma-devel (Linux) or oniguruma (Mac)
21
22
 
22
- * libxslt-dev
23
- * libxml2-dev
24
- * **only if using Ruby 1.8.7:** libonig-dev (Linux) or oniguruma (Mac)
23
+ ### Examples
24
+ For distros based on Debian:
25
+ ~~~
26
+ apt-get install ruby rubygems ruby-dev libxslt1-dev libxml2-dev libonig-dev
27
+ ~~~
28
+
29
+ For distros based on RHEL:
30
+ ~~~
31
+ yum install libxml2-devel libxslt-devel ruby-devel openssl-devel gcc gcc-c++ ruby rubygems oniguruma-devel
32
+ ~~~
25
33
 
26
34
  Installation
27
35
  ------------
28
36
 
29
- **[Mac OS X has some special requirements for the installation. Detailed information can be found in
30
- doc/macosx.md.](doc/macosx.md)**
37
+ ### From RubyGems.org
31
38
 
32
39
  To install the most recent stable version
33
40
 
41
+ gem install rake
34
42
  gem install occi-core
35
43
 
36
44
  To install the most recent beta version
37
45
 
46
+ gem install rake
38
47
  gem install occi-core --pre
39
48
 
40
- ### Installation from source
49
+ ### From source (dev)
50
+
51
+ **Installation from source should never be your first choice! Especially, if you are not familiar with RVM, Bundler, Rake and other dev tools for Ruby!**
52
+ **However, if you wish to contribute to our project, this is the right way to start.**
41
53
 
42
54
  To use rOCCI from source it is very much recommended to use RVM. [Install RVM](https://rvm.io/rvm/install/) with
43
55
 
44
56
  curl -L https://get.rvm.io | bash -s stable --ruby
45
-
46
- #### Ruby
57
+ rvm install 1.9.3
47
58
 
48
59
  To build and install the bleeding edge version from master
49
60
 
50
61
  git clone git://github.com/gwdg/rOCCI-core.git
51
62
  cd rOCCI-core
52
- rvm install ruby-1.9.3
53
63
  gem install bundler
54
64
  bundle install
55
- rake test
56
-
57
- Documentation
58
- -------------
59
-
60
- [Code documentation can be found on RubyDoc.info](rubydoc.info/github/gwdg/rOCCI-core).
65
+ bundle exec rake test
66
+ rake install
61
67
 
62
68
  Usage
63
69
  -----
@@ -157,9 +157,10 @@ module Occi
157
157
  # @param [Occi::Model] model representation of the Occi model to check the attributes against
158
158
  def check
159
159
  raise "No model associated" unless @model
160
- definitions = model.get_by_id(@kind.to_s).attributes
160
+ definitions = Occi::Core::Attributes.new
161
+ definitions.merge!(@model.get_by_id(@kind.to_s).attributes)
161
162
  @mixins.each do |mixin_id|
162
- mixin = model.get_by_id(mixin_id)
163
+ mixin = @model.get_by_id(mixin_id)
163
164
  next if mixin.nil?
164
165
  definitions.merge!(mixin.attributes) if mixin.attributes
165
166
  end if @mixins
data/lib/occi/parser.rb CHANGED
@@ -71,7 +71,8 @@ module Occi
71
71
  else
72
72
  nil
73
73
  end
74
- locations
74
+
75
+ locations.flatten
75
76
  end
76
77
 
77
78
  end
data/lib/occi/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Occi
2
- VERSION = "4.0.0" unless defined?(::Occi::VERSION)
2
+ VERSION = "4.0.1" unless defined?(::Occi::VERSION)
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: occi-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 4.0.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2013-08-02 00:00:00.000000000 Z
14
+ date: 2013-08-15 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: json