SUSHI 0.4.0
NOTE: This version contains a bug that has been fixed in the SUSHI 0.4.1 release. Please use SUSHI 0.4.1.
SUSHI 0.4.0 contains the following features and fixes:
- Simplified support for adding extensions to profiles (details below)
- Initial (limited) support for generating Implementation Guides (details below)
- Default output folder changed from
out
tobuild
- Bug fix for applying constraints to extension values
- Reports total number of errors and warnings after processing completes
Simplified support for adding extensions to profiles
Prior to this release, authors could add extensions using the contains
keyword, but they were required to specify the slicing discriminator manually (using the ^
feature). Now when authors add extensions, if no discriminator has been specified already, SUSHI will automatically add a value
-based discriminator on the url
path (unordered and open).
Example:
Profile: Pirate
Parent: Patient
* extension contains ParrotName 0..1
Extension: ParrotName
* extension 0..0
* value[x] only string
Initial (limited) support for generating Implementation Guides (IG)
SUSHI generates implementation guides that can be published via the new template-based IG Publisher. The template-based publisher is still being developed by the FHIR community. See the Guidance for HL7 IG Creation for more details.
To indicate that SUSHI should generate the IG structure and files, add a folder named ig-data
to the folder containing your FSH files (i.e. the "FSH Tank"). If the folder is empty, SUSHI will generate a basic implementation guide using information in your package.json
and FSH files. In this initial release, SUSHI also supports very limited customization of the IG via the following files:
ig-data/ig.ini
: If present, the user-provided igi.ini values will be merged with the SUSHI-generated ig.ini. The FHIR team has not yet fully documented the ig.ini file, but the following example shows the default values for some of the fields that authors may commonly want to override:Possible values for[IG] template = fhir.base.template copyrightyear = 2019+ ballotstatus = STU1 excludexml = No excludejson = No excludettl = No excludeMaps = No
template
arefhir.base.template
,hl7.fhir.template
, andfhir.davinci.template
.ig-data/package-list.json
: If present, the user-provided package-list.json will be used. If not present, SUSHI will generate a package-list.json. See the FHIR PackageList documentation.ig-data/input/pagecontent/index.md
: If present, the user-provided index.md will be used as the content for the IG's main page. If not preset, SUSHI will generate this file and insert thedescription
value from thepackage.json
file.
Future versions of SUSHI will allow authors to configure the menu, add custom resources, and add additional content (such as pages and snippets).
After running SUSHI, navigate to the output folder (default name: build
) and run the _updatePublisher
script to download the latest publisher to the input-cache
folder. After the download is completed, run the _genonce
script to initiate the Java-based IG builder process (NOTE: Java must be installed). After the publishing process is complete, open the output/index.html
file in your browser.
For more details about the template-based IG Publisher, see Using the HL7 Templates.
Install or Update
To install or update to the latest version, run the following command:
$ npm install -g fsh-sushi