Commit Graph

34 Commits

Author SHA1 Message Date
Jon Grace-Cox
9d4470a1a0 Allow badges with no value or no label (#89)
This commit allows badges to be generated with only a label or only
a value.

Badges must provide at least a label or a value, so it is not valid
to create a badge with no label and no value. This will result in
a `ValueError` being raised.
2024-12-30 06:53:33 -05:00
Jon Grace-Cox
f4fbb70d87 Add pepy.tech total downloads badge to readme (#83) 2022-08-24 18:52:28 -04:00
Jon Grace-Cox
bc1ff41348 Fix readme and contribution guide (#82) 2022-08-24 18:44:22 -04:00
Jon Grace-Cox
ea180efc1e Add snyk health badge to readme (#81) 2022-08-24 18:36:59 -04:00
Jon Grace-Cox
2af319bc6b Add standard color names (#76)
Closes #56
2022-08-15 14:43:27 -04:00
Jon Grace-Cox
34374dbc2b Add emoji examples to documentation (#74)
Closes #43
2022-08-14 12:33:12 -04:00
Jon Grace-Cox
8a434d95b5 Drop <3.7 support and add type hints (#59)
- Drop support for Python <3.7
- Bump the pre-commit version used in CI
- Add type hinting and docstrings
- Add mypy to pre-commit config
- Fix typing issues
- Update colors module
  - Update colors module to use uppercase hex codes
  - Add `__lt__` to allow sorting colors by name
- Fix `build_examples.py` to work with color Enum
- Update example badges in `README.md`
- Fix typing issues in server
- Update travis links in `README.md`
- Fix PyPi deployment bug (#60)
2022-08-08 23:19:50 -04:00
Jon Grace-Cox
b6ca345ebe Drop py27 support and refactor (#51) (#52)
Python version support
======================
- Drop Python 2.7 support
- Add testing for Python 3.4 and 3.9
- Set python version requirements in setup.py

Package changes
===============
- Split module up into a package with submodules
- Break templates out into package resources
- Incorporate server into same package
- Use Enum for colors
- Refresh example badges
- Simplify documentation - Remove cli options and python api
  documentation from the README as it is hard to maintain, and
  often goes out-of-date
- Add CONTRIBUTING.md
2022-03-10 07:26:46 -05:00
Matt Calvert
6de2da8d58 Add style support and add GitLab Scoped labels (#50)
- Add new `--style` argument
- Add new **GitLab Scoped** label style
- Update documentation to reflect new argument
2022-02-22 08:52:24 -05:00
Jon Grace-Cox
fa351616e1 Add buymeacoffee link to README.md 2021-11-04 14:45:58 -04:00
Jon Grace-Cox
a5ff4f0dfe Add semantic version support (#45) (#46)
Allow value and thresholds to be interpreted as semantic version numbers
by passing --semver (cli) or semver=True (python).

Add docs, unittests, import error handling, cli updates, requirements updates.
2021-05-25 18:22:43 -04:00
Jon Grace-Cox
0f8dfbb695 Add label and value padding char command line options. (#40)
Also fixes command line usage with args defaulting to None on main function.
2020-03-15 13:29:08 -04:00
Jon Grace-Cox
aeedfbb93d Fix padding issues (#38)
* Set default padding chars to 0.5.
* Split num_padding_chars into num_label_padding_chars and num_value_padding_chars
  to allow better control. Retain num_padding_chars as an input parameter, but
  internally it is dropped.
* Remove padding multipliers.
* Add measurements image for developers. Helps show what each of the internal
  measurements are.
* Add script to build example badges.
* Update example badges.

Reliability
=======

* Raise a value error if an invalid font is passed.
* Handle labels that are not passed as str.
* Raise a value error if an invalid color name is passed.

Testing
=======

* Expand doctests to increase test coverage.
* Add Arial size 11 font and extra font sizes (mainly for testing).
* Make parse_args and main more testable by taking args as an input parameter.
* Use useful badge text in unittest badges.
* Add template svg file for testing.
* Add HTML coverage generation to travis yaml.
2020-03-15 12:51:34 -04:00
Jon Grace-Cox
b7387b9f1e Fix README code used to generate color examples table 2019-11-16 23:39:46 -05:00
Jon Grace-Cox
32935bd204 Add github cdn url prefixes to README color examples (#35) 2019-11-16 23:34:34 -05:00
Jon Grace-Cox
1cb03dcab9 33 fix setup readme issue (#34)
* Add bash prefixes to README code sections
* Switch to providing long description as markdown in setup.py

Closes #33
2019-11-16 23:19:38 -05:00
Jon Grace-Cox
c4d06f3e05 Add extra colors and update docs (#31)
* Add a wider set of color names.
* Add better documentation in readme to show use of colors and
  custom colors.
* Add example color badges.
2019-08-12 09:41:50 -04:00
Jon Grace-Cox
b394b47cc2 Adding all the badges to README (#23) 2019-06-21 01:12:01 -04:00
Jon Grace-Cox
6b232b1e9b Add downloads stats to README 2019-06-21 00:24:17 -04:00
Jon Grace-Cox
a284b4f32e Add demo repl to README.md 2019-06-02 00:28:34 -04:00
Jon Grace-Cox
281c7871d6 Add pypi package badge to README.md 2019-06-01 04:35:10 -04:00
Jon Grace-Cox
5405e1920c Update README.md with latest changes 2019-06-01 03:38:41 -04:00
Jon Grace-Cox
2905d4a022 Switch to renderable SVG links in README. 2018-02-10 11:43:08 -05:00
Jon Grace-Cox
6d9863262c Added reStructuredText syntax check to setup.py and updated README. 2018-02-10 11:27:40 -05:00
Jon Grace-Cox
b1ff0c468a Add PyPi link to README. 2018-02-10 10:48:03 -05:00
Jon Grace-Cox
352f11f27f Convert remainder of README to markdown. 2018-02-10 10:46:05 -05:00
Jon Grace-Cox
397add0179 Added extra examples to README. 2018-02-10 10:31:01 -05:00
Jon Grace-Cox
bf68dd7b92 Include examples in README. Switch to markdown README. 2018-02-10 10:21:31 -05:00
Jon Grace-Cox
74ab9802b2 Replaced README and README.md with README.rst. (#5) 2017-09-12 19:44:23 -04:00
Jon Grace-Cox
311dee665d Added changelog and extended README.md. (#4) 2017-09-12 19:44:15 -04:00
Jon Grace-Cox
a5ff11669d README.md 2017-09-11 21:47:01 -04:00
Jon Grace-Cox
dedb789c0c Added link to travis from build badge in README. 2017-09-11 21:05:02 -04:00
Jon Grace-Cox
68700eb657 Added build badge to readme. 2017-09-11 18:23:58 -04:00
jongracecox
8a9f03ac22 Initial commit 2017-09-11 17:04:36 -04:00