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

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


The following commit(s) were added to refs/heads/master by this push:
     new 0d81f15d838 Add deadlink check (#286)
0d81f15d838 is described below

commit 0d81f15d838f2efe5cb35306391e645d77159b3e
Author: Calvin Kirs <[email protected]>
AuthorDate: Tue Aug 8 18:10:31 2023 +0800

    Add deadlink check (#286)
---
 .dlc.json                            | 19 ++++++++++++++++++
 .github/workflows/deadlink-check.yml | 38 ++++++++++++++++++++++++++++++++++++
 2 files changed, 57 insertions(+)

diff --git a/.dlc.json b/.dlc.json
new file mode 100644
index 00000000000..7b5e133479b
--- /dev/null
+++ b/.dlc.json
@@ -0,0 +1,19 @@
+{
+        "ignorePatterns": [
+          {
+            "pattern": "^http://localhost";
+          },
+          {
+            "pattern": "^https://twitter.com*";
+          }
+        ],
+        "timeout": "10s",
+        "retryOn429": true,
+        "retryCount": 10,
+        "fallbackRetryDelay": "1000s",
+        "aliveStatusCodes": [
+          200,
+          401,
+          403
+        ]
+      }
\ No newline at end of file
diff --git a/.github/workflows/deadlink-check.yml 
b/.github/workflows/deadlink-check.yml
new file mode 100644
index 00000000000..cd5d27f8b1b
--- /dev/null
+++ b/.github/workflows/deadlink-check.yml
@@ -0,0 +1,38 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+name: Dead Link Checker
+
+on:
+  pull_request:
+  schedule:
+    - cron: '0 18 * * *'  # TimeZone: UTC 0
+
+concurrency:
+  group: dlc-${{ github.event.pull_request.number || github.ref }}
+  cancel-in-progress: true
+
+jobs:
+  CheckDeadLinks:
+    runs-on: ubuntu-latest
+    timeout-minutes: 30
+    steps:
+      - uses: actions/checkout@v3
+      - run: sudo npm install -g [email protected]
+      - run: |
+          for file in $(find . -name "*.md"); do
+            markdown-link-check -c .dlc.json -q "$file"
+          done
\ No newline at end of file


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to