From 4b10c687f8976df51e08f71c7f6c75816bf978a0 Mon Sep 17 00:00:00 2001 From: Daniel Azuma Date: Thu, 12 Mar 2026 14:56:20 -0700 Subject: [PATCH] chore: Update tools Signed-off-by: Daniel Azuma --- .github/workflows/ci.yml | 7 +++---- .gitignore | 1 + .toys/.data/releases.yml | 2 ++ .toys/.toys.rb | 6 +++--- .toys/ci.rb | 31 ++++++++++++++++++------------- 5 files changed, 27 insertions(+), 20 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ce91136..faa5631 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,10 +42,9 @@ jobs: - os: ubuntu-latest ruby: jruby flags: "--test --cucumber" - # TEMPORARY: Disable truffleruby due to some issues with bundler - # - os: ubuntu-latest - # ruby: truffleruby - # flags: "--test --cucumber" + - os: ubuntu-latest + ruby: truffleruby + flags: "--test --cucumber" - os: macos-latest ruby: "4.0" flags: "--test --cucumber" diff --git a/.gitignore b/.gitignore index d1ee9ea..fd60ab0 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ .DS_STORE .bundle/ +.claude/ .yardoc/ Gemfile.lock coverage/ diff --git a/.toys/.data/releases.yml b/.toys/.data/releases.yml index 80ecd0c..172295d 100644 --- a/.toys/.data/releases.yml +++ b/.toys/.data/releases.yml @@ -2,6 +2,8 @@ repo: cloudevents/sdk-ruby git_user_name: CNCF CloudEvents Bot git_user_email: cncfcloudevents@gmail.com signoff_commits: true +update_existing_requests: true +issue_number_suffix_handling: delete gems: - name: cloud_events diff --git a/.toys/.toys.rb b/.toys/.toys.rb index 31ea983..4adbb37 100644 --- a/.toys/.toys.rb +++ b/.toys/.toys.rb @@ -1,8 +1,8 @@ # frozen_string_literal: true -toys_version! ">= 0.19" +toys_version! ">= 0.20" -expand :clean, paths: :gitignore +expand :clean, paths: :gitignore, preserve: ".claude/" expand :minitest, libs: ["lib"], bundler: true @@ -19,4 +19,4 @@ expand :gem_build, name: "install", install_gem: true -load_gem "toys-release", version: "~> 0.4", as: "release" +load_gem "toys-release", version: ">= 0.8.1", as: "release" diff --git a/.toys/ci.rb b/.toys/ci.rb index 248dc3c..83c7a29 100644 --- a/.toys/ci.rb +++ b/.toys/ci.rb @@ -1,18 +1,23 @@ # frozen_string_literal: true -load_git remote: "https://github.com/dazuma/toys.git", - path: "common-tools/ci", - update: 3600 +load_gem "toys-ci" -desc "Run all CI checks" +desc "CI target that runs CI jobs in this repo" -expand("toys-ci") do |toys_ci| - toys_ci.only_flag = true - toys_ci.fail_fast_flag = true - toys_ci.job("Bundle update", flag: :bundle, exec: ["bundle", "update", "--all"]) - toys_ci.job("Rubocop", flag: :rubocop, tool: ["rubocop"]) - toys_ci.job("Tests", flag: :test, tool: ["test"]) - toys_ci.job("Cucumber", flag: :cucumber, tool: ["cucumber"]) - toys_ci.job("Yardoc", flag: :yard, tool: ["yardoc"]) - toys_ci.job("Gem build", flag: :build, tool: ["build"]) +flag :bundle_update, "--update", "--bundle-update", desc: "Update instead of install bundles" + +expand(Toys::CI::Template) do |ci| + ci.only_flag = true + ci.fail_fast_flag = true + + ci.job("Bundle install", flag: :bundle) do + cmd = bundle_update ? ["bundle", "update", "--all"] : ["bundle", "install"] + exec(cmd, name: "Bundle").success? + end + + ci.tool_job("Rubocop", ["rubocop"], flag: :rubocop) + ci.tool_job("Tests", ["test"], flag: :test) + ci.tool_job("Cucumber", ["cucumber"], flag: :cucumber) + ci.tool_job("Yardoc", ["yardoc"], flag: :yard) + ci.tool_job("Gem build", ["build"], flag: :build) end