shopify-sinatra-app 0.10.0 → 0.11.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.
- checksums.yaml +4 -4
- data/.travis.yml +1 -1
- data/CHANGELOG +7 -0
- data/README.md +1 -1
- data/example/Gemfile +3 -3
- data/example/db/schema.rb +5 -5
- data/example/src/app.rb +2 -0
- data/lib/sinatra/shopify-sinatra-app.rb +1 -5
- data/shopify-sinatra-app.gemspec +2 -4
- metadata +4 -32
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: 06c208a5e6a5d5b7f496276e1aedea79466f8d7abc6082afdb7cff0b88223d49
         | 
| 4 | 
            +
              data.tar.gz: 18439bd6c8f38719b02b7afdd1ec7559bf1b016f97fcca41d473739c85708042
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: fbd6555480c19155bb742b423e27df1f53aacdb3779134fdc8b18294926611f863f43abed6a2393e4994247381cc21653c64a4171786063da5f022b1aef52f2d
         | 
| 7 | 
            +
              data.tar.gz: bae80dff8e96cc0dd29febed95b8a2336a944cab4b397803f9ad816b4c93f6996e7cc094e605bb5e3d88a12fbbbb2cf1e516d81f7575cfc7eec68dd50ea8afe1
         | 
    
        data/.travis.yml
    CHANGED
    
    
    
        data/CHANGELOG
    CHANGED
    
    | @@ -1,3 +1,10 @@ | |
| 1 | 
            +
            0.11.0
         | 
| 2 | 
            +
            ----------
         | 
| 3 | 
            +
            * remove rack-flash3 use sinatra-flash instead
         | 
| 4 | 
            +
            * remove a duplicate config of sessions that was breaking the same_site fix
         | 
| 5 | 
            +
            * remove a runtime dependency that didn't end up being used for the same_site fix but was added anyways
         | 
| 6 | 
            +
            * update ruby and rake versions
         | 
| 7 | 
            +
             | 
| 1 8 | 
             
            0.10.0
         | 
| 2 9 | 
             
            ------
         | 
| 3 10 | 
             
            * Add the api_version to settings and update to 2019-07
         | 
    
        data/README.md
    CHANGED
    
    | @@ -128,7 +128,7 @@ note - a flash must be followed by a redirect or it won't work! | |
| 128 128 |  | 
| 129 129 | 
             
            Developing
         | 
| 130 130 | 
             
            ----------
         | 
