Commit 6ae1aef3 authored by Markus Chmelar's avatar Markus Chmelar

[Outdated] Change colorscheme of outdated command from red-yellow-green to red-blue-green

This is an improvement for colorblind users who can not differentiate between green and yellow.
Refs #7372
parent e6fd8276
...@@ -31,6 +31,9 @@ To install release candidates run `[sudo] gem install cocoapods --pre` ...@@ -31,6 +31,9 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
resources or embed frameworks unless `UNLOCALIZED_RESOURCES_FOLDER_PATH` resources or embed frameworks unless `UNLOCALIZED_RESOURCES_FOLDER_PATH`
or `FRAMEWORKS_FOLDER_PATH` is set. or `FRAMEWORKS_FOLDER_PATH` is set.
[Samuel Giddins](https://github.com/segiddins) [Samuel Giddins](https://github.com/segiddins)
* Change color scheme of `pod outdated` from red-yellow-green to red-blue-green to be more colorblind friendly
[iv-mexx](https://github.com/iv-mexx)
[#7372](https://github.com/CocoaPods/CocoaPods/issues/7372)
##### Bug Fixes ##### Bug Fixes
......
...@@ -24,13 +24,13 @@ module Pod ...@@ -24,13 +24,13 @@ module Pod
else else
UI.section 'The color indicates what happens when you run `pod update`' do UI.section 'The color indicates what happens when you run `pod update`' do
UI.puts "#{'<green>'.green}\t\t - Will be updated to the newest version" UI.puts "#{'<green>'.green}\t\t - Will be updated to the newest version"
UI.puts "#{'<yellow>'.yellow}\t - Will be updated, but not to the newest version because of specified version in Podfile" UI.puts "#{'<blue>'.blue}\t - Will be updated, but not to the newest version because of specified version in Podfile"
UI.puts "#{'<red>'.red}\t\t - Will not be updated because of specified version in Podfile" UI.puts "#{'<red>'.red}\t\t - Will not be updated because of specified version in Podfile"
UI.puts '' UI.puts ''
end end
UI.section 'The following pod updates are available:' do UI.section 'The following pod updates are available:' do
updates.each do |(name, from_version, matching_version, to_version)| updates.each do |(name, from_version, matching_version, to_version)|
color = :yellow color = :blue
if matching_version == to_version if matching_version == to_version
color = :green color = :green
elsif from_version == matching_version elsif from_version == matching_version
......
...@@ -75,16 +75,16 @@ module Pod ...@@ -75,16 +75,16 @@ module Pod
UI.output.should.include('BlocksKit 1.0 -> 1.0 (latest version 2.0)') UI.output.should.include('BlocksKit 1.0 -> 1.0 (latest version 2.0)')
end end
it 'tells the user about outdated pods that can be updated, but not to the latest version in yellow' do it 'tells the user about outdated pods that can be updated, but not to the latest version in blue' do
pod_name = 'BlocksKit' pod_name = 'BlocksKit'
current_version_string = mock current_version_string = mock
current_version_string.expects(:yellow).returns('1.0').once current_version_string.expects(:blue).returns('1.0').once
current_version = mock current_version = mock
current_version.stubs(:to_s).returns(current_version_string) current_version.stubs(:to_s).returns(current_version_string)
next_version_string = mock next_version_string = mock
next_version_string.expects(:yellow).returns('1.1').once next_version_string.expects(:blue).returns('1.1').once
next_version = mock next_version = mock
next_version.stubs(:to_s).returns(next_version_string) next_version.stubs(:to_s).returns(next_version_string)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment