diff --git a/.gitignore b/.gitignore index b53495e..ca97989 100644 --- a/.gitignore +++ b/.gitignore @@ -8,4 +8,16 @@ static/ # asciidoctor .asciidoctor/ *.svg -.DS_Store \ No newline at end of file +.DS_Store + +# node modules +node_modules/ + +# bundler +_build + +# build script generated files +dist/ + +# github action keys +gh-pages* diff --git a/.gitmodules b/.gitmodules index a1524f2..bcc3dc6 100644 --- a/.gitmodules +++ b/.gitmodules @@ -2,3 +2,6 @@ [submodule "themes/docsy"] path = themes/docsy url = https://github.com/google/docsy +[submodule "m30pm"] + path = m30pm + url = git@github.com:Mach30/m30mlTools.git diff --git a/architecture/0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml b/architecture/0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml new file mode 100644 index 0000000..9cd9e38 --- /dev/null +++ b/architecture/0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml @@ -0,0 +1,2 @@ +title: Joint Statement on Multiple Patients Per Ventilator +url: 'https://www.asahq.org/about-asa/newsroom/news-releases/2020/03/joint-statement-on-multiple-patients-per-ventilator' diff --git a/architecture/1-StakeholderNeeds/01-VolumesFillMostCompliantLungSegment.yaml b/architecture/1-StakeholderNeeds/01-VolumesFillMostCompliantLungSegment.yaml new file mode 100644 index 0000000..b82c0d5 --- /dev/null +++ b/architecture/1-StakeholderNeeds/01-VolumesFillMostCompliantLungSegment.yaml @@ -0,0 +1,5 @@ +id: 1 +name: Volumes fill most compliant lung segment +statement: Volumes would go to the most compliant lung segments +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/02-PEEPWouldBeImpossibleToManage.yaml b/architecture/1-StakeholderNeeds/02-PEEPWouldBeImpossibleToManage.yaml new file mode 100644 index 0000000..ac51dc8 --- /dev/null +++ b/architecture/1-StakeholderNeeds/02-PEEPWouldBeImpossibleToManage.yaml @@ -0,0 +1,5 @@ +id: 2 +name: PEEP would be impossible to manage +statement: Positive end‐expiratory pressure (PEEP), which is of critical importance in these patients, would be impossible to manage. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/03-MonitoringPulmonaryMechanicsImpossible.yaml b/architecture/1-StakeholderNeeds/03-MonitoringPulmonaryMechanicsImpossible.yaml new file mode 100644 index 0000000..403cee7 --- /dev/null +++ b/architecture/1-StakeholderNeeds/03-MonitoringPulmonaryMechanicsImpossible.yaml @@ -0,0 +1,5 @@ +id: 3 +name: Monitoring pulmonary mechanics impossible +statement: Monitoring patients and measuring pulmonary mechanics would be challenging, if not impossible. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/04-AlarmMonitoringNotFeasible.yaml b/architecture/1-StakeholderNeeds/04-AlarmMonitoringNotFeasible.yaml new file mode 100644 index 0000000..66773c2 --- /dev/null +++ b/architecture/1-StakeholderNeeds/04-AlarmMonitoringNotFeasible.yaml @@ -0,0 +1,5 @@ +id: 4 +name: Alarm monitoring infeasible +statement: Alarm monitoring and management would not be feasible. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/05-IndividualizedManagementForClinicalImprovement.yaml b/architecture/1-StakeholderNeeds/05-IndividualizedManagementForClinicalImprovement.yaml new file mode 100644 index 0000000..6933543 --- /dev/null +++ b/architecture/1-StakeholderNeeds/05-IndividualizedManagementForClinicalImprovement.yaml @@ -0,0 +1,5 @@ +id: 5 +name: Individualized management for clinical improvement +statement: Individualized management for clinical improvement or deterioration would be impossible. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/06-StopVentilationInTheEventOfCardiacArrest.yaml b/architecture/1-StakeholderNeeds/06-StopVentilationInTheEventOfCardiacArrest.yaml new file mode 100644 index 0000000..6930392 --- /dev/null +++ b/architecture/1-StakeholderNeeds/06-StopVentilationInTheEventOfCardiacArrest.yaml @@ -0,0 +1,5 @@ +id: 6 +name: Stop ventilation in the event of cardiac arrest +statement: In the case of a cardiac arrest, ventilation to all patients would need to be stopped to allow the change to bag ventilation without aerosolizing the virus and exposing healthcare workers. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/07-AddedCircuitVolume.yaml b/architecture/1-StakeholderNeeds/07-AddedCircuitVolume.yaml new file mode 100644 index 0000000..2e02a05 --- /dev/null +++ b/architecture/1-StakeholderNeeds/07-AddedCircuitVolume.yaml @@ -0,0 +1,5 @@ +id: 7 +name: Added circuit volume +statement: The added circuit volume defeats the operational self‐test (the test fails). +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/08-ExternalMonitoringRequired.yaml b/architecture/1-StakeholderNeeds/08-ExternalMonitoringRequired.yaml new file mode 100644 index 0000000..31b7e0b --- /dev/null +++ b/architecture/1-StakeholderNeeds/08-ExternalMonitoringRequired.yaml @@ -0,0 +1,5 @@ +id: 8 +name: External monitoring required +statement: Additional external monitoring would be required. The ventilator monitors the average pressures and volumes. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/09-PatientsDeteriorateAndRecoverAtDifferentRates.yaml b/architecture/1-StakeholderNeeds/09-PatientsDeteriorateAndRecoverAtDifferentRates.yaml new file mode 100644 index 0000000..58d3b35 --- /dev/null +++ b/architecture/1-StakeholderNeeds/09-PatientsDeteriorateAndRecoverAtDifferentRates.yaml @@ -0,0 +1,5 @@ +id: 9 +name: Patients deteriorate and recover at different rates. +statement: Patients deteriorate and recover at different rates, and distribution of gas to each patient would be unequal and unmonitored. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/1-StakeholderNeeds/10-GreatestRisksWithSuddenDeterioration.yaml b/architecture/1-StakeholderNeeds/10-GreatestRisksWithSuddenDeterioration.yaml new file mode 100644 index 0000000..80fa10a --- /dev/null +++ b/architecture/1-StakeholderNeeds/10-GreatestRisksWithSuddenDeterioration.yaml @@ -0,0 +1,5 @@ +id: 10 +name: Greatest risk with sudden deterioration +statement: The greatest risks occur with sudden deterioration of a single patient (e.g., pneumothorax, kinked endotracheal tube), with the balance of ventilation distributed to the other patients. +derivedFrom: + - "0-References/1-JointStatementOnMultiplePatientsPerVentilator.yaml" diff --git a/architecture/2-UserStories/1-VolumeAdjustment.yaml b/architecture/2-UserStories/1-VolumeAdjustment.yaml new file mode 100644 index 0000000..c3e9b0a --- /dev/null +++ b/architecture/2-UserStories/1-VolumeAdjustment.yaml @@ -0,0 +1,10 @@ +id: 1 +name: Volume Adjustment +actor: Clinician +behavior: individually adjust valves +rationale: control volumetric flowrate per patient +derivedFrom: +- "1-StakeholderNeeds/01-VolumesFillMostCompliantLungSegment.yaml" +- "1-StakeholderNeeds/05-IndividualizedManagementForClinicalImprovement.yaml" +- "1-StakeholderNeeds/09-PatientsDeteriorateAndRecoverAtDifferentRates.yaml" +example: Adjusting flow for each patient, decreasing PIP for the healthier lungs, and increasing PIP for the less healthy patient. diff --git a/architecture/2-UserStories/2-MatchingProtocols.yaml b/architecture/2-UserStories/2-MatchingProtocols.yaml new file mode 100644 index 0000000..bfc30e3 --- /dev/null +++ b/architecture/2-UserStories/2-MatchingProtocols.yaml @@ -0,0 +1,10 @@ +id: 2 +name: Matching Protocols +actor: Clinician +behavior: {activity-that-manages-matching-protocols} +rationale: maintain matching protocols per patient volume +derivedFrom: +- "1-StakeholderNeeds/01-VolumesFillMostCompliantLungSegment.yaml" +- "1-StakeholderNeeds/05-IndividualizedManagementForClinicalImprovement.yaml" +- "1-StakeholderNeeds/09-PatientsDeteriorateAndRecoverAtDifferentRates.yaml" +example: {example-here} diff --git a/build.sh b/build.sh index cff0ed2..6c608a2 100755 --- a/build.sh +++ b/build.sh @@ -1,5 +1,34 @@ #!/usr/bin/env bash +# Install node_modules, if not already installed +if [ ! -r ./node_modules ]; then + docker run --rm --volume "$PWD:/src" -w "/src" capsulecorplab/asciidoctor-extended:asciidocsy-nodejs 'npm ci' +fi + +# Install m30pm node_modules, if not already installed +if [ ! -r ./m30pm/node_modules ]; then + docker run --rm --volume "$PWD:/src" -w "/src" capsulecorplab/asciidoctor-extended:asciidocsy-nodejs 'cd m30pm && npm ci' +fi + +# Make dist/ directory, if none exists +if [ ! -r ./dist ]; then + mkdir dist/ +fi + +# Build the unified model +docker run --rm --volume "$PWD:/src" -w "/src" capsulecorplab/asciidoctor-extended:asciidocsy-nodejs 'node m30pm/buildUnifiedModel.js && cp dist/architecture.yaml dist/architecture.yml' + +# generate tetra-requirements.adoc from liquid template +docker run --rm --volume "$PWD:/src" -w "/src" capsulecorplab/asciidoctor-extended:asciidocsy-nodejs 'node m30pm/generateDoc.js --unifiedModel=dist/architecture.yaml --template=templates/tetra-requirements.adoc.liquid --out=dist/tetra-requirements.adoc' + +# generate pdf-theme.yml from liquid template +docker run --rm --volume "$PWD:/src" -w "/src" capsulecorplab/asciidoctor-extended:liquidoc 'bundle exec liquidoc -d dist/architecture.yml -t templates/pdf-theme.yml.liquid -o dist/pdf-theme.yml' +#docker run --rm --volume "$PWD:/src" -w "/src" capsulecorplab/asciidoctor-extended:asciidocsy-nodejs 'bundle exec liquidoc -d dist/architecture.yml -t templates/pdf-theme.yml.liquid -o dist/pdf-theme.yml' + +# generate tetra-requirements.pdf +docker run --rm --volume $PWD:/src -w "/src" capsulecorplab/asciidoctor-extended:asciidocsy-nodejs 'asciidoctor dist/tetra-requirements.adoc -o dist/tetra-requirements.pdf -r asciidoctor-pdf -r asciidoctor-diagram -b pdf -a pdf-theme=dist/pdf-theme.yml' + +# build Hugo site if [ ! -r ./node_modules ]; then docker run --rm --volume $PWD:/src -w "/src" capsulecorplab/hugo-asciidoctor-plantuml:0.76.5-alpine 'npm ci' fi diff --git a/content/en/references/dist b/content/en/references/dist new file mode 120000 index 0000000..35f47bf --- /dev/null +++ b/content/en/references/dist @@ -0,0 +1 @@ +../../../dist \ No newline at end of file diff --git a/content/en/references/stakeholder-concerns-and-requirements.adoc b/content/en/references/stakeholder-concerns-and-requirements.adoc index 2944468..9e3dfba 100644 --- a/content/en/references/stakeholder-concerns-and-requirements.adoc +++ b/content/en/references/stakeholder-concerns-and-requirements.adoc @@ -6,12 +6,4 @@ description: > Identifying stakeholder concerns & deriving top-level requirements. --- -[plantuml, pkg-stakeholder-concerns, svg] -.... -include::system-model/requirements/pkg-stakeholder-concerns.puml[] -.... - -[plantuml, pkg-requirements, svg] -.... -include::system-model/requirements/pkg-requirements.puml[] -.... +include::dist/tetra-requirements.adoc[] diff --git a/m30pm b/m30pm new file mode 160000 index 0000000..06fc95e --- /dev/null +++ b/m30pm @@ -0,0 +1 @@ +Subproject commit 06fc95ea88962fcdde09f057dcd71e00b87a71f1 diff --git a/package-lock.json b/package-lock.json index 255fffe..6e7509a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { - "name": "tech-doc-hugo", - "version": "0.0.1", + "name": "tetra", + "version": "0.1.0", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -803,25 +803,29 @@ "dependencies": { "abbrev": { "version": "1.1.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", "dev": true, "optional": true }, "ansi-regex": { "version": "2.1.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", "dev": true, "optional": true }, "aproba": { "version": "1.2.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", + "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", "dev": true, "optional": true }, "are-we-there-yet": { "version": "1.1.5", - "bundled": true, + "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz", + "integrity": "sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w==", "dev": true, "optional": true, "requires": { @@ -831,13 +835,15 @@ }, "balanced-match": { "version": "1.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", "dev": true, "optional": true }, "brace-expansion": { "version": "1.1.11", - "bundled": true, + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, "optional": true, "requires": { @@ -847,37 +853,43 @@ }, "chownr": { "version": "1.1.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.1.tgz", + "integrity": "sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g==", "dev": true, "optional": true }, "code-point-at": { "version": "1.1.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", + "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", "dev": true, "optional": true }, "concat-map": { "version": "0.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", "dev": true, "optional": true }, "console-control-strings": { "version": "1.1.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", + "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", "dev": true, "optional": true }, "core-util-is": { "version": "1.0.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", "dev": true, "optional": true }, "debug": { "version": "2.6.9", - "bundled": true, + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, "optional": true, "requires": { @@ -886,25 +898,29 @@ }, "deep-extend": { "version": "0.6.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", "dev": true, "optional": true }, "delegates": { "version": "1.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", + "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=", "dev": true, "optional": true }, "detect-libc": { "version": "1.0.3", - "bundled": true, + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", + "integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=", "dev": true, "optional": true }, "fs-minipass": { "version": "1.2.5", - "bundled": true, + "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.5.tgz", + "integrity": "sha512-JhBl0skXjUPCFH7x6x61gQxrKyXsxB5gcgePLZCwfyCGGsTISMoIeObbrvVeP6Xmyaudw4TT43qV2Gz+iyd2oQ==", "dev": true, "optional": true, "requires": { @@ -913,13 +929,15 @@ }, "fs.realpath": { "version": "1.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true, "optional": true }, "gauge": { "version": "2.7.4", - "bundled": true, + "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", "dev": true, "optional": true, "requires": { @@ -935,7 +953,8 @@ }, "glob": { "version": "7.1.3", - "bundled": true, + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz", + "integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==", "dev": true, "optional": true, "requires": { @@ -949,13 +968,15 @@ }, "has-unicode": { "version": "2.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", + "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=", "dev": true, "optional": true }, "iconv-lite": { "version": "0.4.24", - "bundled": true, + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "dev": true, "optional": true, "requires": { @@ -964,7 +985,8 @@ }, "ignore-walk": { "version": "3.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-3.0.1.tgz", + "integrity": "sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ==", "dev": true, "optional": true, "requires": { @@ -973,7 +995,8 @@ }, "inflight": { "version": "1.0.6", - "bundled": true, + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "dev": true, "optional": true, "requires": { @@ -983,19 +1006,22 @@ }, "inherits": { "version": "2.0.3", - "bundled": true, + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", "dev": true, "optional": true }, "ini": { "version": "1.3.5", - "bundled": true, + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", + "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", "dev": true, "optional": true }, "is-fullwidth-code-point": { "version": "1.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", "dev": true, "optional": true, "requires": { @@ -1004,13 +1030,15 @@ }, "isarray": { "version": "1.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "dev": true, "optional": true }, "minimatch": { "version": "3.0.4", - "bundled": true, + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "dev": true, "optional": true, "requires": { @@ -1019,13 +1047,15 @@ }, "minimist": { "version": "0.0.8", - "bundled": true, + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", "dev": true, "optional": true }, "minipass": { "version": "2.3.5", - "bundled": true, + "resolved": "https://registry.npmjs.org/minipass/-/minipass-2.3.5.tgz", + "integrity": "sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA==", "dev": true, "optional": true, "requires": { @@ -1035,7 +1065,8 @@ }, "minizlib": { "version": "1.2.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.2.1.tgz", + "integrity": "sha512-7+4oTUOWKg7AuL3vloEWekXY2/D20cevzsrNT2kGWm+39J9hGTCBv8VI5Pm5lXZ/o3/mdR4f8rflAPhnQb8mPA==", "dev": true, "optional": true, "requires": { @@ -1044,7 +1075,8 @@ }, "mkdirp": { "version": "0.5.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", "dev": true, "optional": true, "requires": { @@ -1053,13 +1085,15 @@ }, "ms": { "version": "2.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", "dev": true, "optional": true }, "needle": { "version": "2.2.4", - "bundled": true, + "resolved": "https://registry.npmjs.org/needle/-/needle-2.2.4.tgz", + "integrity": "sha512-HyoqEb4wr/rsoaIDfTH2aVL9nWtQqba2/HvMv+++m8u0dz808MaagKILxtfeSN7QU7nvbQ79zk3vYOJp9zsNEA==", "dev": true, "optional": true, "requires": { @@ -1070,7 +1104,8 @@ }, "node-pre-gyp": { "version": "0.10.3", - "bundled": true, + "resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.10.3.tgz", + "integrity": "sha512-d1xFs+C/IPS8Id0qPTZ4bUT8wWryfR/OzzAFxweG+uLN85oPzyo2Iw6bVlLQ/JOdgNonXLCoRyqDzDWq4iw72A==", "dev": true, "optional": true, "requires": { @@ -1088,7 +1123,8 @@ }, "nopt": { "version": "4.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz", + "integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=", "dev": true, "optional": true, "requires": { @@ -1098,13 +1134,15 @@ }, "npm-bundled": { "version": "1.0.5", - "bundled": true, + "resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.0.5.tgz", + "integrity": "sha512-m/e6jgWu8/v5niCUKQi9qQl8QdeEduFA96xHDDzFGqly0OOjI7c+60KM/2sppfnUU9JJagf+zs+yGhqSOFj71g==", "dev": true, "optional": true }, "npm-packlist": { "version": "1.2.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.2.0.tgz", + "integrity": "sha512-7Mni4Z8Xkx0/oegoqlcao/JpPCPEMtUvsmB0q7mgvlMinykJLSRTYuFqoQLYgGY8biuxIeiHO+QNJKbCfljewQ==", "dev": true, "optional": true, "requires": { @@ -1114,7 +1152,8 @@ }, "npmlog": { "version": "4.1.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", + "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", "dev": true, "optional": true, "requires": { @@ -1126,19 +1165,22 @@ }, "number-is-nan": { "version": "1.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", + "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", "dev": true, "optional": true }, "object-assign": { "version": "4.1.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", "dev": true, "optional": true }, "once": { "version": "1.4.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "dev": true, "optional": true, "requires": { @@ -1147,19 +1189,22 @@ }, "os-homedir": { "version": "1.0.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "dev": true, "optional": true }, "os-tmpdir": { "version": "1.0.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true, "optional": true }, "osenv": { "version": "0.1.5", - "bundled": true, + "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz", + "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", "dev": true, "optional": true, "requires": { @@ -1169,19 +1214,22 @@ }, "path-is-absolute": { "version": "1.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true, "optional": true }, "process-nextick-args": { "version": "2.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", + "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==", "dev": true, "optional": true }, "rc": { "version": "1.2.8", - "bundled": true, + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", "dev": true, "optional": true, "requires": { @@ -1193,7 +1241,8 @@ "dependencies": { "minimist": { "version": "1.2.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true, "optional": true } @@ -1201,7 +1250,8 @@ }, "readable-stream": { "version": "2.3.6", - "bundled": true, + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "optional": true, "requires": { @@ -1216,7 +1266,8 @@ }, "rimraf": { "version": "2.6.3", - "bundled": true, + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", + "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", "dev": true, "optional": true, "requires": { @@ -1225,43 +1276,50 @@ }, "safe-buffer": { "version": "5.1.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", "dev": true, "optional": true }, "safer-buffer": { "version": "2.1.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", "dev": true, "optional": true }, "sax": { "version": "1.2.4", - "bundled": true, + "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", + "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==", "dev": true, "optional": true }, "semver": { "version": "5.6.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/semver/-/semver-5.6.0.tgz", + "integrity": "sha512-RS9R6R35NYgQn++fkDWaOmqGoj4Ek9gGs+DPxNUZKuwE183xjJroKvyo1IzVFeXvUrvmALy6FWD5xrdJT25gMg==", "dev": true, "optional": true }, "set-blocking": { "version": "2.0.0", - "bundled": true, + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true, "optional": true }, "signal-exit": { "version": "3.0.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", + "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", "dev": true, "optional": true }, "string-width": { "version": "1.0.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", "dev": true, "optional": true, "requires": { @@ -1272,7 +1330,8 @@ }, "string_decoder": { "version": "1.1.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "dev": true, "optional": true, "requires": { @@ -1281,7 +1340,8 @@ }, "strip-ansi": { "version": "3.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "optional": true, "requires": { @@ -1290,13 +1350,15 @@ }, "strip-json-comments": { "version": "2.0.1", - "bundled": true, + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true, "optional": true }, "tar": { "version": "4.4.8", - "bundled": true, + "resolved": "https://registry.npmjs.org/tar/-/tar-4.4.8.tgz", + "integrity": "sha512-LzHF64s5chPQQS0IYBn9IN5h3i98c12bo4NCO7e0sGM2llXQ3p2FGC5sdENN4cTW48O915Sh+x+EXx7XW96xYQ==", "dev": true, "optional": true, "requires": { @@ -1311,13 +1373,15 @@ }, "util-deprecate": { "version": "1.0.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", "dev": true, "optional": true }, "wide-align": { "version": "1.1.3", - "bundled": true, + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", "dev": true, "optional": true, "requires": { @@ -1326,13 +1390,15 @@ }, "wrappy": { "version": "1.0.2", - "bundled": true, + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true, "optional": true }, "yallist": { "version": "3.0.3", - "bundled": true, + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.0.3.tgz", + "integrity": "sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A==", "dev": true, "optional": true } diff --git a/package.json b/package.json index 298c420..7dffa79 100644 --- a/package.json +++ b/package.json @@ -1,21 +1,10 @@ { - "name": "tech-doc-hugo", - "version": "0.0.1", - "description": "Hugo theme for technical documentation.", - "main": "none.js", - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/bep/tech-doc-hugo.git" - }, - "author": "", - "license": "ISC", - "bugs": { - "url": "https://github.com/bep/tech-doc-hugo/issues" - }, - "homepage": "https://github.com/bep/tech-doc-hugo#readme", + "name": "tetra", + "version": "0.1.0", + "description": "Project Tetra", + "repository": "https://github.com/tetrabiodistributed/tetra.git", + "license": "MIT", + "homepage": "https://tetrabiodistributed.github.io/tetra", "dependencies": {}, "devDependencies": { "autoprefixer": "^9.8.0", diff --git a/style-guide.adoc b/style-guide.adoc new file mode 100644 index 0000000..7ca4385 --- /dev/null +++ b/style-guide.adoc @@ -0,0 +1,11 @@ += Style Guide + +This document is a content style guide for content in the `architecture/` directory. + +=== Architecture + +Content in `architecture/` should be consistent with the https://github.com/Mach30/m30ml[Mach30 modeling language (m30ml)]. +YAML files specified in m30ml should subside in the `0-References/`, `1-StakeholderNeeds`, `2-UserStories`, or `3-Datastructures` directory, +and be prependend with a number, followed by a dash, the content name in https://wiki.c2.com/?PascalCase[Pascal Case], and a `.yaml`, +e.g., `2-CubeSatDesignSpecificationRev13.yaml`. + diff --git a/templates/pdf-theme.yml.liquid b/templates/pdf-theme.yml.liquid new file mode 100644 index 0000000..e578c85 --- /dev/null +++ b/templates/pdf-theme.yml.liquid @@ -0,0 +1,43 @@ +# This yaml file extends default theme. See https://github.com/asciidoctor/asciidoctor-pdf/blob/master/docs/theming-guide.adoc +extends: default +base-font-size: 11 +heading: + h2-font-size: $base-font-size * 1.25 + h2-font-color: #255c91 + h3-font-size: $base-font-size * 1 + h4-font-size: $base-font-size * 1 +page: + layout: portrait + margin: [1in, 1in, 1in, 1in] + size: Letter +caption: + align: center +table: + caption: + side: bottom +base: + font-family: Helvetica + line-height: 1 +header: + height: 1.25in + line_height: 1 + recto: + left: + content: | + *{{package.description}}* + + right: + content: | + *v{{package.version}}* + verso: + left: + content: $header-recto-left-content + right: + content: $header-recto-right-content +footer: + columns: =100% + recto: + center: + content: '{page-number}' + verso: + center: + content: '{page-number}' diff --git a/templates/tetra-requirements.adoc.liquid b/templates/tetra-requirements.adoc.liquid new file mode 100644 index 0000000..6fe72fd --- /dev/null +++ b/templates/tetra-requirements.adoc.liquid @@ -0,0 +1,65 @@ += {{architecture.package.description}} +:doc-name: tetra-requirements +:doc-name-adoc: tetra-requirements.adoc +:revnumber: v{{architecture.package.version}} +:toc: left + +ifndef::backend-pdf[] +image:https://img.shields.io/badge/License-MIT-yellow.svg[MIT License, link=https://opensource.org/licenses/MIT] +image:https://img.shields.io/badge/Contribute%20on-GitHub-orange[Contribute on GitHub, link={{architecture.package.repository}}] +image:https://img.shields.io/badge/Download%20-PDF-blue[Download PDF, link=../dist/{doc-name}.pdf] +endif::[] + +<<< + +== Stakeholder Concerns + +The {{architecture.package.description}} is guided by a series of stakeholder concerns, listed below. + +{% for need in architecture['1-StakeholderNeeds'] %} +=== {{need.id}}: {{need.name}} +**** +{{need.statement}} +**** + +{% if need.derivedFrom.length > 0 %} +==== *Reference:* + +{% for derivedFromItem in need.derivedFrom %} +{% if architecture['elements'][derivedFromItem].url %} +* {{architecture['elements'][derivedFromItem].url}}[{{architecture['elements'][derivedFromItem].title}}] +{% endif %} +{% endfor %} +{% endif %} + +{% endfor %} + +== User Stories + +The {{architecture.package.description}}'s stakeholder concerns are then used to identify a series of user stories to capture the functional requirements of the {{architecture.package.description}} project. + +{% for us in architecture['2-UserStories'] %} +=== {{us.id}}: {{us.name}} + +**** +As a *{{us.actor}}* I want to *{{us.behavior}}* so that I can *{{us.rationale}}*. +**** + +==== Example: + +{{us.example}} + +{% if us.derivedFrom.length > 0 %} +==== *Derived From:* + +{% for derivedFromItem in us.derivedFrom %} +{% if architecture['elements'][derivedFromItem].url %} +* {{architecture['elements'][derivedFromItem].url}}[{{architecture['elements'][derivedFromItem].title}}] +{% endif %} +{% if architecture['elements'][derivedFromItem].name %} +* xref:{doc-name-adoc}#_{{architecture['elements'][derivedFromItem].id | downcase | replace: " ", "_" | replace: ".", "_"}}_{{architecture['elements'][derivedFromItem].name | downcase | replace: " ", "_"}}[{{architecture['elements'][derivedFromItem].name}}] +{% endif %} +{% endfor %} +{% endif %} + +{% endfor %}