Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(docs): Add documentation/gh-pages using Catalyst-CI docs builders and actions. #104

Merged
merged 56 commits into from
Nov 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
d6affe2
refactor(gateway): Rename catalyst-voices-backend to the catalyst-gat…
stevenj Oct 18, 2023
d1736b9
docs(gateway): Update readme
stevenj Oct 18, 2023
d966461
refactor(gateway): Move the code into the new directory trees, cleanu…
stevenj Oct 18, 2023
dd7594a
refactor(gateway): Basic refactor of the event-db config/data and the…
stevenj Oct 18, 2023
e00cc4e
docs(gateway): Initial docs for the crates directory inside catalyst …
stevenj Oct 18, 2023
ffc2514
refactor(gateway): Move code out of cat-data-service and put it direc…
stevenj Oct 18, 2023
fc63b2f
feat(gateway): first build seems to work, but fails due to WIP refactor
stevenj Oct 19, 2023
85f369d
refactor(gateway): Refactor builds properly to a static executable.
stevenj Oct 19, 2023
0a0ce4f
refactor(gateway): autofixed lints
stevenj Oct 19, 2023
4163ad4
refactor(gateway): WIP remove lint errors
stevenj Oct 19, 2023
ff9ed9d
refactor(gateway): WIP refactoring work to remove lint errors
stevenj Oct 20, 2023
117d1ae
refactor(gateway): Don't panic, return the error, and generalize the …
stevenj Oct 20, 2023
f07a4d5
refactor(gateway): generalize error response
stevenj Oct 20, 2023
8e398ab
docs(gateway): indexing ok here, slice already checked to have values
stevenj Oct 20, 2023
ab19189
refactor(gateway): Indexing is safe here, so note it.
stevenj Oct 20, 2023
90020db
refactor(gateway): don't panic, return an error. reduce size of func…
stevenj Oct 20, 2023
deff8a1
refactor(gateway): Purge metrics from legacy service. Unused and can…
stevenj Oct 20, 2023
d783069
refactor(gateway): remove unused rust files from EventDB directory
stevenj Oct 20, 2023
1d11b40
refactor(gateway): remove unused dependencies
stevenj Oct 20, 2023
6b0ec08
docs(gateway): Allow intentional panic for test code
stevenj Oct 20, 2023
8807d41
refactor(gateway): eliminate or notate why unwraps/expect are safe
stevenj Oct 20, 2023
df7b034
refactor(gateway): All lints are clean and restrictively applied
stevenj Oct 20, 2023
b2059af
refactor(gateway): remove unused dependencies from workspace cargo file
stevenj Oct 20, 2023
3026cda
refactor(gateway): restrict visibility of event_db to pub(crate) as i…
stevenj Oct 20, 2023
4bd314b
docs(gateway): root level fully documented
stevenj Oct 20, 2023
d044759
docs(gateway): state fully documented
stevenj Oct 20, 2023
d460fc6
docs(gateway): Don't worry about full docs for legacy service.
stevenj Oct 20, 2023
32403db
docs(gateway): Service top level fully documented
stevenj Oct 20, 2023
21652a4
docs(gateway): middleware docs complete
stevenj Oct 20, 2023
399dca9
docs(gateway): Fully documented the docs part of the service
stevenj Oct 20, 2023
34ad5a9
docs(gateway): common responses and module root fully documented
stevenj Oct 20, 2023
d195417
docs(gateway): Common objects now fully documented
stevenj Oct 20, 2023
e7c7571
docs(gateway): Api endpoint docs are complete
stevenj Oct 20, 2023
bb9a680
docs(gateway): DB Types fully documented
stevenj Oct 20, 2023
1dd5df6
docs(gateway): Queries partially documented
stevenj Oct 20, 2023
791dc90
docs(gateway): Everything that needs docs is documented
stevenj Oct 20, 2023
eb2d73f
feat(gateway): Initial CI and Cat-Gateway build ready for PR
stevenj Oct 20, 2023
1a982e9
feat(rust): Add recommended rust extensions for vscode, and rust sett…
stevenj Oct 20, 2023
2554ca3
docs(gateway): Fix spelling
stevenj Oct 20, 2023
906d5eb
ci(gateway): Use the proper versioned CI tooling from catalyst-ci
stevenj Oct 24, 2023
34750c3
Merge branch 'main' into feat/catalyst-gateway
stevenj Oct 24, 2023
98f2e4a
feat(docs): Docs WIP setup
stevenj Oct 26, 2023
b1eb247
docs(docs): Fix the docs so they use the latests docs-ci and are able…
stevenj Nov 2, 2023
f43fe65
docs(docs): fix spelling and markdown lint issues
stevenj Nov 2, 2023
08cc557
docs(docs): Update to use latest Cat-CI Docs and reduce replication
stevenj Nov 3, 2023
752571b
docs(docs): Fix the top level parts of the docs and remove test values
stevenj Nov 3, 2023
53d5e29
Merge branch 'main' into feat/voices-docs
stevenj Nov 3, 2023
65fdbf1
docs(docs): try and build and deploy docs to gh-pages
stevenj Nov 4, 2023
6c82887
docs(docs): fix spelling issue
stevenj Nov 4, 2023
a495586
docs(docs): Use proper docs action, and also add branch cleanup for b…
stevenj Nov 4, 2023
46f3418
Merge branch 'main' into feat/voices-docs
stevenj Nov 6, 2023
3e87a84
docs(docs): Use the published versions from Catalyst-CI
stevenj Nov 8, 2023
4ec5afa
docs(docs): Ensure we do not try and clean docs while building them.
stevenj Nov 8, 2023
ac80bd1
docs(docs): Ensure we don't try and build docs simultaneously, Don't …
stevenj Nov 8, 2023
b456f33
ci(mdlint): Use tagged CI versions for stability
stevenj Nov 8, 2023
086b7ab
ci(spelling): Use tagged CI versions for stability
stevenj Nov 8, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .config/dictionaries/project.dic
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
aarch
addrr
adminer
asyncio
auditability
BROTLI
cardano
Expand All @@ -26,6 +27,8 @@ Intellij
jetbrains
jorm
jormungandr
Jörmungandr
kroki
lcov
Leshiy
localizable
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/branch-delete-cleanup.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Branch Deleted

