-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from franzliedke/fl/modernize
Update CI, test dependencies and code style
- Loading branch information
Showing
14 changed files
with
207 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: Lint | ||
on: push | ||
jobs: | ||
rubocop: | ||
name: rubocop | ||
runs-on: ubuntu-20.04 | ||
|
||
steps: | ||
- uses: actions/checkout@master | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: 2.6 | ||
bundler-cache: true | ||
env: | ||
BUNDLE_JOBS: 4 | ||
BUNDLE_RETRY: 3 | ||
|
||
- name: Run rubocop | ||
run: bundle exec rubocop --parallel --color |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
name: test | ||
on: push | ||
jobs: | ||
rspec: | ||
name: "${{ matrix.ruby }} / ${{ matrix.adapter }}" | ||
runs-on: ubuntu-20.04 | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
ruby: | ||
- "3.0" | ||
- "2.7" | ||
- "2.6" | ||
- "2.5" | ||
|
||
steps: | ||
- uses: actions/checkout@master | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
env: | ||
BUNDLE_JOBS: 4 | ||
BUNDLE_RETRY: 3 | ||
|
||
- run: bundle exec rspec --color |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
inherit_gem: | ||
my-rubocop: default.yml | ||
|
||
AllCops: | ||
TargetRubyVersion: 2.5 | ||
Exclude: | ||
- vendor/**/* | ||
|
||
Layout/LineLength: | ||
Exclude: | ||
- spec/**/* | ||
|
||
RSpec/MessageSpies: | ||
EnforcedStyle: receive |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,18 @@ | ||
# frozen_string_literal: true | ||
|
||
source 'https://rubygems.org' | ||
|
||
# Specify your gem's dependencies in rack-remote.gemspec | ||
gemspec | ||
|
||
# Development gems | ||
# | ||
gem 'rake' | ||
gem 'rspec' | ||
gem 'coveralls' | ||
gem 'webmock', '~> 1.7' | ||
gem 'rack-test' | ||
gem 'rake' | ||
gem 'rspec' | ||
gem 'webmock', '~> 3.0' | ||
|
||
# Specify your gem's dependencies in gemspec | ||
gemroot = File.dirname File.absolute_path __FILE__ | ||
gemspec path: gemroot | ||
group :test do | ||
gem 'my-rubocop', github: 'jgraichen/my-rubocop' | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,18 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'bundler/gem_tasks' | ||
require 'rspec/core/rake_task' | ||
|
||
RSpec::Core::RakeTask.new(:spec) | ||
task :default => :spec | ||
task default: :spec | ||
|
||
begin | ||
require 'yard' | ||
require 'yard/rake/yardoc_task' | ||
|
||
YARD::Rake::YardocTask.new do |t| | ||
t.files = %w(lib/**/*.rb) | ||
t.options = %w(--output-dir doc/) | ||
t.files = %w[lib/**/*.rb] | ||
t.options = %w[--output-dir doc/] | ||
end | ||
rescue LoadError | ||
rescue LoadError # rubocop:disable Lint/SuppressedException | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
module Rack | ||
class Remote | ||
VERSION = '1.1.0' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,29 @@ | ||
# coding: utf-8 | ||
lib = File.expand_path('../lib', __FILE__) | ||
# frozen_string_literal: true | ||
|
||
lib = File.expand_path('lib', __dir__) | ||
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) | ||
|
||
require 'rack/remote/version' | ||
|
||
Gem::Specification.new do |spec| | ||
spec.name = 'rack-remote' | ||
spec.version = Rack::Remote::VERSION | ||
spec.authors = ['Jan Graichen'] | ||
spec.email = %w([email protected]) | ||
spec.summary = %q{Small request intercepting rack middleware to invoke remote calls over HTTP.} | ||
spec.description = %q{Small request intercepting rack middleware to invoke remote calls over HTTP.} | ||
spec.email = %w[[email protected]] | ||
spec.summary = 'Small request intercepting rack middleware to ' \ | ||
'invoke remote calls over HTTP.' | ||
spec.description = 'Small request intercepting rack middleware to ' \ | ||
'invoke remote calls over HTTP.' | ||
spec.homepage = 'https://github.com/jgraichen/rack-remote' | ||
spec.license = 'MIT' | ||
|
||
spec.files = `git ls-files`.split($/) | ||
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) } | ||
spec.files = `git ls-files -z`.split("\x0") | ||
spec.executables = spec.files.grep(%r{^bin/}) {|f| File.basename(f) } | ||
spec.test_files = spec.files.grep(%r{^(test|spec|features)/}) | ||
spec.require_paths = %w(lib) | ||
spec.require_paths = %w[lib] | ||
|
||
spec.add_dependency 'rack' | ||
spec.add_dependency 'multi_json' | ||
spec.add_dependency 'rack' | ||
|
||
spec.add_development_dependency 'bundler' | ||
end |
Oops, something went wrong.