From 43d730d62c104a755510af25c6004add4e03ee5b Mon Sep 17 00:00:00 2001 From: Nicholas Felt Date: Wed, 18 Oct 2023 10:06:58 -0700 Subject: [PATCH 1/4] ci: Update the previous changelog to be able to be added to git in order for python-semantic-release to work properly. --- .../CHANGELOG.md.j2 | 2 +- .../previous_changelog_for_template.md | 163 ++++++++++++++++++ 2 files changed, 164 insertions(+), 1 deletion(-) create mode 100644 python_semantic_release_templates/previous_changelog_for_template.md diff --git a/python_semantic_release_templates/CHANGELOG.md.j2 b/python_semantic_release_templates/CHANGELOG.md.j2 index 5333d2f4..6833b534 100644 --- a/python_semantic_release_templates/CHANGELOG.md.j2 +++ b/python_semantic_release_templates/CHANGELOG.md.j2 @@ -19,5 +19,5 @@ {%- filter replace("## Unreleased", "## Unreleased\n\n______________________________________________________________________\n\n## " + latest_version_number + " (" + latest_version_date + ")" + merged_prs_text) %} - {%- include "temp_CHANGELOG_copy.md" %} + {%- include "previous_changelog_for_template.md" %} {% endfilter %} diff --git a/python_semantic_release_templates/previous_changelog_for_template.md b/python_semantic_release_templates/previous_changelog_for_template.md new file mode 100644 index 00000000..9837b307 --- /dev/null +++ b/python_semantic_release_templates/previous_changelog_for_template.md @@ -0,0 +1,163 @@ +# Changelog + +The format is based on [Keep a Changelog](https://keepachangelog.com), and this +project adheres to [Semantic Versioning](https://semver.org). + +Valid subsections within a version are: + +- Added +- Changed +- Deprecated +- Removed +- Fixed +- Security + +______________________________________________________________________ + +## Unreleased + +### Added + +- A command-line script to list all available VISA resources, `list-visa-resources` + +______________________________________________________________________ + +## v0.1.14 (2023-10-05) + +### Added + +- Added support for Python 3.12. + +______________________________________________________________________ + +## v0.1.13 (2023-09-21) + +### Fixed + +- Fixed bug when generating a waveform using Burst Mode on an AFG. + +______________________________________________________________________ + +## v0.1.12 (2023-09-06) + +### Added + +- Support for DPOJET to TekScope5k7k70k models. + +______________________________________________________________________ + +## v0.1.11 (2023-08-29) + +### Added + +- Cache `*OPT?` on first access. + +______________________________________________________________________ + +## v0.1.10 (2023-08-29) + +### Added + +- Support for AWG7KB + +______________________________________________________________________ + +## v0.1.9 (2023-08-24) + +### Added + +- Support for `num_dig_bits_in_ch` and `total_channels` properties to TekScope5k7k70k. + +______________________________________________________________________ + +## v0.1.8 (2023-08-09) + +### Added + +- Support for AWG5KB + +### Changed + +- Changed waveform generation to enforce CustomStrEnum function type. + +______________________________________________________________________ + +## v0.1.7 (2023-08-02) + +### Added + +- Support for connecting to instruments created on top of the `pyvisa-mock` framework. + +### Changed + +- Updated auto-generated API documentation to not show all inherited attributes and methods in order to speed up documentation build time. +- `SourceDeviceConstants.function_list` was changed to be `SourceDeviceConstants.functions`, which is now an Enumeration of valid functions. + +______________________________________________________________________ + +## v0.1.6 (2023-07-25) + +### Changed + +- Fixed bug with not allowing empty license lists. + +______________________________________________________________________ + +## v0.1.5 (2023-07-25) + +### Changed + +- Updated syntax for AFG polarities. + +______________________________________________________________________ + +## v0.1.4 (2023-07-21) + +### Added + +- `channel` property to TekScope +- Abstract mixin classes for licenses, analysis objects, and usb drives. +- @family_base_class to denote and enforce end of method definitions in the inheritance tree. + +### Changed + +- Refactored abstract method inheritance to use Mixins for many methods and properties for ease of expandability. +- Channel specific functions now only accept strings as input. + +### Removed + +- `all_channel_numbers_list` property since MSO2 breaks convention so can no longer rely on sequential channel numbering. + +______________________________________________________________________ + +## v0.1.3 (2023-07-03) + +### Changed + +- Removed TRIANGLE from AFG function list. +- Added symmetry to waveform generation function call. + +______________________________________________________________________ + +## v0.1.2 (2023-06-27) + +### Changed + +- Updated the add_new dynamic item methods to work with numbers higher than 9. +- Fixed malformed command syntax due to a bug in determining the preceding separator character. + +______________________________________________________________________ + +## v0.1.1 (2023-06-20) + +### Added + +- Added support for .dev versions. + +______________________________________________________________________ + +## v0.1.0 (2022-08-08) + +### Added + +- First release of `tm_devices`! From fba95d1808af603a56d6490a460f4c804c272248 Mon Sep 17 00:00:00 2001 From: Nicholas Felt Date: Wed, 18 Oct 2023 10:11:12 -0700 Subject: [PATCH 2/4] ci: Update workflow to copy file to correct location. --- .github/workflows/package-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/package-release.yml b/.github/workflows/package-release.yml index fe4ada74..cd3cfbc1 100644 --- a/.github/workflows/package-release.yml +++ b/.github/workflows/package-release.yml @@ -37,7 +37,7 @@ jobs: - name: Check for unreleased entries in the Changelog run: python scripts/check_unreleased_changelog_items.py - name: Copy Changelog to template directory - run: cp CHANGELOG.md python_semantic_release_templates/temp_CHANGELOG_copy.md + run: cp CHANGELOG.md python_semantic_release_templates/previous_changelog_for_template.md - name: Python Semantic Release id: release uses: python-semantic-release/python-semantic-release@v8.0.0 From 52bc247e561fededf2d6d46c3dcf9c0c67c1460b Mon Sep 17 00:00:00 2001 From: Nicholas Felt Date: Wed, 18 Oct 2023 10:11:43 -0700 Subject: [PATCH 3/4] ci: Remove git config modification that isn't used. --- .github/workflows/package-release.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/package-release.yml b/.github/workflows/package-release.yml index cd3cfbc1..1b33556c 100644 --- a/.github/workflows/package-release.yml +++ b/.github/workflows/package-release.yml @@ -27,8 +27,6 @@ jobs: - uses: actions/checkout@v3 with: fetch-depth: 0 - - name: Modify Git configuration - run: git config advice.addIgnoredFile false - name: Set up Python uses: actions/setup-python@v4 with: From 26dea9fe4d5a3ef55851b7cea295a585df8a97da Mon Sep 17 00:00:00 2001 From: Nicholas Felt Date: Wed, 18 Oct 2023 10:18:44 -0700 Subject: [PATCH 4/4] ci: Use a file that starts with a dot in order to not accidentally add a new file in the root directory of the repo when the changelog is updated. --- .github/workflows/package-release.yml | 2 +- ...elog_for_template.md => .previous_changelog_for_template.md} | 0 python_semantic_release_templates/CHANGELOG.md.j2 | 2 +- 3 files changed, 2 insertions(+), 2 deletions(-) rename python_semantic_release_templates/{previous_changelog_for_template.md => .previous_changelog_for_template.md} (100%) diff --git a/.github/workflows/package-release.yml b/.github/workflows/package-release.yml index 1b33556c..626bd129 100644 --- a/.github/workflows/package-release.yml +++ b/.github/workflows/package-release.yml @@ -35,7 +35,7 @@ jobs: - name: Check for unreleased entries in the Changelog run: python scripts/check_unreleased_changelog_items.py - name: Copy Changelog to template directory - run: cp CHANGELOG.md python_semantic_release_templates/previous_changelog_for_template.md + run: cp CHANGELOG.md python_semantic_release_templates/.previous_changelog_for_template.md - name: Python Semantic Release id: release uses: python-semantic-release/python-semantic-release@v8.0.0 diff --git a/python_semantic_release_templates/previous_changelog_for_template.md b/python_semantic_release_templates/.previous_changelog_for_template.md similarity index 100% rename from python_semantic_release_templates/previous_changelog_for_template.md rename to python_semantic_release_templates/.previous_changelog_for_template.md diff --git a/python_semantic_release_templates/CHANGELOG.md.j2 b/python_semantic_release_templates/CHANGELOG.md.j2 index 6833b534..d1097f1f 100644 --- a/python_semantic_release_templates/CHANGELOG.md.j2 +++ b/python_semantic_release_templates/CHANGELOG.md.j2 @@ -19,5 +19,5 @@ {%- filter replace("## Unreleased", "## Unreleased\n\n______________________________________________________________________\n\n## " + latest_version_number + " (" + latest_version_date + ")" + merged_prs_text) %} - {%- include "previous_changelog_for_template.md" %} + {%- include ".previous_changelog_for_template.md" %} {% endfilter %}