on: delete

concurrency:
group: "docs"
cancel-in-progress: false

jobs:
delete:
name: On branch deleted
if: github.event.ref_type == 'branch'
uses: input-output-hk/catalyst-ci/.github/workflows/[email protected]
30 changes: 30 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Docs

# cspell: words earthfile

on:
push:
tags-ignore:
- "*"

concurrency:
group: "docs"
cancel-in-progress: false

permissions:
id-token: write
contents: write
packages: write

jobs:
ci:
uses: input-output-hk/catalyst-ci/.github/workflows/[email protected]
with:
aws_role_arn: arn:aws:iam::332405224602:role/ci
aws_region: eu-central-1
ci_cli_version: 1.3.1
earthfile: ./docs
target: docs
secrets:
earthly_runner_address: ${{ secrets.EARTHLY_SATELLITE_ADDRESS }}
earthly_runner_secret: ${{ secrets.EARTHLY_RUNNER_SECRET }}
2 changes: 1 addition & 1 deletion .github/workflows/markdown-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ on:
jobs:
build:
name: Check markdown files formatted consistently
uses: input-output-hk/catalyst-ci/.github/workflows/markdown-check.yml@master
uses: input-output-hk/catalyst-ci/.github/workflows/markdown-check.yml@v2.0.6
2 changes: 1 addition & 1 deletion .github/workflows/spell-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ on:
jobs:
build:
name: Check spelling across all files
uses: input-output-hk/catalyst-ci/.github/workflows/spell-check.yml@master
uses: input-output-hk/catalyst-ci/.github/workflows/spell-check.yml@v2.0.6
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -78,3 +78,9 @@ $RECYCLE.BIN/
!/.vscode/launch.recommended.json
!/.vscode/settings.recommended.json
!/.vscode/tasks.recommended.json

# Local only development artefacts can get installed here.
/local

# We only want the actual document source from this directory.
/docs/site/
19 changes: 18 additions & 1 deletion .vscode/settings.recommended.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"editor.codeActionsOnSave": {
"source.organizeImports": true,
"source.sortMembers": true,
"source.fixAll": true
"source.fixAll": true,
"source.fixAll.markdownlint": true
},
"files.autoSave": "afterDelay",
"editor.formatOnType": true,
Expand Down Expand Up @@ -55,6 +56,22 @@
"-c",
"cargo lint-vscode"
],
"yaml.schemas": {
"https://squidfunk.github.io/mkdocs-material/schema.json": "mkdocs.yml"
},
"yaml.customTags": [
"!ENV scalar",
"!ENV sequence",
"tag:yaml.org,2002:python/name:materialx.emoji.to_svg",
"tag:yaml.org,2002:python/name:materialx.emoji.twemoji",
"tag:yaml.org,2002:python/name:pymdownx.superfences.fence_code_format"
],
"[markdown]": {
"editor.formatOnSave": true,
"editor.formatOnPaste": true,
"files.trimTrailingWhitespace": true,
"editor.defaultFormatter": "DavidAnson.vscode-markdownlint"
},
"rust-analyzer.rustfmt.extraArgs": [
"+nightly"
],
Expand Down
10 changes: 9 additions & 1 deletion Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,12 @@ spell-check:
LOCALLY

