Skip to content

Commit

Permalink
add ruby3.4 alias (#480)
Browse files Browse the repository at this point in the history
  • Loading branch information
bogyo210 authored Jan 8, 2025
1 parent a194291 commit 92e5d78
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions sem-version
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ version::change_ruby() {
[[ "$software_version" == "3.1" ]] && software_version="3.1.6"
[[ "$software_version" == "3.2" ]] && software_version="3.2.6"
[[ "$software_version" == "3.3" ]] && software_version="3.3.6"
[[ "$software_version" == "3.4" ]] && software_version="3.4.1"

if ! [ -d ~/.rbenv/versions/"${software_version}" ]; then
sem-install ruby "${software_version}"
Expand Down
5 changes: 5 additions & 0 deletions tests/sem_version_focal/ruby.bats
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,11 @@ setup() {
assert_success
run ruby --version
assert_line --partial "ruby 3.3.6"

run sem-version ruby 3.4
assert_success
run ruby --version
assert_line --partial "ruby 3.4.1"
}

@test "change ruby to 4.0.1" {
Expand Down
5 changes: 5 additions & 0 deletions tests/sem_version_jammy/ruby.bats
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,11 @@ setup() {
assert_success
run ruby --version
assert_line --partial "ruby 3.3.6"

run sem-version ruby 3.4
assert_success
run ruby --version
assert_line --partial "ruby 3.4.1"
}

@test "change ruby to 4.0.1" {
Expand Down
5 changes: 5 additions & 0 deletions tests/sem_version_noble/ruby.bats
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,11 @@ setup() {
assert_success
run ruby --version
assert_line --partial "ruby 3.3.6"

run sem-version ruby 3.4
assert_success
run ruby --version
assert_line --partial "ruby 3.4.1"
}

@test "change ruby to 4.0.1" {
Expand Down

0 comments on commit 92e5d78

Please sign in to comment.