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
2.8 KiB
Contributing to anybadge
I love your input! I want to make contributing to this project as easy and transparent as possible, whether it's:
- Reporting a bug
- Discussing the current state of the code
- Submitting a fix
- Proposing new features
- Becoming a maintainer
I use Github Flow, so all code changes happen through pull requests
Pull requests are the best way to propose changes to the codebase (I use Github Flow). I actively welcome your pull requests:
- Fork the repo and create your branch from
master
- If you've added code that should be tested, add tests
- If you've changed APIs, update the documentation
- Ensure the test suite passes
- Make sure your code lints (tbc)
- Issue that pull request!
Any contributions you make will be under the MIT Software License
When you submit code changes, your submissions are understood to be under the same MIT License that covers the project. Feel free to contact the maintainers if that's a concern.
Report bugs using Github's issues
I use GitHub issues to track public bugs. Report a bug by opening a new issue.
Write bug reports with detail, background, and sample code
Great Bug Reports tend to have:
- A quick summary and/or background
- Steps to reproduce
- Be specific!
- Give sample code if you can (ideally sample code that anyone with a basic setup can run to reproduce)
- What you expected would happen - (include explanation, screenshot, drawings, etc. to be exact)
- What actually happens
- Notes (possibly including why you think this might be happening, or stuff you tried that didn't work)
People love thorough bug reports.
Use a Consistent Coding Style
Please follow the existing coding style.
License
By contributing, you agree that your contributions will be licensed under its MIT License.
Technical stuff
Documentation
The README.md
file contains a table showing example badges for the different built-in colors. If you modify the
appearance of badges, or the available colors please update the table using the following code:
import anybadge
print("""| Color Name | Hex Code | Example |
| ---------- | -------- | ------- |""")
for color in sorted([c for c in anybadge.colors.Color], key=lambda x: x.name):
file = 'examples/color_' + color.name.lower() + '.svg'
url = 'https://cdn.rawgit.com/jongracecox/anybadge/master/' + file
anybadge.Badge(label='Color', value=color, default_color=color.name.lower()).write_badge(file, overwrite=True)
print("| {color} | {hex} |  |".format(color=color.name.lower(), hex=color.value.upper(), url=url))