Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1
with:
ruby-version: 3.1
ruby-version: 4.0
bundler-cache: true
- run: bundle install
- run: bundle exec rspec
Expand All @@ -18,7 +18,7 @@ jobs:
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1
with:
ruby-version: 3.1
ruby-version: 4.0
bundler-cache: true
- run: bundle install
- run: bundle exec rubocop
11 changes: 7 additions & 4 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
require:
- rubocop-performance

AllCops:
NewCops: enable
TargetRubyVersion: 2.6
TargetRubyVersion: 4.0
SuggestExtensions: false

plugins:
- rubocop-performance
Metrics/AbcSize:
Enabled: false
Metrics/BlockLength:
Expand All @@ -16,3 +17,5 @@ Naming/MemoizedInstanceVariableName:
Enabled: false
Style/Documentation:
Enabled: false
Style/HashAsLastArrayItem:
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The CI server has a cached version of rubocop that treats this rule differently depending on the ruby version. That's why this is added.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I don't understand. What is it that the CI server does if we don't disable this rule?

Enabled: false
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.2.2
4.0.1
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Changelog

## [1.1.0] - 2026-02-11

### Added
- Added `faraday ~> 2.0` as explicit runtime dependency
- Added `faraday-mashify ~> 1.0` as explicit runtime dependency
- Added `require 'faraday/mashify'` to main library file

### Upgrades
- Upgraded from Ruby 3.2.2 to Ruby 4.0.1
- Updated vertebrae dependency to >= 1.0.5
- Updated bundler development dependency to >= 2.1 (from ~> 2.1)
11 changes: 11 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,14 @@ git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }

# Specify your gem's dependencies in action_network_rest.gemspec
gemspec

group :development do
gem 'bundler', '>= 2.1'
gem 'debug', '> 0'
gem 'dotenv', '~> 2.7'
gem 'rake', '~> 13.0'
gem 'rspec', '~> 3.0'
gem 'rubocop', '> 0'
gem 'rubocop-performance', '> 0'
gem 'webmock', '~> 3.8.3'
end
14 changes: 4 additions & 10 deletions action_network_rest.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,11 @@ Gem::Specification.new do |spec|
end
spec.require_paths = ['lib']

spec.required_ruby_version = '>= 2.6'
spec.required_ruby_version = '>= 4.0.0'

spec.add_runtime_dependency 'vertebrae', '>= 1.0.0'
spec.add_dependency 'faraday', '~> 2.0'
spec.add_dependency 'faraday-mashify', '~> 1.0'
spec.add_dependency 'vertebrae', '>= 1.0.5'

spec.add_development_dependency 'bundler', '~> 2.1'
spec.add_development_dependency 'debug', '> 0'
spec.add_development_dependency 'dotenv', '~> 2.7'
spec.add_development_dependency 'rake', '~> 13.0'
spec.add_development_dependency 'rspec', '~> 3.0'
spec.add_development_dependency 'rubocop', '> 0'
spec.add_development_dependency 'rubocop-performance', '> 0'
spec.add_development_dependency 'webmock', '~> 3.8.3'
spec.metadata['rubygems_mfa_required'] = 'true'
end
1 change: 0 additions & 1 deletion bin/rake
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
# this file is here to facilitate running it.
#

require 'pathname'
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
Pathname.new(__FILE__).realpath)

Expand Down
1 change: 0 additions & 1 deletion bin/rspec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
# this file is here to facilitate running it.
#

require 'pathname'
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
Pathname.new(__FILE__).realpath)

Expand Down
1 change: 1 addition & 0 deletions lib/action_network_rest.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# frozen_string_literal: true

require 'vertebrae'
require 'faraday/mashify'

module ActionNetworkRest
extend Vertebrae::Base
Expand Down
4 changes: 0 additions & 4 deletions lib/action_network_rest/advocacy_campaigns.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@

module ActionNetworkRest
class AdvocacyCampaigns < Base
def initialize(client:)
super(client: client)
end

def base_path
'advocacy_campaigns/'
end
Expand Down
4 changes: 0 additions & 4 deletions lib/action_network_rest/campaigns.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@ module ActionNetworkRest
class Campaigns < Base
attr_accessor :campaign_id

def initialize(client:)
super(client: client)
end

def base_path
'campaigns/'
end
Expand Down
4 changes: 2 additions & 2 deletions lib/action_network_rest/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ module ActionNetworkRest
class Client < API
attr_accessor :api_key

def initialize(options = {}, &block)
def initialize(options = {}, &)
self.api_key = options[:api_key]
super(options, &block)
super
end

def default_options
Expand Down
4 changes: 0 additions & 4 deletions lib/action_network_rest/forms.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@

module ActionNetworkRest
class Forms < Base
def initialize(client:)
super(client: client)
end

def base_path
'forms/'
end
Expand Down
2 changes: 1 addition & 1 deletion lib/action_network_rest/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module ActionNetworkRest
VERSION = '1.0.1'
VERSION = '1.1.0'
end
2 changes: 1 addition & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
require 'webmock/rspec'

# Require everything in the `support` directory
Dir[File.join(File.dirname(__FILE__), 'support', '**', '*.rb')].sort.each { |f| require f }
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no need to sort here IMO

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aha, it looks like we originally did the sort because of https://docs.rubocop.org/rubocop/cops_lint.html#lintnondeterministicrequireorder, but that's no longer relevant with ruby 3+

Dir[File.join(File.dirname(__FILE__), 'support', '**', '*.rb')].each { |f| require f }

RSpec.configure do |config|
# Enable flags like --only-failures and --next-failure
Expand Down