Consider some output variables
fiddlermikey opened this issue · comments
When choosing the "latest" tag I find myself wanting to know which tag name it is using.
I would like to be able to refer to the outputs of this action to use in another step in the same workflow to create logs and upload release artifacts.
I could use another action like actions/create-release but I think having the information available in this action would be more reliable.
Some create-release actions output basic reusable properties such as
Action Outputs
Output name | Description |
---|---|
id | The identifier of the created release. |
html_url | The HTML URL of the release. |
upload_url | The URL for uploading assets to the release. |
This sounds like a good addition to this action. I can add the tag_name
of a release to the output, as it is readily available.
@fiddlermikey I just merged a PR which adds the tag_name
output variable to this action. You may use it from the main
branch as follows
- uses: robinraju/release-downloader@a2560d77c56d90bc684e42df51576a951cd49b86
with:
latest: true
fileName: "foo.zip"
it can be accessed as follows
${{steps.<step-id>.outputs.tag_name}}
I'll publish a new version once you confirm it works as expected.
I am getting the following error:
Error: unable to verify the first certificate when using release-downloader@main
Reverting back to 1.4 the error went away
name: Get Latest Release
on: [push, repository_dispatch, workflow_dispatch]
jobs:
build:
name: FindLatestRelease
runs-on: windows-latest
steps:
- name: Download Release Asset
id: downloadAsset
uses: robinraju/release-downloader@[main | v1.4]
with:
repository: ${{ github.repository }}
token: ${{ github.token }}
latest: true
fileName: "*.zip"
github-api-url: "https://keyfactor.com/api/v3"
- name: debug output
run: |
echo "latestReleaseTag = ${{ steps.downloadAsset.outputs.tag_name }}"
A similar issue with a solution described here: https://stackoverflow.com/questions/71658093/github-actions-self-hosted-runner-error-unable-to-verify-the-first-certificate
Can you try that and see if it works.
And more here: https://github.com/actions/runner/blob/main/docs/checks/sslcert.md
The first link is to a solution for self-hosted runners behind a firewall and the second requires access to the runner OS configuration and I am using the github hosted windows-latest runner and do not have the option to mess with the configuration.
I am using the github hosted windows-latest runner
in that case its not required to use the github-api-url: "https://keyfactor.com/api/v3"
param.
this option is only for github enterprise hosted on a custom domain.
This option is required if the target repo is hosted on GH enterprise. Unfortunately, I haven't used GH enterprise, and this action is not tested against a real one.
Hi @robinraju Can you create a new release ? I'm not able to use tag_name
in the latest release.