From 960c5ad0d5d02f762357c585bdefad513098b6ad Mon Sep 17 00:00:00 2001 From: ieQu1 <99872536+ieQu1@users.noreply.github.com> Date: Mon, 14 Mar 2022 11:05:07 +0100 Subject: [PATCH] ci: Run spellcheck --- .github/workflows/build_slim_packages.yaml | 26 ++++++++++++++++++ .github/workflows/spelling.yml | 32 ---------------------- apps/emqx_conf/src/emqx_conf_schema.erl | 6 ++-- 3 files changed, 29 insertions(+), 35 deletions(-) delete mode 100644 .github/workflows/spelling.yml diff --git a/.github/workflows/build_slim_packages.yaml b/.github/workflows/build_slim_packages.yaml index ceefb1655..0a43e46ad 100644 --- a/.github/workflows/build_slim_packages.yaml +++ b/.github/workflows/build_slim_packages.yaml @@ -84,6 +84,10 @@ jobs: with: name: ${{ matrix.profile}}-${{ matrix.otp }}-${{ matrix.os }} path: _packages/${{ matrix.profile}}/*.tar.gz + - uses: actions/upload-artifact@v2 + with: + name: "${{ matrix.profile }}_schema_dump" + path: _build/*/lib/emqx_dashboard/priv/www/static/schema.json windows: runs-on: windows-2019 @@ -204,3 +208,25 @@ jobs: with: name: macos path: _packages/**/*.tar.gz + + spellcheck: + needs: linux + strategy: + matrix: + profile: + - emqx-edge + - emqx + - emqx-enterprise + runs-on: ubuntu-20.04 + container: "ghcr.io/iequ1/emqx-schema-validate:0.2.1" + steps: + - uses: actions/download-artifact@v2 + name: Download schema dump + with: + name: "${{ matrix.profile }}_schema_dump" + path: /tmp/ + - name: Run spellcheck + run: | + cd /LanguageTool + bash start.sh > /dev/null & + ./emqx_schema_validate /tmp/${{ matrix.profile }}/lib/emqx_dashboard/priv/www/static/schema.json diff --git a/.github/workflows/spelling.yml b/.github/workflows/spelling.yml deleted file mode 100644 index 0b9fb1b24..000000000 --- a/.github/workflows/spelling.yml +++ /dev/null @@ -1,32 +0,0 @@ -name: Spellcheck - -on: - workflow_run: - workflows: [Build slim packages] - types: - - completed - -jobs: - spellcheck_schema: - runs-on: ubuntu-latest - - strategy: - fail-fast: true - matrix: - profile: - - emqx-enterprise - otp: - - 24.2.1-1 - os: - - ubuntu20.04 - steps: - - uses: actions/checkout@v2 - - uses: dawidd6/action-download-artifact@v2 - with: - name: ${{ matrix.profile }}-${{ matrix.otp }}-${{ matrix.os }} - workflow: build_slim_packages.yaml - path: . - - name: Run spellcheck - run: | - tar zxf *.tar.gz - find . -name schema.json -exec scripts/spellcheck \{\} \; diff --git a/apps/emqx_conf/src/emqx_conf_schema.erl b/apps/emqx_conf/src/emqx_conf_schema.erl index 2bcbe9d38..b9157f43e 100644 --- a/apps/emqx_conf/src/emqx_conf_schema.erl +++ b/apps/emqx_conf/src/emqx_conf_schema.erl @@ -306,10 +306,10 @@ fields("node") -> desc => """ Path to the persistent data directory. -Possible auto-created sub-directories are: +Possible auto-created subdirectories are: - `mnesia/\`: EMQX's built-in database directory. For example, `mnesia/emqx@127.0.0.1`. - There should be only one such sub directory. + There should be only one such subdirectory. Meaning, in case the node is to be renamed (to e.g. `emqx@10.0.1.1`), the old dir should be deleted first. - `configs`: Generated configs at boot time, and cluster/local override configs. @@ -433,7 +433,7 @@ to rlog. List of core nodes that the replicant will connect to.
Note: this parameter only takes effect when the backend is set to rlog and the role is set to replicant.
-This values needs to be defined for manual or static cluster discovery mechanisms.
+This value needs to be defined for manual or static cluster discovery mechanisms.
If an automatic cluster discovery mechanism is being used (such as etcd), there is no need to set this value. """