diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml index 7718b5be7..93e0957a4 100644 --- a/.github/workflows/cicd.yml +++ b/.github/workflows/cicd.yml @@ -148,14 +148,14 @@ jobs: - name: Release | Python Semantic Release id: release - uses: python-semantic-release/python-semantic-release@9293da56b24a9bd1a97acd4e9b1aabda4ef89fd6 # v10.3.2 + uses: python-semantic-release/python-semantic-release@6df5e876c8682fe0753ec2f8c81eb45547e52747 # v10.4.0 with: github_token: ${{ secrets.GITHUB_TOKEN }} verbosity: 1 build: false - name: Release | Add distribution artifacts to GitHub Release Assets - uses: python-semantic-release/publish-action@63a952936fa65b0942a64427d3636fa691d676ce # v10.3.2 + uses: python-semantic-release/publish-action@4681bbe581b99f950d7b6f14599870b6a117fdc1 # v10.4.0 if: steps.release.outputs.released == 'true' with: github_token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/manual.yml b/.github/workflows/manual.yml index e1f292d66..509e66b87 100644 --- a/.github/workflows/manual.yml +++ b/.github/workflows/manual.yml @@ -60,7 +60,7 @@ jobs: steps: - name: Setup | Install Python ${{ env.COMMON_PYTHON_VERSION }} - uses: actions/setup-python@v5 + uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 with: python-version: ${{ env.COMMON_PYTHON_VERSION }} diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 17678d579..d991c59e3 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -28,7 +28,7 @@ jobs: steps: - name: Stale Issues/PRs - uses: actions/stale@v9 + uses: actions/stale@3a9db7e6a41a89f618792c92c0e97cc736e1b13f # v10.0.0 with: # default: 30, GitHub Actions API Rate limit is 1000/hr operations-per-run: ${{ env.OPERATIONS_RATE_LIMIT }} @@ -67,7 +67,7 @@ jobs: # that point the submitter has 14 days before a reminder/warning is given. If # no response has been received within 3 weeks, the issue is closed. There are # no exemptions besides removing the awaiting-reply label. - uses: actions/stale@v9 + uses: actions/stale@3a9db7e6a41a89f618792c92c0e97cc736e1b13f # v10.0.0 with: # GitHub Actions API Rate limit is 1000/hr operations-per-run: ${{ env.OPERATIONS_RATE_LIMIT }} @@ -97,7 +97,7 @@ jobs: # forgotten completely, this job will post a reminder message to the maintainers # No closures will occur and there are no exemptions besides removing the confirmed # label. - uses: actions/stale@v9 + uses: actions/stale@3a9db7e6a41a89f618792c92c0e97cc736e1b13f # v10.0.0 with: # GitHub Actions API Rate limit is 1000/hr operations-per-run: ${{ env.OPERATIONS_RATE_LIMIT }} diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index eac75bb64..44289f651 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -100,7 +100,7 @@ jobs: git checkout -B ${{ github.ref_name }} - name: Setup | Install Python ${{ env.COMMON_PYTHON_VERSION }} - uses: actions/setup-python@v5 + uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 with: python-version: ${{ env.COMMON_PYTHON_VERSION }} cache: 'pip' @@ -112,7 +112,7 @@ jobs: - name: Build | Build next version artifacts id: version - uses: python-semantic-release/python-semantic-release@9293da56b24a9bd1a97acd4e9b1aabda4ef89fd6 # v10.3.2 + uses: python-semantic-release/python-semantic-release@6df5e876c8682fe0753ec2f8c81eb45547e52747 # v10.4.0 with: github_token: "" verbosity: 1 @@ -167,7 +167,7 @@ jobs: fetch-depth: 1 - name: Setup | Install Python ${{ env.LOWEST_PYTHON_VERSION }} - uses: actions/setup-python@v5 + uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 with: python-version: ${{ env.LOWEST_PYTHON_VERSION }} cache: 'pip' @@ -223,7 +223,7 @@ jobs: fetch-depth: 1 - name: Setup | Install Python ${{ matrix.python-version }} - uses: actions/setup-python@v5 + uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 with: python-version: ${{ matrix.python-version }} cache: 'pip' @@ -312,7 +312,7 @@ jobs: fetch-depth: 1 - name: Setup | Install Python ${{ matrix.python-version }} - uses: actions/setup-python@v5 + uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 with: python-version: ${{ matrix.python-version }} cache: 'pip' @@ -453,7 +453,7 @@ jobs: fetch-depth: 1 - name: Setup | Install Python ${{ env.COMMON_PYTHON_VERSION }} - uses: actions/setup-python@v5 + uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0 with: python-version: ${{ env.COMMON_PYTHON_VERSION }} cache: 'pip' diff --git a/.github/workflows/verify_upstream.sh b/.github/workflows/verify_upstream.sh index 3e8a38ac2..8444eba57 100644 --- a/.github/workflows/verify_upstream.sh +++ b/.github/workflows/verify_upstream.sh @@ -5,7 +5,7 @@ set -eu +o pipefail # Example output of `git status -sb`: # ## master...origin/master [behind 1] # M .github/workflows/verify_upstream.sh -UPSTREAM_BRANCH_NAME="$(git status -sb | head -n 1 | cut -d' ' -f2 | grep -E '\.{3}' | cut -d'.' -f4)" +UPSTREAM_BRANCH_NAME="$(git status -sb | head -n 1 | awk -F '\\.\\.\\.' '{print $2}' | cut -d ' ' -f1)" printf '%s\n' "Upstream branch name: $UPSTREAM_BRANCH_NAME" set -o pipefail diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 6e1a00f45..458f1a5ee 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,40 @@ CHANGELOG ========= +.. _changelog-v10.4.1: + +v10.4.1 (2025-09-13) +==================== + +🪲 Bug Fixes +------------ + +* **cmd-version**: Fix error where ``--no-tag`` is not respected, closes `#1304`_ (`PR#1329`_, + `b090fa2`_) + +📖 Documentation +---------------- + +* **CHANGELOG**: Update hyperlink in v10.4.0's additional info paragraph (`PR#1323`_, `98ef722`_) + +* **getting-started-guide**: Remove notice about lack of monorepo support, closes `#1326`_ + (`PR#1327`_, `3f21f3f`_) + +* **github-actions**: Fix recommended upstream detection script's upstream name parsing (`PR#1328`_, + `ccc91c0`_) + +.. _#1304: https://github.com/python-semantic-release/python-semantic-release/issues/1304 +.. _#1326: https://github.com/python-semantic-release/python-semantic-release/issues/1326 +.. _3f21f3f: https://github.com/python-semantic-release/python-semantic-release/commit/3f21f3fc47a0dacc11ec95feb2a23f8cf132e77b +.. _98ef722: https://github.com/python-semantic-release/python-semantic-release/commit/98ef722b65bd6a37492cf7ec8b0425800f719114 +.. _b090fa2: https://github.com/python-semantic-release/python-semantic-release/commit/b090fa2efc0ebfb40bdc572fea307d356af95a3f +.. _ccc91c0: https://github.com/python-semantic-release/python-semantic-release/commit/ccc91c09fab45358c7e52b42e6c0607c68c9d8f3 +.. _PR#1323: https://github.com/python-semantic-release/python-semantic-release/pull/1323 +.. _PR#1327: https://github.com/python-semantic-release/python-semantic-release/pull/1327 +.. _PR#1328: https://github.com/python-semantic-release/python-semantic-release/pull/1328 +.. _PR#1329: https://github.com/python-semantic-release/python-semantic-release/pull/1329 + + .. _changelog-v10.4.0: v10.4.0 (2025-09-08) @@ -34,11 +68,11 @@ v10.4.0 (2025-09-08) * **config**: This release introduces a new built-in parser type that can be utilized for monorepo projects. The type value is ``conventional-monorepo`` and when specified it will apply the conventional commit parser to a monorepo environment. This parser has specialized options to help - handle monorepo projects as well. For more information, please refer to the [Monorepo - Docs](https://python-semantic-release.readthedocs.io/en/stable). + handle monorepo projects as well. For more information, please refer to the `Monorepo Docs`_. .. _#614: https://github.com/python-semantic-release/python-semantic-release/issues/614 .. _e18f866: https://github.com/python-semantic-release/python-semantic-release/commit/e18f86640a78b374a327848b9e2ba868003d1a43 +.. _Monorepo Docs: /configuration/configuration-guides/monorepos.html .. _PR#1143: https://github.com/python-semantic-release/python-semantic-release/pull/1143 diff --git a/docs/concepts/getting_started.rst b/docs/concepts/getting_started.rst index d34062457..81e5842ad 100644 --- a/docs/concepts/getting_started.rst +++ b/docs/concepts/getting_started.rst @@ -175,13 +175,6 @@ behavior, you will need to specify the parser options you want to override. parse_squash_commits = true ignore_merge_commits = true -.. important:: - Python Semantic Release does not currently support Monorepo projects. You will need to provide - a custom commit parser that is built for Monorepos. Follow the Monorepo-support progress in - `Issue #168 `_, - `Issue #614 `_, - and `PR #1143 `_. - Choosing your Changelog ''''''''''''''''''''''' diff --git a/docs/configuration/automatic-releases/github-actions.rst b/docs/configuration/automatic-releases/github-actions.rst index 57cd7b507..be8a8b480 100644 --- a/docs/configuration/automatic-releases/github-actions.rst +++ b/docs/configuration/automatic-releases/github-actions.rst @@ -903,7 +903,7 @@ to the GitHub Release Assets as well. run: | set +o pipefail - UPSTREAM_BRANCH_NAME="$(git status -sb | head -n 1 | cut -d' ' -f2 | grep -E '\.{3}' | cut -d'.' -f4)" + UPSTREAM_BRANCH_NAME="$(git status -sb | head -n 1 | awk -F '\\.\\.\\.' '{print $2}' | cut -d ' ' -f1)" printf '%s\n' "Upstream branch name: $UPSTREAM_BRANCH_NAME" set -o pipefail @@ -933,14 +933,14 @@ to the GitHub Release Assets as well. - name: Action | Semantic Version Release id: release # Adjust tag with desired version if applicable. - uses: python-semantic-release/python-semantic-release@v10.4.0 + uses: python-semantic-release/python-semantic-release@v10.4.1 with: github_token: ${{ secrets.GITHUB_TOKEN }} git_committer_name: "github-actions" git_committer_email: "actions@users.noreply.github.com" - name: Publish | Upload to GitHub Release Assets - uses: python-semantic-release/publish-action@v10.4.0 + uses: python-semantic-release/publish-action@v10.4.1 if: steps.release.outputs.released == 'true' with: github_token: ${{ secrets.GITHUB_TOKEN }} @@ -1039,7 +1039,7 @@ The equivalent GitHub Action configuration would be: - name: Action | Semantic Version Release # Adjust tag with desired version if applicable. - uses: python-semantic-release/python-semantic-release@v10.4.0 + uses: python-semantic-release/python-semantic-release@v10.4.1 with: github_token: ${{ secrets.GITHUB_TOKEN }} force: patch @@ -1098,14 +1098,14 @@ Publish Action. - name: Release submodule 1 id: release-submod-1 - uses: python-semantic-release/python-semantic-release@v10.4.0 + uses: python-semantic-release/python-semantic-release@v10.4.1 with: directory: ${{ env.SUBMODULE_1_DIR }} github_token: ${{ secrets.GITHUB_TOKEN }} - name: Release submodule 2 id: release-submod-2 - uses: python-semantic-release/python-semantic-release@v10.4.0 + uses: python-semantic-release/python-semantic-release@v10.4.1 with: directory: ${{ env.SUBMODULE_2_DIR }} github_token: ${{ secrets.GITHUB_TOKEN }} @@ -1117,7 +1117,7 @@ Publish Action. # ------------------------------------------------------------------- # - name: Publish | Upload package 1 to GitHub Release Assets - uses: python-semantic-release/publish-action@v10.4.0 + uses: python-semantic-release/publish-action@v10.4.1 if: steps.release-submod-1.outputs.released == 'true' with: directory: ${{ env.SUBMODULE_1_DIR }} @@ -1125,7 +1125,7 @@ Publish Action. tag: ${{ steps.release-submod-1.outputs.tag }} - name: Publish | Upload package 2 to GitHub Release Assets - uses: python-semantic-release/publish-action@v10.4.0 + uses: python-semantic-release/publish-action@v10.4.1 if: steps.release-submod-2.outputs.released == 'true' with: directory: ${{ env.SUBMODULE_2_DIR }} diff --git a/pyproject.toml b/pyproject.toml index 22640474d..dd3ef56d9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -6,7 +6,7 @@ build-backend = "setuptools.build_meta" [project] name = "python-semantic-release" -version = "10.4.0" +version = "10.4.1" description = "Automatic Semantic Versioning for Python projects" requires-python = "~= 3.8" license = { text = "MIT" } diff --git a/src/gh_action/requirements.txt b/src/gh_action/requirements.txt index e35c59aae..c624d98e8 100644 --- a/src/gh_action/requirements.txt +++ b/src/gh_action/requirements.txt @@ -1 +1 @@ -python-semantic-release == 10.4.0 +python-semantic-release == 10.4.1 diff --git a/src/semantic_release/cli/commands/version.py b/src/semantic_release/cli/commands/version.py index 27b86be79..717f55278 100644 --- a/src/semantic_release/cli/commands/version.py +++ b/src/semantic_release/cli/commands/version.py @@ -710,7 +710,7 @@ def version( # noqa: C901 # are disabled, and the changelog generation is disabled or it's not # modified, then the HEAD commit will be tagged as a release commit # despite not being made by PSR - if commit_changes or create_tag: + if create_tag: project.git_tag( tag_name=new_version.as_tag(), message=new_version.as_tag(),