Stream: IG creation
Topic: Genomics Reporting template
Matthew Koch (Jan 04 2019 at 17:29):
Hi @Lloyd McKenzie - using the framework set up in the the genomics reporting Github repo, how would you establish "content" at the top of the fold before the formal profile definition?
Example:
http://www.hl7.org/fhir/us/core/StructureDefinition-us-core-patient.html
Matthew Koch (Jan 04 2019 at 19:40):
I'm also getting output for my rendered profiles that doesn't seem to show the content outlined numerically:
Notice the .1
before the header with no preceding number?
Kevin Power (Jan 04 2019 at 20:06):
I have noticed a similar issue with the header numbers in the "real" genomics reporting IG. I haven't really dug in, but take a look at the Style tag on the headers in this file:
/framework/includes/fragment-pagebegin.html
Lloyd McKenzie (Jan 05 2019 at 22:47):
It looks like the numbering is messed up in both the SDC and CG profiles. Not sure what happened there. I'll dig and see if I can figure out what's happening. @Matthew Koch to add text at the top, put a .xml file containing an XHTML 'div' element or a .md file containing markdown in your pages folder. The name of the file should be "[id of your resource ]-intro" to come before the formal definition or "[id of your resoruce]-notes" to come after. You can see examples for obs-described-variant in the genomics-reporting ig (and a bunch of places in the sdc ig)
Matthew Koch (Jan 06 2019 at 16:29):
I didn't realize we could use markdown with your template, awesome. I just converted 1/2 of my existing pages to XML but I kind of prefer markdown...so maybe I'll switch back to that :)
Lloyd McKenzie (Jan 06 2019 at 17:56):
I can validate XHTML and it's more powerful, it's less likely to result in unexpected behavior when mixed with Jekyll and there's only one flavor of it, so no risk of confusion with different authors. As a result, I strrongly prefer it. I only added markdown in the hope of appeasing @Eric Haas :)
Matthew Koch (Jan 06 2019 at 21:27):
Fair points. I just find it easier to write markdown as it’s less verbose
Matthew Koch (Jan 07 2019 at 13:35):
It looks like the numbering is messed up in both the SDC and CG profiles. Not sure what happened there. I'll dig and see if I can figure out what's happening. @Matthew Koch to add text at the top, put a .xml file containing an XHTML 'div' element or a .md file containing markdown in your pages folder. The name of the file should be "[id of your resource ]-intro" to come before the formal definition or "[id of your resoruce]-notes" to come after. You can see examples for obs-described-variant in the genomics-reporting ig (and a bunch of places in the sdc ig)
Hi @Lloyd McKenzie I gave this a try and it doesn't seem to be working - I'm not sure if it matters, but my profile is in json
format and not the spreadsheet format that I see in the genomics-reporting or sdc IGs. The name of it is cr-core-patient.json
so I named my intro and notes page fragments cr-core-patient-intro.xml
and cr-core-patient-notes.xml
.
I'm also assuming you mean to put these files in src/pagecontent
and not src/pages
?
Lloyd McKenzie (Jan 07 2019 at 15:07):
Yes, in pagecontent. Grahame was reorganizing some things before he left, so it's possible this is also broken. I'll dig either today or tomorrow.
Matthew Koch (Jan 07 2019 at 16:35):
Thanks @Lloyd McKenzie
Eric Haas (Jan 08 2019 at 16:40):
I think Markdown is friendlier
- writing in markdown is much more natural
- with Jekyll you have Kramdown which is pretty powerful
- and you can revert to
xhtml
when you need to right in line! - leave the validation to others and enjoy writing :-)
Matthew Koch (Jan 08 2019 at 17:38):
@Eric Haas I think it also has the benefit of being able to be easily preview-able in browser, e.g. GitHub. This allows folks who only want to be concerned with the content writing easily make changes.
Matthew Koch (Jan 08 2019 at 20:46):
@Lloyd McKenzie Really helped to clarify a few things, such as making sure I'm only using elements appropriate for the version of FHIR I am targeting in my IG. With that in mind I am able to run the generator with no issues. I've converted a bunch of my pages to markdown which I am liking so far.
Can we customize the name of the output
folder? What I'd like to do is rename this to docs
so that I can utilize GitHub pages for my repo. This would allow me to generate output and host the rendered content directly from my repo.
Lloyd McKenzie (Jan 08 2019 at 21:43):
Not and also use the continuous integration build publisher - which is mandatory if you're balloting through HL7. That said, being able to change the name of the output folder is high on my list of desires too (though I'd actually like it called "website" so all of my folders are organized logically :>)
Matthew Koch (Jan 08 2019 at 22:26):
Well I’m just running the publisher via the ant launcher in your template to get some generated output. I am not balloting through HL7 for this IG. Does the Java application have to be updated to change the output folder or can I just do it via a config file somewhere? Maybe in the framework folder?
I’m not sure what the plans are for IG generation for the masses, but if it involves the HL7 IG publisher perhaps making that code available via GitHub to accept contributions would be a nice step to take?
Lloyd McKenzie (Jan 08 2019 at 22:49):
It's driven by the config file. If you adjust the XSLT file that produces the config file, that should do it for you
Matthew Koch (Jan 09 2019 at 17:05):
Yes, in pagecontent. Grahame was reorganizing some things before he left, so it's possible this is also broken. I'll dig either today or tomorrow.
Hi @Lloyd McKenzie just wondering if you could point my in the right direction on this, re: the *-intro and *-notes fragments for profiles.
Lloyd McKenzie (Jan 09 2019 at 17:11):
It should just be a question of putting files with the right names in the pagecontent folder. I'm still chasing other IG publisher issues, so I haven't had a chance to check if this is broken too.
Matthew Koch (Jan 09 2019 at 17:36):
OK, understood. Do you happen to know what file(s) in the framework folder control (or are supposed to control) this? I can take a look on my own...
Lloyd McKenzie (Jan 09 2019 at 18:13):
That bit is handled entirely by the IG publisher. The framework only affects what folder gets looked in and where the content gets included.
Matthew Koch (Jan 10 2019 at 00:37):
Ah I see. I wonder if @Grahame Grieve could add anything then?
Matthew Koch (Jan 10 2019 at 18:41):
Just so I remember for later, here is a link to where some of this structure is outlined: http://wiki.hl7.org/index.php?title=FHIR_IG_Framework
Matthew Koch (Jan 10 2019 at 18:49):
It definitely looks like this is broken, since I've tried a bunch of permutations of naming convention and I can't get any intro or notes output.
Eric Haas (Jan 11 2019 at 09:37):
I change the output folder to 'docs' for a lot of my work so I can use the Git Pages. its just a config variable in the ig.json file. There is a limit to how big the content can be however. Only good for relatively small IGs.
Matthew Koch (Jan 11 2019 at 13:33):
I change the output folder to 'docs' for a lot of my work so I can use the Git Pages. its just a config variable in the ig.json file. There is a limit to how big the content can be however. Only good for relatively small IGs.
This is good to know...thanks
Matthew Koch (Jan 14 2019 at 12:58):
@Lloyd McKenzie would you recommend opening a ticket somewhere?
Lloyd McKenzie (Jan 14 2019 at 14:12):
To add support for alternative folders for the continuous integration build process? Sure
Matthew Koch (Jan 14 2019 at 17:41):
Well, I can do that. I was talking about the fact that I can’t get “notes” or “intro” fragments to render despite following the file name convention.
Lloyd McKenzie (Jan 14 2019 at 23:01):
Hmm. I just checked and things are showing up fine in the SDC and CG IGs (I re-genned both with the current publisher) and both are showing up fine.
Lloyd McKenzie (Jan 14 2019 at 23:01):
Are you at the WGM?
Lloyd McKenzie (Jan 14 2019 at 23:01):
If not, is your content checked into Github anywhere?
Matthew Koch (Jan 15 2019 at 00:54):
Hmmmmm
Matthew Koch (Jan 15 2019 at 00:55):
https://github.com/esource-consortium/fhir-clinical-research
Matthew Koch (Jan 15 2019 at 00:56):
I actually didn’t commit any -intro or -notes files because I couldn’t get it working locally. Not sure if it matters but don’t the SDC and CG IGs use spreadsheets for profiles?
Lloyd McKenzie (Jan 15 2019 at 01:31):
That bit shouldn't matter. Can you commit a note and/or intro that you have locally that's not working?
Matthew Koch (Jan 15 2019 at 02:02):
I went ahead and created a branch with this in my local fork: https://github.com/mattkoch614/fhir-clinical-research/tree/test/intro
Matthew Koch (Jan 18 2019 at 16:36):
That bit shouldn't matter. Can you commit a note and/or intro that you have locally that's not working?
@Lloyd McKenzie Anything else you want me to submit? I'm sure you are busy with IG tooling...
Matthew Koch (Jan 24 2019 at 22:22):
@Lloyd McKenzie bump!
Lloyd McKenzie (Jan 25 2019 at 04:34):
Sorry. Finally cloned your repository. There weren't any intro or notes files in src/pagecontent. Also, you were missing the declaration for artifacts.html in your "pages" for the IG. It's essential to have that as all of the pages for your artifacts get added underneath that page. Without it, not only do notes and intro not work, you don't get the artifacts showing up in the table of contents and your section numbers won't be right.
Lloyd McKenzie (Jan 25 2019 at 04:34):
cr-core-ig.xml cr-core-patient-intro.md cr-core-patient-notes.md
Lloyd McKenzie (Jan 25 2019 at 04:35):
(And sorry for taking so long to get to this)
Matthew Koch (Jan 25 2019 at 15:51):
No worries Lloyd. Thank you for getting back to me. I didn't know I needed a pagecontent
folder, I just lumped everything into pages
and assumed that would work. I was also unaware about the need for artifacts.html
- I assume Markdown is OK for this page? I'll give these things a shot and report back.
Lloyd McKenzie (Jan 25 2019 at 15:54):
The artifacts page content gets generated automatically as HTML. All you have to do is specify the entry in your IG so it shows up in the table of contents where you want
Lloyd McKenzie (Jan 25 2019 at 15:55):
I thought you were actually using pagecontent already. If you've tweaked the framework to use pages, that is ok too - wherever you have your other pages.
Matthew Koch (Jan 25 2019 at 17:04):
Thanks again. As a side note I only committed notes/intro files in my local fork of the repo, not in the base repo.
Matthew Koch (Jan 25 2019 at 17:17):
By the way, adding in artifacts.html
into the IG XML file worked! Thank you...
Lloyd McKenzie (Jan 25 2019 at 18:06):
Sorry again for leaving waiting so long. When we put together the "official" framework, I promise it'll actually have proper documentation :)
Last updated: Apr 12 2022 at 19:14 UTC