Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Updating dependencies #40

Merged
merged 1 commit into from
Oct 9, 2024
Merged
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: 4 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# These are supported funding model platforms

github: whomwah
buy_me_a_coffee: duncanrobertson
2 changes: 1 addition & 1 deletion .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
ruby: ['2.6', '2.7', '3.0', '3.1', '3.2']
ruby: ['3.0', '3.1', '3.2', '3.3']
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
Expand Down
65 changes: 37 additions & 28 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,49 +7,58 @@ GEM
remote: https://rubygems.org/
specs:
ast (2.4.2)
json (2.6.3)
language_server-protocol (3.17.0.2)
minitest (5.16.3)
parallel (1.22.1)
parser (3.1.3.0)
json (2.7.2)
language_server-protocol (3.17.0.3)
lint_roller (1.1.0)
minitest (5.25.1)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
racc
racc (1.8.1)
rainbow (3.1.1)
rake (13.0.6)
regexp_parser (2.6.1)
rexml (3.2.5)
rubocop (1.40.0)
rake (13.2.1)
regexp_parser (2.9.2)
rubocop (1.66.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
parallel (~> 1.10)
parser (>= 3.1.2.1)
parser (>= 3.3.0.2)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.8, < 3.0)
rexml (>= 3.2.5, < 4.0)
rubocop-ast (>= 1.23.0, < 2.0)
regexp_parser (>= 2.4, < 3.0)
rubocop-ast (>= 1.32.2, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 1.4.0, < 3.0)
rubocop-ast (1.24.0)
parser (>= 3.1.1.0)
rubocop-performance (1.15.1)
rubocop (>= 1.7.0, < 2.0)
rubocop-ast (>= 0.4.0)
ruby-progressbar (1.11.0)
standard (1.20.0)
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-performance (1.22.1)
rubocop (>= 1.48.1, < 2.0)
rubocop-ast (>= 1.31.1, < 2.0)
ruby-progressbar (1.13.0)
standard (1.41.0)
language_server-protocol (~> 3.17.0.2)
rubocop (= 1.40.0)
rubocop-performance (= 1.15.1)
standardrb (1.0.1)
standard
unicode-display_width (2.3.0)
lint_roller (~> 1.0)
rubocop (~> 1.66.0)
standard-custom (~> 1.0.0)
standard-performance (~> 1.5)
standard-custom (1.0.2)
lint_roller (~> 1.0)
rubocop (~> 1.50)
standard-performance (1.5.0)
lint_roller (~> 1.1)
rubocop-performance (~> 1.22.0)
unicode-display_width (2.6.0)

PLATFORMS
aarch64-linux
ruby

DEPENDENCIES
bundler (~> 2.0)
minitest (~> 5.0)
rake (~> 13.0)
rqrcode_core!
standardrb (~> 1.0)
standard (~> 1.41)

BUNDLED WITH
2.3.26
2.5.16
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Features:
* It is an encoding library. You can't decode QR Codes with it.
* The interface is simple and assumes you just want to encode a string into a QR Code, but also allows for encoding multiple segments.
* QR Code is trademarked by Denso Wave inc.
* Minimum Ruby version is `>= 3.0.0`

`rqrcode_core` is the basis of the popular `rqrcode` gem [https://github.com/whomwah/rqrcode]. This gem allows you to generate different renderings of your QR Code, including `png`, `svg` and `ansi`.

Expand Down
10 changes: 5 additions & 5 deletions lib/rqrcode_core/qrcode/qr_code.rb
Original file line number Diff line number Diff line change
Expand Up @@ -274,8 +274,8 @@ def place_position_probe_pattern(row, col) # :nodoc:
(-1..7).each do |c|
next unless (col + c).between?(0, @module_count - 1)

is_vert_line = (r.between?(0, 6) && (c == 0 || c == 6))
is_horiz_line = (c.between?(0, 6) && (r == 0 || r == 6))
is_vert_line = r.between?(0, 6) && (c == 0 || c == 6)
is_horiz_line = c.between?(0, 6) && (r == 0 || r == 6)
is_square = r.between?(2, 4) && c.between?(2, 4)

is_part_of_probe = is_vert_line || is_horiz_line || is_square
Expand Down Expand Up @@ -315,7 +315,7 @@ def place_position_adjust_pattern # :nodoc:

(-2..2).each do |r|
(-2..2).each do |c|
is_part_of_pattern = (r.abs == 2 || c.abs == 2 || (r == 0 && c == 0))
is_part_of_pattern = r.abs == 2 || c.abs == 2 || (r == 0 && c == 0)
@modules[row + r][col + c] = is_part_of_pattern
end
end
Expand All @@ -327,7 +327,7 @@ def place_version_info(test) # :nodoc:
bits = QRUtil.get_bch_version(@version)

18.times do |i|
mod = (!test && ((bits >> i) & 1) == 1)
mod = !test && ((bits >> i) & 1) == 1
@modules[(i / 3).floor][ i % 3 + @module_count - 8 - 3 ] = mod
@modules[i % 3 + @module_count - 8 - 3][ (i / 3).floor ] = mod
end
Expand All @@ -338,7 +338,7 @@ def place_format_info(test, mask_pattern) # :nodoc:
bits = QRUtil.get_bch_format_info(data)

QRFORMATINFOLENGTH.times do |i|
mod = (!test && ((bits >> i) & 1) == 1)
mod = !test && ((bits >> i) & 1) == 1

# vertical
row = if i < 6
Expand Down
4 changes: 2 additions & 2 deletions rqrcode_core.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ Gem::Specification.new do |spec|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]

spec.required_ruby_version = ">= 2.6"
spec.required_ruby_version = ">= 3.0.0"
spec.add_development_dependency "bundler", "~> 2.0"
spec.add_development_dependency "rake", "~> 13.0"
spec.add_development_dependency "minitest", "~> 5.0"
spec.add_development_dependency "standardrb", "~> 1.0"
spec.add_development_dependency "standard", "~> 1.41"
end
Loading