Sha256: 57b47ae1dcf052fb6bf9604107f40741dfbc03e45542c6552b15b22c4155043a

Contents?: true

Size: 1.86 KB

Versions: 1

Compression:

Stored size: 1.86 KB

Contents

# CherrypieRailsSdk

Cherrypie Rails SDK.

## Installation

Add this line to your application's Gemfile:

```ruby
gem 'cherrypie-rails-sdk', '~> 0.2.4'
```

And then execute:

    $ bundle install

Or install it yourself as:

    $ gem install cherrypie-rails-sdk

## Usage

```
# config/application.rb

require_relative "boot"

require "rails/all"
require 'cherrypie_rails_sdk'

# Require the gems listed in Gemfile, including any gems
# you've limited to :test, :development, or :production.
Bundler.require(*Rails.groups)

module HelloApp
  class Application < Rails::Application
    # Initialize configuration defaults for originally generated Rails version.
    config.load_defaults 6.1

    # Configuration for the application, engines, and railties goes here.
    #
    # These settings can be overridden in specific environments using the files
    # in config/environments, which are processed later.
    #
    # config.time_zone = "Central Time (US & Canada)"
    # config.eager_load_paths << Rails.root.join("extras")

  config.middleware.use(CherrypieRailsSdk::Middleware, "<TOKEN>",
  lambda{ |request| {
    # request: ActionDispatch::Request
    "entityKey"=> "1", "name"=> "RAILS"
    } },
  )
  end
end
```

## Development

After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).

## Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/cherrypie_rails_sdk.

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
cherrypie-rails-sdk-0.2.5 README.md