mirror of
https://github.com/langgenius/dify-docs-archived.git
synced 2026-06-30 20:37:57 -04:00
Feat/update ai docs lang check action (#510)
* Feat: update auto lang check script * Feat: update auto lang check script, enable api check * Feat: update github auto check * Feat: update github auto check file * Feat: update github auto check file * Feat: hide secret key * Feat: test app key update * Feat: hide app key * Feat: add automatic file deletion
This commit is contained in:
@@ -36,9 +36,13 @@ jobs:
|
||||
|
||||
# Check if output contains ❌ symbol
|
||||
if echo "$output" | grep -q "❌"; then
|
||||
# Clean up temporary file before exit
|
||||
rm -f ./lang-check/commit-*.txt
|
||||
echo "Check failed, PR cannot be merged"
|
||||
exit 1 # Non-zero exit code will fail the Action
|
||||
else
|
||||
# Clean up temporary file before exit
|
||||
rm -f ./lang-check/commit-*.txt
|
||||
echo "Check passed"
|
||||
exit 0 # Zero exit code indicates Action success
|
||||
fi
|
||||
@@ -6,6 +6,7 @@ venv/
|
||||
ENV/
|
||||
env.bak/
|
||||
venv.bak/
|
||||
lang-check/.env
|
||||
|
||||
# Pyre type checker
|
||||
.pyre/
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
DIFY_API_KEY=your_api_key_here
|
||||
@@ -0,0 +1,14 @@
|
||||
|
||||
<start---lang-check/lang-check/test.md---start>
|
||||
# 一个文档
|
||||
|
||||
不加xxx中英文空格
|
||||
|
||||
- xxxx
|
||||
|
||||
https://langgenius.feishu.cn/
|
||||
|
||||
测试31231三大
|
||||
|
||||
<end---/lang-check/test.md---end>
|
||||
|
||||
@@ -55,7 +55,7 @@ if [ "$debug_mode" = true ]; then
|
||||
fi
|
||||
|
||||
# 设置 API 密钥和其他常量
|
||||
api_key="app-jlPYjfHIRLXbSoy9gw3ZOyXw"
|
||||
api_key="${DIFY_API_KEY}"
|
||||
user=$(git config user.name) # 获取 Git 配置中的用户名
|
||||
|
||||
# 如果获取失败,使用默认值
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
# 一个文档
|
||||
|
||||
不加xxx中英文空格
|
||||
|
||||
- xxxx
|
||||
|
||||
https://langgenius.feishu.cn/
|
||||
Reference in New Issue
Block a user