...because your users shouldn't need to connect to someone else's server, just to display a few (static) badges in your README
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

3.4 KiB

Release Log of ./badges

Unreleased Changes

Additions

  • Added an example template: example-circle

v2.0.0 - 2021-09-18

This marks a major release for ./badges with numerous large- and small-scale improvements, especially for creating GUIs around ./badges due to explicit parameter declaration. CLI invocation has been simplified and yet made more flexible by adding stdin/stdout support.

Bugfixes

  • Fixed template.tmpl referring to the wrong font's metrics.
  • Fixed invalid error message when parsing badge parameters.
  • Builtin standard badge template received metrics for the left font instead of for the right font.
  • Fixed toInteger incorrectly handling float32 and invalid type values.
  • FilesystemTemplate: ListThemes used the wrong directory

Additions

  • Added example parameter to parameters.json and paramspec
  • CLI: Added support for setting parameters in subtrees
  • Added basic unit tests for badgerenderer
  • Added explicit error for referencing an unknown font
  • Extended documentation

Modifications

  • Moving tplfunctions and badgetemplate/compile.go back into badgerenderer
  • Moved the badgetemplate and templates packages out of badgerenderer
  • Fonts are no longer passed in as template parameters, instead they are referenced by name (with the related template functions becoming closures of the Renderer)
  • Simplified template parameter usage (dropped requirement for prepending .params)
  • Dropped template name from badgerenderer compilation functions
  • ConvertAndValidateParams no longer modifies the parameter map in place, instead it creates a copy
  • Renderer now integrates parameter spec compilation and parameter validation
  • ConvertAndValidateParams now explicitly rejects nil parameter maps
  • Renderer now has its own, high-level error values
  • Gracefully handling flag.ErrHelp in CLI

v2.0.0-rc.3 - 2021-08-16

Bugfixes

  • Fixed module path to now include the suffix /v2.

v2.0.0-rc.2 - 2021-08-16

Bugfixes

  • Fixed output file not getting truncated.
  • Text metrics / spacing fixed (issue #2).

Additions

  • Added isFontName flag to parameter specification.
  • Added script to generate generic badges.

Modifications

  • standard-badge: Adding a bit more padding.
  • paramspec: Correcting case of JSON serialization.

v2.0.0-rc.1 - 2021-08-15

Deletions

  • Removed the packages themes and params.

Modifications

  • Templates now have their own directory, which also contains the themes, parameter specification (parameters.json) and optional embedding package (template.go).
  • Templates now declare their parameters and the types of the parameters.
  • Changed LoadBuiltinFonts to panic in case of error, since failure is not expected.
  • Dropped separation between theme and template parameters.
  • Dropped TemplateInput struct.
  • Changed badgerenderer API to use a Renderer struct, decoupling the rendering process.
  • Moved template functions into their own sub-package.
  • Rewritten CLI, dropped batch processing, modified arguments (see usage info).
  • Renaming default-parameters to generic-badges.

Additions

  • Package paramspec contains types and functions for representing parameter specifications (parameters.json) and validating/converting parameters according to these specifications.
  • Package badgetemplate contains types and functions for loading and handling badge templates.

v1.0.0 - 2021-06-03

The initial release of ./badges