DO github.com/input-output-hk/catalyst-ci/earthly/cspell:v1.3.0+CSPELL_LOCALLY --src=$(echo ${PWD})


repo-docs:
# Create artifacts of extra files we embed inside the documentation when its built.
FROM scratch

WORKDIR /repo
COPY --dir *.md LICENSE-APACHE LICENSE-MIT .

SAVE ARTIFACT /repo repo
29 changes: 29 additions & 0 deletions docs/Earthfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Set the Earthly version to 0.7
VERSION 0.7

# cspell: words mkdocs runable

# Copy all the source we need to build the docs
src:
# Common src setup
DO github.com/input-output-hk/catalyst-ci/earthly/docs:v2.0.5+SRC

# Now copy into that any artifacts we pull from the builds.
COPY --dir ../+repo-docs/repo /docs/includes

# Build the docs here.
docs:
FROM +src

DO github.com/input-output-hk/catalyst-ci/earthly/docs:v2.0.5+BUILD

# Make a locally runable container that can serve the docs.
local:
# Build a self contained service to show built docs locally.
DO github.com/input-output-hk/catalyst-ci/earthly/docs:v2.0.5+PACKAGE

# Copy the static pages into the container
COPY +docs/ /usr/share/nginx/html

# This is a local only image, we do not publish it.
SAVE IMAGE cat-voices-docs:latest
41 changes: 41 additions & 0 deletions docs/mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
INHERIT: std-theme.yml

# cspell: words cips

# Project Information
site_name: Project Catalyst - Catalyst Voices
site_url: https://input-output-hk.github.io/catalyst-docs

# Repository
repo_name: input-output-hk/catalyst-voices
repo_url: https://github.com/input-output-hk/catalyst-voices

# Page tree
nav:
- Home: index.md
- Getting Started:
- Getting Started: getting-started/index.md
- Quick Start: getting-started/quick-start.md
- Advanced: getting-started/advanced.md
- Development: getting-started/development.md
- Monorepo Architecture:
- Monorepo Architecture: monorepo-architecture/index.md
- Catalyst Standards:
- Catalyst Standards: catalyst-standards/index.md
- Draft CIPs:
- Draft CIPs: catalyst-standards/draft-cips/index.md
- Role Registration: catalyst-standards/draft-cips/role-registration/cip-xxxx.md
- RBAC CIP30 Extension: catalyst-standards/draft-cips/rbac-cip30-extension/cip-xxxx.md
- Catalyst Voting CIP30 Extension: catalyst-standards/draft-cips/catalyst-vote-signing-cip30-extension/cip-xxxx.md
- Catalyst Ballot Formats:
- Catalyst Ballot Formats: catalyst-standards/ballot/index.md
- Catalyst V1 Ballot: catalyst-standards/ballot/catalyst-v1.md
- Catalyst V2 Ballot: catalyst-standards/ballot/catalyst-v2.md
- Appendix:
- Appendix: appendix/index.md
- Important Information:
- Important Information: appendix/important/index.md
- Contributing: appendix/important/contributing.md
- Code of Conduct: appendix/important/coc.md
- Security: appendix/important/security.md
- License: appendix/important/license.md
7 changes: 7 additions & 0 deletions docs/src/appendix/important/coc.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
icon: material/file-sign
---

<!-- markdownlint-disable first-line-h1 -->
<!-- markdownlint-disable required-headers -->
{{ include_file('includes/repo/CODE_OF_CONDUCT.md') }}
7 changes: 7 additions & 0 deletions docs/src/appendix/important/contributing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
icon: material/pen-plus
---

<!-- markdownlint-disable first-line-h1 -->
<!-- markdownlint-disable required-headers -->
{{ include_file('includes/repo/CONTRIBUTING.md') }}
5 changes: 5 additions & 0 deletions docs/src/appendix/important/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
icon: material/alert-decagram-outline
---

# Important
19 changes: 19 additions & 0 deletions docs/src/appendix/important/license.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
icon: material/license
---

# License

