From ced5552aa4849c47a0fe78b5c6f174c84c2081ce Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 20:12:48 +0000 Subject: [PATCH 1/4] Initial plan From f435c685cf62f5575d3f59ffee4cf091a4ec5b26 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 20:14:54 +0000 Subject: [PATCH 2/4] Update Pandoc PDF template and add version/date metadata Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .github/workflows/build.yaml | 12 ++++++++++++ docs/template/template.html | 35 ++++++++++++++++++++++++++++------- 2 files changed, 40 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index efbbdf1..0b5fe2b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -345,10 +345,13 @@ jobs: Get-Content docs/quality/sonar-quality.md - name: Generate Guide HTML with Pandoc + shell: pwsh run: > dotnet pandoc --defaults docs/guide/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd + --metadata version="${{ inputs.version }}" + --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" --output docs/guide/guide.html - name: Generate Guide PDF with Weasyprint @@ -359,10 +362,13 @@ jobs: "docs/SarifMark User Guide.pdf" - name: Generate Code Quality HTML with Pandoc + shell: pwsh run: > dotnet pandoc --defaults docs/quality/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd + --metadata version="${{ inputs.version }}" + --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" --output docs/quality/quality.html - name: Generate Code Quality PDF with Weasyprint @@ -373,10 +379,13 @@ jobs: "docs/SarifMark Code Quality.pdf" - name: Generate Requirements HTML with Pandoc + shell: pwsh run: > dotnet pandoc --defaults docs/requirements/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd + --metadata version="${{ inputs.version }}" + --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" --output docs/requirements/requirements.html - name: Generate Requirements PDF with Weasyprint @@ -387,10 +396,13 @@ jobs: "docs/SarifMark Requirements.pdf" - name: Generate Trace Matrix HTML with Pandoc + shell: pwsh run: > dotnet pandoc --defaults docs/tracematrix/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd + --metadata version="${{ inputs.version }}" + --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" --output docs/tracematrix/tracematrix.html - name: Generate Trace Matrix PDF with Weasyprint diff --git a/docs/template/template.html b/docs/template/template.html index 1a34602..eb2ac3a 100644 --- a/docs/template/template.html +++ b/docs/template/template.html @@ -56,6 +56,13 @@ margin-bottom: 1rem; } +.version { + font-size: 1rem; + color: #888; + margin-bottom: 1rem; + font-style: italic; +} + .author, .date { font-size: 1rem; color: #888; @@ -153,7 +160,7 @@ border: 1px solid #ddd; border-radius: 4px; padding: 1rem; - overflow-x: auto; + overflow: auto; margin-bottom: 1rem; page-break-inside: avoid; } @@ -250,26 +257,32 @@ size: letter; margin: 1in 0.75in; - @top-center { + @top-left { content: string(doctitle); font-size: 10pt; color: #666; - border-bottom: 1px solid #e0e0e0; - padding-bottom: 0.25in; + } + + @top-right { + content: string(docversion); + font-size: 10pt; + color: #666; } @bottom-center { content: "Page " counter(page) " of " counter(pages); font-size: 10pt; color: #666; - border-top: 1px solid #e0e0e0; - padding-top: 0.25in; } } /* Don't show header/footer on title page */ @page :first { - @top-center { + @top-left { + content: none; + } + + @top-right { content: none; } @@ -283,6 +296,11 @@ string-set: doctitle content(); } +/* Set the document version for the header */ +.version { + string-set: docversion content(); +} + /* Add page numbers to TOC entries using target-counter */ #TOC a::after { content: leader('.') target-counter(attr(href), page); @@ -309,6 +327,9 @@
$subtitle$
$endif$ +$if(version)$ +Version $version$
+$endif$ $for(author)$ $endfor$ From 9004dfdfffce58bc93cfadf51be1e793434e5709 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 20:19:03 +0000 Subject: [PATCH 3/4] Fix metadata parameter handling in pandoc commands Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .github/workflows/build.yaml | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 0b5fe2b..e5cdbea 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -344,6 +344,13 @@ jobs: echo "=== SonarCloud Quality Report ===" Get-Content docs/quality/sonar-quality.md + - name: Set build date + shell: pwsh + run: | + $buildDate = Get-Date -Format 'yyyy-MM-dd' + echo "BUILD_DATE=$buildDate" >> $env:GITHUB_ENV + echo "Build date: $buildDate" + - name: Generate Guide HTML with Pandoc shell: pwsh run: > @@ -351,7 +358,7 @@ jobs: --defaults docs/guide/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" + --metadata date="${{ env.BUILD_DATE }}" --output docs/guide/guide.html - name: Generate Guide PDF with Weasyprint @@ -368,7 +375,7 @@ jobs: --defaults docs/quality/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" + --metadata date="${{ env.BUILD_DATE }}" --output docs/quality/quality.html - name: Generate Code Quality PDF with Weasyprint @@ -385,7 +392,7 @@ jobs: --defaults docs/requirements/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" + --metadata date="${{ env.BUILD_DATE }}" --output docs/requirements/requirements.html - name: Generate Requirements PDF with Weasyprint @@ -402,7 +409,7 @@ jobs: --defaults docs/tracematrix/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="$(Get-Date -Format 'yyyy-MM-dd')" + --metadata date="${{ env.BUILD_DATE }}" --output docs/tracematrix/tracematrix.html - name: Generate Trace Matrix PDF with Weasyprint From 1b0f03668c8151375e9faf5be466672da57fcb54 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 27 Jan 2026 20:37:49 +0000 Subject: [PATCH 4/4] Simplify date metadata handling using bash date command Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .github/workflows/build.yaml | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e5cdbea..41ff038 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -344,21 +344,13 @@ jobs: echo "=== SonarCloud Quality Report ===" Get-Content docs/quality/sonar-quality.md - - name: Set build date - shell: pwsh - run: | - $buildDate = Get-Date -Format 'yyyy-MM-dd' - echo "BUILD_DATE=$buildDate" >> $env:GITHUB_ENV - echo "Build date: $buildDate" - - name: Generate Guide HTML with Pandoc - shell: pwsh run: > dotnet pandoc --defaults docs/guide/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="${{ env.BUILD_DATE }}" + --metadata date="$(date +'%Y-%m-%d')" --output docs/guide/guide.html - name: Generate Guide PDF with Weasyprint @@ -369,13 +361,12 @@ jobs: "docs/SarifMark User Guide.pdf" - name: Generate Code Quality HTML with Pandoc - shell: pwsh run: > dotnet pandoc --defaults docs/quality/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="${{ env.BUILD_DATE }}" + --metadata date="$(date +'%Y-%m-%d')" --output docs/quality/quality.html - name: Generate Code Quality PDF with Weasyprint @@ -386,13 +377,12 @@ jobs: "docs/SarifMark Code Quality.pdf" - name: Generate Requirements HTML with Pandoc - shell: pwsh run: > dotnet pandoc --defaults docs/requirements/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="${{ env.BUILD_DATE }}" + --metadata date="$(date +'%Y-%m-%d')" --output docs/requirements/requirements.html - name: Generate Requirements PDF with Weasyprint @@ -403,13 +393,12 @@ jobs: "docs/SarifMark Requirements.pdf" - name: Generate Trace Matrix HTML with Pandoc - shell: pwsh run: > dotnet pandoc --defaults docs/tracematrix/definition.yaml --filter node_modules/.bin/mermaid-filter.cmd --metadata version="${{ inputs.version }}" - --metadata date="${{ env.BUILD_DATE }}" + --metadata date="$(date +'%Y-%m-%d')" --output docs/tracematrix/tracematrix.html - name: Generate Trace Matrix PDF with Weasyprint