Skip to content

Commit

Permalink
Update documentation for clarification
Browse files Browse the repository at this point in the history
The changes made update the wording in the documentation to clarify the roles of `include_bumps` and `exclude_bumps` in the bump-my-version configuration. Additionally, unnecessary repetition was removed and overlapping examples were also corrected.
  • Loading branch information
coordt committed Jun 13, 2024
1 parent 2df57cc commit 2224808
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions docs/reference/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -736,9 +736,9 @@ if `True`, don't fail if the configured file is missing.
type
: list of strings

The `include_bumps` file configuration allows you to control when this file is changed by inclusion. Its alternative is the `exclude_bumps` configuration. When a `bump <version component>` command is issued, this file is changed only if the version component is in this list and not in [`exclude_bumps`](#exclude_bumps). The [parse](#parse) configuration defines version components.
The `include_bumps` file configuration allows you to control when bump-my-version includes this file for changes. Its alternative is the `exclude_bumps` configuration. When a `bump <version component>` command is issued, this file is changed only if the version component is in this list and not in [`exclude_bumps`](#exclude_bumps). The [parse](#parse) configuration defines version components.

The default value, or an empty list, includes all version components.
The default value, or an empty list, includes all version components.

### exclude_bumps

Expand All @@ -753,17 +753,17 @@ The default value, or an empty list, includes all version components.
type
: list of strings

The `exclude_bumps` file configuration allows you to control when this file is changed by exclusion. Its alternative is the `include_bumps` configuration.When a `bump <version component>` command is issued, this file is only changed if the version component is *not in this list.* The [parse](#parse) configuration defines version components.
The `exclude_bumps` file configuration allows you to control when bump-my-version excludes this file for changes. Its alternative is the `include_bumps` configuration. When a `bump <version component>` command is issued, this file is only changed if the version component is *not in this list.* The [parse](#parse) configuration defines version components.

The default value does not exclude anything.

### Examples

=== "TOML"

TOML allows us to specify the files using an [array of tables.](https://toml.io/en/v1.0.0#array-of-tables) TOML configuration files add two configuration fields to each file configuration: `filename` and `glob`. These fields are mutually exclusive: if you specify a value for both, only the `glob` value is used.
TOML allows us to specify the files using an [array of tables.](https://toml.io/en/v1.0.0#array-of-tables) TOML configuration adds two fields to each file configuration: `filename` and `glob`. These fields are mutually exclusive: if you specify a value for both, only the `glob` value is used.

For example, to change `coolapp/__init__.py` with the defaults, and alter `CHANGELOG.md` in twice:
For example, to change `coolapp/__init__.py` with the defaults and alter `CHANGELOG.md` twice:

```toml
[[tool.bumpversion.files]]
Expand All @@ -790,9 +790,9 @@ The default value does not exclude anything.
The configuration file format requires each section header to be unique. If you want to process a certain file multiple times, you may append a description between parens to the `file` keyword: `[bumpversion:file (special one):…]`.


For example, to change `coolapp/__init__.py` with the defaults, and alter `CHANGELOG.md` in twice:

For example, to change `coolapp/__init__.py` with the defaults and alter `CHANGELOG.md` twice:

```ini
[bumpversion:file:coolapp/__init__.py]

Expand Down

0 comments on commit 2224808

Please sign in to comment.