Skip to content

Commit

Permalink
Modernize gem.
Browse files Browse the repository at this point in the history
  • Loading branch information
ioquatix committed Feb 20, 2024
1 parent df48675 commit 7611099
Show file tree
Hide file tree
Showing 13 changed files with 50 additions and 27 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 @@ -21,10 +21,10 @@ jobs:
- macos

ruby:
- "3.1"
- "3.3"

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{matrix.ruby}}
Expand All @@ -34,7 +34,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 @@ -44,10 +44,10 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: "3.1"
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.1"
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
5 changes: 3 additions & 2 deletions .github/workflows/test-external.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,13 @@ jobs:
- macos

ruby:
- "2.7"
- "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
5 changes: 3 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@ jobs:
- macos

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

experimental: [false]

Expand All @@ -39,7 +40,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
8 changes: 1 addition & 7 deletions async-container.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,8 @@ Gem::Specification.new do |spec|

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

spec.required_ruby_version = ">= 2.5"
spec.required_ruby_version = ">= 3.0"

spec.add_dependency "async"
spec.add_dependency "async-io"

spec.add_development_dependency "bake-test"
spec.add_development_dependency "bake-test-external"
spec.add_development_dependency "bundler"
spec.add_development_dependency "covered"
spec.add_development_dependency "sus"
end
4 changes: 4 additions & 0 deletions examples/benchmark/scalability.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# frozen_string_literal: true

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

# gem install async-container
gem "async-container"
Expand Down
2 changes: 0 additions & 2 deletions examples/controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
# frozen_string_literal: true

# Released under the MIT License.
# Copyright, 2019-2022, by Samuel Williams.
# Copyright, 2019, by Yuji Yaginuma.
# Copyright, 2022, by Anton Sozontov.

require '../lib/async/container/controller'
Expand Down
4 changes: 4 additions & 0 deletions examples/http/client.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# frozen_string_literal: true

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

require 'async'
require 'async/http/endpoint'
Expand Down
4 changes: 4 additions & 0 deletions examples/http/server.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# frozen_string_literal: true

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

require 'async/container'

Expand Down
10 changes: 9 additions & 1 deletion gems.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, 2020-2022, by Samuel Williams.
# Copyright, 2017-2022, by Samuel Williams.

source 'https://rubygems.org'

Expand All @@ -14,3 +14,11 @@

gem "utopia-project"
end

group :test do
gem "sus"
gem "covered"

gem "bake-test"
gem "bake-test-external"
end
2 changes: 1 addition & 1 deletion lib/async/container/group.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, 2019-2022, by Samuel Williams.
# Copyright, 2018-2022, by Samuel Williams.

require 'fiber'
require 'async/clock'
Expand Down
8 changes: 8 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,11 @@ We welcome contributions to this project.
3. Commit your changes (`git commit -am 'Add some feature'`).
4. Push to the branch (`git push origin my-new-feature`).
5. Create new Pull Request.

### Developer Certificate of Origin

This project uses the [Developer Certificate of Origin](https://developercertificate.org/). All contributors to this project must agree to this document to have their contributions accepted.

### Contributor Covenant

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

0 comments on commit 7611099

Please sign in to comment.