Skip to content

Commit b0e49a5

Browse files
committed
Add the iro-support gem
1 parent 6eae8fb commit b0e49a5

38 files changed

+1103
-1
lines changed

Gemfile.lock

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
PATH
2+
remote: iro-support-rb
3+
specs:
4+
iro-support (0.1.0)
5+
zeitwerk (~> 2.7)
6+
17
GEM
28
remote: https://rubygems.org/
39
specs:
@@ -30,7 +36,7 @@ GEM
3036
diff-lcs (>= 1.2.0, < 2.0)
3137
rspec-support (~> 3.13.0)
3238
rspec-support (3.13.4)
33-
rubocop (1.75.7)
39+
rubocop (1.75.8)
3440
json (~> 2.3)
3541
language_server-protocol (~> 3.17.0.2)
3642
lint_roller (~> 1.1.0)
@@ -73,13 +79,15 @@ GEM
7379
webrick (1.9.1)
7480
yard (0.9.37)
7581
yard-sitemap (1.0.1)
82+
zeitwerk (2.7.3)
7683

7784
PLATFORMS
7885
arm64-darwin-24
7986
ruby
8087

8188
DEPENDENCIES
8289
github-markup
90+
iro-support!
8391
redcarpet
8492
rspec
8593
rubocop

iro-gems.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
iro-support:
2+
path: iro-support-rb
3+
repo: [email protected]:iro-lib/iro-support-rb.git
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: github-actions
4+
directory: /
5+
schedule:
6+
interval: weekly
7+
day: monday
8+
labels:
9+
- dependabot
10+
- dependencies
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
11+
jobs:
12+
13+
lint:
14+
name: Lint
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Setup project
18+
uses: actions/checkout@v4
19+
- name: Setup ruby
20+
uses: ruby/setup-ruby@v1
21+
with:
22+
bundler-cache: true
23+
ruby-version: 3.2
24+
- name: Lint ruby
25+
run: bundle exec rubocop
26+
27+
test:
28+
name: Test (ruby ${{ matrix.ruby_version }})
29+
env:
30+
CODACY_PROJECT_TOKEN: ${{ secrets.CODACY_PROJECT_TOKEN }}
31+
runs-on: ubuntu-latest
32+
steps:
33+
- name: Setup project
34+
uses: actions/checkout@v4
35+
- name: Setup ruby
36+
uses: ruby/setup-ruby@v1
37+
with:
38+
bundler-cache: true
39+
ruby-version: ${{ matrix.ruby_version }}
40+
- name: Run RSpec
41+
run: bundle exec rspec
42+
- name: Report Coverage
43+
if: env.CODACY_PROJECT_TOKEN != ''
44+
shell: bash
45+
run: bash <(curl -Ls https://coverage.codacy.com/get.sh)
46+
strategy:
47+
matrix:
48+
ruby_version:
49+
- 3.2
50+
- 3.3
51+
- 3.4
52+
53+
package:
54+
name: Package
55+
runs-on: ubuntu-latest
56+
steps:
57+
- name: Setup project
58+
uses: actions/checkout@v4
59+
- name: Setup ruby
60+
uses: ruby/setup-ruby@v1
61+
with:
62+
bundler-cache: true
63+
ruby-version: 3.2
64+
- name: Package gem
65+
run: bin/build

iro-support-rb/.gitignore

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
*.gem
2+
*.rbc
3+
/.config
4+
/coverage/
5+
/InstalledFiles
6+
/logs/
7+
/pkg/
8+
/spec/reports/
9+
/spec/examples.txt
10+
/test/tmp/
11+
/test/version_tmp/
12+
/tmp/
13+
14+
# Used by dotenv library to load environment variables.
15+
# .env
16+
17+
# Ignore Byebug command history file.
18+
.byebug_history
19+
20+
## Documentation cache and generated files:
21+
/.yardoc/
22+
/_yardoc/
23+
/doc/
24+
/rdoc/
25+
26+
## Environment normalization:
27+
/.bundle/
28+
/vendor/bundle
29+
/lib/bundler/man/
30+
31+
# for a library or gem, you might want to ignore these files since the code is
32+
# intended to run in multiple environments; otherwise, check them in:
33+
Gemfile.lock
34+
# .ruby-version
35+
# .ruby-gemset
36+
37+
# unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
38+
.rvmrc
39+
40+
# Used by RuboCop. Remote config files pulled in from inherit_from directive.
41+
.rubocop-https?--*

iro-support-rb/.rspec

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
--require spec_helper
2+
--format documentation
3+
--order rand
4+
--color

iro-support-rb/.rubocop.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
inherit_from:
2+
# TODO: change this to a remote url
3+
- ../.rubocop.yml
4+
5+
Naming/FileName:
6+
Exclude:
7+
- lib/iro-support.rb

iro-support-rb/.ruby-version

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
3.2.8

iro-support-rb/.yardopts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
lib/**/*.rb
2+
--title Iro::Support
3+
--readme README.md
4+
--no-private
5+
--protected
6+
--markup markdown
7+
--markup-provider redcarpet
8+
--embed-mixins
9+
--files LICENSE

iro-support-rb/Gemfile

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# frozen_string_literal: true
2+
3+
require 'yaml'
4+
5+
source 'https://rubygems.org'
6+
gemspec
7+
8+
ruby '~> 3.2'
9+
10+
group :iro do
11+
YAML.load_file(File.expand_path('iro-gems.yml', File.dirname(__FILE__)))&.each_pair do |gem_name, config|
12+
gem gem_name, path: config['path'] if Dir.exist?(config['path'])
13+
end
14+
end
15+
16+
group :doc do
17+
gem 'github-markup', require: false
18+
gem 'redcarpet', require: false
19+
gem 'webrick', require: false
20+
gem 'yard', require: false
21+
gem 'yard-sitemap', require: false
22+
end
23+
24+
group :lint do
25+
gem 'rubocop', require: false
26+
gem 'rubocop-ordered_methods', require: false
27+
gem 'rubocop-performance', require: false
28+
gem 'rubocop-rspec', require: false
29+
gem 'rubocop-thread_safety', require: false
30+
gem 'rubocop-yard', require: false
31+
end
32+
33+
group :test do
34+
gem 'rspec', require: false
35+
gem 'simplecov', require: false
36+
gem 'simplecov-lcov', require: false
37+
end

0 commit comments

Comments
 (0)