SUSHI 2.0.0-beta.2 is the second beta release for SUSHI 2.0.0. It contains the following enhancements and bug fixes:
- Adds support for paths preceding insert rules (#853) (details below)
- Adds support for Binary Adjunct Files (#819)
- Supports a code value in the Value Set Filter operators
=,in, andnot-in(#812)- NOTE: The use of a string values in the operators above is now deprecated
- Adds support for Logical Models and Resources to constrain nested paths of elements they defined (#849)
- Adds support for using FHIR R4B (4.1.0) as the FHIR version (#855)
- Adds support for constraining a canonical type to a specific canonical using the
Canonicalkeyword (#846)- NOTE: Support for constraining to a canonical w/ a specific version is not yet supported (see #863)
- Adds a warning when a custom resource is defined using the
Resourcekeyword which is not in thehttp://hl7.org/fhir/StructureDefinitiondomain (#842) - Fixes a bug so authors can specify a version when referencing a code from a FSH-defined CodeSystem (#816)
- Fixes a bug related to setting caret paths on code systems codes in a RuleSet (#833)
- Fixes a bug so that authors can set values on elements that are constrained to a choice of profiles (#794)
- NOTE: In this case, it will be assigned using the base resource type and a warning will be logged
Insert Rules with Paths
SUSHI now supports specifying a path before using an insert rule. The path that is specified is used throughout all rules in the RuleSet being applied. In the following example, we apply the NameRules RuleSet on the PatientProfile1 profile:
RuleSet: NameRules
* family MS
* given MS
Profile: PatientProfile1
Parent: Patient
* name insert NameRules
which is equivalent to the following profile definition:
Profile: EquivalentProfile
Parent: Patient
* name.family MS
* name.given MS
This also allows insert rules to be used on indented rules. The following profile PatientProfile2 is equivalent to the two profiles above:
Profile: Profile2
Parent: Patient
* name
* insert NameRules
Full Documentation
For additional documentation, refer to FSH School's SUSHI documentation, the FSH STU1 specification, and/or the FSH current build specification.
Install or Update
NPM only installs non-stable releases when a tag or version number is specified. To install or update to this beta version of SUSHI, run the following command:
$ npm install -g fsh-sushi@2.0.0-beta.2To revert to the most recent stable (non-beta) release, run the following command:
$ npm install -g fsh-sushiTo check or confirm what version of SUSHI you have installed, you can run the following command:
$ sushi -vUsing SUSHI 2.0.0 Beta Releases in the Auto Build
The autobuild environment uses the latest stable version of SUSHI. To force the IG Publisher to use SUSHI 2.0.0-beta.2 when building your project (such as in the autobuild environment), create a fsh.ini file at the root of your project with the following contents:
[FSH]
sushi-version=2.0.0-beta.2