Run of fresh-releases for ruby-paint

Merge these changes:

git pull https://janitor.debian.net/git/ruby-paint fresh-releases/main
git pull https://janitor.debian.net/git/ruby-paint fresh-releases/pristine-tar
git pull https://janitor.debian.net/git/ruby-paint fresh-releases/upstream

Summary

Merged new upstream version: 2.2.1 (was: 2.2.0).

Diff

Branch: main

diff --git a/CHANGELOG.md b/CHANGELOG.md
index 1dee5a1..7d94bcf 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,9 @@
 # CHANGELOG
 
+### 2.2.1
+
+* Explicitly set mac's Terminal.app to 256 colors only, fixes #28
+
 ### 2.2.0
 
 * Support NO_COLOR environment variable, implements #26 (see no-color.org)
diff --git a/README.md b/README.md
index 22aff80..ad6f135 100644
--- a/README.md
+++ b/README.md
@@ -2,6 +2,10 @@
 
 Paint creates terminal colors and effects for you. It combines the strengths of **term-ansicolor**, **rainbow**, and similar projects into a simple to use, however still flexible terminal colors gem with no core extensions by default.
 
+Supported Rubies: **2.7**, **2.6**, **2.5**
+
+Unsupported, but might still work: **2.4**, **2.3**, **2.2**, **2.1**, **2.0**, **1.9**
+
 ## Features
 
 * No string extensions (suitable for library development)
