Skip to content

Rename TemplateDotNetTool → ReviewMark and add ARCHITECTURE.md#1

Merged
Malcolmnixon merged 5 commits intomainfrom
copilot/rename-template-dotnet-tool-to-reviewmark
Mar 8, 2026
Merged

Rename TemplateDotNetTool → ReviewMark and add ARCHITECTURE.md#1
Malcolmnixon merged 5 commits intomainfrom
copilot/rename-template-dotnet-tool-to-reviewmark

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 8, 2026

Applies all project-wide renames from TemplateDotNetTool to ReviewMark and introduces ARCHITECTURE.md describing how the ReviewMark file-review evidence management tool works.

Description

Structural renames

  • src/DemaConsulting.TemplateDotNetTool/src/DemaConsulting.ReviewMark/
  • test/DemaConsulting.TemplateDotNetTool.Tests/test/DemaConsulting.ReviewMark.Tests/
  • DemaConsulting.TemplateDotNetTool.slnxDemaConsulting.ReviewMark.slnx

Package / tool identity

  • PackageId: DemaConsulting.ReviewMark
  • ToolCommandName: reviewmark (was templatetool)
  • Description, Title, PackageProjectUrl, RepositoryUrl updated to ReviewMark

Code

  • C# namespaces updated to DemaConsulting.ReviewMark
  • Banner: ReviewMark version …
  • Self-validation test names: ReviewMark_VersionDisplay, ReviewMark_HelpDisplay

Requirements & config

  • requirements.yaml: section title, requirement IDs (ReviewMark-*), and test name references
  • .cspell.json: replaced templatetool/TMPL with reviewmark, ReviewMark, PdfSharp, reindex, empira, fileshare
  • CI workflow, CodeQL config, VSCode tasks, build/lint scripts all updated

Documentation

  • README.md rewritten for ReviewMark; added Review Definition section with an example .reviewmark.yaml and a link to ARCHITECTURE.md
  • docs/guide/guide.md rewritten for ReviewMark
  • All docs/*/title.txt and docs/*/introduction.md updated
  • CONTRIBUTING.md, SECURITY.md, CODE_OF_CONDUCT.md, AGENTS.md updated
  • ARCHITECTURE.md created — covers the review definition file format, SHA256 fingerprinting algorithm, evidence index (index.json), PDF Keywords metadata format, --reindex command, enforcement, CI/CD integration, and standards alignment (IEC 62443, ISO 26262, DO-178C)
  • Fixed linting issues in ARCHITECTURE.md: added text language specifier to bare fenced code block (MD040) and wrapped a 155-char line to ≤120 chars (MD013)
  • Replaced artefact/artefacts with artifact/artifacts throughout ARCHITECTURE.md
  • Replaced British English spellings with US English throughout ARCHITECTURE.md: authorisationauthorization, organisationorganization; removed both from .cspell.json

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Code quality improvement

Pre-Submission Checklist

Build and Test

  • Code builds successfully: dotnet build --configuration Release
  • All unit tests pass: dotnet test --configuration Release
  • Self-validation tests pass:
    dotnet run --project src/DemaConsulting.ReviewMark --configuration Release --framework net10.0
    --no-build -- --validate
  • Code produces zero warnings

Code Quality

  • Code formatting is correct: dotnet format --verify-no-changes
  • New code has appropriate XML documentation comments
  • Static analyzer warnings have been addressed

Quality Checks

  • Spell checker passes: cspell "**/*.{md,cs}"
  • Markdown linter passes: markdownlint "**/*.md"
  • YAML linter passes: yamllint .

Testing

  • Added unit tests for new functionality
  • Updated existing tests if behavior changed
  • All tests follow the AAA (Arrange, Act, Assert) pattern
  • Test coverage is maintained or improved

Documentation

  • Updated README.md (if applicable)
  • Updated ARCHITECTURE.md (if applicable)
  • Added code examples for new features (if applicable)
  • Updated requirements.yaml (if applicable)

Additional Notes

