From 0a98c066a93eab6b7b8a5dd1e027585c65898f97 Mon Sep 17 00:00:00 2001 From: Derek Homeier Date: Wed, 26 Oct 2022 21:24:53 +0200 Subject: [PATCH 1/3] Add Yaml configs for release and autochangelog generator --- .github/release.yml | 21 ++++++++++++++++ .github/workflows/update-changelog.yaml | 33 +++++++++++++++++++++++++ 2 files changed, 54 insertions(+) create mode 100644 .github/release.yml create mode 100644 .github/workflows/update-changelog.yaml diff --git a/.github/release.yml b/.github/release.yml new file mode 100644 index 0000000..3fadb19 --- /dev/null +++ b/.github/release.yml @@ -0,0 +1,21 @@ +changelog: + exclude: + authors: + - pre-commit-ci + labels: + - no-changelog-entry-needed + - skip-changelog + + categories: + - title: New Features + labels: + - enhancement + - title: Bug Fixes + labels: + - bug + - title: Documentation + labels: + - documentation + - title: Other Changes + labels: + - "*" diff --git a/.github/workflows/update-changelog.yaml b/.github/workflows/update-changelog.yaml new file mode 100644 index 0000000..5e4e1c4 --- /dev/null +++ b/.github/workflows/update-changelog.yaml @@ -0,0 +1,33 @@ +# This workflow takes the GitHub release notes and updates the changelog on the +# main branch with the body of the release notes, thereby keeping a log in +# the git repo of the changes. + +name: "Update Changelog" + +on: + release: + types: [released] + +jobs: + update: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v2 + with: + ref: main + + - name: Update Changelog + uses: stefanzweifel/changelog-updater-action@v1 + with: + release-notes: ${{ github.event.release.body }} + latest-version: ${{ github.event.release.name }} + path-to-changelog: CHANGES.md + + - name: Commit updated Changelog + uses: stefanzweifel/git-auto-commit-action@v4 + with: + branch: main + commit_message: Update CHANGELOG + file_pattern: CHANGES.md From 4727b906beb3077bae2503e861a50555b726c4b5 Mon Sep 17 00:00:00 2001 From: Derek Homeier Date: Wed, 26 Oct 2022 21:25:21 +0200 Subject: [PATCH 2/3] DOC: new release process instructions [ci skip] --- RELEASE.rst | 33 ++++++++------------------------- 1 file changed, 8 insertions(+), 25 deletions(-) diff --git a/RELEASE.rst b/RELEASE.rst index 907e99a..8b58d69 100644 --- a/RELEASE.rst +++ b/RELEASE.rst @@ -1,28 +1,11 @@ -How to release a new version of glue-astronomy +How to release a new version of Glue-Astronomy ============================================== -#. Edit the ``CHANGES.rst`` file to add the release date for the release - you want to make and make sure the changelog is complete. +#. Follow the instructions in the `Glue documentation + `_ + to create a release using the `GitHub menu + `_. -#. Commit the changes using:: - - git commit -m "Preparing release v..." - - where v... is the version you are releasing and push to main:: - - git push upstream main - -#. Tag the release you want to make, optionally signing it (``-s``):: - - git tag -m v0.5.0 v0.5.0 - - and push the tag:: - - git push upstream v0.5.0 - -#. At this point, the release sdist and wheel will be built on by GitHub - Actions and automatically uploaded to PyPI. You can check the build - for the release commit `here `_ - and if there are any issues you can delete the tag, fix the issues - (preferably via a pull request) and then try the release process - again. +#. Have a beverage of your choosing while you can check the build progress + `here `_. + (The wheels may take a little while to build). From 2b6fdcf24abf1667ba0602d0bce827b80acd9612 Mon Sep 17 00:00:00 2001 From: Derek Homeier Date: Wed, 26 Oct 2022 21:37:38 +0200 Subject: [PATCH 3/3] DOC: reformat Changelog --- CHANGES.md | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++ CHANGES.rst | 57 --------------------------------------- MANIFEST.in | 2 +- 3 files changed, 79 insertions(+), 58 deletions(-) create mode 100644 CHANGES.md delete mode 100644 CHANGES.rst diff --git a/CHANGES.md b/CHANGES.md new file mode 100644 index 0000000..20a6afb --- /dev/null +++ b/CHANGES.md @@ -0,0 +1,78 @@ +# Full changelog + +## [0.5.1](https://github.com/glue-viz/glue-astronomy/compare/v0.5.0...v0.5.1) - 2022-09-26 + +### What's Changed + +#### New Features + +- Added basic support for importing and exporting a wider range of + ``SpectralCube`` classes. in https://github.com/glue-viz/glue-astronomy/pull/54 + +#### Bug Fixes + +- Fixed unit parsing for ``Specutils1DHandler.to_data`` so it no longer + drops the flux unit in some cases. in https://github.com/glue-viz/glue-astronomy/pull/78 + +## [0.5.0](https://github.com/glue-viz/glue-astronomy/compare/v0.4.0...v0.5.0) - 2022-08-18 + +### What's Changed + +#### New Features + +- Updated ``AstropyRegions`` translator to export ``roi.theta`` angle + (supported as of ``glue`` 1.5.0). in https://github.com/glue-viz/glue-astronomy/pull/73 + +- Added support to import and export ``specreduce`` ``Trace`` objects. in https://github.com/glue-viz/glue-astronomy/pull/72 + +## [0.4.0](https://github.com/glue-viz/glue-astronomy/compare/v0.3.3...v0.4.0) - 2022-04-07 + +### What's Changed + +#### New Features + +- Updated ``Spectrum1D`` translator to generate dummy WCS when needed for any + dimensionality, and to preserve specutils axis order when translating + to Glue ``Data``. in https://github.com/glue-viz/glue-astronomy/pull/68 + +## [0.3.3](https://github.com/glue-viz/glue-astronomy/compare/v0.3.2...v0.3.3) - 2022-03-22 + +#### Bug Fixes + +- Fixed translation to ``regions.EllipsePixelRegion``. Previous translation + was passing in radii as full height/width of the ellipse. in https://github.com/glue-viz/glue-astronomy/pull/67 + +- Fixed compatibility of CCDData translator with GWCS. in https://github.com/glue-viz/glue-astronomy/pull/58 + +## [0.3.2](https://github.com/glue-viz/glue-astronomy/compare/v0.3.1...v0.3.2) - 2021-09-14 + +#### Bug Fixes + +- Fixed round-tripping of metadata in Spectrum1D. in https://github.com/glue-viz/glue-astronomy/pull/48 + +## [0.3.1](https://github.com/glue-viz/glue-astronomy/compare/v0.3...v0.3.1) - 2021-09-09 + +#### Bug Fixes + +- Fixed coordinate conversion for 2D spectra. in https://github.com/glue-viz/glue-astronomy/pull/47 + +## [0.3](https://github.com/glue-viz/glue-astronomy/compare/v0.2...v0.3) - 2021-09-07 + +### What's Changed + +#### New Features + +- Improvements to the ``Spectrum1D`` to glue ``Data`` translator, in particular + for >1-d datasets. [#36, #40, #41, #44, #45] + +## [0.2](https://github.com/glue-viz/glue-astronomy/compare/v0.1...v0.2) - 2021-07-05 + +### What's Changed + +#### New Features + +- Add support for converting ``EllipticalROI`` to ``EllipsePixelRegion``. in https://github.com/glue-viz/glue-astronomy/pull/32 + +## [0.1](https://github.com/glue-viz/glue-astronomy/releases/tag/v0.1) - 2020-09-17 + +- Initial release diff --git a/CHANGES.rst b/CHANGES.rst deleted file mode 100644 index 120c9bc..0000000 --- a/CHANGES.rst +++ /dev/null @@ -1,57 +0,0 @@ -0.5.1 (2022-09-26) ------------------- - -- Fixed unit parsing for ``Specutils1DHandler.to_data`` so it no longer - drops the flux unit in some cases. [#78] - -- Added basic support for importing and exporting a wider range of - ``SpectralCube`` classes. [#54] - -0.5.0 (2022-08-18) ------------------- - -- Updated ``AstropyRegions`` translator to export ``roi.theta`` angle - (supported as of ``glue`` 1.5.0). [#73] - -- Added support to import and export ``specreduce`` ``Trace`` objects. [#72] - -0.4.0 (2022-04-07) ------------------- - -- Updated ``Spectrum1D`` translator to generate dummy WCS when needed for any - dimensionality, and to preserve specutils axis order when translating - to Glue ``Data``. [#68] - -0.3.3 (2022-03-22) ------------------- - -- Fixed translation to ``regions.EllipsePixelRegion``. Previous translation - was passing in radii as full height/width of the ellipse. [#67] - -- Fixed compatibility of CCDData translator with GWCS. [#58] - -0.3.2 (2021-09-14) ------------------- - -- Fixed round-tripping of metadata in Spectrum1D. [#48] - -0.3.1 (2021-09-09) ------------------- - -- Fixed coordinate conversion for 2D spectra. [#47] - -0.3 (2021-09-07) ----------------- - -- Improvements to the ``Spectrum1D`` to glue ``Data`` translator, in particular - for >1-d datasets. [#36, #40, #41, #44, #45] - -0.2 (2021-07-05) ----------------- - -- Add support for converting ``EllipticalROI`` to ``EllipsePixelRegion``. [#32] - -0.1 (2020-09-17) ----------------- - -- Initial release diff --git a/MANIFEST.in b/MANIFEST.in index 357e3a1..e91acb5 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,6 +1,6 @@ include LICENSE include README.rst -include CHANGES.rst +include CHANGES.md include setup.cfg include pyproject.toml