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 +27 -21
- data/lib/occi/core/entity.rb +3 -2
- data/lib/occi/parser.rb +2 -1
- data/lib/occi/version.rb +1 -1
- metadata +2 -2
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
|
-
|
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
|
-
|
23
|
-
|
24
|
-
|
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
|
-
|
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
|
-
###
|
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
|
-----
|
data/lib/occi/core/entity.rb
CHANGED
@@ -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 =
|
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
data/lib/occi/version.rb
CHANGED
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.
|
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-
|
14
|
+
date: 2013-08-15 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: json
|