39 unit tests pass across net8.0, net9.0, and net10.0. No CodeQL alerts. The .github/agents/ files were intentionally left unmodified (agent instructions are not within scope for direct editing).

Original prompt

Please bring in the template, and then apply all appropriate renames from TemplateDotNetTool to ReviewMark (noting that the repo-consistency-agent still needs to keep the ReviewMark repo consistent with the TemplateDotNetTool repo).

Secondarily the documentation of the ReviewMark tool needs to be updated. The rest of this is an overview of how this ReviewMark tool should work - please create an ARCHITECTURE.md file containing the following:

File Review

In regulated environments, software artefacts — source files, configuration, requirements, test code —
must be formally reviewed before release. Tracking which files have been reviewed, whether those reviews
are current, and whether every file in the repository is covered by a review is a significant manual
burden. Without automation, reviews go stale silently and coverage gaps are discovered only at audit time.

ReviewMark automates file-review evidence management. It computes cryptographic fingerprints of
defined file-sets, queries a review evidence store (URL or file-share) for corresponding code-review
PDFs, and produces two compliance documents with every CI/CD run.

How It Works

Review Definition File

Reviews are configured in a '.reviewmark.yaml' definition file at the repository root:

# .reviewmark.yaml

# Patterns identifying all files in the repository that require review.
# Processed in order; prefix a pattern with '!' to exclude.
needs-review:
  - "**/*.cs"
  - "**/*.yaml"
  - "!**/obj/**"           # exclude build output
  - "!src/Generated/**"    # exclude auto-generated files

evidence-source:
  type: url                # 'url' or 'fileshare'
  location: https://reviews.example.com/evidence/

reviews:
  - id: Core-Logic
    title: Review of core business logic
    paths:
      - "src/Core/**/*.cs"
      - "src/Core/**/*.yaml"
      - "!src/Core/Generated/**"   # exclude auto-generated files within the set
  - id: Security-Layer
    title: Review of authentication and authorisation
    paths:
      - "src/Auth/**/*.cs"

The needs-review section defines the full set of files in the repository that are subject to
review. ReviewMark uses this to detect any file that is not covered by any review-set — a coverage
gap that would otherwise go unnoticed until an audit.

Each review-set is a named group of ordered glob patterns. Patterns prefixed with ! are exclusions
and are applied in the order they appear, allowing fine-grained control over which files are included.

Fingerprinting

The fingerprint for a review-set is computed as follows:

  1. Resolve all files matched by the ordered include/exclude glob patterns.
  2. Compute a SHA256 hash of the content of each matched file.
  3. Sort the resulting SHA256 hashes lexicographically.
  4. Concatenate the sorted hashes into a single string.
  5. Compute a final SHA256 hash of that concatenated string.

Sorting by content hash rather than file path means that renaming a file does not invalidate the
review
— only actual content changes cause the fingerprint to change. This avoids spurious review
expiry due to refactoring or directory restructuring.

Evidence Source

ReviewMark queries the configured evidence source for review PDFs. Two source types are supported:

Type Description
url HTTP/HTTPS endpoint; credentials supplied via environment variables
fileshare UNC or local file-system path; credentials supplied via environment variables

Evidence Index

Rather than imposing a file-naming convention on the evidence store, ReviewMark uses an
index fileindex.json — located at the root of the evidence source. The index is a
machine-maintained catalogue of all available review PDFs and their metadata. ReviewMark fetches
this index at the start of each run and looks up each review-set by ID and fingerprint.

The index has the following structure:

{
  "reviews": [
    {
      "id": "Core-Logic",
      "fingerprint": "a3f9c2d1e4b5...",
      "date": "2026-02-14",
      "result": "pass",
      "file": "CR-2026-014 Core Logic Review.pdf"
    },
    {
      "id": "Security-Layer",
      "fingerprint": "c72b8a3f91e0...",
      "date": "2025-11-03",
      "result": "pass",
      "file": "CR-2025-089 Security Layer Review.pdf"
    }
  ]
}
Field Description
id Matches a review ID in the definition file
fingerprint The file-set fingerprint at the time of review
date Date the review was completed
result Outcome of the review: pass or fail
file File name of the evidence PDF in the evidence store

