Skip to content

Commit 8591f15

Browse files
dbantyGitHub
and
GitHub
authored
chore: prepare release 0.21.0 (#1053)
This PR was created by Knope. Merging it will create a new release ### Breaking Changes #### Removed the `update` command The `update` command is no more, you can (mostly) replace its usage with some new flags on the `generate` command. If you had a package named `my-api-client` in the current working directory, the `update` command previously would update the `my_api_client` module within it. You can now _almost_ perfectly replicate this behavior using `openapi-python-client generate --meta=none --output-path=my-api-client/my_api_client --overwrite`. The only difference is that `my-api-client` would have run `post_hooks` in the `my-api-client` directory, but `generate` will run `post_hooks` in the `output-path` directory. Alternatively, you can now also run `openapi-python-client generate --meta=<your-meta-type> --overwrite` to regenerate the entire client, if you don't care about keeping any changes you've made to the generated client. Please comment on [discussion #824](#824) (or a new discussion, as appropriate) to aid in designing future features that fill any gaps this leaves for you. ### Features #### Added an `--output-path` option to `generate` Rather than changing directories before running `generate` you can now specify an output directory with `--output-path`. Note that the project name will _not_ be appended to the `--output-path`, whatever path you specify is where the generated code will be placed. #### Added an `--overwrite` flag to `generate` You can now tell `openapi-python-client` to overwrite an existing directory, rather than deleting it yourself before running `generate`. Co-authored-by: GitHub <[email protected]>
1 parent 732b533 commit 8591f15

5 files changed

+33
-36
lines changed

.changeset/added_an_output_path_option_to_generate.md

Lines changed: 0 additions & 9 deletions
This file was deleted.

.changeset/added_an_overwrite_flag_to_generate.md

Lines changed: 0 additions & 8 deletions
This file was deleted.

.changeset/remove_the_update_command.md

Lines changed: 0 additions & 18 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,38 @@ Programmatic usage of this project (e.g., importing it as a Python module) and t
1313

1414
The 0.x prefix used in versions for this project is to indicate that breaking changes are expected frequently (several times a year). Breaking changes will increment the minor number, all other changes will increment the patch number. You can track the progress toward 1.0 [here](https://github.com/openapi-generators/openapi-python-client/projects/2).
1515

16+
## 0.21.0 (2024-06-08)
17+
18+
### Breaking Changes
19+
20+
#### Removed the `update` command
21+
22+
The `update` command is no more, you can (mostly) replace its usage with some new flags on the `generate` command.
23+
24+
If you had a package named `my-api-client` in the current working directory, the `update` command previously would update the `my_api_client` module within it. You can now _almost_ perfectly replicate this behavior using `openapi-python-client generate --meta=none --output-path=my-api-client/my_api_client --overwrite`.
25+
26+
The only difference is that `my-api-client` would have run `post_hooks` in the `my-api-client` directory,
27+
but `generate` will run `post_hooks` in the `output-path` directory.
28+
29+
Alternatively, you can now also run `openapi-python-client generate --meta=<your-meta-type> --overwrite` to regenerate
30+
the entire client, if you don't care about keeping any changes you've made to the generated client.
31+
32+
Please comment on [discussion #824](https://github.com/openapi-generators/openapi-python-client/discussions/824)
33+
(or a new discussion, as appropriate) to aid in designing future features that fill any gaps this leaves for you.
34+
35+
### Features
36+
37+
#### Added an `--output-path` option to `generate`
38+
39+
Rather than changing directories before running `generate` you can now specify an output directory with `--output-path`.
40+
Note that the project name will _not_ be appended to the `--output-path`, whatever path you specify is where the
41+
generated code will be placed.
42+
43+
#### Added an `--overwrite` flag to `generate`
44+
45+
You can now tell `openapi-python-client` to overwrite an existing directory, rather than deleting it yourself before
46+
running `generate`.
47+
1648
## 0.20.0 (2024-05-18)
1749

1850
### Breaking Changes

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ dependencies = [
1818
"typing-extensions>=4.8.0,<5.0.0",
1919
]
2020
name = "openapi-python-client"
21-
version = "0.20.0"
21+
version = "0.21.0"
2222
description = "Generate modern Python clients from OpenAPI"
2323
keywords = [
2424
"OpenAPI",

0 commit comments

Comments
 (0)