Skip to content

Use shields.io for badges and add logos#30679

Closed
sweepies wants to merge 1 commit into
microsoft:masterfrom
sweepies:add-badge-logos
Closed

Use shields.io for badges and add logos#30679
sweepies wants to merge 1 commit into
microsoft:masterfrom
sweepies:add-badge-logos

Conversation

@sweepies
Copy link
Copy Markdown

@sweepies sweepies commented Apr 1, 2019

Fixes a README beauty shortfall 🎉

Copy link
Copy Markdown
Contributor

@ExE-Boss ExE-Boss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Shields.io Travis badge always reports the latest build, even if that build is from a pull request or an unrelated branch.

The Travis‑CI.org badge only reports the build status of the master branch, which is what you generally want for README.md:

Comment thread README.md
@@ -1,11 +1,11 @@
[![Build Status](https://travis-ci.org/Microsoft/TypeScript.svg?branch=master)](https://travis-ci.org/Microsoft/TypeScript)
[![Build Status](https://img.shields.io/travis/Microsoft/TypeScript.svg?logo=travis)](https://travis-ci.org/Microsoft/TypeScript)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
[![Build Status](https://img.shields.io/travis/Microsoft/TypeScript.svg?logo=travis)](https://travis-ci.org/Microsoft/TypeScript)
[![Build Status](https://travis-ci.org/Microsoft/TypeScript.svg?branch=master)](https://travis-ci.org/Microsoft/TypeScript)

Copy link
Copy Markdown
Contributor

@ExE-Boss ExE-Boss Apr 14, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns out that Shields.io now supports Travis branch builds too:

Suggested change
[![Build Status](https://img.shields.io/travis/Microsoft/TypeScript.svg?logo=travis)](https://travis-ci.org/Microsoft/TypeScript)
[![Build Status](https://img.shields.io/travis/Microsoft/TypeScript/master.svg?logo=travis-ci&logoColor=white)](https://travis-ci.org/Microsoft/TypeScript)

Copy link
Copy Markdown
Author

@sweepies sweepies Apr 15, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why logoColor=white?

Build Status - looks kind of odd.

LGTM other than that.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks better than without it: Build Status

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Huh, why does it turn blue when you pass it the master branch? Without it the default is

Build Status
 

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because I used the simple-icons travis-ci logo, instead of the shields.io travis logo.

Copy link
Copy Markdown
Author

@sweepies sweepies Apr 25, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, it's a difference of travis vs travis-ci. I wasn't aware shields added their own logos since it also uses simpleicons. In that case, travis should have probably been kept anyways since it aligns with the style of the npm logo - which shields has no way of setting to the simpleicons version since they're both named the same (it doesn't look great either).

@RyanCavanaugh
Copy link
Copy Markdown
Member

We're pretty OK with the badges as-is, and this is already turning into bikeshedding.

@microsoft microsoft locked as resolved and limited conversation to collaborators Oct 21, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants