pling 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,5 @@
1
+ *.gem
2
+ .bundle
3
+ .rspec
4
+ Gemfile.lock
5
+ pkg/*
@@ -0,0 +1,8 @@
1
+ rvm:
2
+ - ruby-head
3
+ - 1.9.2
4
+ - 1.8.7
5
+ - ree
6
+ - jruby
7
+ - rbx
8
+ - rbx-2.0.0pre
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ source 'http://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in pling.gemspec
4
+ gemspec
5
+
6
+ gem 'guard'
data/LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2011 flinc AG
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,89 @@
1
+ # Pling ![Travis build status of pling](http://travis-ci.org/flinc/pling.png)
2
+
3
+ Pling is a notification framework that supports multiple gateways.
4
+
5
+
6
+ ## Requirements
7
+
8
+
9
+
10
+ ## Install
11
+
12
+ Add this line to your `Gemfile`:
13
+
14
+ gem 'pling'
15
+
16
+ ## Configuration
17
+
18
+ Pling.configure do |config|
19
+ config.gateways = [
20
+ Pling::Gateways::C2DM.new(:options => 'here'),
21
+ Pling::Gateways::IPhone.new(:options => 'here'),
22
+ Pling::Gateways::Email.new(:options => 'here')
23
+ ]
24
+ end
25
+
26
+ ## Usage
27
+
28
+ Pling has three core components:
29
+
30
+ * A `Device` describes a concrete receiver such as a smartphone or an email address.
31
+ * A `Message` wraps the content delivered to a device.
32
+ * A `Gateway` handles the communication with the service provider used to deliver the message.
33
+
34
+ To integrate Pling in your application you have to implement a `to_pling` method on each of your models to convert your data into Pling compatible objects.
35
+
36
+ ### Devices
37
+
38
+ Devices store an identifier and a type.
39
+
40
+ Example:
41
+
42
+ email_device = Pling::Device.new(:identifier => 'someone@example.com', :type => :email)
43
+ iphone_device = Pling::Device.new(:identifier => 'XXXXXXXXXX...XXXXXX', :type => :iphone)
44
+
45
+
46
+ ### Messages
47
+
48
+ The `Message` stores the content as well as additional options that may be evaluated by the gateways.
49
+
50
+ Example:
51
+
52
+ options = {} # To be added
53
+ message = Pling::Message.new("Hello from Pling", options)
54
+
55
+
56
+ ### Gateways
57
+
58
+ The Gateway delivers the message in the required format to the service provider.
59
+
60
+ Currently there are these gateways available:
61
+
62
+ * Android C2DM (not yet implemented)
63
+ * iPhone Push (not yet implemented)
64
+ * SMS via Mobilant (See `pling-mobilant` gem, not yet implemented)
65
+ * E-Mail (See `pling-actionmailer` gem, not yet implemented)
66
+
67
+ ## Build Status
68
+
69
+ Pling is on [Travis](http://travis-ci.org/flinc/pling) running the specs on Ruby 1.8.7, Ruby 1.9.2 and Ruby Enterprise Edition.
70
+
71
+
72
+ ## Known issues
73
+
74
+ See https://github.com/flinc/pling/issues
75
+
76
+
77
+ ## Repository
78
+
79
+ See https://github.com/flinc/pling and feel free to fork it!
80
+
81
+
82
+ ## Contributors
83
+
84
+ See a list of all contributors at https://github.com/flinc/pling/contributors. Thanks a lot everyone!
85
+
86
+
87
+ ## Copyright
88
+
89
+ Copyright (c) 2010-2011 flinc AG. See LICENSE for details.
@@ -0,0 +1,10 @@
1
+ require 'bundler/gem_tasks'
2
+
3
+ require 'rspec/core/rake_task'
4
+ require 'yard/rake/yardoc_task'
5
+
6
+ RSpec::Core::RakeTask.new(:spec)
7
+
8
+ YARD::Rake::YardocTask.new(:doc)
9
+
10
+ task :default => :spec
@@ -0,0 +1,5 @@
1
+ require "pling/version"
2
+
3
+ module Pling
4
+ # Your code goes here...
5
+ end
@@ -0,0 +1,3 @@
1
+ module Pling
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,26 @@
1
+ # -*- encoding: utf-8 -*-
2
+ $:.push File.expand_path("../lib", __FILE__)
3
+ require "pling/version"
4
+
5
+ Gem::Specification.new do |s|
6
+ s.name = "pling"
7
+ s.version = Pling::VERSION
8
+ s.authors = ["benedikt", "t6d", "fabrik42"]
9
+ s.email = ["benedikt@synatic.net", "me@t6d.de", "fabrik42@gmail.com"]
10
+ s.homepage = "https://flinc.github.com/pling"
11
+ s.summary = %q{Pling is a notification framework that supports multiple gateways}
12
+ s.description = %q{Pling is a notification framework that supports multiple gateways. Currently supported are Android Push and SMS.}
13
+
14
+ s.files = `git ls-files`.split("\n")
15
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
16
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
17
+ s.require_paths = ["lib"]
18
+
19
+ # specify any dependencies here; for example:
20
+ # s.add_development_dependency "rspec"
21
+ # s.add_runtime_dependency "rest-client"
22
+
23
+ s.add_development_dependency "rspec", "~> 2.7"
24
+ s.add_development_dependency "yard", ">= 0.7"
25
+ s.add_development_dependency "rake", ">= 0.9"
26
+ end
@@ -0,0 +1,10 @@
1
+ require 'rubygems'
2
+ require 'bundler'
3
+
4
+ Bundler.require
5
+
6
+ Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
7
+
8
+ RSpec.configure do |config|
9
+ config.mock_with :rspec
10
+ end
metadata ADDED
@@ -0,0 +1,95 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: pling
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - benedikt
9
+ - t6d
10
+ - fabrik42
11
+ autorequire:
12
+ bindir: bin
13
+ cert_chain: []
14
+ date: 2011-10-17 00:00:00.000000000Z
15
+ dependencies:
16
+ - !ruby/object:Gem::Dependency
17
+ name: rspec
18
+ requirement: &2256950400 !ruby/object:Gem::Requirement
19
+ none: false
20
+ requirements:
21
+ - - ~>
22
+ - !ruby/object:Gem::Version
23
+ version: '2.7'
24
+ type: :development
25
+ prerelease: false
26
+ version_requirements: *2256950400
27
+ - !ruby/object:Gem::Dependency
28
+ name: yard
29
+ requirement: &2256949420 !ruby/object:Gem::Requirement
30
+ none: false
31
+ requirements:
32
+ - - ! '>='
33
+ - !ruby/object:Gem::Version
34
+ version: '0.7'
35
+ type: :development
36
+ prerelease: false
37
+ version_requirements: *2256949420
38
+ - !ruby/object:Gem::Dependency
39
+ name: rake
40
+ requirement: &2256948960 !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0.9'
46
+ type: :development
47
+ prerelease: false
48
+ version_requirements: *2256948960
49
+ description: Pling is a notification framework that supports multiple gateways. Currently
50
+ supported are Android Push and SMS.
51
+ email:
52
+ - benedikt@synatic.net
53
+ - me@t6d.de
54
+ - fabrik42@gmail.com
55
+ executables: []
56
+ extensions: []
57
+ extra_rdoc_files: []
58
+ files:
59
+ - .gitignore
60
+ - .travis.yml
61
+ - Gemfile
62
+ - LICENSE
63
+ - README.md
64
+ - Rakefile
65
+ - lib/pling.rb
66
+ - lib/pling/version.rb
67
+ - pling.gemspec
68
+ - spec/spec_helper.rb
69
+ homepage: https://flinc.github.com/pling
70
+ licenses: []
71
+ post_install_message:
72
+ rdoc_options: []
73
+ require_paths:
74
+ - lib
75
+ required_ruby_version: !ruby/object:Gem::Requirement
76
+ none: false
77
+ requirements:
78
+ - - ! '>='
79
+ - !ruby/object:Gem::Version
80
+ version: '0'
81
+ required_rubygems_version: !ruby/object:Gem::Requirement
82
+ none: false
83
+ requirements:
84
+ - - ! '>='
85
+ - !ruby/object:Gem::Version
86
+ version: '0'
87
+ requirements: []
88
+ rubyforge_project:
89
+ rubygems_version: 1.8.10
90
+ signing_key:
91
+ specification_version: 3
92
+ summary: Pling is a notification framework that supports multiple gateways
93
+ test_files:
94
+ - spec/spec_helper.rb
95
+ has_rdoc: