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

Fix some errors in the README.md #93

Merged
merged 1 commit into from
Oct 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 40 additions & 28 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,19 @@
[![GitHub Link](https://img.shields.io/badge/GitHub-HBehrens/puncover-8da0cb?style=flat-square&logo=github)](https://github.com/HBehrens/puncover)

[![GitHub Workflow Status (branch)](https://img.shields.io/github/actions/workflow/status/HBehrens/puncover/ci.yml?style=flat-square&branch=master)](https://github.com/HBehrens/puncover/actions?query=branch%3Amaster+)

[![Codecov branch](https://img.shields.io/codecov/c/github/HBehrens/puncover/master?style=flat-square)](https://codecov.io/gh/HBehrens/puncover)

[![PyPI](https://img.shields.io/pypi/v/puncover?style=flat-square)](https://pypi.org/project/puncover)

[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/puncover?style=flat-square)](https://pypi.org/project/puncover)

[![License - MIT](https://img.shields.io/github/license/HBehrens/puncover?color=blue&style=flat-square)](https://github.com/HBehrens/puncover)
[![](https://img.shields.io/badge/GitHub-HBehrens/puncover-8da0cb?style=flat-square&logo=github)](https://github.com/HBehrens/puncover)
[![](https://img.shields.io/github/actions/workflow/status/HBehrens/puncover/ci.yml?style=flat-square&branch=master)](https://github.com/HBehrens/puncover/actions?query=branch%3Amaster+)
[![](https://img.shields.io/codecov/c/github/HBehrens/puncover/master?style=flat-square)](https://codecov.io/gh/HBehrens/puncover)
[![](https://img.shields.io/pypi/v/puncover?style=flat-square)](https://pypi.org/project/puncover)
[![](https://img.shields.io/pypi/pyversions/puncover?style=flat-square)](https://pypi.org/project/puncover)
[![](https://img.shields.io/github/license/HBehrens/puncover?color=blue&style=flat-square)](https://github.com/HBehrens/puncover)

# puncover

![image](https://raw.githubusercontent.com/HBehrens/puncover/master/images/overview.png)
![](https://raw.githubusercontent.com/HBehrens/puncover/master/images/overview.png)

Analyzes C/C++ binaries for code size, static variables and stack usages. It
creates a report with disassembler and call-stack analysis per directory, file,
or function.

# Installation and Usage
## Installation and Usage

Install with pip:

Expand All @@ -36,11 +31,13 @@ puncover --elf_file project.elf

Open the link in your browser to view the analysis.

# Running Tests Locally
## Running Tests Locally

### Setup

To run the tests locally, you need to install the development dependencies:

1. install pyenv: <https://github.com/pyenv/pyenv>
1. install pyenv: https://github.com/pyenv/pyenv

```bash
curl https://pyenv.run | bash
Expand All @@ -59,16 +56,38 @@ To run the tests locally, you need to install the development dependencies:
pip install -r requirements-dev.txt
```

### Running Tests

Then you can run the tests with:

```bash
tox
```

# Publishing Release
or, to target only the current `python` on `$PATH`:

1. Update the version in `puncover/__version__.py`.
```bash
tox -e py
```

## Publishing Release

### Release Script

See `release.sh` for a script that automates the above steps. This example will
work with the PyPi tokens (now required):

```bash
PUNCOVER_VERSION=0.3.5 TWINE_PASSWORD="<pypi token>" TWINE_USERNAME=__token__ ./release.sh
```

### Manual Steps

Only for reference, the release script should take care of all of this.

<details><summary>Click to expand</summary>

1. Update the version in `puncover/__version__.py`.
2. Commit the version update:

```bash
Expand All @@ -88,8 +107,8 @@ tox
```

5. Either wait for the GitHub Action to complete and download the release
artifact for uploading: <https://github.com/HBehrens/puncover/actions> OR
Build the package locally: `python setup.py sdist bdist_wheel`
artifact for uploading: https://github.com/HBehrens/puncover/actions OR Build
the package locally: `python setup.py sdist bdist_wheel`

6. Upload the package to PyPI:

Expand All @@ -102,15 +121,8 @@ tox
- `gh release create --generate-notes x.y.z`
- attach the artifacts to the release too: `gh release upload x.y.z dist/*`

## Release Script

See `release.sh` for a script that automates the above steps. This example will
work with the PyPi tokens (now required):

```bash
PUNCOVER_VERSION=0.3.5 TWINE_PASSWORD="<pypi token>" TWINE_USERNAME=__token__ ./release.sh
```
</details>

# Contributing
## Contributing

Contributions are welcome! Please open an issue or pull request on GitHub.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def run(self):
version=__version__,
description="Analyses C/C++ build output for code size, static variables, and stack usage.",
long_description=open("README.md").read(),
long_description_content_type="text/x-rst",
long_description_content_type="text/markdown",
url="https://github.com/hbehrens/puncover",
download_url="https://github.com/hbehrens/puncover/tarball/%s" % __version__,
author="Heiko Behrens",
Expand Down