From 146a2f56dcd14f9a593b2c80e5c650389e65bfc9 Mon Sep 17 00:00:00 2001 From: 0xSage Date: Tue, 22 Aug 2023 16:57:42 +0800 Subject: [PATCH] docs: adrs --- Makefile | 5 +++++ README.md | 12 ++++++------ adr/README.md | 18 ++++++++++++++++++ adr/adr-template.md | 24 ++++++++++++++++++++++++ 4 files changed, 53 insertions(+), 6 deletions(-) create mode 100644 Makefile create mode 100644 adr/README.md create mode 100644 adr/adr-template.md diff --git a/Makefile b/Makefile new file mode 100644 index 000000000..ce640d4fe --- /dev/null +++ b/Makefile @@ -0,0 +1,5 @@ +newadr: + @echo "Initiating an ADR..." + @read -p "Enter ADR number (e.g. 001): " number; \ + read -p "Enter ADR title: " title; \ + cp $(CURDIR)/adr/adr-template.md $(CURDIR)/adr/adr-$${number}-$${title}.md \ No newline at end of file diff --git a/README.md b/README.md index cc200d69d..1161cf263 100644 --- a/README.md +++ b/README.md @@ -57,11 +57,11 @@ Jan is a monorepo that pulls in the following submodules ```shell ├── docker-compose.yml -├── jan-mobile -├── jan-web -├── jan-backend -├── jan-inference -├── jan-docs - ├── adrs # Architecture Decision Records +├── mobile-client +├── web-client +├── app-backend +├── inference-backend +├── docs # Developer Docs +├── adrs # Architecture Decision Records ``` diff --git a/adr/README.md b/adr/README.md new file mode 100644 index 000000000..ae6691594 --- /dev/null +++ b/adr/README.md @@ -0,0 +1,18 @@ +# Architectural Decision Records (ADR) + +This is a repo of key architecture decisions for Jan. [Read more about ADRs](https://github.com/joelparkerhenderson/architecture-decision-record) + + +### Get started: + +```sh +# In root: +make newadr +``` + +### Template: +- **Status**: `pending`, `approved`, or `rejected` +- **Context**: a clearly defined problem/goal +- **Decisions**: the proposed architecture choices & changes +- **Consequences**: pros and cons of the decision +- **References**: any relevant materials to read \ No newline at end of file diff --git a/adr/adr-template.md b/adr/adr-template.md new file mode 100644 index 000000000..e47d6a6b9 --- /dev/null +++ b/adr/adr-template.md @@ -0,0 +1,24 @@ +# ADR {ADR-NUM}: {TITLE} + +## Changelog +- {date}: {changelog} + +## Status + +What is the status, such as proposed, accepted, rejected, deprecated, superseded, etc.? + +{Proposed|Accepted|Rejected} + +## Context + +What is the issue that we're seeing that is motivating this decision or change? + +## Decision + +What is the change that we're proposing and/or doing? + +## Consequences + +What becomes easier or more difficult to do because of this change? + +## Reference \ No newline at end of file