Skip to content

Commit

Permalink
Merge pull request #1792 from Shopify/centralize_ruby_version
Browse files Browse the repository at this point in the history
Centralize Ruby Version to `.ruby-version`
  • Loading branch information
peterzhu2118 committed Apr 11, 2024
2 parents 6bf1877 + 88d013c commit 77bc56a
Show file tree
Hide file tree
Showing 8 changed files with 78 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/liquid.yml
Expand Up @@ -22,6 +22,7 @@ jobs:
with:
ruby-version: ${{ matrix.entry.ruby }}
bundler-cache: true
bundler: latest
- run: bundle exec rake
continue-on-error: ${{ matrix.entry.allowed-failure }}

Expand All @@ -31,6 +32,5 @@ jobs:
- uses: actions/checkout@v3
- uses: ruby/setup-ruby@v1
with:
ruby-version: 3.3
bundler-cache: true
- run: bundle exec rake memory_profile:run
2 changes: 0 additions & 2 deletions .gitignore
Expand Up @@ -4,7 +4,5 @@
pkg
*.rbc
.rvmrc
.ruby-version
Gemfile.lock
.bundle
.byebug_history
1 change: 0 additions & 1 deletion .rubocop.yml
Expand Up @@ -10,7 +10,6 @@ Performance:
Enabled: true

AllCops:
TargetRubyVersion: 2.7
NewCops: disable
SuggestExtensions: false
Exclude:
Expand Down
1 change: 1 addition & 0 deletions .ruby-version
@@ -0,0 +1 @@
3.3.0
2 changes: 1 addition & 1 deletion Gemfile
Expand Up @@ -18,7 +18,7 @@ group :benchmark, :test do
end

group :test do
gem 'rubocop', '~> 1.44.0'
gem 'rubocop', '~> 1.61.0'
gem 'rubocop-shopify', '~> 2.12.0', require: false
gem 'rubocop-performance', require: false

Expand Down
73 changes: 73 additions & 0 deletions Gemfile.lock
@@ -0,0 +1,73 @@
GIT
remote: https://github.com/Shopify/liquid-c.git
revision: 5a786af7284df55e013ea20551c4b688d02e8326
ref: main
specs:
liquid-c (4.2.0)
liquid (>= 5.0.1)

PATH
remote: .
specs:
liquid (5.5.0)

GEM
remote: https://rubygems.org/
specs:
ast (2.4.2)
benchmark-ips (2.13.0)
json (2.7.2)
language_server-protocol (3.17.0.3)
memory_profiler (1.0.1)
minitest (5.22.3)
parallel (1.24.0)
parser (3.3.0.5)
ast (~> 2.4.1)
racc
racc (1.7.3)
rainbow (3.1.1)
rake (13.2.1)
regexp_parser (2.9.0)
rexml (3.2.6)
rubocop (1.61.0)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
parallel (~> 1.10)
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.30.0, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.31.2)
parser (>= 3.3.0.4)
rubocop-performance (1.19.1)
rubocop (>= 1.7.0, < 2.0)
rubocop-ast (>= 0.4.0)
rubocop-shopify (2.12.0)
rubocop (~> 1.44)
ruby-progressbar (1.13.0)
stackprof (0.2.26)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
unicode-display_width (2.5.0)

PLATFORMS
ruby

DEPENDENCIES
benchmark-ips
liquid!
liquid-c!
memory_profiler
minitest
rake (~> 13.0)
rubocop (~> 1.61.0)
rubocop-performance
rubocop-shopify (~> 2.12.0)
stackprof
terminal-table

BUNDLED WITH
2.5.7
2 changes: 1 addition & 1 deletion lib/liquid/context.rb
Expand Up @@ -27,7 +27,7 @@ def initialize(environments = {}, outer_scope = {}, registers = {}, rethrow_erro
@environments.flatten!

@static_environments = [static_environments].flatten(1).freeze
@scopes = [(outer_scope || {})]
@scopes = [outer_scope || {}]
@registers = registers.is_a?(Registers) ? registers : Registers.new(registers)
@errors = []
@partial = false
Expand Down
2 changes: 1 addition & 1 deletion lib/liquid/tags/if.rb
Expand Up @@ -111,7 +111,7 @@ def strict_parse(markup)
def parse_binary_comparisons(p)
condition = parse_comparison(p)
first_condition = condition
while (op = (p.id?('and') || p.id?('or')))
while (op = p.id?('and') || p.id?('or'))
child_condition = parse_comparison(p)
condition.send(op, child_condition)
condition = child_condition
Expand Down

0 comments on commit 77bc56a

Please sign in to comment.