@@ -23,14 +27,6 @@ Starting with **Paint 2.0**, *true color* mode is the new default mode, since mo
 - Manually set `Paint.mode = 256` at the beginning of your code
 - Please [open a new issue](https://github.com/janlelis/paint/issues/new) so we can figure out how to blacklist the terminal used
 
-## Supported Rubies
-
-* **2.7**, **2.6**, **2.5**, **2.4**
-
-Unsupported, but might still work:
-
-* **2.3**, **2.2**, **2.1**, **2.0**, **1.9**
-
 ## Setup
 
 Add to `Gemfile`:
@@ -93,6 +89,8 @@ You can choose between five ways to use `Paint.[]` by setting `Paint.mode` to on
 
 Paint tries to automatically detect the proper value your terminal is capable of, please [open an issue](https://github.com/janlelis/paint/issues/new) if `Paint.detect_mode` yields a wrong value for you.
 
+`Paint.detect_mode` will return 0 if the [NO_COLOR environment variable is set](https://github.com/jcs/no_color/).
+
 ## More Details About Terminal Colors and Effects
 
 <img src="https://pbs.twimg.com/media/ENyLvgVXUAgeDTn.jpg" />
@@ -186,7 +184,7 @@ pa "Ruby", :red, :underline  # same as puts Paint["Ruby", :red, :underline]
 
 ## Advanced Usage: Shortcuts
 
-There is an extension gem available which allows you to define custom color definitions, which you can reuse later. See [SHORTCUTS.md](https://github.com/janlelis/paint/blob/master/SHORTCUTS.md) for documentation. This is completely optional.
+There is an extension gem available which allows you to define custom color definitions, which you can reuse later. See [SHORTCUTS.md](https://github.com/janlelis/paint/blob/main/SHORTCUTS.md) for documentation. This is completely optional.
 
 ## J-_-L
 
diff --git a/debian/changelog b/debian/changelog
index 8ed027a..426ea2b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-ruby-paint (2.2.0-2) UNRELEASED; urgency=low
+ruby-paint (2.2.1-1) UNRELEASED; urgency=low
 
   * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
     Repository-Browse.
@@ -6,8 +6,9 @@ ruby-paint (2.2.0-2) UNRELEASED; urgency=low
     + ruby-paint: Add Multi-Arch: foreign.
   * Bump debhelper from old 12 to 13.
   * Update standards version to 4.5.1, no changes needed.
+  * New upstream release.
 
- -- Debian Janitor <janitor@jelmer.uk>  Thu, 13 Aug 2020 05:51:00 -0000
+ -- Debian Janitor <janitor@jelmer.uk>  Thu, 10 Mar 2022 03:09:45 -0000
 
 ruby-paint (2.2.0-1) unstable; urgency=medium
 
diff --git a/debian/patches/fix_autopkg_test.patch b/debian/patches/fix_autopkg_test.patch
index 1eec855..2f4dac2 100644
--- a/debian/patches/fix_autopkg_test.patch
+++ b/debian/patches/fix_autopkg_test.patch
@@ -8,6 +8,9 @@ Index: ruby-paint/spec/spec_helper.rb
 ===================================================================
 --- ruby-paint.orig/spec/spec_helper.rb
 +++ ruby-paint/spec/spec_helper.rb
-@@ -1 +1 @@
+@@ -1,4 +1,4 @@
 -require File.dirname(__FILE__) + '/../lib/paint'
 +require 'paint'
+ 
+ RSpec.configure do |config|
+   config.expect_with :rspec do |c|
diff --git a/debian/patches/remove-test-shortcuts.patch b/debian/patches/remove-test-shortcuts.patch
index c235575..ac8cbc4 100644
--- a/debian/patches/remove-test-shortcuts.patch
+++ b/debian/patches/remove-test-shortcuts.patch
@@ -5,7 +5,9 @@ Author: Sophie Brun <sophie@offensive-security.com>
 Last-Update: 2020-03-10
 ---
 This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/spec/paint_shortcuts_spec.rb
+Index: ruby-paint/spec/paint_shortcuts_spec.rb
+===================================================================
+--- ruby-paint.orig/spec/paint_shortcuts_spec.rb
 +++ /dev/null
 @@ -1,64 +0,0 @@
 -require File.dirname(__FILE__) + '/spec_helper'
diff --git a/lib/paint.rb b/lib/paint.rb
index 8dfad54..09f7af7 100644
--- a/lib/paint.rb
+++ b/lib/paint.rb
@@ -182,6 +182,8 @@ module Paint
         else
           0
         end
+      elsif ENV['TERM_PROGRAM'] == 'Apple_Terminal'
+        256
       else
         case ENV['TERM']
         when /^rxvt-(?:.*)-256color$/
diff --git a/lib/paint/version.rb b/lib/paint/version.rb
index 5083b9a..10b05b7 100644
--- a/lib/paint/version.rb
+++ b/lib/paint/version.rb
@@ -1,5 +1,5 @@
 # frozen_string_literal: true
 
 module Paint
-  VERSION = "2.2.0"
+  VERSION = "2.2.1"
 end

Branch: pristine-tar

diff --git a/ruby-paint_2.2.1.orig.tar.gz.delta b/ruby-paint_2.2.1.orig.tar.gz.delta
new file mode 100644
index 0000000..ea50f77
Binary files /dev/null and b/ruby-paint_2.2.1.orig.tar.gz.delta differ
diff --git a/ruby-paint_2.2.1.orig.tar.gz.id b/ruby-paint_2.2.1.orig.tar.gz.id
new file mode 100644
index 0000000..1296106
--- /dev/null
+++ b/ruby-paint_2.2.1.orig.tar.gz.id
@@ -0,0 +1 @@
+5c3033fca401575796e881b072e545ec75fa2710

Branch: upstream

Tag: v.2.2.1
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 1dee5a1..7d94bcf 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,9 @@
 # CHANGELOG
 
+### 2.2.1
+
+* Explicitly set mac's Terminal.app to 256 colors only, fixes #28
+
 ### 2.2.0
 
 * Support NO_COLOR environment variable, implements #26 (see no-color.org)
diff --git a/README.md b/README.md
index 22aff80..ad6f135 100644
--- a/README.md
+++ b/README.md
@@ -2,6 +2,10 @@
 
 Paint creates terminal colors and effects for you. It combines the strengths of **term-ansicolor**, **rainbow**, and similar projects into a simple to use, however still flexible terminal colors gem with no core extensions by default.
 
+Supported Rubies: **2.7**, **2.6**, **2.5**
+
+Unsupported, but might still work: **2.4**, **2.3**, **2.2**, **2.1**, **2.0**, **1.9**
+
 ## Features
 
 * No string extensions (suitable for library development)
@@ -23,14 +27,6 @@ Starting with **Paint 2.0**, *true color* mode is the new default mode, since mo
 - Manually set `Paint.mode = 256` at the beginning of your code
 - Please [open a new issue](https://github.com/janlelis/paint/issues/new) so we can figure out how to blacklist the terminal used
 
-## Supported Rubies
-
-* **2.7**, **2.6**, **2.5**, **2.4**
-
-Unsupported, but might still work:
-
-* **2.3**, **2.2**, **2.1**, **2.0**, **1.9**
-
 ## Setup
 
 Add to `Gemfile`:
@@ -93,6 +89,8 @@ You can choose between five ways to use `Paint.[]` by setting `Paint.mode` to on
 
 Paint tries to automatically detect the proper value your terminal is capable of, please [open an issue](https://github.com/janlelis/paint/issues/new) if `Paint.detect_mode` yields a wrong value for you.
 
+`Paint.detect_mode` will return 0 if the [NO_COLOR environment variable is set](https://github.com/jcs/no_color/).
+
 ## More Details About Terminal Colors and Effects
 
 <img src="https://pbs.twimg.com/media/ENyLvgVXUAgeDTn.jpg" />
@@ -186,7 +184,7 @@ pa "Ruby", :red, :underline  # same as puts Paint["Ruby", :red, :underline]
 
 ## Advanced Usage: Shortcuts
 
-There is an extension gem available which allows you to define custom color definitions, which you can reuse later. See [SHORTCUTS.md](https://github.com/janlelis/paint/blob/master/SHORTCUTS.md) for documentation. This is completely optional.
+There is an extension gem available which allows you to define custom color definitions, which you can reuse later. See [SHORTCUTS.md](https://github.com/janlelis/paint/blob/main/SHORTCUTS.md) for documentation. This is completely optional.
 
 ## J-_-L
 
diff --git a/lib/paint.rb b/lib/paint.rb
index 8dfad54..09f7af7 100644
--- a/lib/paint.rb
+++ b/lib/paint.rb
@@ -182,6 +182,8 @@ module Paint
         else
           0
         end
+      elsif ENV['TERM_PROGRAM'] == 'Apple_Terminal'
+        256
       else
         case ENV['TERM']
         when /^rxvt-(?:.*)-256color$/
diff --git a/lib/paint/version.rb b/lib/paint/version.rb
index 5083b9a..10b05b7 100644
--- a/lib/paint/version.rb
+++ b/lib/paint/version.rb
@@ -1,5 +1,5 @@
 # frozen_string_literal: true
 
 module Paint
-  VERSION = "2.2.0"
+  VERSION = "2.2.1"
 end

Publish Blockers

  • ☑ run was successful
  • ☑ package has not been removed from the archive
  • ☑ command has not changed
  • ☒ not yet reviewed, but review needed
  • ☑ 0 publish attempts so far.not currently attempting to back off
  • ☒ merge proposals for the package maintainer are currently being rate-limited (open: 1253, max open: 300)
  • ☑ change set 50e463c1-f037-49c3-8507-808d96238bc5 is ready

Resulting package

The resulting binary packages can be installed (if you have the apt repository enabled) by running one of:

apt install -t fresh-releases ruby-paint

Lintian Result

Full worker log Full build log