在上面创建的hello-world-docker-action目录中创建一个新的action.yml文件。 # action.ymlname:'Hello World'description:'Greet someone and record the time'inputs:who-to-greet:# id of inputdescription:'Who to greet'required:truedefault:'World'outputs:time:# id of outputdescription:'The time we gre...
For example, you can use the steps context to set the value of an output to the output value of a step. For more information on how to use context syntax, see Accessing contextual information about workflow runs. runs Required Specifies whether this is a JavaScript action, a composit...
In thehello-world-composite-actionrepository, create a new file calledaction.ymland add the following example code. For more information about this syntax, seeMetadata syntax for GitHub Actions. YAML name:'Hello World'description:'Greet someone'inputs:who-to-greet:# id of inputdescription:'Who ...
to perform custom tasks, or by using actions the GitHub community shares. Navigating through various actions, you'll notice that there are three different types of actions:Docker container actions,JavaScript actions, andcomposite run steps actions. Let's take a closer look at each action type. ...
main: File that contains the action code; the application defined in using executes this file.For example, here's a runs statement for a JavaScript action using Node.js:yml Copy runs: using: 'node12' main: 'main.js' runs for composite run steps actionsComposite...
{ steps.random-number-generator.outputs.random-id }}runs:using:"composite"steps:- run: echo Hello ${{ inputs.who-to-greet }}.shell: bash- id: random-number-generatorrun: echo"::set-output name=random-id::$(echo $RANDOM)"shell: bash- run: ${{ github.action_path }}/goodbye.sh...
使用srggrs/assign-one-project-github-action, 我们可以将新增的 Issues 或者 PR 添加到指定的 Projects 中。 -name:Assign NEW issues and NEW pull requests to project 2uses:srggrs/assign-one-project-github-action@1.2.0if:github.event.action == 'opened'with:project:'https://github.com/srggrs/as...
Composite Actions Acompositeaction allows you to combine multiple workflow steps within one action. For example, you can use this feature to bundle together multiple run commands into an action, and then have a workflow that executes the bundled commands as a single step using that action. To ...
What I like from GitHub action is we can ensure that our action is up-to-date with available fixes in the upstream. E.g.: we can use actions/checkout@v2 and the CI will still run with the latest version of checkout@v2. Unfortunately, thi...
To make this context work with composite actions, reference it within the env context of the composite action. github.action_repository string For a step executing an action, this is the owner and repository name of the action. For example, actions/checkout.Do not use in the run keyword. ...