Skip to content

Commit

Permalink
Modernize gem.
Browse files Browse the repository at this point in the history
  • Loading branch information
ioquatix committed Apr 24, 2024
1 parent ada9619 commit 9b19538
Show file tree
Hide file tree
Showing 19 changed files with 36 additions and 30 deletions.
4 changes: 4 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,7 @@ root = true
[*]
indent_style = tab
indent_size = 2

[*.{yml,yaml}]
indent_style = space
indent_size = 2
10 changes: 5 additions & 5 deletions .github/workflows/coverage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ jobs:
- ubuntu

ruby:
- "3.2"
- "3.3"

gemfile:
- gems/rack-v1.rb
- gems/rack-v2.rb
- gems/rack-v3.rb

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{matrix.ruby}}
Expand All @@ -40,7 +40,7 @@ jobs:
timeout-minutes: 5
run: bundle exec bake test

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
with:
name: coverage-${{matrix.os}}-${{matrix.ruby}}
path: .covered.db
Expand All @@ -50,10 +50,10 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2"
ruby-version: "3.3"
bundler-cache: true

- uses: actions/download-artifact@v3
Expand Down
11 changes: 4 additions & 7 deletions .github/workflows/documentation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ on:
branches:
- main

# Allows you to run this workflow manually from the Actions tab:
workflow_dispatch:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages:
permissions:
contents: read
Expand All @@ -28,11 +25,11 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2"
ruby-version: "3.3"
bundler-cache: true

- name: Installing packages
Expand All @@ -43,7 +40,7 @@ jobs:
run: bundle exec bake utopia:project:static --force no

- name: Upload documentation artifact
uses: actions/upload-pages-artifact@v1
uses: actions/upload-pages-artifact@v2
with:
path: docs

Expand All @@ -58,4 +55,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1
uses: actions/deploy-pages@v3
4 changes: 2 additions & 2 deletions .github/workflows/test-external.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ jobs:
- macos

ruby:
- "3.0"
- "3.1"
- "3.2"
- "3.3"

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{matrix.ruby}}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ jobs:
- macos

ruby:
- "3.0"
- "3.1"
- "3.2"
- "3.3"

gemfile:
- gems/rack-v1.rb
Expand All @@ -46,7 +46,7 @@ jobs:
experimental: true

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{matrix.ruby}}
Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/adapter.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022-2023, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

require 'rack'

Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/adapter/generic.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022-2023, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

require 'console'

Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/adapter/rack2.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022-2023, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

require 'console'

Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/adapter/rack3.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

require 'console'

Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/constants.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

module Protocol
module Rack
Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/input.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022-2023, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.
# Copyright, 2023, by Genki Takiuchi.

require 'protocol/http/body/stream'
Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/response.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

require_relative 'body'
require_relative 'constants'
Expand Down
2 changes: 1 addition & 1 deletion lib/protocol/rack/version.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022-2023, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

module Protocol
module Rack
Expand Down
2 changes: 1 addition & 1 deletion license.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# MIT License

Copyright, 2022-2023, by Samuel Williams.
Copyright, 2022-2024, by Samuel Williams.
Copyright, 2023, by Genki Takiuchi.

Permission is hereby granted, free of charge, to any person obtaining a copy
Expand Down
7 changes: 6 additions & 1 deletion protocol-rack.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,14 @@ Gem::Specification.new do |spec|

spec.homepage = "https://github.com/socketry/protocol-rack"

spec.metadata = {
"documentation_uri" => "https://socketry.github.io/protocol-rack/",
"source_code_uri" => "https://github.com/socketry/protocol-rack.git",
}

spec.files = Dir.glob(['{lib}/**/*', '*.md'], File::FNM_DOTMATCH, base: __dir__)

spec.required_ruby_version = ">= 3.0"
spec.required_ruby_version = ">= 3.1"

spec.add_dependency "protocol-http", "~> 0.23"
spec.add_dependency "rack", ">= 1.0"
Expand Down
2 changes: 1 addition & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ This project uses the [Developer Certificate of Origin](https://developercertifi

### Contributor Covenant

This project is governed by [Contributor Covenant](https://www.contributor-covenant.org/). All contributors and participants agree to abide by its terms.
This project is governed by the [Contributor Covenant](https://www.contributor-covenant.org/). All contributors and participants agree to abide by its terms.

## See Also

Expand Down
2 changes: 1 addition & 1 deletion test/protocol/rack/adapter.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022-2023, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

require 'rack/lint'

Expand Down
2 changes: 1 addition & 1 deletion test/protocol/rack/input.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022-2023, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.
# Copyright, 2023, by Genki Takiuchi.

require 'protocol/rack/input'
Expand Down
2 changes: 1 addition & 1 deletion test/protocol/rack/request.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2022, by Samuel Williams.
# Copyright, 2022-2024, by Samuel Williams.

require 'protocol/rack/request'
require 'protocol/rack/adapter'
Expand Down

0 comments on commit 9b19538

Please sign in to comment.