ReviewMark determines review status by looking up the current review ID and fingerprint in the
index:

Status Condition
Current An entry exists matching both id and fingerprint, with result of pass
Stale One or more entries exist matching id, but none match the current fingerprint
*...

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com>
Copilot AI changed the title [WIP] Rename TemplateDotNetTool to ReviewMark with repo consistency Rename TemplateDotNetTool → ReviewMark and add ARCHITECTURE.md Mar 8, 2026
@Malcolmnixon Malcolmnixon marked this pull request as ready for review March 8, 2026 20:17
Copilot AI review requested due to automatic review settings March 8, 2026 20:17
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR renames the tool and repository identity from TemplateDotNetTool to ReviewMark, updates build/test/CI and docs to match the new name, and adds an ARCHITECTURE.md describing the intended ReviewMark evidence-management workflow.

Changes:

  • Renamed namespaces, assembly/package/tool identifiers, solution/test project references, and CLI banner/help text to ReviewMark.
  • Updated CI workflow, scripts, requirements IDs, and documentation to reference the new tool/package/command name.
  • Added ARCHITECTURE.md with the proposed review-definition, fingerprinting, indexing, and reporting design.

Reviewed changes

Copilot reviewed 46 out of 47 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
test/DemaConsulting.ReviewMark.Tests/Runner.cs Updates test namespace to DemaConsulting.ReviewMark.Tests.
test/DemaConsulting.ReviewMark.Tests/ProgramTests.cs Updates expected banner/version text to “ReviewMark”.
test/DemaConsulting.ReviewMark.Tests/PathHelpersTests.cs Updates test namespace to DemaConsulting.ReviewMark.Tests.
test/DemaConsulting.ReviewMark.Tests/IntegrationTests.cs Updates test namespace + DLL name + expected log/banner strings.
test/DemaConsulting.ReviewMark.Tests/DemaConsulting.ReviewMark.Tests.csproj Updates project reference to renamed src project.
test/DemaConsulting.ReviewMark.Tests/ContextTests.cs Updates test namespace to DemaConsulting.ReviewMark.Tests.
test/DemaConsulting.ReviewMark.Tests/AssemblyInfo.cs Adds assembly-level MSTest setting to disable parallelization.
src/DemaConsulting.ReviewMark/Validation.cs Renames validation output/test IDs and headings to ReviewMark.
src/DemaConsulting.ReviewMark/Program.cs Renames CLI banner/help/usage strings and namespaces to ReviewMark.
src/DemaConsulting.ReviewMark/PathHelpers.cs Renames namespace to DemaConsulting.ReviewMark.
src/DemaConsulting.ReviewMark/DemaConsulting.ReviewMark.csproj Updates tool/package identity (ToolCommandName/PackageId/URLs/InternalsVisibleTo).
src/DemaConsulting.ReviewMark/Context.cs Renames namespace to DemaConsulting.ReviewMark.
requirements.yaml Renames requirement IDs/section title and self-validation test references.
lint.sh Updates comment header to ReviewMark.
lint.bat Updates comment header to ReviewMark.
docs/tracematrix/title.txt Renames titles/keywords to ReviewMark.
docs/tracematrix/introduction.md Renames project references to ReviewMark.
docs/requirements/title.txt Renames titles/keywords to ReviewMark.
docs/requirements/introduction.md Renames project references to ReviewMark.
docs/quality/title.txt Renames titles/keywords to ReviewMark.
docs/quality/introduction.md Renames project references to ReviewMark.
docs/justifications/title.txt Renames titles/keywords to ReviewMark.
docs/justifications/introduction.md Renames project references to ReviewMark.
docs/guide/title.txt Renames titles/keywords to ReviewMark and updates guide positioning.
docs/guide/guide.md Updates usage examples and descriptive text for ReviewMark.
docs/buildnotes/title.txt Renames titles/keywords to ReviewMark.
docs/buildnotes/introduction.md Renames project references to ReviewMark.
build.sh Updates script text and project path for self-validation run.
build.bat Updates script text and project path for self-validation run.
SECURITY.md Renames project references and GitHub links to ReviewMark.
README.md Renames project and rewrites feature/usage text for ReviewMark.
DemaConsulting.TemplateDotNetTool.slnx Removes old solution file.
DemaConsulting.ReviewMark.slnx Adds new solution file with renamed project paths.
CONTRIBUTING.md Renames project references, commands, and links to ReviewMark.
CODE_OF_CONDUCT.md Updates issues link to ReviewMark repo.
ARCHITECTURE.md Adds architecture/design document for review evidence management workflow.
AGENTS.md Updates agent quick reference text and self-validation naming guidance.
.yamllint.yaml Updates comment header to ReviewMark.
.vscode/tasks.json Updates solution/project paths for VS Code tasks.
.github/workflows/build.yaml Updates Sonar keys, package paths, tool install name, and CLI invocations to ReviewMark.
.github/pull_request_template.md Updates self-validation command path to renamed project.
.github/codeql-config.yml Updates CodeQL exclude paths and config name to ReviewMark.
.github/ISSUE_TEMPLATE/question.yml Updates template text/links/tool name to ReviewMark.
.github/ISSUE_TEMPLATE/feature_request.yml Updates template text/examples to ReviewMark.
.github/ISSUE_TEMPLATE/config.yml Updates contact links to ReviewMark repo/discussions.
.github/ISSUE_TEMPLATE/bug_report.yml Updates template text/tool name to ReviewMark.
.cspell.json Updates dictionary terms to match ReviewMark vocabulary.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@Malcolmnixon
Copy link
Copy Markdown
Contributor

