{"id":21823465,"url":"https://github.com/f2calv/gha-check-release-exists","last_synced_at":"2025-03-21T11:30:20.384Z","repository":{"id":63221079,"uuid":"566163242","full_name":"f2calv/gha-check-release-exists","owner":"f2calv","description":"GitHub Action to check if a release tag exists (i.e. before attempting to publish)","archived":false,"fork":false,"pushed_at":"2024-05-17T18:56:44.000Z","size":25,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-26T07:46:47.110Z","etag":null,"topics":["github-action"],"latest_commit_sha":null,"homepage":"","language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/f2calv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-11-15T04:54:48.000Z","updated_at":"2024-05-17T18:56:24.000Z","dependencies_parsed_at":"2024-04-26T04:29:18.779Z","dependency_job_id":"589d3dc2-9de7-4a62-bb17-50d79faa330c","html_url":"https://github.com/f2calv/gha-check-release-exists","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f2calv%2Fgha-check-release-exists","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f2calv%2Fgha-check-release-exists/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f2calv%2Fgha-check-release-exists/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/f2calv%2Fgha-check-release-exists/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/f2calv","download_url":"https://codeload.github.com/f2calv/gha-check-release-exists/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244790297,"owners_count":20510719,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["github-action"],"created_at":"2024-11-27T17:32:14.967Z","updated_at":"2025-03-21T11:30:20.275Z","avatar_url":"https://github.com/f2calv.png","language":"PowerShell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GitHub Action: Check Release Exists\n\nThis GitHub Action executes GitHub CLI and evaluates it's output to see if a release name exists in the current repository, with this information you can then determine whether or not to create a new release.\n\n## Example\n\n```yaml\nsteps:\n\n#insert your automated versioning system/tool here, e.g. gitversion, etc...\n- name: gitversion (1 of 2)\n  uses: gittools/actions/gitversion/setup@v1\n  with:\n    versionSpec: 5.x\n\n- name: gitversion (2 of 2)\n  id: gitversion\n  uses: gittools/actions/gitversion/execute@v1\n  with:\n    useConfigFile: true\n    additionalArguments: /nofetch\n\n- uses: f2calv/gha-check-release-exists@v2\n  with:\n    GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n    ReleaseName: 1.2.3\n    #Note: ideally pass in the desired release name from another action output\n    #ReleaseName: ${{ steps.gitversion.outputs.semVer }}\n\n#insert your build steps here, e.g. nuget, container, etc...\n\n#push package/create release\n- name: dotnet push (api.nuget.org)\n  shell: bash\n  run: |\n    #dotnet nuget push ...\n    #docker push ...\n    #etc...\n  if: |\n    steps.check-release-exists.outputs.ReleaseExists == 'false'\n      \u0026\u0026 (github.ref == format('refs/heads/{0}', github.event.repository.default_branch) || github.event.inputs.PublishPreview == 'true')\n```\n\n## Inputs\n\n- GITHUB_TOKEN, i.e. secrets.GITHUB_TOKEN\n- ReleaseName, i.e. `1.2.2` or `1.2.2-2022-04-ci-updates.12`\n\n## Outputs\n\n- ReleaseExists, i.e. `True` or `False`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ff2calv%2Fgha-check-release-exists","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ff2calv%2Fgha-check-release-exists","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ff2calv%2Fgha-check-release-exists/lists"}