gitea-action-test/.github/workflows/zzz.yml
LIRUI 90670f6666
Some checks failed
获取完整内核版本 / clone_with_proxy (push) Failing after 35s
1028
2024-10-28 15:54:39 +08:00

36 lines
1005 B
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: test
on:
# push:
# branches:
# - main
jobs:
# 第一个 Job检出代码并上传
checkout_and_upload:
runs-on: ubuntu-latest
steps:
- name: 🛒 检出代码
uses: https://git.aoun.ltd/actions/checkout@v4
- name: 📦 上传代码作为工件
uses: actions/upload-artifact@v3
with:
name: source-code # 工件名称
path: . # 上传当前目录的所有内容
# 第二个 Job下载工件并使用代码
download_and_use:
runs-on: ubuntu-latest
needs: checkout_and_upload # 确保在第一个 Job 完成后再运行
steps:
- name: 📥 下载代码工件
uses: actions/download-artifact@v3
with:
name: source-code # 下载第一个 Job 中的工件
- name: 🔍 使用下载的代码
run: |
ls -la # 确认文件是否已成功下载
# 这里可以继续使用检出的代码进行构建或其他操作