<!-- markdownlint-disable max-one-sentence-per-line -->

??? note "Apache 2 License"

```text
{{ include_file('includes/repo/LICENSE-APACHE', 0, -1, 8) }}
```

??? note "MIT License"

```text
{{ include_file('includes/repo/LICENSE-MIT', 0, -1, 8) }}
```
7 changes: 7 additions & 0 deletions docs/src/appendix/important/security.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
icon: material/security
---

<!-- markdownlint-disable first-line-h1 -->
<!-- markdownlint-disable required-headers -->
{{ include_file('includes/repo/SECURITY.md') }}
7 changes: 7 additions & 0 deletions docs/src/appendix/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
icon: material/file-document-plus-outline
---

# Appendix

The appendix contains collections of extra information and examples relevant to Catalyst Voices.
6 changes: 6 additions & 0 deletions docs/src/catalyst-standards/ballot/catalyst-v1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
icon: material/ballot
---

<!-- markdownlint-disable MD025-->
# Catalyst Ballot Format V1
6 changes: 6 additions & 0 deletions docs/src/catalyst-standards/ballot/catalyst-v2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
icon: material/ballot-outline
---

<!-- markdownlint-disable MD025-->
# Catalyst Ballot Format V2
6 changes: 6 additions & 0 deletions docs/src/catalyst-standards/ballot/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
icon: material/ballot-recount-outline
---

<!-- markdownlint-disable MD025-->
# Catalyst Ballot Formats
2 changes: 2 additions & 0 deletions docs/src/catalyst-standards/draft-cips/.meta.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
status: new
template: cip.html
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
icon: material/vote-outline
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
---
CIP: /?
Title: Role based Access Control Registration
Category: MetaData
Status: Proposed
Authors:
- Steven Johnson<[email protected]>
Implementors: []
Discussions:
- https://github.com/cardano-foundation/cips/pulls/?
Created: 2023-10-24
License: CC-BY-4.0
---

<!-- Existing categories:

- Meta | For meta-CIPs which typically serves another category or group of categories.
- Wallets | For standardization across wallets (hardware, full-node or light).
- Tokens | About tokens (fungible or non-fungible) and minting policies in general.
- Metadata | For proposals around metadata (on-chain or off-chain).
- Tools | A broad category for ecosystem tools not falling into any other category.
- Plutus | Changes or additions to Plutus
- Ledger | For proposals regarding the Cardano ledger (including Reward Sharing Schemes)
- Catalyst | For proposals affecting Project Catalyst / the Jormungandr project

-->

<!-- markdownlint-disable MD025-->
# Role Based Access Control Registration

## Abstract
<!-- A short (\~200 word) description of the proposed solution and the technical issue being addressed. -->

## Motivation: why is this CIP necessary?
<!-- A clear explanation that introduces the reason for a proposal, its use cases and stakeholders.
If the CIP changes an established design then it must outline design issues that motivate a rework.
For complex proposals, authors must write a Cardano Problem Statement (CPS) as defined in CIP-9999
and link to it as the `Motivation`. -->

## Specification
<!-- The technical specification should describe the proposed improvement in sufficient technical detail.
In particular, it should provide enough information that an implementation can be performed solely on the basis
of the design in the CIP.
This is necessary to facilitate multiple, interoperable implementations.
This must include how the CIP should be versioned.
If a proposal defines structure of on-chain data it must include a CDDL schema in it's specification.-->

## Rationale: how does this CIP achieve its goals?
<!-- The rationale fleshes out the specification by describing what motivated the design and what led to
particular design decisions.
It should describe alternate designs considered and related work.
The rationale should provide evidence of consensus within the community and discuss significant objections
or concerns raised during the discussion.

It must also explain how the proposal affects the backward compatibility of existing solutions when applicable.
If the proposal responds to a CPS, the 'Rationale' section should explain how it addresses the CPS,
and answer any questions that the CPS poses for potential solutions.
-->

## Path to Active

### Acceptance Criteria
<!-- Describes what are the acceptance criteria whereby a proposal becomes 'Active' -->

### Implementation Plan
<!-- A plan to meet those criteria. Or `N/A` if not applicable. -->

## Copyright
<!-- The CIP must be explicitly licensed under acceptable copyright terms. -->
6 changes: 6 additions & 0 deletions docs/src/catalyst-standards/draft-cips/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
icon: material/pencil-box-multiple-outline
---

<!-- markdownlint-disable MD025-->
# Draft CIPs
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
icon: material/account-check
Loading
Loading