diff --git a/CHANGELOG.md b/CHANGELOG.md index dfc56cd..e40e855 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,32 +2,64 @@ All notable changes to this project will be documented in this file. -## [0.1.1] - 2023-06-22 +## [unreleased] + +### Features + +- Skip selected hosts with new `_meta` option - ([e7bdc9b](https://github.com/pythoninja/sshgen/commit/e7bdc9b4d42d181a72fd9ee97d2e98f16166f3cf)) ### Bug Fixes -- Properly include aliases ([PR #3](https://github.com/pythoninja/sshgen/pull/3)) ([3795443](https://github.com/pythoninja/sshgen/commit/37954430364805292f6f3dbe4a4bcd7e31193676)) +- Change compatible type - ([67f9099](https://github.com/pythoninja/sshgen/commit/67f9099dacd55c8f94ec4c946b419b072159744e)) + +### Refactor + +- Dynamic format fallback auth - ([763b357](https://github.com/pythoninja/sshgen/commit/763b3570044b231567a69fd5645b4d6e0b3984a8)) -### Continuous Integration +### Development -- Add linter and release workflows ([PR #8](https://github.com/pythoninja/sshgen/pull/8)) ([ef77472](https://github.com/pythoninja/sshgen/commit/ef774722d63d528aaa1e679ee857eac7f3ffc9a8)) -- Add dependabot ([PR #9](https://github.com/pythoninja/sshgen/pull/9)) ([a006907](https://github.com/pythoninja/sshgen/commit/a006907e4109748e1000b50086487a0a570fd3d2)) +- *(dev)* Change type of quotes (experimentally) - ([9b9f75d](https://github.com/pythoninja/sshgen/commit/9b9f75dd2881fbcd0776277a2271558eaf2b3e1d)) +- *(dev)* Remove isort rule - ([8815fb9](https://github.com/pythoninja/sshgen/commit/8815fb999bc11e58300181c8cfe47bfa93c09263)) +- *(dev)* Add ruff rules - ([a36d07f](https://github.com/pythoninja/sshgen/commit/a36d07ff647249679c6ae495e0bae9874d0ea634)) +- *(dev)* Add pre-commit - ([e338bf3](https://github.com/pythoninja/sshgen/commit/e338bf3dc08479021270ab85b2d612e9d7f78d58)) +- *(dev)* Bump Python to 3.12 in pyproject.toml - ([9670e35](https://github.com/pythoninja/sshgen/commit/9670e3598fbb76d87362e277e20afa8b5a9f1547)) +- *(dev)* Regenerate poetry.lock - ([d4180f0](https://github.com/pythoninja/sshgen/commit/d4180f052b82fef546b7f2c9aff7479aaf5cb622)) ### Miscellaneous Tasks -- *(deps-dev)* Bump ruff from 0.0.272 to 0.0.274 ([PR #1](https://github.com/pythoninja/sshgen/pull/1)) ([fa35a10](https://github.com/pythoninja/sshgen/commit/fa35a10cb6aea6df3d947b59560a1d180eb65c03)) -- *(dev)* Exclude files from example dir ([ee481ab](https://github.com/pythoninja/sshgen/commit/ee481aba26a796c649cd49800eaee2bba2fa5a45)) -- *(dev)* Bump versions in readme ([PR #5](https://github.com/pythoninja/sshgen/pull/5)) ([560f0b6](https://github.com/pythoninja/sshgen/commit/560f0b6e742fdee60d88baebdc7b402a1624a482)) -- *(dev)* Add changelog generator ([PR #7](https://github.com/pythoninja/sshgen/pull/7)) ([1618a78](https://github.com/pythoninja/sshgen/commit/1618a78b11d72b7ef60b0397bebd2f5fe72916b1)) -- *(dev)* Fix ruff version ([955af2c](https://github.com/pythoninja/sshgen/commit/955af2ca2aa8ccdf0970ee8584144d4c228c6053)) -- *(dev)* Add link to changelog for pypi ([8ad9abb](https://github.com/pythoninja/sshgen/commit/8ad9abb87493e14d5651b099b6b721642eb65c79)) -- *(dev)* Run changelog generator on version bump ([c9abbec](https://github.com/pythoninja/sshgen/commit/c9abbec5d43ab24e5bba5829d627f7ef1bd1bf22)) -- *(dev)* Improve search for version string in readme ([a7344fb](https://github.com/pythoninja/sshgen/commit/a7344fb631bfc3ef62c5694513c0506855d104ba)) +- Bump Poetry to 1.6.1 and Python to 3.12 - ([09ac311](https://github.com/pythoninja/sshgen/commit/09ac31117dd580dc8ff2c70a130399f004a76fb6)) +- Lint on toml and lock changes ([#15](https://github.com/pythoninja/sshgen/issues/15)) - ([7005a88](https://github.com/pythoninja/sshgen/commit/7005a8880a3b856a688187bd1e3b277f59271bdc)) -## [0.1.0] - 2023-06-21 +### Documentation + +- *(readme)* Update install instructions - ([5abddbc](https://github.com/pythoninja/sshgen/commit/5abddbc37eedeb5d17c89afbd73ed9ebd5a5634a)) +- Add toc to readme - ([90636a6](https://github.com/pythoninja/sshgen/commit/90636a697a605cf357a818ec282a3f6da38d224d)) + +## [0.1.1](https://github.com/pythoninja/sshgen/compare/v0.1.0..v0.1.1) - 2023-06-22 + +### Bug Fixes + +- Properly include aliases ([#3](https://github.com/pythoninja/sshgen/issues/3)) - ([3795443](https://github.com/pythoninja/sshgen/commit/37954430364805292f6f3dbe4a4bcd7e31193676)) + +### Development + +- *(dev)* Improve search for version string in readme - ([a7344fb](https://github.com/pythoninja/sshgen/commit/a7344fb631bfc3ef62c5694513c0506855d104ba)) +- *(dev)* Run changelog generator on version bump - ([c9abbec](https://github.com/pythoninja/sshgen/commit/c9abbec5d43ab24e5bba5829d627f7ef1bd1bf22)) +- *(dev)* Add link to changelog for pypi - ([8ad9abb](https://github.com/pythoninja/sshgen/commit/8ad9abb87493e14d5651b099b6b721642eb65c79)) +- *(dev)* Fix ruff version - ([955af2c](https://github.com/pythoninja/sshgen/commit/955af2ca2aa8ccdf0970ee8584144d4c228c6053)) +- *(dev)* Add changelog generator ([#7](https://github.com/pythoninja/sshgen/issues/7)) - ([1618a78](https://github.com/pythoninja/sshgen/commit/1618a78b11d72b7ef60b0397bebd2f5fe72916b1)) +- *(dev)* Bump versions in readme ([#5](https://github.com/pythoninja/sshgen/issues/5)) - ([560f0b6](https://github.com/pythoninja/sshgen/commit/560f0b6e742fdee60d88baebdc7b402a1624a482)) +- *(dev)* Exclude files from example dir - ([ee481ab](https://github.com/pythoninja/sshgen/commit/ee481aba26a796c649cd49800eaee2bba2fa5a45)) ### Miscellaneous Tasks -- *(dev)* Fix project name ([858aced](https://github.com/pythoninja/sshgen/commit/858aced9365754803b3b20162417102ad0378853)) +- Add dependabot ([#9](https://github.com/pythoninja/sshgen/issues/9)) - ([a006907](https://github.com/pythoninja/sshgen/commit/a006907e4109748e1000b50086487a0a570fd3d2)) +- Add linter and release workflows ([#8](https://github.com/pythoninja/sshgen/issues/8)) - ([ef77472](https://github.com/pythoninja/sshgen/commit/ef774722d63d528aaa1e679ee857eac7f3ffc9a8)) + +## [0.1.0] - 2023-06-21 + +### Development + +- *(dev)* Fix project name - ([858aced](https://github.com/pythoninja/sshgen/commit/858aced9365754803b3b20162417102ad0378853)) diff --git a/cliff.toml b/cliff.toml index 12f98c5..61b85ab 100644 --- a/cliff.toml +++ b/cliff.toml @@ -5,30 +5,35 @@ All notable changes to this project will be documented in this file.\n """ # template for the changelog body -# https://tera.netlify.app/docs +# https://keats.github.io/tera/docs/#introduction body = """ -{% set_global repo = "https://github.com/pythoninja/sshgen" -%} {% if version %}\ - ## [{{ version | trim_start_matches(pat="v") }}] - {{ timestamp | date(format="%Y-%m-%d") }} + {% if previous.version %}\ + ## [{{ version | trim_start_matches(pat="v") }}](/compare/{{ previous.version }}..{{ version }}) - {{ timestamp | date(format="%Y-%m-%d") }} + {% else %}\ + ## [{{ version | trim_start_matches(pat="v") }}] - {{ timestamp | date(format="%Y-%m-%d") }} + {% endif %}\ {% else %}\ ## [unreleased] {% endif %}\ + +{% macro commit(commit) -%} + - {% if commit.scope %}*({{ commit.scope }})* {% endif %}{% if commit.breaking %}[**breaking**] {% endif %}\ + {{ commit.message | upper_first }} - ([{{ commit.id | truncate(length=7, end="") }}](/commit/{{ commit.id }}))\ +{% endmacro -%} + {% for group, commits in commits | group_by(attribute="group") %} ### {{ group | striptags | trim | upper_first }} - {% for commit in commits | filter(attribute="scope") | sort(attribute="scope") %} - - *({{commit.scope}})*{% if commit.breaking %} [**breaking**]{% endif %} \ - {{ commit.message | upper_first }} ([{{ commit.id | truncate(length=7, end="") }}]({{ repo}}/commit/{{ commit.id }})) + {% for commit in commits + | filter(attribute="scope") + | sort(attribute="scope") %} + {{ self::commit(commit=commit) }} {%- endfor -%} {% raw %}\n{% endraw %}\ {%- for commit in commits %} - {%- if commit.scope -%} - {% else -%} - - {% if commit.breaking %} [**breaking**]{% endif %} \ - {{ commit.message | upper_first }} ([{{ commit.id | truncate(length=7, end="") }}]({{ repo}}/commit/{{ commit.id }})) + {%- if not commit.scope -%} + {{ self::commit(commit=commit) }} {% endif -%} - {% for link in commit.links -%} - , {{ link.text }}({{ link.href }})\ - {% endfor -%} {% endfor -%} {% endfor %}\n """ @@ -40,6 +45,10 @@ footer = """ """ +postprocessors = [ + { pattern = '', replace = "https://github.com/pythoninja/sshgen" }, # replace repository URL +] + [git] # parse the commits based on https://www.conventionalcommits.org conventional_commits = true @@ -49,42 +58,37 @@ filter_unconventional = true split_commits = false # regex for preprocessing the commit messages commit_preprocessors = [ - { pattern = '(.*)\(#([0-9]).*', replace = '${1}([PR #${2}](https://github.com/pythoninja/sshgen/pull/${2}))' } + { pattern = '\((\w+\s)?#([0-9]+)\)', replace = "([#${2}](/issues/${2}))" }, ] # regex for parsing and grouping commits commit_parsers = [ - { message = "^feat", group = "Features" }, - { message = "^fix", group = "Bug Fixes" }, - { message = "^doc", group = "Documentation" }, - { message = "^perf", group = "Performance" }, - { message = "^refactor", group = "Refactor" }, - { message = "^style", group = "Styling" }, - { message = "^test", group = "Testing" }, + { message = "^feat", group = " Features" }, + { message = "^fix", group = " Bug Fixes" }, + { message = "^refactor", group = " Refactor" }, + { message = "^test", group = " Testing" }, + { message = "^chore\\(dev\\):", group = " Development" }, + { message = "^chore\\(deps|deps-dev\\):", skip = true }, + { message = "^perf", group = "Performance", skip = true }, + { message = "^style", group = "Styling", skip = true }, { message = "^chore\\(release\\): v", skip = true }, - { message = "^chore", group = "Miscellaneous Tasks" }, - { message = "^ci", group = "Continuous Integration" }, - { body = ".*security", group = "Security" }, + { message = "^chore|ci", group = " Miscellaneous Tasks" }, + { message = "^doc", group = " Documentation" }, + { body = ".*security", group = "Security" }, ] # protect breaking changes from being skipped due to matching a skipping commit_parser protect_breaking_commits = false # filter out the commits that are not matched by commit parsers -filter_commits = false +filter_commits = true # glob pattern for matching git tags tag_pattern = "v[0-9]*" # regex for skipping tags -skip_tags = "v0.1.0-beta.1" +skip_tags = "beta|alpha" # regex for ignoring tags -ignore_tags = "" +ignore_tags = "rc" # sort the tags topologically topo_order = false # sort the commits inside sections by oldest/newest order -sort_commits = "oldest" +sort_commits = "newest" # limit the number of commits included in the changelog. # limit_commits = 42 - -link_parsers = [ - { pattern = "[fF]ixes #(\\d+)", text = "fixes [#${1}]", href = "https://github.com/pythoninja/sshgen/issues/$1" }, - { pattern = "[cC]loses #(\\d+)", text = "closes [#${1}]", href = "https://github.com/pythoninja/sshgen/issues/$1" }, - { pattern = "[sS]ee #(\\d+)", text = "see [#${1}]", href = "https://github.com/pythoninja/sshgen/issues/$1" }, -]