unifonic_integration 0.1.0 → 0.1.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
  SHA256:
3
- metadata.gz: d7e87220046928479588a82b9c7930357bda6c3f2533a76b5348aa1dd7e9cae4
4
- data.tar.gz: c85f89052820208d7eb330b68a2fecde028d5503a0d930ad483821eae038902a
3
+ metadata.gz: cc2875d1cdba8f632ff6a47f1de160051838db8d7d8a1b244db44bd8aef9cd6c
4
+ data.tar.gz: a9dc797ffabe6ee19c0e2ead3ed8aea0451829a9875b2343670e8393dddd4fb7
5
5
  SHA512:
6
- metadata.gz: 3c13aafaa78c18045cb8506b040c74bbcdfe186f8c6c8427d1bce8a13a4c728cae444d426d7510905701c6cf772b0c42edbc1b0d5aae674defb0f86f0c75acdc
7
- data.tar.gz: 71cd75dbbd4548d21ec29fb9e696e25148bde95aba08a2ae0778d84ed8776bd832e4a3941543400eebf774430d8588641f84b574239817bbef08d94238812e97
6
+ metadata.gz: 4592256e0eed770908c97a20aa18d1bcb65d86125005159ee29baca8c42694665f17e9a5c18bdf686988c21030df145cea38bc59731258b8b1e3bbf6eb585c25
7
+ data.tar.gz: 0b538c24cf31e887a08b2c63e5a1f6d68f6731519f8639c161945f171564b6c5f0d3ee70bc7574850c3b96efaf49a3322330bf46b77d03a0e456152ba4d87739
@@ -0,0 +1,13 @@
1
+ require 'rails/generators'
2
+
3
+ module UnifonicIntegration
4
+ module Generators
5
+ class InstallGenerator < Rails::Generators::Base
6
+ source_root File.expand_path('templates', __dir__)
7
+
8
+ def create_initializer_file
9
+ copy_file 'unifonic_integration_init.rb', 'config/initializers/unifonic_integration.rb'
10
+ end
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,6 @@
1
+ # frozen_string_literal: true
2
+
3
+ UnifonicIntegration.configure do |config|
4
+ config.app_sid = UNIFONIC_APP_SID
5
+ config.sender_id = UNIFONIC_SENDER_ID
6
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module UnifonicIntegration
4
- VERSION = "0.1.0"
4
+ VERSION = "0.1.1"
5
5
  end
@@ -8,4 +8,14 @@ require_relative 'unifonic_integration/configuration'
8
8
 
9
9
  module UnifonicIntegration
10
10
  class Error < StandardError; end
11
+
12
+ class << self
13
+ attr_accessor :configuration
14
+ end
15
+
16
+ def self.configure
17
+ self.configuration ||= Configuration.new
18
+ yield(configuration)
19
+ end
20
+
11
21
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: unifonic_integration
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Omar Elsamahy
@@ -44,6 +44,8 @@ files:
44
44
  - bin/console
45
45
  - bin/setup
46
46
  - config/initializers/unifonic_integration.rb
47
+ - lib/generators/unifonic_integration/install/install_generator.rb
48
+ - lib/generators/unifonic_integration/install/templates/unifonic_integration_init.rb
47
49
  - lib/unifonic_integration.rb
48
50
  - lib/unifonic_integration/client.rb
49
51
  - lib/unifonic_integration/configuration.rb