From fec87ae0fcbb264b72e8811fb5dec7f0a6da08e5 Mon Sep 17 00:00:00 2001 From: Liz Moy Date: Tue, 1 Apr 2025 11:43:10 +0100 Subject: [PATCH 1/7] add dependabot --- .github/dependabot.yml | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..cee821df --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,9 @@ +version: 2 +updates: + - package-ecosystem: "bundler" + directory: "/" # Root of the repo, where Gemfile and intercom.gemspec are + schedule: + interval: "weekly" + open-pull-requests-limit: 5 + commit-message: + prefix: "chore" From 8f48a6d1e9383a174e383de1786a1872dd211aa2 Mon Sep 17 00:00:00 2001 From: Liz Moy Date: Tue, 1 Apr 2025 13:11:13 +0100 Subject: [PATCH 2/7] update config --- .circleci/config.yml | 72 +++++++++++++++++++++++++++----------------- 1 file changed, 45 insertions(+), 27 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 23fcf9e1..4f5ca747 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,35 +1,53 @@ -version: 2 -jobs: - "Test against Ruby 2.4": - docker: - - image: circleci/ruby:2.4.9 - working_directory: ~/intercom-ruby - steps: - - checkout - - run: bundle install - - run: bundle exec rake - "Test against Ruby 2.5": - docker: - - image: circleci/ruby:2.5.7 - working_directory: ~/intercom-ruby - steps: - - checkout - - run: bundle install - - run: bundle exec rake - "Test against Ruby 2.6": +version: 2.1 + +executors: + ruby-executor: + parameters: + ruby_version: + type: string docker: - - image: circleci/ruby:2.6.5 + - image: cimg/ruby:<< parameters.ruby_version >> working_directory: ~/intercom-ruby + +jobs: + test: + parameters: + ruby_version: + type: string + executor: + name: ruby-executor + ruby_version: << parameters.ruby_version >> steps: - checkout - - run: bundle install - - run: bundle exec rake + + - restore_cache: + keys: + - bundler-<< parameters.ruby_version >>-{{ checksum "Gemfile.lock" }} + + - run: + name: Install dependencies + command: | + gem install bundler + bundle install --jobs=4 --retry=3 + + - save_cache: + key: bundler-<< parameters.ruby_version >>-{{ checksum "Gemfile.lock" }} + paths: + - vendor/bundle + + - run: + name: Run tests + command: bundle exec rake workflows: - version: 2 build_and_test: jobs: - - "Test against Ruby 2.4" - - "Test against Ruby 2.5" - - "Test against Ruby 2.6" - + - test: + name: "Test against Ruby 2.4" + ruby_version: "2.4" + - test: + name: "Test against Ruby 2.5" + ruby_version: "2.5" + - test: + name: "Test against Ruby 2.6" + ruby_version: "2.6" From 95c1c66816dc8de93bc412c1d7d289df1a0420ff Mon Sep 17 00:00:00 2001 From: Liz Moy Date: Tue, 1 Apr 2025 13:25:02 +0100 Subject: [PATCH 3/7] adding gemfile lock as its needed for circleci config --- .gitignore | 1 - Gemfile.lock | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 53 insertions(+), 1 deletion(-) create mode 100644 Gemfile.lock diff --git a/.gitignore b/.gitignore index c55233b6..ef916796 100644 --- a/.gitignore +++ b/.gitignore @@ -2,7 +2,6 @@ doc *.gem *.iml .bundle -Gemfile.lock pkg/* .rakeTasks .yardoc diff --git a/Gemfile.lock b/Gemfile.lock new file mode 100644 index 00000000..241ab648 --- /dev/null +++ b/Gemfile.lock @@ -0,0 +1,53 @@ +PATH + remote: . + specs: + intercom (4.2.0) + +GEM + remote: http://rubygems.org/ + specs: + addressable (2.8.7) + public_suffix (>= 2.0.2, < 7.0) + bigdecimal (3.1.9) + coderay (1.1.3) + crack (1.0.0) + bigdecimal + rexml + fakeweb (1.3.0) + gem-release (2.2.4) + hashdiff (1.1.2) + m (1.5.1) + method_source (>= 0.6.7) + rake (>= 0.9.2.2) + method_source (1.1.0) + minitest (5.25.5) + mocha (1.16.1) + pry (0.15.2) + coderay (~> 1.1) + method_source (~> 1.0) + public_suffix (6.0.1) + rake (10.5.0) + rexml (3.4.1) + webmock (3.25.1) + addressable (>= 2.8.0) + crack (>= 0.3.2) + hashdiff (>= 0.4.0, < 2.0.0) + +PLATFORMS + arm64-darwin-24 + ruby + +DEPENDENCIES + fakeweb (~> 1.3) + gem-release + intercom! + jruby-openssl + m (~> 1.5.0) + minitest (~> 5.4) + mocha (~> 1.0) + pry + rake (~> 10.3) + webmock + +BUNDLED WITH + 2.6.6 From 9bfc15d312ce45a8b058bc20ed99e0f761cb5308 Mon Sep 17 00:00:00 2001 From: Liz Moy Date: Tue, 1 Apr 2025 13:30:03 +0100 Subject: [PATCH 4/7] fix config --- .circleci/config.yml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 4f5ca747..53493664 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,22 +1,13 @@ version: 2.1 -executors: - ruby-executor: +jobs: + test: parameters: ruby_version: type: string docker: - image: cimg/ruby:<< parameters.ruby_version >> working_directory: ~/intercom-ruby - -jobs: - test: - parameters: - ruby_version: - type: string - executor: - name: ruby-executor - ruby_version: << parameters.ruby_version >> steps: - checkout From b3544f00566b1c4ad6f717875c2e8255dad8bb79 Mon Sep 17 00:00:00 2001 From: Liz Moy Date: Tue, 1 Apr 2025 13:38:05 +0100 Subject: [PATCH 5/7] add new versions --- .circleci/config.yml | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 53493664..4975238e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -15,11 +15,16 @@ jobs: keys: - bundler-<< parameters.ruby_version >>-{{ checksum "Gemfile.lock" }} + - run: + name: Install correct Bundler version (2.6.6) + command: | + gem uninstall bundler -a -x || true + gem install bundler -v 2.6.6 + - run: name: Install dependencies command: | - gem install bundler - bundle install --jobs=4 --retry=3 + bundle _2.6.6_ install --jobs=4 --retry=3 - save_cache: key: bundler-<< parameters.ruby_version >>-{{ checksum "Gemfile.lock" }} @@ -28,7 +33,7 @@ jobs: - run: name: Run tests - command: bundle exec rake + command: bundle _2.6.6_ exec rake workflows: build_and_test: @@ -42,3 +47,12 @@ workflows: - test: name: "Test against Ruby 2.6" ruby_version: "2.6" + - test: + name: "Test against Ruby 3.1" + ruby_version: "3.1" + - test: + name: "Test against Ruby 3.2" + ruby_version: "3.2" + - test: + name: "Test against Ruby 3.3" + ruby_version: "3.3" \ No newline at end of file From bac64cddc5ae1bb8adef5a44e83cb6accea64ad7 Mon Sep 17 00:00:00 2001 From: Liz Moy Date: Tue, 1 Apr 2025 13:44:26 +0100 Subject: [PATCH 6/7] fix config bundler --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 4975238e..ce195e42 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -16,10 +16,10 @@ jobs: - bundler-<< parameters.ruby_version >>-{{ checksum "Gemfile.lock" }} - run: - name: Install correct Bundler version (2.6.6) + name: Install correct Bundler version (2.4.22) command: | gem uninstall bundler -a -x || true - gem install bundler -v 2.6.6 + gem install bundler -v 2.4.22 - run: name: Install dependencies From b0068543c976fad6d1f63fd6bbf52d5485e88494 Mon Sep 17 00:00:00 2001 From: Liz Moy Date: Tue, 1 Apr 2025 13:46:14 +0100 Subject: [PATCH 7/7] add gemfile lock with bundle _2.4.22_ install --- Gemfile.lock | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 241ab648..4c0eb382 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -35,7 +35,6 @@ GEM PLATFORMS arm64-darwin-24 - ruby DEPENDENCIES fakeweb (~> 1.3) @@ -50,4 +49,4 @@ DEPENDENCIES webmock BUNDLED WITH - 2.6.6 + 2.4.22