pubnub-publisher 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ea389b2bbe81e52d0c3789f85d8f3f6acce213bc
4
- data.tar.gz: dd0a6ef4720d420f44748ec81ee78873c5e81399
3
+ metadata.gz: 6c9746182be62395a1bc58e0c89dd49822bb8870
4
+ data.tar.gz: eea4c04dfa118ffd17cebd1c6b94d01f15d54780
5
5
  SHA512:
6
- metadata.gz: 683fe19193c0d1b374415cb6e2c119f6fd58d9fda28f054c89b73231852219bb495919265a2e048d8a3d33e8d7b48310b6c2db611952caea9e05fc3222d9740f
7
- data.tar.gz: 66f62daa6f402c9e0065fa30c8b9103446aa560813dc05cae72ff740db222d35818d467b97641abeab24579fc6866ea9bd98d86d4db9b0d8edf0663f2dd8e272
6
+ metadata.gz: b9cd29094bd772de854239e258a6d3772ea0244f5779ccfec99863d2b2cc79c352a7be013614534b3f58db61e1b7bd210a3f133c3d6f74eca34e9b9f57fa0da9
7
+ data.tar.gz: 0cf14af323d35e6b70fda75d2785a10cd7966f8ddb847e633b8e958307066b115e0d466112e06567ed955edcda67efcf2ab90336050538b389f4ee6c3cf47da8
data/CHANGELOG.md ADDED
@@ -0,0 +1,7 @@
1
+ # Changelog
2
+
3
+ * 1.0.1 added `Pubnub::Publisher.publish_key`,
4
+ `Pubnub::Publisher.subscribe`, and `Pubnub::Publisher.ssl` accessors so
5
+ we can easily accessed the shared config main keys.
6
+
7
+ * 1.0 first release
data/LICENSE.txt CHANGED
@@ -1,22 +1,3 @@
1
- Copyright (c) 2013 Matt Aimonetti
2
-
3
- MIT License
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining
6
- a copy of this software and associated documentation files (the
7
- "Software"), to deal in the Software without restriction, including
8
- without limitation the rights to use, copy, modify, merge, publish,
9
- distribute, sublicense, and/or sell copies of the Software, and to
10
- permit persons to whom the Software is furnished to do so, subject to
11
- the following conditions:
12
-
13
- The above copyright notice and this permission notice shall be
14
- included in all copies or substantial portions of the Software.
15
-
16
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
- NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
- LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
- OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1
+ LICENSE
2
+ Copyright (c) Matt Aimonetti
3
+ MIT: http://mattaimonetti.mit-license.org
data/README.md CHANGED
@@ -97,6 +97,8 @@ end
97
97
 
98
98
  ## TODOs
99
99
 
100
+ * support for cipher, aes and other options that aren't currently
101
+ supported.
100
102
  * Use a thread pool to go non blocking publishing.
101
103
  * use a persistent http connection to pubnub.
102
104
 
@@ -1,12 +1,5 @@
1
- require "base64"
2
- require "net/https"
3
- require "net/http"
4
- require "uri"
5
- require "json"
6
- require "securerandom"
7
-
8
1
  module Pubnub
9
2
  class Publisher
10
- VERSION = "1.0.0"
3
+ VERSION = "1.0.1"
11
4
  end
12
5
  end
@@ -1,3 +1,8 @@
1
+ require "net/https"
2
+ require "net/http"
3
+ require "uri"
4
+ require "json"
5
+ require "securerandom"
1
6
  require "pubnub/publisher/version"
2
7
 
3
8
  module Pubnub
@@ -42,6 +47,10 @@ module Pubnub
42
47
  instance
43
48
  end
44
49
 
50
+ def self.publish_key; @publish_key end
51
+ def self.subscribe_key; @subscribe_key end
52
+ def self.ssl; @ssl end
53
+
45
54
  def initialize(opts={})
46
55
  opts.each do |k,v|
47
56
  next unless CONFIG_KEYS.include?(k)
@@ -56,6 +56,12 @@ describe Pubnub::Publisher do
56
56
  expect(pub_client.ssl).to be_true
57
57
  end
58
58
 
59
+ it "has some global getters" do
60
+ Pubnub::Publisher.setup(publish_key: "pub key", subscribe_key: "sub key", ssl: false)
61
+ expect(Pubnub::Publisher.publish_key).to eql("pub key")
62
+ expect(Pubnub::Publisher.subscribe_key).to eql("sub key")
63
+ end
64
+
59
65
  end
60
66
 
61
67
  context "new instance" do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pubnub-publisher
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Aimonetti
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-07-23 00:00:00.000000000 Z
11
+ date: 2013-07-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -60,6 +60,7 @@ extensions: []
60
60
  extra_rdoc_files: []
61
61
  files:
62
62
  - .gitignore
63
+ - CHANGELOG.md
63
64
  - Gemfile
64
65
  - LICENSE.txt
65
66
  - README.md