gorki 0.0.0

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.
Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/lib/gorki.rb +16 -0
  3. metadata +44 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 4d3ae0b185b6c5b02ec5e4168879744a94a46e7f
4
+ data.tar.gz: 740300cc3104df75605677bd5e5b46453afcf131
5
+ SHA512:
6
+ metadata.gz: de214fcd3c6450c08aff8d63bc8b1b27b250d4cfa63f4ca589a7afa16a34292cf0b70d176d26c55e5de907456afc8790711179b4b0216bd1b7cd4a59c3b2c54f
7
+ data.tar.gz: 8f4a9d2c3d46265e96700fef6751b1ad2b7513ee9fef913f2abe3d59777eaf5b55c2b2147102a8b54cd4a39b8878c2cd15273490785cd431b7331d41bab3579e
data/lib/gorki.rb ADDED
@@ -0,0 +1,16 @@
1
+ require 'net/http'
2
+
3
+ class Gorki
4
+ def initialize(host, port)
5
+ @host = host
6
+ @port = port
7
+ end
8
+
9
+ def set(key, value)
10
+ Net::HTTP.get(URI("http://#{@host}:#{@port}/set/#{key}/#{value}"))
11
+ true
12
+ end
13
+ def get(key)
14
+ Net::HTTP.get(URI("http://#{@host}:#{@port}/get/#{key}"))
15
+ end
16
+ end
metadata ADDED
@@ -0,0 +1,44 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: gorki
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Hugo Abonizio
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-05-07 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: A client to Gorki key-value datastore
14
+ email: hugo_abonizio@hotmail.com
15
+ executables: []
16
+ extensions: []
17
+ extra_rdoc_files: []
18
+ files:
19
+ - lib/gorki.rb
20
+ homepage: http://rubygems.org/gems/gorki
21
+ licenses:
22
+ - MIT
23
+ metadata: {}
24
+ post_install_message:
25
+ rdoc_options: []
26
+ require_paths:
27
+ - lib
28
+ required_ruby_version: !ruby/object:Gem::Requirement
29
+ requirements:
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: '0'
33
+ required_rubygems_version: !ruby/object:Gem::Requirement
34
+ requirements:
35
+ - - ">="
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ requirements: []
39
+ rubyforge_project:
40
+ rubygems_version: 2.2.2
41
+ signing_key:
42
+ specification_version: 4
43
+ summary: Gorki
44
+ test_files: []