Composite Run Steps GitHub Actions错误:“在URI上找不到操作" [英] Composite Run Steps GitHub Actions error: 'An action could not be found at the URI'

查看:79
本文介绍了Composite Run Steps GitHub Actions错误:“在URI上找不到操作"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在GitHub Actions上使用复合运行步骤操作,如此处,以便在不同的工作流程中重复使用它们. 但是,我得到了错误:

I am trying to use a composite run steps action on GitHub Actions, as described here, in order to reuse them in different workflows. However, I am getting the error:

An action could not be found at the URI 'https://api.github.com/repos/scripts/build_ubuntu/tarball/v1

我的主要工作流程(.github/workflows/BuildUbuntu.yml)如下:

My main workflow (.github/workflows/BuildUbuntu.yml) is the following:

[...]

jobs:
  ubuntu_build_appimage:
    name: Build MeshLab (Ubuntu - AppImage)
    runs-on: ubuntu-16.04

    steps:
    - uses: scripts/build_ubuntu@v1

[...]

合成步骤(.github/workflows/scripts/build_ubuntu/action.yml)如下:

runs:
  using: "composite"
  steps: 
  - uses: actions/checkout@v2
    with:
      submodules: true

  [other steps...]

我在做什么错了?

以下是链接: GitHub提交 推荐答案

您的工作流程错误地引用了该操作.它正在寻找标签为v1的用户/组织scripts的存储库build_ubuntu.

Your workflow is referencing the action incorrectly. It's looking for the repository build_ubuntu of the user / organization scripts with the tag v1.

您可以在本地引用它,因为它在同一存储库中.

You can reference it locally, because it is in the same repository.

[...]

jobs:
  ubuntu_build_appimage:
    name: Build MeshLab (Ubuntu - AppImage)
    runs-on: ubuntu-16.04

    steps:
    - uses: ./.github/workflows/scripts/build_ubuntu

[...]

您的操作缺少namedescription元素.根据 https://docs .github.com/en/actions/creating-actions/metadata-syntax-for-github-actions .

Your action is missing the name and description elements. These are required as per https://docs.github.com/en/actions/creating-actions/metadata-syntax-for-github-actions.

name: "My composite action"
description: "Checks out the repository and does something"
runs:
  using: "composite"
  steps: 
  - uses: actions/checkout@v2
    with:
      submodules: true

  [other steps...]

这篇关于Composite Run Steps GitHub Actions错误:“在URI上找不到操作"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