Skip to content

Append release notes to changelog instead of overwrite #858

Closed

Description

@Rebekah-Chuang

Hello!

I'm wondering if there's a way to simply append the latest release notes to the changelog instead of overwriting the entire changelog. I'm asking because, at the beginning of the project, I didn't follow the correct commit message format, resulting in most of them being unrecognized. My solution was to manually update the changelog for those incorrect commit messages. I thought it would update the changelog based on the previous version, but it instead overwrites the entire changelog, causing the unknown section to reappear. If this is not currently possible, I believe it could be a beneficial feature, as it would make the changelog neater (I've noticed that the changelog for this repo also includes an unknown section in earlier versions).

Thank you in advance!

Activity

  1. codejedi365 commented on Mar 13, 2024

    @codejedi365
    Contributor

    @Rebekah-Chuang, unfortunately there is not a current method for only prepending the latest release information. I do believe there was a previous ticket that mentioned this but it seems nothing specifically came of it. I agree it would be a useful feature to provide methods of adoption of this project to an existing project.

  2. Rebekah-Chuang commented on Mar 22, 2024

    @Rebekah-Chuang
    Author

    Hi @codejedi365, sorry for the late response, thank you so much for replying, I think the ticket you mentioned was #722. Hope to see this feature in the future!

  3. codejedi365 commented on Mar 23, 2024

    @codejedi365
    Contributor

    @Rebekah-Chuang, given the complexities discussed in #722, I'm not sure if or when this feature would actually be solved, but there may be an alternative.

    You could use the changelog template directory to write a custom template which does not loop through all of the versions as the provided default does. Jinja2 also provides the ability to import other files and macros. Potentially, you could correct your changelog for the previous versions and store that as a file such as 3.x_CHANGELOG.md. Then in your custom changelog template abort the loop when the version matches 3.x and just import the other file and append it. Unfortunately, Jinja does not support "break" so you likely will need to write a macro to filter out all versions below your threshold (ex. 4.x). This is a bit exploratory as I have not done this myself but thinking about it now I believe it accomplishes what you need.

  4. added this to the Better Changelogs milestone on Apr 12, 2024
  5. added
    confirmed
    on May 6, 2024
  6. added
    feature
    and removed on May 13, 2024
  7. github-actions commented on Jul 13, 2024

    @github-actions

    It has been 60 days since the last update on this confirmed issue. @python-semantic-release/team can you provide an update on the status of this issue?

  8. added
    needs-update
    on Jul 13, 2024
  9. codejedi365 commented on Jul 13, 2024

    @codejedi365
    Contributor

    Still in the backlog however as I'm reviewing the changelog architecture and the performance of PSR, I am finding this issue to be one of more importance and I might of devised a way to make this a reality. Hopefully over the next few months I can implement a solution.

  10. removed
    needs-update
    on Jul 14, 2024
  11. added a commit that references this issue on Aug 31, 2024
    c670a18
  12. codejedi365 commented on Sep 1, 2024

    @codejedi365
    Contributor

    I have found a solution that works for re-introducing the placeholder version update for changelogs using jinja. It will be released as a default changelog variation (toggled by a config option, changelog.mode) soon in v9. If you have a custom template configuration, you will need to modify your templates for the newly provided context variables for use.

    My plan is to convert the placeholder functionality back to the default in v10. Stay tuned.

  13. added a commit that references this issue on Sep 8, 2024
    f2f1690
  14. added 6 commits that reference this issue on Sep 23, 2024
    b474fd4
    ad8cd79
    58215bc
    0cb7eb2
    9277cd9
    f80f1b5
  15. added a commit that references this issue on Oct 7, 2024
    c18c245
  16. codejedi365 commented on Oct 7, 2024

    @codejedi365
    Contributor

    🎉 This issue has been resolved in version 9.10.0 🎉

    The release is available on:


    Check out the Changelog Templates in the documentation to learn about the "update" mode.

  17. removed
    confirmed
    on Aug 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions