Files
gitea_actions/.gitea/workflows/test.yml
编码猿 7acf000234
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 6s
33344
2025-10-05 02:16:12 +08:00

44 lines
1.5 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 工作流名称
name: Gitea Actions Demo
# 运行名称在Gitea界面中显示的具体运行名称支持动态变量
run-name: ${{ gitea.actor }} 正在测试 Gitea Actions 🚀
# 触发条件当发生push事件时触发
on: [push]
# 作业定义
jobs:
# 作业名称探索Gitea Actions
Explore-Gitea-Actions:
# 运行环境在ubuntu-latest标签的runner上运行
runs-on: ubuntu-latest
# 步骤序列
steps:
# 步骤1输出事件信息
- run: echo "🎉 该作业由 ${{ gitea.event_name }} 事件自动触发。"
# 步骤2输出运行环境信息
- run: echo "🐧 该作业现在正在Gitea托管的 ${{ runner.os }} 服务器上运行!"
# 步骤3输出分支和仓库信息
- run: echo "🔎 您的分支名称是 ${{ gitea.ref }},您的仓库是 ${{ gitea.repository }}。"
# 步骤4检出仓库代码具有名称的步骤
- name: 检出仓库代码
uses: actions/checkout@v4
# 步骤5输出克隆完成信息
- run: echo "💡 ${{ gitea.repository }} 仓库已克隆到runner。"
# 步骤6准备测试提示
- run: echo "🖥️ 工作流现已准备好在runner上测试您的代码。"
# 步骤7列出仓库文件多行命令
- name: 列出仓库中的文件
run: |
ls ${{ gitea.workspace }}
# 步骤8输出作业状态
- run: echo "🍏 此作业的状态是 ${{ job.status }}。"