Skip to content

Commit

Permalink
feat(gemspec): Update gem details, add Rakefile
Browse files Browse the repository at this point in the history
  • Loading branch information
pandomic committed Apr 19, 2019
1 parent f970412 commit 249af87
Show file tree
Hide file tree
Showing 8 changed files with 31 additions and 16 deletions.
1 change: 1 addition & 0 deletions .rspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
--color
--require spec/spec_helper
--default-path .
--exclude-pattern vendor/**/*
1 change: 1 addition & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ AllCops:
TargetRubyVersion: 2.3
Exclude:
- !ruby/regexp /_spec\.rb\z/
- vendor/**/*

Documentation:
Enabled: false
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ cache: bundler
rvm:
- 2.3.3
before_install:
- gem install bundler -v 1.16.1
- gem install bundler -v 1.17.1
- bundle install
- rubocop
- bundle exec rubocop
- bundle exec rspec --version
- bundle exec rspec
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [0.1.0] - 2017-06-20
## [0.1.0] - 2019-04-19
### Added
- Global hooks for ActiveRecord 4.2.10.
- Overrides to ActiveRecord::Base, ActiveRecord::Relation, ActiveRecord::Persistence to serve callbacks.
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[![Build Status](https://travis-ci.org/Advanon/active_record_streams.svg?branch=master)](https://travis-ci.org/Advanon/active_record_streams)
[![Gem Version](https://badge.fury.io/rb/active_record_streams.svg)](https://badge.fury.io/rb/active_record_streams)

# Active Record Streams

A small library to stream ActiveRecord's create/update/delete
Expand Down
8 changes: 8 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# frozen_string_literal: true

require 'bundler/gem_tasks'
require 'rspec/core/rake_task'

RSpec::Core::RakeTask.new(:spec)

task default: :spec
27 changes: 14 additions & 13 deletions active_record_streams.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -10,36 +10,37 @@ Gem::Specification.new do |spec|
spec.authors = ['Advanon Team']
spec.email = ['[email protected]']

spec.summary = 'Write a short summary, because RubyGems requires one.'
spec.description = 'Write a longer description or delete this line.'
spec.homepage = 'https://advanon.com'
spec.summary = <<-HEREDOC
Stream ActiveRecord events via HTTP, AWS SNS or Kinesis streams
HEREDOC

spec.description = <<-HEREDOC
Publish events about changes to your ActiveRecord models to different
targets, like HTTP endpoints, AWS SNS topics or Kinesis streams
HEREDOC

spec.homepage = 'https://advanon.com'
spec.required_ruby_version = '>= 2.3.3'

# Prevent pushing this gem to RubyGems.org. To allow pushes either set the
# 'allowed_push_host' to allow pushing to a single host or delete this section
# to allow pushing to any host.
if spec.respond_to?(:metadata)
spec.metadata['allowed_push_host'] = 'http://mygemserver.com'
spec.metadata['allowed_push_host'] = 'https://rubygems.org'

spec.metadata['homepage_uri'] = spec.homepage

spec.metadata['source_code_uri'] =
'https://github.com/Advanon/active_record_streams'

spec.metadata['changelog_uri'] = 'Put your gem\'s CHANGELOG.md URL here.'
spec.metadata['changelog_uri'] =
'https://github.com/Advanon/active_record_streams/blob/master/CHANGELOG.md'
else
raise 'RubyGems 2.0 or newer is required to protect against ' \
'public gem pushes.'
end

# Specify which files should be added to the gem when it is released.
# The `git ls-files -z` loads the files in the RubyGem that have been
# added into git.
spec.files = Dir.chdir(File.expand_path(__dir__)) do
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(spec)/}) }
end

# spec.bindir = 'exe'
# spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ['lib']

spec.add_dependency 'activerecord', '~> 4.2.10'
Expand Down
1 change: 1 addition & 0 deletions lib/active_record_streams.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
require 'active_record_streams/publishers/kinesis_stream'
require 'active_record_streams/publishers/sns_client'
require 'active_record_streams/publishers/sns_stream'
require 'active_record_streams/publishers/http_stream'

require 'active_record_streams/extensions/active_record/persistence'
require 'active_record_streams/extensions/active_record/relation'
Expand Down

0 comments on commit 249af87

Please sign in to comment.