@copilot please fix linting issues, also you may want to add an example .reviewmark.yaml to the README.md - see ARCHITECTURE.md for example.

Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 8, 2026

@copilot please fix linting issues, also you may want to add an example .reviewmark.yaml to the README.md - see ARCHITECTURE.md for example.

Fixed in commit 0f5d41b.

Linting fixes in ARCHITECTURE.md:

  • Added text language specifier to the bare fenced code block (MD040)
  • Wrapped the 155-char "Stale" description line to ≤120 chars (MD013)

Spell check fixes in .cspell.json:

  • Added artefacts, authorisation, organisation (British English terms used in ARCHITECTURE.md)

README.md — added .reviewmark.yaml example:

  • New "Review Definition" section after Features, showing the definition file format with needs-review, evidence-source, and reviews fields, plus a link to ARCHITECTURE.md for the full design details.

All linters now pass (markdownlint: 0 errors, cspell: 0 issues, yamllint: clean).

@Malcolmnixon
Copy link
Copy Markdown
Contributor

@copilot please switch artefact to artifact and remove from cspell dictionary.

@Malcolmnixon
Copy link
Copy Markdown
Contributor

@copilot consider authorisation vs authorization

Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 8, 2026

@copilot please switch artefact to artifact and remove from cspell dictionary.

Done in commit 1e97ce7. Replaced all three occurrences of artefact/artefacts in ARCHITECTURE.md with artifact/artifacts, and removed artefacts from .cspell.json. All linters still pass.

@Malcolmnixon
Copy link
Copy Markdown
Contributor

@copilot and organization

@Malcolmnixon
Copy link
Copy Markdown
Contributor

@copilot essentially use the US rather than English forms

… from cspell dict

Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 8, 2026

@copilot consider authorisation vs authorization

Done in commit 44494ba. Replaced all occurrences of authorisation with authorization in ARCHITECTURE.md and removed authorisation from .cspell.json.

@copilot and organization

Done in the same commit 44494ba. Replaced organisation with organization in ARCHITECTURE.md and removed organisation from .cspell.json.

Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 8, 2026

@copilot essentially use the US rather than English forms

Already done in commit 44494baauthorisationauthorization and organisationorganization were replaced throughout ARCHITECTURE.md, and both entries removed from .cspell.json. A broad scan of the repo shows no other British English spellings remaining.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants