Badgen.net: GitHub release/tag is not perfect

Created on 25 Jul 2018  ·  10Comments  ·  Source: badgen/badgen.net

More of a note to me.

Currently we get the "first in response array" tag/release.
The Babel example is perferct for showing the problem.

I think with /github/release/owner/repo we should show latest stable release/tag. In the case with Babel latest one happens to be a "prerelease", so it shows it in orange.

I'm thinking for this

  • /github/release/owner/repo should show lastest stable release (e.g. Babel's v6), in blue
  • /github/release/owner/repo/prerelease show latest prerelease

Or what about /github/prerelease/owner/repo for the prereleases and /github/release for the stable ones?

Perfect would be /github/release and /github/prerelease, because this will allow for static github badges like /github/release/owner/repo/v1.2.3 ... which... actually, not make much sense because you can just /badge/release/v1.2.3/color ;d

All 10 comments

Perfect would be /github/release and /github/prerelease, because this will allow for static github badges like /github/release/owner/repo/v1.2.3

Nice!

Nice!

Rethinking it, i don't like it.
I'm more for /github/release/owner/repo and /github/release/owner/repo/prerelease, because here the prerelease is like a modifier, which make sense to be there. It's optional, like the color is optional.

😂That make sense too.

Further thoughts:

  • /github/release/owner/repo better show the latest released item in github, as represent the "current status" of repo,
  • /github/release/owner/repo/stable stick to latest stable release,
  • /github/release/owner/repo/prerelease(or just /pre) shows latest prerelease,
  • /github/release/owner/repo/next shows next release.

Overall, the /github/release means the latest release in the repo, or specific channel.

Oookey, great.

Only that: how you'll now "next release" :joy_cat: ?! ;d

Ooops, github don't have a "next" release, that's npm specific 🤦‍♂️

So this issue applies those ideas to npm badges too :laughing:

  • /npm/v/micromatch - the latest (default)
  • /npm/v/micromatch/latest - same as above
  • /npm/v/ava/next - the next dist-tag
  • /npm/v/foobar/whatever - the whatever dist-tag

Finally got this
image

:+1: but why "latest tag"

Hmmm, maybe not. I thought that make it clear it's "latest" (not "some") tag. What's your idea?

To me "release" feels like it's latest by default, but "tag"s feels all equal.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tunnckoCore picture tunnckoCore  ·  3Comments

madnight picture madnight  ·  5Comments

shellscape picture shellscape  ·  4Comments

tunnckoCore picture tunnckoCore  ·  6Comments

tunnckoCore picture tunnckoCore  ·  4Comments