-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (37 loc) · 1.38 KB
/
Copy pathrun-tutorial.yml
File metadata and controls
45 lines (37 loc) · 1.38 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# ============================================================================
# 在干净的 Linux 环境中验证教程可完整运行
# ----------------------------------------------------------------------------
# 说明:本工作流默认只在「手动触发」时运行,不会在每次 push 时自动跑,
# 避免因 R 包安装耗时/网络波动产生无关的红叉。
# 需要时:GitHub 仓库 → Actions → Run tutorial → Run workflow
# ============================================================================
name: Run tutorial
on:
workflow_dispatch:
jobs:
run-tutorial:
runs-on: ubuntu-latest
steps:
- name: 检出代码
uses: actions/checkout@v4
- name: 安装 R
uses: r-lib/actions/setup-r@v2
with:
r-version: "release"
use-public-rspm: true
- name: 安装系统依赖
run: |
sudo apt-get update
sudo apt-get install -y \
libcurl4-openssl-dev libssl-dev libxml2-dev \
libfontconfig1-dev libfreetype6-dev libharfbuzz-dev libfribidi-dev \
fonts-noto-cjk
- name: 安装 R 包
run: Rscript install_deps.R
- name: 运行完整教程
run: Rscript run_all.R
- name: 上传运行产物
uses: actions/upload-artifact@v4
with:
name: tutorial-output
path: output/