首页 新闻 会员 周边

如何消除 github workflow atctions 中的 warning

0
悬赏园豆:30 [已解决问题] 解决于 2024-03-12 18:18

下面这个很简单的 github workflow 清单文件

name: CI

on:
  push:
    branches: [ "main" ]
  pull_request:
    branches: [ "main" ]

jobs:
  build-test:
    runs-on: ubuntu-latest
    container: mcr.microsoft.com/dotnet/sdk:8.0

    steps:
    - name: Checkout
      uses: actions/checkout@v3
    - name: Build
      run: dotnet build -c Release
    - name: Test
      run: dotnet test -c Release

运行时却出现下面的警告

Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.

请问如何消除这个警告?

dudu的主页 dudu | 高人七级 | 园豆:30994
提问于:2024-03-12 18:05
< >
分享
最佳答案
0

actions/checkout@v3 改成 actions/checkout@v4 就可以了

dudu | 高人七级 |园豆:30994 | 2024-03-12 18:18
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册