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

Custom badges #55

Closed
pflannery opened this issue Feb 8, 2015 · 1 comment
Closed

Custom badges #55

pflannery opened this issue Feb 8, 2015 · 1 comment
Labels
enhancement Improvement or suggestion

Comments

@pflannery
Copy link
Contributor

Would be nice to be able to add custom badges like:

badges: 
  custom:
    analytics:
      text: 'Analytics'
      image: 'https://ga-beacon.appspot.com/some-ga-code/some-repo/readme'
      url: 'https://github.com/some-org-auth/some-repo'
      tooltip: 'hello'

something like the following code put into misc badges to parse these custom badges

custom = (opts) ->
  if opts == null
    opts = {}
  if !opts.badges.custom or !opts.name
    return ''
  else
    results = ''
    for key of opts.badges.custom
      customInfo = opts.badges.custom[key]
      tooltipFmtd = if customInfo.tooltip then ' "' + customInfo.tooltip + '"' else ''
      results += '[![' + customInfo.text + '](' + customInfo.image + ')](' + customInfo.url + tooltipFmtd + ')'

  results

I'll be happy to pull on this

@mikeumus mikeumus added the enhancement Improvement or suggestion label Feb 9, 2015
balupton added a commit that referenced this issue Sep 16, 2015
- Initial stable release
- Readme and Package files are now extension independent
- Readme sections are now outputted in HTML instead of Markdown to be
more universal
- Support SPDX licenses
	- Implements [#72](#72),
[#66](#66)
	- Fixes [#65](#65)
- Uses new [bevry/badges](https://github.com/bevry/badges) package for
badge rendering
	- Implements [#67](#67),
[#55](#55),
[#25](#25),
[#10](#10)
- Uses new [bevry/fellow](https://github.com/bevry/fellow) package for
people handling
	- Implements [#37](#37),
[#11](#11)
- Newline no longer required at start of readme file
	- Fixes [#53](#53)
- Moved from CoffeeScript to ES6+
	- Fixes [#20](#20)
@balupton
Copy link
Member

v1.0.0 resolves this

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

No branches or pull requests

3 participants