Skip to content

A docker image to help with FHIR Implementation Guide authoring using FHIR Shorthand (FSH)

License

Notifications You must be signed in to change notification settings

bonfhir/ig-toolbox

Repository files navigation

FHIR Implementation Guide Toolbox

A docker image to help with FHIR Implementation Guide authoring using FHIR Shorthand (FSH).

It contains:

To learn how to get started, head over to our tutorial at https://bonfhir.dev/docs/guides/ig-toolbox

Usage

docker run -it --rm -v .:/workspaces ghcr.io/bonfhir/ig-toolbox

This will get you a shell where all the tools are available, and the current directory is volume-mounted.

To get started with a new sushi project, you can use sushi init; to use it directly from the docker image simply start with:

docker run -it --rm -v .:/workspaces ghcr.io/bonfhir/ig-toolbox sushi init

To use the IG Puslisher, you'll need to execute the ./_updatePublisher.sh script once after the project is generated.

Usage with VS Code and dev containers

You can simply setup a VS Code dev container setup in the current directory by running:

docker run -it --rm -v .:/workspaces ghcr.io/bonfhir/ig-toolbox add-vscode-files

(Or simply run add-vscode-files if you are already in the container).

This will create 2 files:

  1. .devcontainer/devcontainer.json:
{
  "name": "FSH in VS Code",
  "image": "ghcr.io/bonfhir/ig-toolbox",
  "remoteUser": "root",
  "customizations": {
    "vscode": {
      "extensions": [
        "MITRE-Health.vscode-language-fsh",
        "jebbs.plantuml"
      ]
    }
  }
}
  1. .vscode/tasks.json to define tasks tp launch SUSHI and the IG Publisher:
{
  "version": "2.0.0",
  "tasks": [
    {
      "label": "Run SUSHI",
      "type": "shell",
      "command": "sushi .",
      "group": {
        "kind": "build",
        "isDefault": true
      },
      "presentation": {
        "reveal": "always",
        "focus": false,
        "panel": "shared",
        "clear": false
      },
      "problemMatcher": []
    },
    {
      "label": "Run IG Publisher",
      "type": "shell",
      "command": "./_genonce.sh",
      "group": {
        "kind": "build"
      },
      "presentation": {
        "reveal": "always",
        "focus": false,
        "panel": "shared",
        "clear": false
      },
      "problemMatcher": []
    }
  ]
}

Helper scripts

Add profile

Use the add-profile <profile-name> script to create a new Profile FSH file, and its companion Markdown file in the pagecontent folder.

Add FHIR resource diagram

Use the add-fhir-resource-diagram <diagram-name> to create a PlantUML class diagram that can be used to represent FHIR resources relationships.

About

A docker image to help with FHIR Implementation Guide authoring using FHIR Shorthand (FSH)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages