Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bashfiles #1

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions _updatePublisher.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash
echo "========================================================================"
echo "Downloading most recent publisher to:"
echo ~/Downloads/org.hl7.fhir.igpublisher.jar
echo "... it's ~100 MB, so this may take a bit"
echo "========================================================================"
mv ~/Downloads/org.hl7.fhir.igpublisher.jar ~/Downloads/org.hl7.fhir.igpublisher-old.jar
curl -L https://github.com/FHIR/latest-ig-publisher/raw/master/org.hl7.fhir.publisher.jar -o ~/Downloads/org.hl7.fhir.igpublisher.jar
echo "=========================== Done ===================================="
sleep 3
4 changes: 2 additions & 2 deletions ig.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[IG]
ig = input/howto.xml
template = hl7.fhir.template
template = /Users/ehaas/Documents/FHIR/FHIR-IG-Guidance/template
usage-stats-opt-out = false
copyrightyear = 2019+
license = CC0-1.0
Expand All @@ -10,4 +10,4 @@ fhirspec = http://build.fhir.org/
#excludexml = Yes
#excludejson = Yes
#excludettl = Yes
#excludeMaps = Yes
#excludeMaps = Yes
13 changes: 13 additions & 0 deletions ig.ini.bak
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[IG]
ig = input/howto.xml
template = /Users/ehaas/Documents/FHIR/FHIR-IG-Guidance/template
usage-stats-opt-out = false
copyrightyear = 2019+
license = CC0-1.0
version = 0.1.0
ballotstatus = CI Build
fhirspec = http://build.fhir.org/
#excludexml = Yes
#excludejson = Yes
#excludettl = Yes
#excludeMaps = Yes
2,693 changes: 765 additions & 1,928 deletions input-cache/schemas-r5/fhir-single.xsd

Large diffs are not rendered by default.

172 changes: 61 additions & 111 deletions input/pagecontent/best-practice.md

Large diffs are not rendered by default.

332 changes: 240 additions & 92 deletions input/pagecontent/using-templates.xml

Large diffs are not rendered by default.

67 changes: 67 additions & 0 deletions publish.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
#!/bin/bash
# exit when any command fails
set -e
while getopts ds:twopl option
do
case "${option}"
in
t) NA='N/A';;
w) WATCH=1;;
o) PUB=1;;
p) UPDATE=1;;
l) LOAD_TEMPLATE='ig.ini';;
esac
done
echo "================================================================="
echo === Publish $SOURCE IG!!! $(date -u) ===
echo to run from command line '"bash publish.sh [parameters]"'
echo "Optional Parameters"
echo '-t parameter for no terminology server (run faster and offline)= ' $NA
echo '-w parameter for using watch on igpublisher from source default is off = ' $WATCH
echo '-o parameter for running previous version of the igpublisher= ' $PUB
echo '-p parameter for downloading latest version of the igpublisher from source = ' $UPDATE
echo '-l parameter for downloading HL7 ig template from source = ' $LOAD_TEMPLATE
echo ' current directory =' $PWD
echo "================================================================="
echo getting rid of .DS_Store files since they gum up the igpublisher....
find . -name '.DS_Store' -type f -delete
sleep 1
# git status
if [[ $UPDATE ]]; then
echo "========================================================================"
echo "Downloading most recent publisher to:"
echo ~/Downloads/org.hl7.fhir.igpublisher.jar
echo "... it's ~100 MB, so this may take a bit"
echo "========================================================================"
mv ~/Downloads/org.hl7.fhir.igpublisher.jar ~/Downloads/org.hl7.fhir.igpublisher-old.jar
curl -L https://github.com/FHIR/latest-ig-publisher/raw/master/org.hl7.fhir.publisher.jar -o ~/Downloads/org.hl7.fhir.igpublisher.jar
echo "=========================== Done ===================================="
sleep 3
fi

template=$PWD/template
if [[ $LOAD_TEMPLATE ]]; then
template=hl7.fhir.template
fi
echo "================================================================="
echo load the hl7 template by setting $PWD/ig.ini template = $template
echo "================================================================="
sed -i'.bak' -e "s|^template = .*|template = ${template}|" $PWD/ig.ini

path=~/Downloads/org.hl7.fhir.igpublisher.jar
if [[ $PUB ]]; then
path=~/Downloads/org.hl7.fhir.igpublisher-old.jar
fi

if [[ $WATCH ]]; then
echo "================================================================="
echo ===run most recent version of the igpublisher with watch on ===
echo "================================================================="
java -jar ${path} -ig ig.ini -watch -tx $NA
else
echo "================================================================="
echo ===run igpublisher just once \(no watch option\)===
echo "================================================================="
echo java -jar ${path} -ig ig.ini -tx $NA
java -jar ${path} -ig ig.ini -tx $NA
fi