360_services 0.0.5 → 0.0.6

Sign up to get free protection for your applications and to get access to all the features.
data/360_services.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{360_services}
5
- s.version = "0.0.5"
5
+ s.version = "0.0.6"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Sorenson Media"]
data/HOW_TO_BUILD.txt CHANGED
@@ -1,3 +1,5 @@
1
+ (MAKE SURE YOU INCREMENT THE VERSION NUMBER in the Rakefile)
2
+
1
3
  1. GET INTO THIS DIRECTORY
2
4
  cd 360_services_gem
3
5
 
@@ -18,7 +20,7 @@ cd pkg
18
20
 
19
21
  7. PUSH GEM TO GEMCUTTER (MAKE SURE GEMCUTTER GEM IS INSTALLED)
20
22
  gem install gemcutter (IF NEEDED)
21
- gem push 360_services-0.0.1.gem (MAKE SURE VERSION NUMBER WAS INCREMENTED CORRECTLY)
23
+ gem push 360_services-0.0.5.gem (MAKE SURE YOU INCREMENTED THE VERSION NUMBER in the Rakefile!!!)
22
24
 
23
25
  8. INSTALL THE FINISHED GEM LOCALLY
24
26
  gem install 360_services
data/Rakefile CHANGED
@@ -3,7 +3,7 @@ require 'cucumber'
3
3
  require 'cucumber/rake/task'
4
4
  require 'echoe'
5
5
 
6
- Echoe.new('360_services', '0.0.5') do |p|
6
+ Echoe.new('360_services', '0.0.6') do |p|
7
7
  p.description = "Ruby bindings for Sorenson 360"
8
8
  p.url = "http://github.com/sorenson/360_services"
9
9
  p.author = "Sorenson Media"
@@ -3,11 +3,22 @@ module Sorenson
3
3
  class Group < Base
4
4
  attr_accessor :name, :description, :account_id, :id, :guid
5
5
 
6
+ def self.presets(group_id)
7
+ get_from("/groups/#{group_id}/presets")
8
+ end
9
+
6
10
  def self.create(name, attributes={})
7
11
  data = post_to("/groups", :group => attributes.merge(:name => name))
8
12
  new(data['group'])
9
13
  end
10
14
 
15
+ def self.update(name, attributes={})
16
+ attributes[:preset_ids] = attributes[:preset_ids].join(",")
17
+ guid = attributes.delete(:group_id)
18
+ data = put_to("/groups/#{guid}", :group => attributes.merge({:name => name, :id => guid}))
19
+ new(data['group'])
20
+ end
21
+
11
22
  def self.all
12
23
  collection = Base.get_from("/groups")
13
24
  collection.collect { |data| new(data['group'])}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: 360_services
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sorenson Media