This is an automated email from the ASF dual-hosted git repository.

membphis pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-website.git


The following commit(s) were added to refs/heads/master by this push:
     new 6548a1d  feat(CI): add a GitHub Action to lint the Markdown (#107)
6548a1d is described below

commit 6548a1d67b513c6681507fb1f576d42f54a9aa6d
Author: John Bampton <jbamp...@users.noreply.github.com>
AuthorDate: Wed Dec 16 20:22:51 2020 +1000

    feat(CI): add a GitHub Action to lint the Markdown (#107)
    
    - remove trailing spaces from YAML files
    - add a `.markdownlint.yml` config file
    - lint Markdown for rule MD047/single-trailing-newline. Files should end 
with a single newline character
    
    
https://github.com/DavidAnson/markdownlint/blob/main/doc/Rules.md#md047---files-should-end-with-a-single-newline-character
---
 .github/workflows/deploy.yml           |  4 ++--
 .github/workflows/lint.yml             | 16 ++++++++++++++++
 .markdownlint.yml                      | 20 ++++++++++++++++++++
 docs/subscribe-guide.md                |  2 +-
 website/blog/2020-08-22-new-website.md |  2 +-
 5 files changed, 40 insertions(+), 4 deletions(-)

diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
index 3eaff34..cac155a 100644
--- a/.github/workflows/deploy.yml
+++ b/.github/workflows/deploy.yml
@@ -31,7 +31,7 @@ jobs:
 
     - name: Build
       run: cd website && yarn && yarn build
-      
+
     - name: Copy files
       run: |
         cd website/build/apisix-website
@@ -42,7 +42,7 @@ jobs:
         find . -type f -name "*.html" -print0 | xargs -0 sed -i -e 
's/src="\.\.\/images/src="https:\/\/apisix\.apache\.org\/images/g'
         find . -type f -name "*.html" -print0 | xargs -0 sed -i -e 
's/src="\.\/images/src="https:\/\/apisix\.apache\.org\/images/g'
         find . -type f -name "*.html" -print0 | xargs -0 sed -i -e 
's/src="images/src="https:\/\/apisix\.apache\.org\/images/g'
-      
+
     - name: GitHub Pages
       uses: crazy-max/ghaction-github-pages@v2.0.1
       with:
diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml
new file mode 100644
index 0000000..3a283bb
--- /dev/null
+++ b/.github/workflows/lint.yml
@@ -0,0 +1,16 @@
+name: ❄️ Lint
+
+on: [pull_request]
+
+jobs:
+  markdownlint:
+    name: 🍇 Markdown
+    runs-on: ubuntu-latest
+    steps:
+      - uses: actions/checkout@v2
+      - name: 🚀 Use Node.js
+        uses: actions/setup-node@v1
+        with:
+          node-version: '12.x'
+      - run: npm install -g markdownlint-cli@0.25.0
+      - run: markdownlint '**/*.md' --ignore node_modules
diff --git a/.markdownlint.yml b/.markdownlint.yml
new file mode 100644
index 0000000..64ebbc0
--- /dev/null
+++ b/.markdownlint.yml
@@ -0,0 +1,20 @@
+# MD013 Line length
+MD013: false
+
+# MD014 Dollar signs used before commands without showing output
+MD014: false
+
+# MD026/no-trailing-punctuation Trailing punctuation in heading
+MD026: false
+
+# MD029/ol-prefix Ordered list item prefix
+MD029: false
+
+# MD034/no-bare-urls
+MD034: false
+
+# MD040/fenced-code-language
+MD040: false
+
+# MD041/first-line-heading/first-line-h1 First line in file should be a top 
level heading
+MD041: false
diff --git a/docs/subscribe-guide.md b/docs/subscribe-guide.md
index d1df9d6..9b9ad5a 100644
--- a/docs/subscribe-guide.md
+++ b/docs/subscribe-guide.md
@@ -11,4 +11,4 @@ During the process of using Apache APISIX, if there has any 
problems, suggestion
 
 3. Receive the Welcome e-mail. After finishing the two steps above, an e-mail 
with the subject of WELCOME to d...@apisix.apache.org will be sent to your 
e-mail address. Until now, you have succeeded in subscribing Apache APISIX 
mailing-list.
 
-4. Until now, you can interact with community by your subscribed email or 
track email conversations by Archived email list.
\ No newline at end of file
+4. Until now, you can interact with community by your subscribed email or 
track email conversations by Archived email list.
diff --git a/website/blog/2020-08-22-new-website.md 
b/website/blog/2020-08-22-new-website.md
index d915f5d..0d69854 100644
--- a/website/blog/2020-08-22-new-website.md
+++ b/website/blog/2020-08-22-new-website.md
@@ -9,4 +9,4 @@ We are just refactored out website for Apache APISIX by using 
[docusaurus](https
 
 <!--truncate-->
 
-Tip: all contents will be hidden after the `<!--truncate-->` tag in blog list.
\ No newline at end of file
+Tip: all contents will be hidden after the `<!--truncate-->` tag in blog list.

Reply via email to