【发布时间】:2020-03-31 02:13:11
【问题描述】:
我有一个GitHub Repo,它有一个简单的 GitHub Actions 工作流程:
name: CI
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Run a one-line script
run: echo Hello, world!
- name: Run a multi-line script
run: |
echo Add other actions to build,
echo test, and deploy your project.
pip install twine
twine --help
当我运行它时,它安装了 twine,但是fails 运行它,说找不到命令:
...
Successfully installed Pygments-2.5.2 bleach-3.1.0 certifi-2019.11.28 chardet-3.0.4 docutils-0.15.2 idna-2.8 pkginfo-1.5.0.1 readme-renderer-24.0 requests-2.22.0 requests-toolbelt-0.9.1 setuptools-42.0.2 six-1.13.0 tqdm-4.40.0 twine-1.15.0 urllib3-1.25.7 webencodings-0.5.1
/home/runner/work/_temp/1643cb1d-8b12-4aa8-8e1d-bd5bba60fd5b.sh: line 4: twine: command not found
我怎样才能让它工作?
提前致谢。
我已经知道使用 twine 的现有 GitHub 操作,它们不符合我的要求。我也知道我可以分叉一个动作并修改它,但我真正想知道的是,如果我可以运行echo hello world,为什么我不能运行pip install some-pkg; some-pkg ...?
这似乎不是路径问题。我试过用python -m twine 代替twine。我尝试运行find 命令来查找机器上名称中包含twine 的所有文件(它没有找到任何文件)。
【问题讨论】:
标签: python pip github-actions