{"id":18026385,"url":"https://github.com/gamepowerx/pipe-to-release","last_synced_at":"2025-04-04T19:20:24.603Z","repository":{"id":43376846,"uuid":"462882001","full_name":"GamePowerX/pipe-to-release","owner":"GamePowerX","description":"A github action for uploading files to a release (or creating one if it doesn't already exist)","archived":false,"fork":false,"pushed_at":"2022-03-19T21:32:32.000Z","size":1247,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-06T01:02:50.714Z","etag":null,"topics":["action","actions","github-actions","typescript"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/GamePowerX.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":"CODEOWNERS","security":null,"support":null}},"created_at":"2022-02-23T19:42:47.000Z","updated_at":"2023-06-29T18:46:58.000Z","dependencies_parsed_at":"2023-01-05T04:49:24.776Z","dependency_job_id":null,"html_url":"https://github.com/GamePowerX/pipe-to-release","commit_stats":null,"previous_names":["kotwoss/pipe-to-release"],"tags_count":24,"template":false,"template_full_name":"actions/typescript-action","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GamePowerX%2Fpipe-to-release","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GamePowerX%2Fpipe-to-release/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GamePowerX%2Fpipe-to-release/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GamePowerX%2Fpipe-to-release/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GamePowerX","download_url":"https://codeload.github.com/GamePowerX/pipe-to-release/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247235243,"owners_count":20905919,"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":["action","actions","github-actions","typescript"],"created_at":"2024-10-30T08:06:31.195Z","updated_at":"2025-04-04T19:20:24.584Z","avatar_url":"https://github.com/GamePowerX.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/actions/typescript-action/actions\"\u003e\u003cimg alt=\"typescript-action status\" src=\"https://github.com/actions/typescript-action/workflows/build-test/badge.svg\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n# Pipe to Release\n\nWe made this repository because we had some trouble with other existing repos like [upload-release-action](https://github.com/svenstaro/upload-release-action/blob/master/src/main.ts) that were just no longer maintained and couldn't upload multiple files.\n\n\u003cbr\u003e\n\n\n## Options\nHeres a list of all the options you can include into the with block.\n\n| name         | description                                                                                 | required | default                     |\n| ------------ | ------------------------------------------------------------------------------------------- | -------- | --------------------------- |\n| token        | The token this action uses to contact the github api.                                       | true     | none                        |\n| repository   | The repository where the release will be created in.                                        | false    | active repository           |\n| filemap      | The list of files that will be uploaded. See \u003ca href=\"#file-piper\"\u003eFilePiper\u003c/a\u003e for more information. If not set, just a release is being created. | false     | empty                        |\n| release_id | If set, the action will look for an existing release with that id. | false | none |\n| skip_errors  | If true, the action will skip errors instead of setting the build to failed.                | false    | true                        |\n| draft        | If true, the action will create a draft release. (Not published)                            | false    | true                        |\n| prerelease   | If true, the action will create a prerelease.                                                | false    | false                       |\n| overwrite    | If true, the action will update already existing assets instead of throwing an error        | false    | false                       |\n| tag          | The tag of the release.                                                                     | false    | mytag                       |\n| release_name | The name of the release.                                                                    | false    | My cool release             |\n| release_body | The body (description) of the release.                                                      | false    | This is a very cool release |\n\n\u003cbr\u003e\n\n## Outputs\n\nOn succeed you will get the `release_id` as an output.\n\n\u003cbr\u003e\n\n## Usage\nBasic multiple file upload:\n```yaml\n- name: Pipe files to release\n  uses: KotwOSS/pipe-to-release@\u003cversion\u003e\n  with:\n    repo_token: ${{ secrets.GITHUB_TOKEN }}\n\n    # The files that will be uploaded. Use \u003e to specify the file source and the asset name\n    filemap: |\n      target/release/mything\u003emything\n      target/release/someother\u003esomeother\n\n    # Skip errors (doesn't fatal exit, just skips)\n    skip_errors: true\n\n    # Creates a release that is not published\n    draft: true\n    \n    # Creates a prerelease\n    prerelease: true\n\n    # Replaces assets with the same name instead of throwing an error\n    overwrite: true\n\n    # Specifies the tag\n    tag: ${{ github.ref }}\n\n    # Specifies the name and the body content of the release\n    release_name: This is my release\n    release_body: \"This is my release text\"\n\n    # Specifies a custom repository. (If not set the active repository will be used)\n    repository: User/Repository\n```\n\n\u003cbr\u003e\n\nMultiple file upload with automated tag and release_name:\n```yaml\n- name: Generate commit hash\n  id: commithash\n  run: echo \"::set-output name=sha_short::$(git rev-parse --short HEAD)\"\n\n- name: Generate build number\n  id: buildnumber\n    uses: einaregilsson/build-number@v3 \n    with:\n      token: ${{secrets.GITHUB_TOKEN}}\n\n- name: Pipe files to release\n  uses: KotwOSS/pipe-to-release@\u003cversion\u003e\n  with:\n    token: ${{ secrets.GITHUB_TOKEN }}\n\n    filemap: |\n      target/release/mything\u003emything\n      target/release/someother\u003esomeother\n\n    skip_errors: true\n\n    draft: true\n    prerelease: true\n\n    tag: \"build_${{ env.BUILD_NUMBER }}\"\n\n    release_name: \"build:${{ steps.commithash.outputs.sha_short }}\"\n    release_body: \"This is an automated build\"\n```\n\n\u003cbr\u003e\n\nMultiple file upload with automated tag and release_name with matrix:\n```yaml\njobs:\n  prepare:\n    runs-on: ubuntu-latest\n    outputs:\n      BUILD_ID: ${{ steps.buildnumber.outputs.build_number }}\n      SHA_SHORT: ${{ steps.commithash.outputs.sha_short }}\n      RELEASE_ID: ${{ steps.release.outputs.release_id }}\n\n    steps:\n      - uses: actions/checkout@v2\n      \n      - name: Set outputs\n        id: commithash\n        run: echo \"::set-output name=sha_short::$(git rev-parse --short HEAD)\"\n      \n      - name: Generate build number\n        id: buildnumber\n        uses: einaregilsson/build-number@v3 \n        with:\n          token: ${{ secrets.github_token }}\n\n      - name: Create a release\n        id: release\n        uses: KotwOSS/pipe-to-release@\u003cversion\u003e\n        with:\n          token: ${{ secrets.GITHUB_TOKEN }}\n\n          skip_errors: true\n\n          draft: true\n          prerelease: true\n\n          tag: \"build_${{ steps.buildnumber.outputs.build_number }}\"\n          release_name: \"build:${{ steps.commithash.outputs.sha_short }}\"\n          release_body: \"This is an automated build\"\n          \n\n  buildMatrix:\n    name: Publish for ${{ matrix.os }}\n    runs-on: ${{ matrix.os }}\n  \n    strategy:\n        fail-fast: false\n        matrix:\n          include:\n          - os: ubuntu-latest\n            filemap: |\n              target/release/some.deb\u003esome.deb\n              target/release/some.AppImage\u003esome.AppImage\n                         \n          - os: windows-latest\n            filemap: |\n              target/release/some.exe\u003esome.exe\n            \n          - os: macos-latest\n            filemap: |\n              target/release/some.app\u003esome.app\n              target/release/some.dmg\u003esome.dmg\n\n    needs: prepare\n\n    steps:\n    - uses: actions/checkout@v2\n\n    - name: Pipe files to release\n      uses: KotwOSS/pipe-to-release@\u003cversion\u003e\n      with:\n        token: ${{ secrets.GITHUB_TOKEN }}\n\n        filemap: ${{ matrix.filemap }}\n\n        skip_errors: true\n\n        release_id: ${{ needs.prepare.outputs.RELEASE_ID }}\n```\n\n\n\u003cbr\u003e\n\n\u003ca name=\"file-piper\"\u003e\n\n## File Piper\n\n\u003c/a\u003e\n\nFile pipers are a combination of `\u003csource\u003e`, `\u003e` and `\u003cdest\u003e` which specify where a file should go.\n\n\u003cbr\u003e\n\n### Examples\n\nPipe file `a` to file `b` -\u003e `a\u003eb` \n\nPipe file `a\u003e` to file `b\u003e` (escaping `\u003e` with `\\\u003e`) -\u003e `a\\\u003e\u003eb\\\u003e`","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgamepowerx%2Fpipe-to-release","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgamepowerx%2Fpipe-to-release","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgamepowerx%2Fpipe-to-release/lists"}