diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 572262c..af4d85a 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -48,6 +48,7 @@ jobs: - name: generate changelog run: | uv run towncrier build --version=steps.package-version.outputs.version --yes + git commit -a -m "create changelog for version ${{ steps.package-version.outputs.version }}" # Create Release if they differ - name: Create Draft GitHub Release @@ -56,3 +57,4 @@ jobs: body_path: ".github/release_template.md" draft: true tag_name: v${{ steps.package-version.outputs.version }} + files: ../../changelog.md diff --git a/README.md b/README.md index 92796b9..aa95387 100644 --- a/README.md +++ b/README.md @@ -283,7 +283,7 @@ branch. Please create the pr as a draft first because this will save computing t ### versioning -We manually update versions. the version number is store in `pyproject.toml`. It can either be updated manually or through +We manually update versions. The version number is stored in `pyproject.toml`. It can either be updated manually or through ``` uv version --bump [major|minor|patch] @@ -291,4 +291,4 @@ uv version --bump [major|minor|patch] We only update the major version when a major new or breaking functionality is added or a major or breaking data format change is introduced. Minor version are updated for new input data versions and smaller functionality changes. The patch version is update for data corrections, bugfixes etc. -Once a pr with a new version number is merged a release is created automatically. +Once a pr with a new version number is merged a draft release is created automatically. After filling a short description and the most important changes the release can be published. diff --git a/changelog/1.docs.md b/changelog/1.docs.md deleted file mode 100644 index 5aafa26..0000000 --- a/changelog/1.docs.md +++ /dev/null @@ -1 +0,0 @@ -Improved docs for contributors diff --git a/changelog/1.fix.md b/changelog/1.fix.md deleted file mode 100644 index df1469b..0000000 --- a/changelog/1.fix.md +++ /dev/null @@ -1 +0,0 @@ -Fixed typo for liccheck in CI diff --git a/changelog/1.improvement.md b/changelog/1.improvement.md deleted file mode 100644 index 28a64af..0000000 --- a/changelog/1.improvement.md +++ /dev/null @@ -1,2 +0,0 @@ -* Test CI setup -* Add auto release github workflow diff --git a/changelog/3.fix.md b/changelog/3.fix.md deleted file mode 100644 index c756fab..0000000 --- a/changelog/3.fix.md +++ /dev/null @@ -1 +0,0 @@ -Fix github release workflow diff --git a/changelog/7.docs.md b/changelog/7.docs.md new file mode 100644 index 0000000..c796d4d --- /dev/null +++ b/changelog/7.docs.md @@ -0,0 +1 @@ +Updated README to reflect the release process. diff --git a/changelog/7.fix.md b/changelog/7.fix.md new file mode 100644 index 0000000..f1df315 --- /dev/null +++ b/changelog/7.fix.md @@ -0,0 +1 @@ +Improved release workflow to automatically delete old news files and save the current version of the changelog with the release. diff --git a/pyproject.toml b/pyproject.toml index fb9e0f0..aab3e61 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "cdiac_ff_data" -version = "0.1.1" +version = "0.1.2" description = "Download CDIAC fossil fuel related CO2 emissions data and convert to primap2 format" readme = "README.md" #license = "CC BY-NC-SA" diff --git a/uv.lock b/uv.lock index 7ec7585..8f8a073 100644 --- a/uv.lock +++ b/uv.lock @@ -4,7 +4,7 @@ requires-python = ">=3.12" [[package]] name = "cdiac-ff-data" -version = "0.1.1" +version = "0.1.2" source = { virtual = "." } [package.dev-dependencies]