| 131 | 
            -
            The embedded app sdk won't load non https content so you'll need to use a forwarding service like [ngrok](https://ngrok.com/) or [forwardhq](https://forwardhq.com/). Set your application url in the [Shopify Partner area](https://app.shopify.com/services/partners/api_clients) to your forwarded url | 
| 131 | 
            +
            The embedded app sdk won't load non https content so you'll need to use a forwarding service like [ngrok](https://ngrok.com/) or [forwardhq](https://forwardhq.com/). Set your application url in the [Shopify Partner area](https://app.shopify.com/services/partners/api_clients) to your forwarded url and set the redirect_uri to your forwarded url + `/auth/shopify/callback` which will allow you to install your app on a live shop while running it locally.
         | 
| 132 132 |  | 
| 133 133 | 
             
            To run the app locally we use `foreman` which comes with the [Heroku Toolbelt](https://devcenter.heroku.com/articles/quickstart). Foreman handles running our application and setting our credentials as environment variables. To run the application type:
         | 
| 134 134 |  | 
    
        data/example/Gemfile
    CHANGED
    
    | @@ -1,9 +1,9 @@ | |
| 1 1 | 
             
            source 'https://rubygems.org'
         | 
| 2 | 
            -
            ruby '2. | 
| 2 | 
            +
            ruby '2.6.3'
         | 
| 3 3 |  | 
| 4 4 | 
             
            gem 'shopify-sinatra-app', path: '../'
         | 
| 5 5 | 
             
            gem 'sinatra-activerecord'
         | 
| 6 | 
            -
            gem ' | 
| 6 | 
            +
            gem 'sinatra-flash'
         | 
| 7 7 |  | 
| 8 8 | 
             
            group :production do
         | 
| 9 9 | 
             
              gem 'pg'
         | 
| @@ -15,7 +15,7 @@ group :development, :test do | |
| 15 15 | 
             
            end
         | 
| 16 16 |  | 
| 17 17 | 
             
            group :development do
         | 
| 18 | 
            -
              gem 'rake'
         | 
| 18 | 
            +
              gem 'rake', '>= 12.3.3'
         | 
| 19 19 | 
             
              gem 'foreman'
         | 
| 20 20 | 
             
              gem 'dotenv'
         | 
| 21 21 | 
             
            end
         | 
    
        data/example/db/schema.rb
    CHANGED
    
    | @@ -2,11 +2,11 @@ | |
| 2 2 | 
             
            # of editing this file, please use the migrations feature of Active Record to
         | 
| 3 3 | 
             
            # incrementally modify your database, and then regenerate this schema definition.
         | 
| 4 4 | 
             
            #
         | 
| 5 | 
            -
            #  | 
| 6 | 
            -
            #  | 
| 7 | 
            -
            #  | 
| 8 | 
            -
            # from scratch.  | 
| 9 | 
            -
            #  | 
| 5 | 
            +
            # This file is the source Rails uses to define your schema when running `rails
         | 
| 6 | 
            +
            # db:schema:load`. When creating a new database, `rails db:schema:load` tends to
         | 
| 7 | 
            +
            # be faster and is potentially less error prone than running all of your
         | 
| 8 | 
            +
            # migrations from scratch. Old migrations may fail to apply correctly if those
         | 
| 9 | 
            +
            # migrations use external dependencies or application code.
         | 
| 10 10 | 
             
            #
         | 
| 11 11 | 
             
            # It's strongly recommended that you check this file into your version control system.
         | 
| 12 12 |  | 
    
        data/example/src/app.rb
    CHANGED
    
    
| @@ -1,7 +1,6 @@ | |
| 1 1 | 
             
            require 'sinatra/base'
         | 
| 2 2 | 
             
            require 'sinatra/activerecord'
         | 
| 3 3 |  | 
| 4 | 
            -
            require 'rack-flash'
         | 
| 5 4 | 
             
            require 'attr_encrypted'
         | 
| 6 5 | 
             
            require 'active_support/all'
         | 
| 7 6 |  | 
| @@ -157,6 +156,7 @@ module Sinatra | |
| 157 156 | 
             
                def self.registered(app)
         | 
| 158 157 | 
             
                  app.helpers Shopify::Methods
         | 
| 159 158 | 
             
                  app.register Sinatra::ActiveRecordExtension
         | 
| 159 | 
            +
                  app.enable :inline_templates
         | 
| 160 160 |  | 
| 161 161 | 
             
                  app.set :database_file, File.expand_path('config/database.yml')
         | 
| 162 162 | 
             
                  app.set :views, File.expand_path('views')
         | 
| @@ -164,9 +164,6 @@ module Sinatra | |
| 164 164 | 
             
                  app.set :erb, layout: :'layouts/application'
         | 
| 165 165 | 
             
                  app.set :protection, except: :frame_options
         | 
| 166 166 |  | 
| 167 | 
            -
                  app.enable :sessions
         | 
| 168 | 
            -
                  app.enable :inline_templates
         | 
| 169 | 
            -
             | 
| 170 167 | 
             
                  app.set :api_version, '2019-07'
         | 
| 171 168 | 
             
                  app.set :scope, 'read_products, read_orders'
         | 
| 172 169 |  | 
| @@ -174,7 +171,6 @@ module Sinatra | |
| 174 171 | 
             
                  app.set :shared_secret, ENV['SHOPIFY_SHARED_SECRET']
         | 
| 175 172 | 
             
                  app.set :secret, ENV['SECRET']
         | 
| 176 173 |  | 
| 177 | 
            -
                  app.use Rack::Flash, sweep: true
         | 
| 178 174 | 
             
                  app.use Rack::MethodOverride
         | 
| 179 175 | 
             
                  app.use Rack::Session::Cookie, key: 'rack.session',
         | 
| 180 176 | 
             
                                                 path: '/',
         | 
    
        data/shopify-sinatra-app.gemspec
    CHANGED
    
    | @@ -1,6 +1,6 @@ | |
| 1 1 | 
             
            Gem::Specification.new do |s|
         | 
| 2 2 | 
             
              s.name = 'shopify-sinatra-app'
         | 
| 3 | 
            -
              s.version = '0. | 
| 3 | 
            +
              s.version = '0.11.0'
         | 
| 4 4 |  | 
| 5 5 | 
             
              s.summary     = 'A classy shopify app'
         | 
| 6 6 | 
             
              s.description = 'A Sinatra extension for building Shopify Apps. Akin to the shopify_app gem but for Sinatra'
         | 
| @@ -15,15 +15,13 @@ Gem::Specification.new do |s| | |
| 15 15 |  | 
| 16 16 | 
             
              s.add_runtime_dependency 'sinatra', '~> 2.0.2'
         | 
| 17 17 | 
             
              s.add_runtime_dependency 'sinatra-activerecord', '~> 2.0.9'
         | 
| 18 | 
            -
              s.add_runtime_dependency 'rack-flash3', '~> 1.0.5'
         | 
| 19 18 | 
             
              s.add_runtime_dependency 'activesupport'
         | 
| 20 19 | 
             
              s.add_runtime_dependency 'attr_encrypted', '~> 3.1.0'
         | 
| 21 20 |  | 
| 22 21 | 
             
              s.add_runtime_dependency 'shopify_api', '>= 7.0.1', '< 9.1.0'
         | 
| 23 22 | 
             
              s.add_runtime_dependency 'omniauth-shopify-oauth2'
         | 
| 24 | 
            -
              s.add_runtime_dependency 'browser_sniffer', '~> 1.1.3'
         | 
| 25 23 |  | 
| 26 | 
            -
              s.add_development_dependency 'rake'
         | 
| 24 | 
            +
              s.add_development_dependency 'rake', '>= 12.3.3'
         | 
| 27 25 | 
             
              s.add_development_dependency 'sqlite3'
         | 
| 28 26 | 
             
              s.add_development_dependency 'minitest'
         | 
| 29 27 | 
             
              s.add_development_dependency 'rack-test'
         | 
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: shopify-sinatra-app
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 0. | 
| 4 | 
            +
              version: 0.11.0
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Kevin Hughes
         | 
| 8 8 | 
             
            autorequire: 
         | 
| 9 9 | 
             
            bindir: bin
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date: 2020- | 
| 11 | 
            +
            date: 2020-03-29 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: sinatra
         | 
| @@ -38,20 +38,6 @@ dependencies: | |
| 38 38 | 
             
                - - "~>"
         | 
| 39 39 | 
             
                  - !ruby/object:Gem::Version
         | 
| 40 40 | 
             
                    version: 2.0.9
         | 
| 41 | 
            -
            - !ruby/object:Gem::Dependency
         | 
| 42 | 
            -
              name: rack-flash3
         | 
| 43 | 
            -
              requirement: !ruby/object:Gem::Requirement
         | 
| 44 | 
            -
                requirements:
         | 
| 45 | 
            -
                - - "~>"
         | 
| 46 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 47 | 
            -
                    version: 1.0.5
         | 
| 48 | 
            -
              type: :runtime
         | 
| 49 | 
            -
              prerelease: false
         | 
| 50 | 
            -
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 51 | 
            -
                requirements:
         | 
| 52 | 
            -
                - - "~>"
         | 
| 53 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 54 | 
            -
                    version: 1.0.5
         | 
| 55 41 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 56 42 | 
             
              name: activesupport
         | 
| 57 43 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| @@ -114,34 +100,20 @@ dependencies: | |
| 114 100 | 
             
                - - ">="
         | 
| 115 101 | 
             
                  - !ruby/object:Gem::Version
         | 
| 116 102 | 
             
                    version: '0'
         | 
| 117 | 
            -
            - !ruby/object:Gem::Dependency
         | 
| 118 | 
            -
              name: browser_sniffer
         | 
| 119 | 
            -
              requirement: !ruby/object:Gem::Requirement
         | 
| 120 | 
            -
                requirements:
         | 
| 121 | 
            -
                - - "~>"
         | 
| 122 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 123 | 
            -
                    version: 1.1.3
         | 
| 124 | 
            -
              type: :runtime
         | 
| 125 | 
            -
              prerelease: false
         | 
| 126 | 
            -
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 127 | 
            -
                requirements:
         | 
| 128 | 
            -
                - - "~>"
         | 
| 129 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 130 | 
            -
                    version: 1.1.3
         | 
| 131 103 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 132 104 | 
             
              name: rake
         | 
| 133 105 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| 134 106 | 
             
                requirements:
         | 
| 135 107 | 
             
                - - ">="
         | 
| 136 108 | 
             
                  - !ruby/object:Gem::Version
         | 
| 137 | 
            -
                    version:  | 
| 109 | 
            +
                    version: 12.3.3
         | 
| 138 110 | 
             
              type: :development
         | 
| 139 111 | 
             
              prerelease: false
         | 
| 140 112 | 
             
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 141 113 | 
             
                requirements:
         | 
| 142 114 | 
             
                - - ">="
         | 
| 143 115 | 
             
                  - !ruby/object:Gem::Version
         | 
| 144 | 
            -
                    version:  | 
| 116 | 
            +
                    version: 12.3.3
         | 
| 145 117 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 146 118 | 
             
              name: sqlite3
         | 
| 147 119 | 
             
              requirement: !ruby/object:Gem::Requirement
         |