Metadata-Version: 2.4
Name: ezchlog
Version: 1.0.2
Summary: Easy git branch friendly changelogs
Project-URL: Repository, https://gitlab.com/jrdasm/ezchlog
Project-URL: Documentation, https://gitlab.com/jrdasm/ezchlog/-/blob/master/README.md
Project-URL: Bug Tracker, https://gitlab.com/jrdasm/ezchlog/-/issues
Project-URL: Merge Requests, https://gitlab.com/jrdasm/ezchlog/-/merge_requests
Project-URL: Changelog, https://gitlab.com/jrdasm/ezchlog/-/blob/master/CHANGELOG.md
Project-URL: Contributing, https://gitlab.com/jrdasm/ezchlog/-/blob/master/CONTRIBUTING.md
Author-email: Cyrille Pontvieux <cyrille@enialis.net>
License: MIT License
License-File: LICENSE
Keywords: changelog,easy,git,no-conflict,release-notes
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Natural Language :: English
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Documentation
Classifier: Topic :: Software Development :: Documentation
Classifier: Topic :: Text Processing :: Markup :: Markdown
Classifier: Typing :: Typed
Requires-Python: >=3.9
Requires-Dist: tomli; python_version < '3.11'
Description-Content-Type: text/markdown

Easy Changelog
==============

Python version
--------------

Install this repository from Pypi:
```sh
pip install ezchlog
```
Or any other means (`pipx` or a package manager).  
Python 3.9+ required.

Rust version
------------

Download a pre-compiled version from [releases](https://gitlab.com/jrdasm/ezchlog/-/releases).

Don’t forget to download the checksum file and check for corruption.  
You should rename the binary to `ezchlog` and place it on your PATH.

You can also compile the `ezchlog` rust binary from source (you should have `rustc`, `cargo` and `upx` available):
```sh
make release
```

After installation
------------------

Then you’ll have a command to handle your logs:
```sh
ezchlog --help
```

Add a changelog
---------------

```sh
$ ezchlog add "New url for example API"
Changed            new_url_for_example_api
$ ezchlog add -p "Fix example API" Fixed 142
_CHANGELOGS/Fixed/142_fix_example_api.md
```

The file is automatically added to git index unless `--no-git` is used.

List changelogs
---------------

```sh
$ ezchlog list
Fixed              142_fix_example_api
Changed            new_url_for_example_api
```

```sh
$ ezchlog list -p
_CHANGELOGS/Fixed/142_fix_example_api.md
_CHANGELOGS/Changed/new_url_for_example_api.md
```

Commit with git
---------------

If you use `git`, you can automatically create a git commit with its message using part log files.

By default it will use the only part log file in the **git index** as base for the git commit summary message.

If you have **multiple files** in the index, specify which one is the **main one**, i.e. which one will be use as the summary message.

All part log files in the index will be used in the full git message.

```sh
$ ezchlog commit
[master (root-commit) c0cc282] 142: Fix example API
 2 files changed, 3 insertions(+)
 create mode 100644 _CHANGELOGS/Fixed/142_fix_example_api.md
 create mode 100644 example/api_doc.md
```

The summary message format is `{Ref}: {Title}` if there is a reference, or simply `{Title}`.

- `Title` is the part log first line, without the reference and without any markdown list prefix.
- `Ref` is what is between brackets on the part log first line, with `Ref ` added upfront if the reference start with a sharp `#` (because it’s a comment for git)

Merge changelogs
----------------

```sh
$ ezchlog merge 1.2.3
$ cat CHANGELOG.md
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.1.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## 1.2.3
### Fixed
- Fix example API (142)
### Changed
- New url for example API
```

Files are automatically updated in the git index unless `--no-git` is used.

Configuration
-------------

The following configuration parameters could be specified as environment variables or in a `.ezchlog.toml` file (or `pyproject.toml` file for the python version).

- `EZCHLOG_EDITOR` default to `EDITOR` or `vim`
- `EZCHLOG_LOG_DIR` default to `_CHANGELOGS`
- `EZCHLOG_LOG_FILE` default to `CHANGELOG.md`
- `EZCHLOG_CATEGORY_LIST` default to `Security,Fixed,Changed,Added,Removed,Deprecated`
- `EZCHLOG_CATEGORY_DEFAULT` default to `Changed`
- `EZCHLOG_DEFAULT_CHANGELOG` default to  
```
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.1.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
```
- `EZCHLOG_NO_GIT` default to `False`

For `.ezchlog.toml` or `pyproject.toml` config key, use the environment variable name in lowercase without the `EZCHLOG` prefix, for instance `log_dir` or `category_list` keys.

For `pyproject.toml`, the config resides in the `tool.ezchlog` table.
