Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Abolish restrictions governing colour choices #4978

Merged
merged 1 commit into from
Sep 1, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,9 +171,6 @@ Please do this in a community forum or repository used and known by the wider co
Once you've received consensus that the community is happy with your proposed color change, please feel free to open a PR making the change and link to the public discussion where this was agreed by the community.
If there are official branding guidelines to support the colour choice, please link to those too.

Please note that Linguist currently implements a [color proximity test][] to ensure colors are sufficiently different from one another so you may not be able to use the precise color you want - reds and blues are really popular.
As such, we recommend you test the color change locally before making your plea to the wider language community.

## Testing

You can run the tests locally with:
Expand Down Expand Up @@ -245,7 +242,6 @@ If you are the current maintainer of this gem:
[languages]: /lib/linguist/languages.yml
[licenses]: https://github.com/github/linguist/blob/257425141d4e2a5232786bf0b13c901ada075f93/vendor/licenses/config.yml#L2-L11
[new-issue]: https://github.com/github/linguist/issues/new
[color proximity test]: https://github.com/github/linguist/blob/master/test/test_color_proximity.rb
[samples]: /samples
[search-example]: https://github.com/search?utf8=%E2%9C%93&q=extension%3Aboot+NOT+nothack&type=Code&ref=searchresults
[gpr]: https://help.github.com/en/articles/configuring-rubygems-for-use-with-github-package-registry
1 change: 0 additions & 1 deletion github-linguist.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ Gem::Specification.new do |s|
s.add_development_dependency 'pry'
s.add_development_dependency 'rake'
s.add_development_dependency 'yajl-ruby'
s.add_development_dependency 'color-proximity', '~> 0.2.1'
s.add_development_dependency 'licensed', '~> 2.0'
s.add_development_dependency 'licensee'
s.add_development_dependency 'bundler', '>= 1.10'
Expand Down
1 change: 0 additions & 1 deletion test/helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
require "minitest/autorun"
require "mocha/minitest"
require "linguist"
require 'color-proximity'
require "linguist/blob"
require 'licensee'

Expand Down
23 changes: 0 additions & 23 deletions test/test_color_proximity.rb

This file was deleted.

8 changes: 0 additions & 8 deletions test/test_language.rb
Original file line number Diff line number Diff line change
Expand Up @@ -470,14 +470,6 @@ def test_all_popular_languages_exist
assert missing.empty?, message
end

def test_no_unused_colours
Language.all.each do |language|
next unless language.type == :data || language.type == :prose ||
language.group.to_s != language.name
assert !language.color, "Unused colour assigned to #{language.name}"
end
end

def test_non_crash_on_comma
assert_nil Language[',']
assert_nil Language.find_by_name(',')
Expand Down