diff --git a/CHANGELOG.md b/CHANGELOG.md index 6f8eef1..4b51ce5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ * Your changes/patches go here. +- [CHORE: Remove GPL licensed dependency Colorize and replace it with Rainbow] + # v1.3.0 / 2023-06-16 [(commits)](https://github.com/fastruby/next_rails/compare/v1.2.4...v1.3.0) - [FEATURE: Add NextRails.next? for application usage (e.g. Rails shims)](https://github.com/fastruby/next_rails/pull/97) diff --git a/exe/deprecations b/exe/deprecations index 3d476de..b4712d6 100755 --- a/exe/deprecations +++ b/exe/deprecations @@ -1,9 +1,11 @@ #!/usr/bin/env ruby require "json" -require "colorize" +require "rainbow/refinement" require "optparse" require "set" +using Rainbow + def run_tests(deprecation_warnings, opts = {}) tracker_mode = opts[:tracker_mode] next_mode = opts[:next_mode] diff --git a/lib/deprecation_tracker.rb b/lib/deprecation_tracker.rb index 89cd337..7277773 100644 --- a/lib/deprecation_tracker.rb +++ b/lib/deprecation_tracker.rb @@ -1,6 +1,8 @@ -require "colorize" +require "rainbow/refinement" require "json" +using Rainbow + # A shitlist for deprecation warnings during test runs. It has two modes: "save" and "compare" # # DEPRECATION_TRACKER=save diff --git a/lib/next_rails/bundle_report.rb b/lib/next_rails/bundle_report.rb index 41b7be4..49070c4 100644 --- a/lib/next_rails/bundle_report.rb +++ b/lib/next_rails/bundle_report.rb @@ -1,9 +1,11 @@ -require "colorize" +require "rainbow/refinement" require "cgi" require "erb" require "json" require "net/http" +using Rainbow + module NextRails module BundleReport extend self @@ -168,4 +170,4 @@ def output_to_stdout(out_of_date_gems, total_gem_count, sourced_from_git_count) puts footer end end -end \ No newline at end of file +end diff --git a/next_rails.gemspec b/next_rails.gemspec index cf69fe6..e073411 100644 --- a/next_rails.gemspec +++ b/next_rails.gemspec @@ -22,7 +22,7 @@ Gem::Specification.new do |spec| spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) } spec.require_paths = ["lib"] - spec.add_dependency "colorize", ">= 0.8.1" + spec.add_dependency "rainbow", ">= 3" spec.add_development_dependency "bundler", ">= 1.16", "< 3.0" spec.add_development_dependency "rake" spec.add_development_dependency "rspec", "~> 3.0" diff --git a/spec/bundle_report_spec.rb b/spec/bundle_report_spec.rb index 0882764..a5c97ae 100644 --- a/spec/bundle_report_spec.rb +++ b/spec/bundle_report_spec.rb @@ -5,6 +5,8 @@ require_relative 'spec_helper' require_relative '../lib/next_rails/bundle_report' +using Rainbow + RSpec.describe NextRails::BundleReport do describe '.outdated' do let(:mock_version) { Struct.new(:version, :age) }