uri-redis 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/CHANGES.txt +6 -0
  2. data/lib/uri/redis.rb +11 -4
  3. data/uri-redis.gemspec +1 -1
  4. metadata +2 -2
@@ -1,5 +1,11 @@
1
1
  URI-Redis, CHANGES
2
2
 
3
+ #### 0.3.0 (2010-06-03) ###############################
4
+
5
+ * CHANGE: Redis::Client.uri is now Redis.uri
6
+ * ADDED: Support for redis-2.0.0
7
+
8
+
3
9
  #### 0.2.0 (2010-05-30) ###############################
4
10
 
5
11
  * Initial public release
@@ -47,13 +47,20 @@ module URI
47
47
  @@schemes['REDIS'] = Redis
48
48
  end
49
49
 
50
+
50
51
  class Redis
51
- class Client
52
+ def self.uri(conf={})
53
+ URI.parse 'redis://%s:%s/%s' % [conf[:host], conf[:port], conf[:db]]
54
+ end
55
+ if defined?(Redis::VERSION) && Redis::VERSION >= "2.0.0"
52
56
  def uri
53
- URI.parse 'redis://%s:%s/%s' % [@host, @port, @db]
57
+ URI.parse 'redis://%s:%s/%s' % [@client.host, @client.port, @client.db]
54
58
  end
55
- def self.uri(conf={})
56
- URI.parse 'redis://%s:%s/%s' % [conf[:host], conf[:port], conf[:db]]
59
+ else
60
+ class Client
61
+ def uri
62
+ URI.parse 'redis://%s:%s/%s' % [@host, @port, @db]
63
+ end
57
64
  end
58
65
  end
59
66
  end
@@ -1,7 +1,7 @@
1
1
  @spec = Gem::Specification.new do |s|
2
2
  s.name = "uri-redis"
3
3
  s.rubyforge_project = 'uri-redis'
4
- s.version = "0.2.0"
4
+ s.version = "0.3.0"
5
5
  s.summary = "URI-Redis: support for parsing redis://host:port/dbindex"
6
6
  s.description = s.summary
7
7
  s.author = "Delano Mandelbaum"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: uri-redis
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Delano Mandelbaum
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2010-05-30 00:00:00 -04:00
12
+ date: 2010-06-03 00:00:00 -04:00
13
13
  default_executable:
14
14
  dependencies: []
15
15