Skip to content

Commit

Permalink
Docs linter on Documentation Markdown files only (#456)
Browse files Browse the repository at this point in the history
* docs linter only on markdown files

* add gh runner top level permissions

* test docs linter within docs

* cleanup

* linter works so do as it says

* test if ignore files works

* cleanup
  • Loading branch information
louiseschmidtgen committed May 31, 2024
1 parent 754f8e0 commit 6c02df4
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 19 deletions.
36 changes: 19 additions & 17 deletions .github/workflows/markdown.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,26 @@ name: "Docs: Markdown lint"

on: [push, pull_request]

permissions:
contents: read

jobs:
markdown-lint:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: tj-actions/changed-files@v44
id: changed-files
with:
files: |
docs/src/snap/**
docs/src/charm/**
- uses: DavidAnson/markdownlint-cli2-action@v16
if: steps.changed-files.outputs.any_changed == 'true'
with:
config: 'docs/src/.markdownlint.json'
globs: ${{ steps.changed-files.outputs.all_changed_files }}
separator: ","


- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: tj-actions/changed-files@v44
id: changed-markdown-files
with:
files: |
docs/**/*.md
files_ignore: |
docs/src/_parts/**
- uses: DavidAnson/markdownlint-cli2-action@v16
if: steps.changed-markdown-files.outputs.any_changed == 'true'
with:
config: "docs/src/.markdownlint.json"
globs: ${{ steps.changed-markdown-files.outputs.all_changed_files }}
separator: ","
6 changes: 4 additions & 2 deletions docs/src/snap/explanation/about.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ maintain and easy to upgrade.

## What else comes with it?

In addition to the upstream Kubernetes services, Canonical Kubernetes also includes:
In addition to the upstream Kubernetes services,
Canonical Kubernetes also includes:

- a DNS service for the node
- a CNI for the node/cluster
Expand All @@ -30,7 +31,8 @@ In addition to the upstream Kubernetes services, Canonical Kubernetes also inclu

The Canonical Kubernetes snap can be installed on a Linux OS, wherever it may
be: run it in several local containers or VMs for example, or use it on
public/private cloud instances. For deploying with [Juju], a machine [charm] to deploy
public/private cloud instances.
For deploying with [Juju], a machine [charm] to deploy
the snap is also available.

## Can I use it to make a cluster?
Expand Down

0 comments on commit 6c02df4

Please sign in to comment.