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

Adopt flat style badges #44

Closed
fabiopelosin opened this issue Apr 29, 2014 · 48 comments
Closed

Adopt flat style badges #44

fabiopelosin opened this issue Apr 29, 2014 · 48 comments

Comments

@fabiopelosin
Copy link
Member

See http://shields.io

They rock!

@segiddins
Copy link
Member

I don't think they have the Platform badges yet

@fabiopelosin
Copy link
Member Author

Good catch... off course they do 😉

You can specify any text for static badges (i.e. you need to update them manually):

https://img.shields.io/badge/platform-iOS-red.svg?style=flat

@segiddins
Copy link
Member

But right now we have that parsed automatically from the podspec (i.e. https://cocoapod-badges.herokuapp.com/p/RestKit/badge.png)

@segiddins
Copy link
Member

@irrationalfab when I have some time I'll add some more CP badges natively to shields (platform, license)

@fabiopelosin
Copy link
Member Author

Ace!

@segiddins
Copy link
Member

how do these look?

@fabiopelosin
Copy link
Member Author

Great except for the fact that they are not flat :trollface:

@fabiopelosin
Copy link
Member Author

Adding ?style=flat is as expected supported for them:

@fabiopelosin
Copy link
Member Author

@segiddins also now that you are at it, fixing the blue color would be ace!

@segiddins
Copy link
Member

that's a query option :trollface:

@segiddins
Copy link
Member

what do you want the blue color changed to? (I happen to like it)
segiddins/shields@81c115c#diff-78c12f5adc1848d13b1c6f07055d996eR733 is where they apply the coloring for the version

@fabiopelosin
Copy link
Member Author

CocoaPods color is bold-red however it clashes with build failure badges... so I'm on the fence. @orta might have an opinion about this.

@segiddins
Copy link
Member

I'll wait to submit my shields PR until @orta weighs in

Colors Needed:

  • 0.x / dev version of a pod
  • 'normal' version
  • license
  • platforms

@orta
Copy link
Member

orta commented May 15, 2014

lets try:

dev - D1C4C0
normal - 380100
license - 5BA7E9
platforms - C7254E

@segiddins
Copy link
Member

@fjcaetano
Copy link

Guys, is it your interest to move the badges to inside the Cocoapods organization? If so, let me know and I'll discontinue cocoapod-badges.

@fjcaetano
Copy link

Update: I have SVG badges with flat style and license badges working under the branch shield_badges. They're still using the current orange color.

The service is temporarily hosted under the url https://betabadges.herokuapp.com

@orta
Copy link
Member

orta commented May 20, 2014

OK, @fjcaetano so far, I don't feel a need to bring them in-house ( though if it is costing you we sure can do so. )

I don't think we should differentiate between dev & normal pods, I don't think that distinction is something I'd ever look for when looking at a badge, I'm usually just interested in license / platform / version ( will be very glad to add license to cocoapods search eventually. )

Do we know if it's possible to have black text? if so, I'd like to try:

pod version: FB0006
platform: 380100
license : 5BA7E9

@orta
Copy link
Member

orta commented May 20, 2014

this is mainly because I think it fits in terms of the visual hierarchy of brightness, the important thing is version, then platform then license.

@fjcaetano
Copy link

@orta, I switched the badge provider service to shields.io, so the output is the same:

Version Platform License
version platform license
version platform license

@fjcaetano
Copy link

Honestly, I don't like those colors. As mentioned, I think the red may cause confusion with "build failure" CI badges. The platform color actually looks good, but only with the flat style. And the license badge could be a little darker, I think the default blue color looks better.

Nevertheless, I will set the colors to whatever you guys see fit since I believe it makes sense to conform to the official Cocoapods color scheme.

@orta
Copy link
Member

orta commented May 21, 2014

Well it looks like I can play with the html, so IMO, we should have this as the defaults on all new projects:

Travis Version License Platform
version / version version license platform

I agree with the idea that we shouldn't really use reds, but reds / browns are our colour scheme. So I opted for highlighting the version in a neutral blue, then taping off the visual weight as the other badges become lower priority.

@kylef
Copy link
Contributor

kylef commented May 21, 2014

@orta Nicely done 👍. Maybe a docs badge too? 😄.

We should make LICENSE link to the license file too.

@segiddins
Copy link
Member

What are the colors?

@orta
Copy link
Member

orta commented May 21, 2014

5BA7E9 - 373737 - 989898

@segiddins
Copy link
Member

segiddins added a commit to segiddins/shields that referenced this issue May 21, 2014
segiddins added a commit to segiddins/shields that referenced this issue May 21, 2014
@fjcaetano
Copy link

Wait, I don't get it. These changes are in the shields.io project...

@segiddins
Copy link
Member

Right, I just had a PR merged in there

@fjcaetano
Copy link

There is already an official project providing these badges at cocoapod-badges that is the one everyone uses, but you created a new one (inside shields.io) without notifying anyone.

What should I do with the official one then?

@segiddins
Copy link
Member

Oh I was under the impression that this is what Orta/Fabio wanted. My bad if I misunderstood.

@fjcaetano
Copy link

Well, I'm not against moving it into shields.io, but I don't think it was discussed. The problem would be migrating those already using cocoapod-badges

@orta
Copy link
Member

orta commented May 23, 2014

Hrm, now that shields.io support cocoapods as a first party platform I think it makes sense to start migration over to it. Not to detract from cocoapod-badges, you kickstarted the entire idea but they are doing it for everyone else too.

For the migration I actually have a copy of every cocoapods's readme on CocoaDocs.org's server, it might not be too bad to send them a "you should migrate, you've got x months to switch" message.

@segiddins
Copy link
Member

I'd be willing to write a proxy server for cocoapod-badges that forwards requests to shields

@segiddins
Copy link
Member

Here is a basic rack app that redirects to shields:

# config.ru
require 'rack/rewrite'

app = Proc.new do |env|
    [404, {"Content-Type" => "text/plain", "X-Cascade" => "pass"}, ["Not Found: #{env['REQUEST_PATH']}"]]
end

app = Rack::Rewrite.new(app) do
  r301 '/', 'http://badges.github.io/cocoapod-badges/'
  r301 %r{/(.)/(.+)/(?:.+/)?badge.(.+)}, 'http://img.shields.io/cocoapods/$1/$2.$3'
end

run app

It's running at http://secure-bastion-3309.herokuapp.com/ (See i.e. http://secure-bastion-3309.herokuapp.com/p/RestKit/badge.png)

@fabiopelosin
Copy link
Member Author

For me any of the solutions would be fine, the important is to have a rocking flat style with the appropriate colours. One the one hand I like the idea keep using the service of @fjcaetano as an acknowledgement of an early contribution; on the other ones, shields.io is a point of reference where to look for badges and would not require any form of maintenance.

espadrine pushed a commit to badges/shields that referenced this issue May 26, 2014
@fjcaetano
Copy link

I'm really tight this week. Let's see if we can gather during WWDC to proxy these things 😉

@segiddins
Copy link
Member

^ is a ruby proxying app that would do the job

@fjcaetano
Copy link

I'll do it in Django, the same as it was before. It will be quick.

@segiddins, can you add a badge in shields.io with a user specified version in the URL, regardless of what's in the podspec? cocoapod-badges had this feature and I think it would be nice to port over to shields.io:

https://cocoapod-badges.herokuapp.com/v/$PODNAME/$VERSION/badge.png

@segiddins
Copy link
Member

For that, you can just specify the URL straight by the version, since then the pod name doesn't matter.
https://img.shields.io/badge/version-$VERSION-5BA7E9.svg?style=flat

@fjcaetano
Copy link

The problem is the color. The end user may not know what the color for the version badge is. If at some point we decide to change that badge color, the one's specified "by hand" will differ from the official ones.

I asked you to do it because my knowledge of Ruby tends to nil.

@segiddins
Copy link
Member

If the badge color changes in shields, we can update it in the proxy

-Samuel E. Giddins

On May 26, 2014, at 2:26 PM, Flávio Caetano [email protected] wrote:

The problem is the color. The end user may not know what the color for the version badge is. If at some point we decide to change that badge color, the one's specified "by hand" will differ from the official ones.

I asked you to do it because my knowledge of Ruby tends to nil.


Reply to this email directly or view it on GitHub.

@orta
Copy link
Member

orta commented May 27, 2014

@fjcaetano I don't see you at http://www.meetup.com/CocoaPods-SF/events/177557362/

Regardless we should meet up.

@fjcaetano
Copy link

@orta, I was to RSVP to the events but I'm having two absolutely heavy weeks (travel planning) and I completely forgot.

@orta
Copy link
Member

orta commented May 27, 2014

get on the guest list and I'll push you to confirmed, we can't have someone whose helped out like you have not there.

@fjcaetano
Copy link

I'm on the whishlist.

@fjcaetano
Copy link

Gentlemen, after long overdue I finally proxied everything to shields.io service and discontinued the cocoapod-badges project.

The URL service remains as legacy and every pod that has my badges in their README must already have been updated. Thank you all for your support, if there's anything else I can do, please, let me know.

@pavankataria
Copy link

Guys, for the pod version img shield, how can I change the colour of it? I understand there may be conventions in place for the colour blue to be chosen but I don't think that the majority would care if I decided to make it a bright green so it matches with my other badges.
Hope it's possible somehow, by hook or crook. I mean, I could just create the badge myself but then the pod version number wouldn't be dynamic.. and I don't fancy having to change that version number myself repeatedly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants