diff --git a/compiled_starters/ruby/Gemfile b/compiled_starters/ruby/Gemfile new file mode 100644 index 0000000..f5f8980 --- /dev/null +++ b/compiled_starters/ruby/Gemfile @@ -0,0 +1,6 @@ +# frozen_string_literal: true + +source "https://rubygems.org" + +# Add gems here if you need to use them. +# Make sure to run `bundle install` before running tests or submitting your code. diff --git a/compiled_starters/ruby/Gemfile.lock b/compiled_starters/ruby/Gemfile.lock new file mode 100644 index 0000000..5bcfb05 --- /dev/null +++ b/compiled_starters/ruby/Gemfile.lock @@ -0,0 +1,15 @@ +GEM + remote: https://rubygems.org/ + specs: + +PLATFORMS + aarch64-linux-musl + arm64-darwin-21 + arm64-darwin-23 + x86_64-linux + ruby + +DEPENDENCIES + +BUNDLED WITH + 2.5.6 diff --git a/compiled_starters/ruby/README.md b/compiled_starters/ruby/README.md index ff61059..94b324c 100644 --- a/compiled_starters/ruby/README.md +++ b/compiled_starters/ruby/README.md @@ -30,7 +30,7 @@ Time to move on to the next stage! Note: This section is for stages 2 and beyond. -1. Ensure you have `ruby (2.7+)` installed locally +1. Ensure you have `ruby (3.3)` installed locally 1. Run `./your_sqlite3.sh` to run your program, which is implemented in `app/main.rb`. 1. Commit your changes and run `git push origin master` to submit your solution diff --git a/compiled_starters/ruby/codecrafters.yml b/compiled_starters/ruby/codecrafters.yml index 3cee60d..b3ef817 100644 --- a/compiled_starters/ruby/codecrafters.yml +++ b/compiled_starters/ruby/codecrafters.yml @@ -7,5 +7,5 @@ debug: false # Use this to change the Ruby version used to run your code # on Codecrafters. # -# Available versions: ruby-3.2 -language_pack: ruby-3.2 +# Available versions: ruby-3.3 +language_pack: ruby-3.3 diff --git a/dockerfiles/ruby-3.3.Dockerfile b/dockerfiles/ruby-3.3.Dockerfile new file mode 100644 index 0000000..2c92211 --- /dev/null +++ b/dockerfiles/ruby-3.3.Dockerfile @@ -0,0 +1,9 @@ +FROM ruby:3.3-alpine + +ENV CODECRAFTERS_DEPENDENCY_FILE_PATHS="Gemfile,Gemfile.lock" + +WORKDIR /app + +COPY Gemfile Gemfile.lock ./ + +RUN bundle install --verbose diff --git a/solutions/ruby/01-init/code/Gemfile b/solutions/ruby/01-init/code/Gemfile new file mode 100644 index 0000000..f5f8980 --- /dev/null +++ b/solutions/ruby/01-init/code/Gemfile @@ -0,0 +1,6 @@ +# frozen_string_literal: true + +source "https://rubygems.org" + +# Add gems here if you need to use them. +# Make sure to run `bundle install` before running tests or submitting your code. diff --git a/solutions/ruby/01-init/code/Gemfile.lock b/solutions/ruby/01-init/code/Gemfile.lock new file mode 100644 index 0000000..5bcfb05 --- /dev/null +++ b/solutions/ruby/01-init/code/Gemfile.lock @@ -0,0 +1,15 @@ +GEM + remote: https://rubygems.org/ + specs: + +PLATFORMS + aarch64-linux-musl + arm64-darwin-21 + arm64-darwin-23 + x86_64-linux + ruby + +DEPENDENCIES + +BUNDLED WITH + 2.5.6 diff --git a/solutions/ruby/01-init/code/README.md b/solutions/ruby/01-init/code/README.md index ff61059..94b324c 100644 --- a/solutions/ruby/01-init/code/README.md +++ b/solutions/ruby/01-init/code/README.md @@ -30,7 +30,7 @@ Time to move on to the next stage! Note: This section is for stages 2 and beyond. -1. Ensure you have `ruby (2.7+)` installed locally +1. Ensure you have `ruby (3.3)` installed locally 1. Run `./your_sqlite3.sh` to run your program, which is implemented in `app/main.rb`. 1. Commit your changes and run `git push origin master` to submit your solution diff --git a/solutions/ruby/01-init/code/codecrafters.yml b/solutions/ruby/01-init/code/codecrafters.yml index 3cee60d..b3ef817 100644 --- a/solutions/ruby/01-init/code/codecrafters.yml +++ b/solutions/ruby/01-init/code/codecrafters.yml @@ -7,5 +7,5 @@ debug: false # Use this to change the Ruby version used to run your code # on Codecrafters. # -# Available versions: ruby-3.2 -language_pack: ruby-3.2 +# Available versions: ruby-3.3 +language_pack: ruby-3.3 diff --git a/starter-repository-definitions.yml b/starter-repository-definitions.yml index b173094..c26c7c1 100644 --- a/starter-repository-definitions.yml +++ b/starter-repository-definitions.yml @@ -150,8 +150,12 @@ target: your_sqlite3.sh - source: starter_templates/.gitattributes target: .gitattributes + - source: starter_templates/ruby/Gemfile + target: Gemfile + - source: starter_templates/ruby/Gemfile.lock + target: Gemfile.lock template_attributes: - required_executable: "ruby (2.7+)" + required_executable: "ruby (3.3)" user_editable_file: "app/main.rb" - language: swift diff --git a/starter_templates/codecrafters.yml b/starter_templates/codecrafters.yml index 984a711..a62d5f4 100644 --- a/starter_templates/codecrafters.yml +++ b/starter_templates/codecrafters.yml @@ -32,8 +32,8 @@ language_pack: nodejs-18 language_pack: c-9.2 {{/ language_is_c }} {{# language_is_ruby }} -# Available versions: ruby-3.2 -language_pack: ruby-3.2 +# Available versions: ruby-3.3 +language_pack: ruby-3.3 {{/ language_is_ruby }} {{# language_is_rust }} # Available versions: rust-1.77 diff --git a/starter_templates/ruby/Gemfile b/starter_templates/ruby/Gemfile new file mode 100644 index 0000000..f5f8980 --- /dev/null +++ b/starter_templates/ruby/Gemfile @@ -0,0 +1,6 @@ +# frozen_string_literal: true + +source "https://rubygems.org" + +# Add gems here if you need to use them. +# Make sure to run `bundle install` before running tests or submitting your code. diff --git a/starter_templates/ruby/Gemfile.lock b/starter_templates/ruby/Gemfile.lock new file mode 100644 index 0000000..5bcfb05 --- /dev/null +++ b/starter_templates/ruby/Gemfile.lock @@ -0,0 +1,15 @@ +GEM + remote: https://rubygems.org/ + specs: + +PLATFORMS + aarch64-linux-musl + arm64-darwin-21 + arm64-darwin-23 + x86_64-linux + ruby + +DEPENDENCIES + +BUNDLED WITH + 2.5.6