英文:
Update your actions to run on Node 16 instead of Node 12 on GitHub
问题
While I've seen it claimed that this question was answered elsewhere, it was not. 我看到有人声称这个问题在其他地方得到了解答,但实际上并没有。
I am getting a complaint about using Node 12 instead of Node 16 in this code: 我收到了有关在此代码中使用Node 12而不是Node 16的投诉:
There is no documentation that says exactly what is the difference between Node 12 and Node 16 (at least not in the provided links.) 没有文档明确说明Node 12和Node 16之间的区别(至少在提供的链接中没有)。
The supposed answer on StackExchange (https://stackoverflow.com/questions/75061837/github-actions-node-js-12-actions-are-deprecated-although-i-upgraded-everyt) says something about run
vs runs
. StackExchange上的所谓答案(https://stackoverflow.com/questions/75061837/github-actions-node-js-12-actions-are-deprecated-although-i-upgraded-everyt)提到了run
与runs
之间的差异。
Do I just change the word run
to runs
in the last command? 我只需将最后一个命令中的单词run
更改为runs
吗?
英文:
While I've seen it claimed that this question was answered elsewhere, it was not. I am getting a complaint about using Node 12 instead of Node 16 in this code:
There is no documentation that says exactly what is the difference between Node 12 and Node 16 (at least not in the provided links.) The
lint-flake8:
runs-on: ubuntu-latest
name: flake8
strategy:
fail-fast: false
matrix:
python-version: [3.8]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{matrix.python-version}}
uses: actions/setup-python@v2
with:
python-version: ${{matrix.python-version}}
- name: flake8
continue-on-error: false
run: |
pip install flake8
flake8 pyuvm tests/pytests
The supposed answer on StackExchange (https://stackoverflow.com/questions/75061837/github-actions-node-js-12-actions-are-deprecated-although-i-upgraded-everyt) says something about run
vs runs
.
Do I just change the word run
to runs
in the last command?
答案1
得分: 4
You probably need to upgrade the actions to the latest version:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
Both now have a much newer version.
The easiest way to stay current is to enable Dependabot for GitHub Actions.
Then add a file to your repo to enable Dependabot (/.github/dependabot.yml
) for actions:
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
You then get updates that keep you up to date automatically:
英文:
You probably need to upgrade the actions to the latest version:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
Both now have a much newer version.
The easiest way to stay current is to enable Dependabot for GitHub Actions.
Then add a file to your repo to enable dependabot (/.github/dependabot.yml
) for actions:
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
You then get updates that keep you up to date automatically:
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论