diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 81ad2c5b..7753d413 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,30 +1,11 @@ - +Please go the the `Preview` tab and select the appropriate sub-template: -## Description - +[**Contributor PR**](?expand=1&template=PR_Template_Contributor.md) -## Motivation and Context - - - +[Version Upgrade **(for Admins)**](?expand=1&template=PR_Template_VersionUpgrade.md) -## How has this been tested? - - - - -## Snippets or Screenshots (if necessary): - -## Types of changes - -- [ ] Bug fix (non-breaking change which fixes an issue) -- [ ] New feature (non-breaking change which adds functionality) -- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - -## Checklist: - - -- [ ] My code follows the code style of this IG / specification. -- [ ] My change requires a change to the documentation or narrative (intend) of the IG. -- [ ] I have already updated the documentation / narrative (intend) accordingly. \ No newline at end of file + + +## Pull Request Short Cut + \ No newline at end of file diff --git a/.github/PULL_REQUEST_TEMPLATE/PR_Template_Contributor.md b/.github/PULL_REQUEST_TEMPLATE/PR_Template_Contributor.md new file mode 100644 index 00000000..4d417179 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE/PR_Template_Contributor.md @@ -0,0 +1,32 @@ + +# Contributor Pull Request + + +## Description + + +## Motivation and Context + + + + +## How has this been tested? + + + + + +## Snippets or Screenshots (if necessary): + +## Types of changes + +- [ ] Bug fix (non-breaking change which fixes an issue) +- [ ] New feature (non-breaking change which adds functionality) +- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) + +## Checklist: + + +- [ ] My code follows the code style of this IG / specification. +- [ ] My change requires a change to the documentation or narrative (intend) of the IG. +- [ ] I have already updated the documentation / narrative (intend) accordingly. \ No newline at end of file diff --git a/.github/PULL_REQUEST_TEMPLATE/PR_Template_VersionUpgrade.md b/.github/PULL_REQUEST_TEMPLATE/PR_Template_VersionUpgrade.md new file mode 100644 index 00000000..27bd1785 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE/PR_Template_VersionUpgrade.md @@ -0,0 +1,54 @@ +# Version Upgrade Template + + +Version: + +Date: + +## Description + +This is a Pullreuqest that requires an increase in the Version number. Therefore, multiple outside-github, related Task have to be performed and checked. + +All jobs with an `x` in the boxes were performed to the best of knowledge. + +## Pre-Merge Activities + +- [ ] This PR refers to a versioned Branch with a name and a version number in the form of N.n.n, e.g. "TC_3.2.1". +- [ ] This PR has a clean meaningful committ history. Minor committs or committs without descirption have been squashed, at the latest now. +- [ ] The _./github/workflows/main.yml_ refers to the correct Firetly Terminal and SUSHI Version. + > **_Firely Terminal Pipeline_** 0.4.0. + + > **_SUSHI Versions_** 3.5.0. +- [ ] By running the _Release_Publish.py_ script, release version and date was updated accordingly. The script ran without errors. +- [ ] Eventually, increase the dependency of to newer Basis Modul (package and sushi-config) +- [ ] New Release Notes were created, aglined to the committ history and cleaned. In Github, go to + - [ ] _-> Releases_ then _-> Draft a new release_ with the _Modul Name and Version_, then + - [ ] _-> Target the main-Branch_ and _->enter a new Tag according to the Version_, then click. + - [ ] Click _-> Generate Release notes_ , _->Adjust them if necessary_ and _-> Copy/Paste the Details in the RealeaseNotes.md_ of the very Branch you want to merge. + - [ ] Finally _-> Save as Draft_ + +## Merge and Publishing + + +- [ ] With the updated Version, Dates, and Release Notes (as described above) with the last committ into the Branch you want to merge. +- [ ] In GitHub _-> Actions_ the _->CI (FHIR Validation)_ workflow terminates successfully. +- [ ] Add the Approve / the PR gets posivitly reviewed by a collegue. +- [ ] Merge (without squash) the PR, delete the Branch. + + +## Post-Merge Activities + + +- [ ] Go to the corresponding SIMPLIFIER Project and _-> Github -> Reimport_ the project. +- [ ] Go to the corresponding SIMPLIFIER Project and _-> Packages -> Expand the Dropdown for Create -> Create new package_ for the project. + - [ ] With the corresponding version number, and + - [ ] The Release notes (from above) and a compare-link to the previous Release. +- [ ] Publish the previosuly drafteted Release, including version number, on GitHub. +- [ ] Provide / Archive the IG in the corresponding _gh-pages_ branch of the GitHub project. + - [ ] Checkout the Branch (no need to merge it later). + - [ ] Export from Simplifier via _-> Guides -> Expand the Modul ... -> Export_ + - [ ] Unpack the zip, remove the packages folder (because its kinda big), and move everything else to a (version coressponding) new folder in the branch folder structure. + - [ ] committ the branch. + + +## Finished diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index dabf312b..f379a6ed 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -4,11 +4,9 @@ name: CI (FHIR Validation) # Controls when the action will run. on: - # Triggers the workflow on push or pull request events but only for the master branch + # Triggers the workflow on push or pull request events push: - branches: [ master-isik-stufe-2 ] pull_request: - branches: [ master-isik-stufe-2 ] # Allows you to run this workflow manually from the Actions tab workflow_dispatch: diff --git a/.gitignore b/.gitignore index 34df97f7..6515dd43 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /fhirpkg.lock.json +.vscode/* diff --git a/ImplementationGuide/markdown/Angehoeriger/Angehoeriger_Kompatibilitaet.md b/ImplementationGuide/markdown/Angehoeriger/Angehoeriger_Kompatibilitaet.md index 14193cae..65fc4442 100644 --- a/ImplementationGuide/markdown/Angehoeriger/Angehoeriger_Kompatibilitaet.md +++ b/ImplementationGuide/markdown/Angehoeriger/Angehoeriger_Kompatibilitaet.md @@ -3,7 +3,7 @@ Zum Zeitpunkt der Erstellung dieses Leitfadens waren keine geeigneten Basis-Profile zur Darstellung von Angehörigen bekannt. Instanzen, die gegen dieses Profil valide sind, sind auch valide gegen: - * [Profil Bezugsperson der KBV Archiv- und Wechselschnittstelle - v1.2.0](https://simplifier.net/pvs-archivierungs-undwechselschnittstelle/kbvprawbezugsperson) + * [Profil Bezugsperson der KBV Archiv- und Wechselschnittstelle - v1.2.0](https://simplifier.net/packages/kbv.ita.aws/1.2.0) * sofern für den Angehörigen mindestens ein Vor- und Nachname angegeben wurde. * wenn die Ressource einen Narrative enthält und in den Metadaten die Canonical-URL des KBV-Profile angegeben wird diff --git a/Resources/sushi-config.yaml b/Resources/sushi-config.yaml index 4b7e5cd3..8b88d400 100644 --- a/Resources/sushi-config.yaml +++ b/Resources/sushi-config.yaml @@ -4,7 +4,7 @@ FSHOnly: true applyExtensionMetadataToRoot: false id: Implementierungsleitfaden ISiK-Basismodul Stufe 3 3.0.0 name: Implementierungsleitfaden ISiK-Basismodul Stufe 3 3.0.0 -status: draft +status: active version: "3.0.0" publisher: name: Gematik GmbH diff --git a/scripts/config.yaml b/scripts/config.yaml new file mode 100644 index 00000000..ab23a178 --- /dev/null +++ b/scripts/config.yaml @@ -0,0 +1,26 @@ +package.json: + - type: version + regex: '("version":\s*")([\d\.]+.*)(")' +sushi-config.yaml: + - type: version + regex: '(version:\s*)(\d+\.\d+\.\d+.*)()' +ruleset.fsh: + - type: version + regex: + - '(\*\s*version\s*=\s*")([\d\.]+.*)(")' + - '(\*\s*\^version\s*=\s*")([\d\.]+.*)(")' + - '(\*\s*implementationGuide\s*=\s*".*\|)([\d\.]+.*)(")' + - type: date + regex: + - '(\*\s*date\s*=\s*")(\d+\-\d+\-\d+)(")' + - '(\*\s*\^date\s*=\s*")(\d+\-\d+\-\d+)(")' + format: '%Y-%m-%d' +Einfuehrung.md: + - type: version + regex: '(Version: \s*)(\d+\.\d+\.\d+.*)()' + - type: date + regex: '(Datum:\s*)(\d+\.\d+\.\d+.*)()' + format: '%d.%m.%Y' +ImplementierungsleitfadenIsiK_basismodul.json: + - type: version + regex: '("version":\s*")(\d+\.\d+\.\d+.*)(",)' \ No newline at end of file diff --git a/scripts/release_publish.py b/scripts/release_publish.py index 5eead5d5..86adfa52 100644 --- a/scripts/release_publish.py +++ b/scripts/release_publish.py @@ -7,7 +7,7 @@ import yaml -class FileToUpdate: +class FileTypeCombinationToUpdate: def __init__(self, filename, content_type, regex_list, format=None) -> None: self.filename = filename self.content_type = content_type @@ -33,7 +33,7 @@ def create_files_to_update_list(config): for filename, replacements in config.items(): for replacement in replacements: files_to_update.append( - FileToUpdate( + FileTypeCombinationToUpdate( filename, replacement["type"], replacement["regex"] if isinstance(replacement["regex"], list) else [replacement["regex"]], @@ -68,14 +68,14 @@ def replace_content_in_files(files: list, new_release_version: str, new_date: da print("Error: No files found!") return - for file in files: - if file.content_type == "version": - replace_version_in_file(file, new_release_version) - elif file.content_type == "date": - replace_date_in_file(file, new_date) + for FileTypeCombination in files: + if FileTypeCombination.content_type == "version": + replace_version_in_file(FileTypeCombination, new_release_version) + elif FileTypeCombination.content_type == "date": + replace_date_in_file(FileTypeCombination, new_date) -def replace_version_in_file(file: FileToUpdate, new_release_version: str): +def replace_version_in_file(file: FileTypeCombinationToUpdate, new_release_version: str): with open(file.location, 'r') as input_file: input_text = input_file.read() @@ -88,7 +88,7 @@ def replace_version_in_file(file: FileToUpdate, new_release_version: str): output_file.write(input_text) -def replace_date_in_file(file: FileToUpdate, new_date: datetime): +def replace_date_in_file(file: FileTypeCombinationToUpdate, new_date: datetime): with open(file.location, 'r') as input_file: input_text = input_file.read() diff --git a/scripts/update_version.sh b/scripts/update_version.sh deleted file mode 100644 index 2cbe628d..00000000 --- a/scripts/update_version.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash -clear -# This script will download the latest validation script from the template source save it -# to the scripts_folder and execute it to validate your fhir ressources. -script_name=release_publish.py -script_path=. - -#parentdir="$(dirname "$script_path")" -#mkdir -p "$parentdir" - -curl https://raw.githubusercontent.com/gematik/spec-TemplateForSimplifierProjects/feature/release_publish/scripts/$script_name -o $script_path -chmod a+x $script_path -python3 $script_name \ No newline at end of file