Skip to content

Commit 442da1c

Browse files
committed
chore: enable mkdocs-material-linter
1 parent b3dd035 commit 442da1c

File tree

6 files changed

+18
-17
lines changed

6 files changed

+18
-17
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ jobs:
5353
uses: opalmedapps/.github/.github/workflows/markdownlint.yaml@main
5454
with:
5555
semantic-linebreak: false
56+
mkdocs-material-linter: true
5657

5758
build:
5859
runs-on: ubuntu-latest

.markdownlint.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,11 @@ max-one-sentence-per-line:
3939
- "!!"
4040
- "??"
4141
- "vs"
42+
43+
# mkdocs-material-linter
44+
# see: https://github.com/mensfeld/mkdocs-material-linter?tab=readme-ov-file#provided-rules
45+
material-meta-tags: false
46+
# disabled due to code blocks with more than 3 backticks
47+
# https://github.com/mensfeld/mkdocs-material-linter/issues/24
48+
material-blank-lines-spacing: false
49+
material-code-block-syntax: false

docs/development/best_practices/best_practices.md

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -99,9 +99,7 @@ This can be done before making the change, after making the change or during.
9999
The tests should not only cover one (successful) code path but the goal is to achieve branch coverage and test for different inputs and error conditions.
100100
While you design your code, think about all the different ways this could be called, what should be considered and what could potentially go wrong (and test for those).
101101

102-
!!! todo "TODO/TBD"
103-
104-
Integration tests, UI tests, smoke tests, …?
102+
<!-- TODO: Integration tests, UI tests, smoke tests, …? -->
105103

106104
## Continuous Integration (CI) and Delivery (CD)
107105

@@ -175,9 +173,7 @@ This is easier to accomplish the smaller the changes are that a commit adds.
175173
In general, there are explicit merges, fast-forward merges and “squash on merge”.
176174
A great visualization of these is provided in the article [Pull Request Merge Strategies: The Great Debate - Atlassian Developer Blog](https://blog.developer.atlassian.com/pull-request-merge-strategies-the-great-debate/) and a debate on pros and cons can be found at [Git team workflows: merge or rebase? | Atlassian Git Tutorial](https://www.atlassian.com/git/articles/git-team-workflows-merge-or-rebase)
177175

178-
!!! todo "TBD"
179-
180-
Use squash merge vs. merge commit
176+
<!-- TODO: Use squash merge vs. merge commit -->
181177

182178
### Merging Resources
183179

docs/development/best_practices/diagrams.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ It is also possible to define a standalone file and include it within a page as
7171

7272
The advantage of putting a diagram in its dedicated file is that the diagram is separated and can be automatically processed for other purposes.
7373

74-
!!! important
74+
!!! info
7575

7676
The plugin requires the full path within the repository to be specified.
7777
For this reason the recommendation is to place all diagrams within the directory under `docs/diagrams/`.

docs/development/guides/python.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,3 @@ If not already done by an automatic dependency checker (see above), dependencies
4040
## Django Migrations
4141

4242
When writing migrations in Django that require custom Python code to be executed (using the RunPython migration), forward and backward code needs to be provided to ensure that the database can be migrated in both directions without encountering any errors.
43-
44-
!!! todo "TBD"
45-
46-
Have a checker check for this (pylint has a plugin)

docs/install/integration.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ Depending on which Opal application is providing the endpoint, the authenticatio
2525
_OpalAdmin_ is built using [Django](https://www.djangoproject.com/) and uses the [Django REST Framework](https://www.django-rest-framework.org/) which provides support for token-based authentication.
2626
During the setup of the Opal PIE, an administrator can issue the hospital data system an API token which should be appended to the headers section of all API requests to _OpalAdmin_, for example:
2727

28-
```bash
28+
```shell
2929
curl --location 'https://<host>/api/' \
3030
--header 'Content-Type: application/json' \
3131
--header 'Authorization: Token <token>'
@@ -38,15 +38,15 @@ _Legacy OpalAdmin_ will respond to successful calls at this endpoint with an arr
3838
Also included in the response will be a session/cookie string that should be appended to the headers of future requests to protected endpoints.
3939
For example:
4040

41-
```bash
41+
```shell
4242
curl --location 'https://<host>/opalAdmin/user/system-login' \
4343
--header 'Content-Type: application/x-www-form-urlencoded' \
4444
--data 'username=<username>&password=<password>'
4545
```
4646

4747
Handle the response and append the cookie string to the next request:
4848

49-
```bash
49+
```shell
5050
curl --location 'https://<host>/opalAdmin/patient/get/patient-exist' \
5151
--header 'Content-Type: application/x-www-form-urlencoded' \
5252
--header 'Cookie: sessionId=<sessionid>' \
@@ -61,20 +61,20 @@ You can use "Basic Authentication" at the reverse proxy level (`traefik`).
6161
Use the `htpasswd` utility to create a bcrypt hash, pressing enter when given the opportunity to enter an additional password for the hash.
6262
For example:
6363

64-
```bash
64+
```shell
6565
echo $(htpasswd -nB integration_engine) | sed -e s/\\$/\\$\\$/g
6666
```
6767

6868
The username and password used in the Basic Authentication header request from the hospital integration engine needs to be base64 encoded.
6969
So:
7070

71-
```bash
71+
```shell
7272
echo -n 'integration_engine:<hash>' | base64
7373
```
7474

7575
The base64 representation of the username:password can then be added as an authorization header in the destination connector settings for our labs channel, prepended by the string `Basic` to indicate the auth type.
7676

77-
```bash
77+
```shell
7878
--header 'Authorization Basic <value>'
7979
```
8080

0 commit comments

Comments
 (0)