{"id":16203092,"url":"https://github.com/michidk/winget-updater","last_synced_at":"2025-03-19T07:30:36.660Z","repository":{"id":198398461,"uuid":"700725497","full_name":"michidk/winget-updater","owner":"michidk","description":"A GitHub action which automatically updates winget packages, based on Komac.","archived":false,"fork":false,"pushed_at":"2025-03-16T12:27:42.000Z","size":54,"stargazers_count":7,"open_issues_count":2,"forks_count":4,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-16T13:29:10.339Z","etag":null,"topics":["ci","deployment-automation","deployment-tools","github-action","github-actions","komac","release-automation","winget"],"latest_commit_sha":null,"homepage":"","language":null,"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/michidk.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":"2023-10-05T07:08:07.000Z","updated_at":"2025-03-16T12:27:45.000Z","dependencies_parsed_at":"2024-01-03T13:27:55.789Z","dependency_job_id":"c239b069-eb22-427e-ae05-ec94e123d035","html_url":"https://github.com/michidk/winget-updater","commit_stats":null,"previous_names":["michidk/winget-updater"],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michidk%2Fwinget-updater","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michidk%2Fwinget-updater/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michidk%2Fwinget-updater/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michidk%2Fwinget-updater/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/michidk","download_url":"https://codeload.github.com/michidk/winget-updater/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244378999,"owners_count":20443378,"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":["ci","deployment-automation","deployment-tools","github-action","github-actions","komac","release-automation","winget"],"created_at":"2024-10-10T09:51:37.057Z","updated_at":"2025-03-19T07:30:36.654Z","avatar_url":"https://github.com/michidk.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1\u003e \u003cimg src=\"https://github.com/vedantmgoyal9/winget-releaser/blob/main/.github/github-actions-logo.png\" width=\"32\" height=\"32\" alt=\"Logo\" /\u003e WinGet Updater (GitHub Action) \u003c/h1\u003e\n\n[![GitHub release (latest by date)](https://img.shields.io/github/v/release/michidk/winget-updater?logo=github)](https://github.com/michidk/winget-updater/releases)\n[![GitHub](https://img.shields.io/github/license/michidk/winget-updater)](https://github.com/michidk/winget-updater?tab=MIT-1-ov-file#readme)\n\nA GitHub action which automatically updates WinGet packages, based on Komac.\n\nThis project is heavily inspired by [vedantmgoyal2009/winget-releaser](https://github.com/vedantmgoyal2009/winget-releaser).\nThe main differences are:\n\n- This action will update your package to the latest release available on GitHub automatically. It does not need to react to an `on: release` event in GitHub actions.\n- It is a composite action, which consists of other GitHub actions, which makes it very simple (no big Typescript project).\n\n## Getting Started 🚀\n\n1. At least **one** version of your package should already be present in the [Windows Package Manager Community Repository](https://github.com/microsoft/winget-pkgs). The action will use that version as a base to create manifests for new versions of the package.\n\n2. You will need to create a _classic_ Personal Access Token (PAT) with `public_repo` scope. _New_ fine-grained PATs aren't supported by the action. Review [this issue](https://github.com/vedantmgoyal2009/winget-releaser/issues/172) for information.\n\n3. Fork the [winget-pkgs](https://github.com/microsoft/winget-pkgs) repository under the same account/organization as your repository on which you want to use this action. Ensure that the fork is up-to-date with the upstream repository (see [this issue](https://github.com/vedantmgoyal2009/winget-releaser/issues/32) for why this is important). You can do this using one of the following methods:\nhttps://github.com/vedantmgoyal2009/winget-releaser\n- Give `workflow` permission to the token you created in Step 1. This will allow the action to automatically update your\n  fork with the upstream repository.\n- You can use **[Pull App](https://github.com/wei/pull)** which keeps your fork up-to-date with the upstream repository via automated pull requests.\n\n4. Add the action to your workflow file (e.g. `.github/workflows/\u003cname\u003e.yml`).\n\n\u003e [!IMPORTANT]\n\u003e The action will only work when the release is **published** (not a draft), because the release assets (binaries) aren't available publicly until the release is published.\n\n\u003e [!NOTE]\n\u003e In case you're pinning the action to a commit hash, you'll need to update the hash frequently to get the latest features \u0026 bug fixes. Therefore, it is **highly** recommended to setup dependabot auto-updates for your repository. Check out [keeping your actions up to date with Dependabot](https://docs.github.com/en/actions/security-guides/encrypted-secrets#using-encrypted-secrets-in-a-workflow) for guidance on how to do this. (Yes, it also supports updating actions pinned to a commit hash!)\n\n\n## 📖 Example Usage\n\nMinimal example:\n\n```yaml\nname: Update WinGet Packages\n\non: workflow_dispatch\n\njobs:\n  update:\n    name: Update Package\n    runs-on: ubuntu-latest\n    steps:\n    - name: Update Packages\n      uses: michidk/winget-updater@v1\n      with:\n        komac-token: ${{ secrets.KOMAC_TOKEN }}\n        identifier: \"michidk.vscli\"\n        repo: \"michidk.vscli\"\n        URL: \"https://github.com/michidk/vscli/releases/download/v{VERSION}/vscli-x86_64-pc-windows-msvc.zip\"\n```\n\nUse a matrix to update multiple packages at once. Can also be combined with [Run Komac](https://github.com/michidk/run-komac) to automatically clean up branches after a PR has been merged:\n\n```yaml\nname: Update WinGet Packages\n\non:\n  workflow_dispatch:\n  schedule:\n    - cron:  '0 3 * * *' # Scheduled to run daily at 03:00\n\njobs:\n  update:\n    name: Update package ${{ matrix.id }}\n    runs-on: ubuntu-22.04\n\n    strategy:\n      matrix:\n        include:\n          - id: \"Casey.Just\"\n            repo: \"casey/just\"\n            url: \"https://github.com/casey/just/releases/download/{VERSION}/just-{VERSION}-x86_64-pc-windows-msvc.zip\"\n          - id: \"michidk.vscli\"\n            repo: \"michidk/vscli\"\n            url: \"https://github.com/michidk/vscli/releases/download/v{VERSION}/vscli-x86_64-pc-windows-msvc.zip\"\n            # Multi URL package entry\n          - id: \"michidk.vscli\"\n            repo: \"michidk/vscli\"\n            url: \"'https://github.com/michidk/vscli/releases/download/v{VERSION}/vscli-x86_64-pc-windows-msvc.zip https://github.com/michidk/vscli/releases/download/v{VERSION}/vscli-i686-pc-windows-msvc.zip'\"\n\n    steps:\n    - name: Update Packages\n      uses: michidk/winget-updater@latest\n      with:\n        komac-token: ${{ secrets.KOMAC_TOKEN }}\n        identifier: ${{ matrix.id }}\n        repo: ${{ matrix.repo }}\n        url: ${{ matrix.url }}\n\n  cleanup:\n    name: Cleanup branches\n    needs: update # Not necessarily needed as PRs don't get closed that quick but still nice to have it in order\n    runs-on: ubuntu-22.04\n\n    steps:\n    - name: Run Komac\n      uses: michidk/run-komac@latest\n      with:\n        args: 'cleanup --only-merged --token=${{ secrets.KOMAC_TOKEN }}'\n```\n\nFor a real-world example, have a look at my WinGet package updater repository: [michidk/winget](https://github.com/michidk/winget)\n\n## ⚒️ Configuration Options\n\n- `komac-version`: Specifies which version of Komac to use.\n  - **Required**: ❌\n  - **Default**: `2.6.0`\n- `komac-token`: The GitHub token to use for authentication. The token should have the `public_repo` scope.\n  - **Required**: ✅\n  - ⚠ **WARNING**: Do **not** directly put the token in the action. Instead, create a repository secret containing the token and use that in the workflow. Refer to [using encrypted secrets in a workflow](https://docs.github.com/en/actions/security-guides/encrypted-secrets#using-encrypted-secrets-in-a-workflow) for more information.\n- `identifier`: The package identifier of the package to be updated in the [WinGet Community Repository](https://github.com/microsoft/winget-pkgs).\n  - **Required**: ✅\n  - **Example**: `michidk.vscli`\n- `repo`: The GitHub repository to check for the latest release.\n  - **Required**: ✅\n  - **Example**: `michidk/vscli`\n- `url`: The URL(s) to the latest release. Can also be a comma-separated list. Use the placeholder `{VERSION}` to specify where the version should be inserted. The placeholder contains the version without `v`, e.g. `1.2.3`. If multiple URL's are specified, they must be wrapped in either `'` or `\"`. See the second example.\n  - **Required**: ✅\n  - **Example 1**: `https://github.com/michidk/vscli/releases/download/v{VERSION}/vscli-x86_64-pc-windows-msvc.zip`\n  - **Example 2**: `url: \"'https://github.com/michidk/vscli/releases/download/v{VERSION}/vscli-x86_64-pc-windows-msvc.zip https://github.com/michidk/vscli/releases/download/v{VERSION}/vscli-i686-pc-windows-msvc.zip'\"`\n- `custom-fork-owner`: The owner of the `winget-pkgs` repo fork to use. If not specified, the owner of the repository where the action is used will be used.\n  - **Required**: ❌\n  - **Example**: `michidk`\n\n\u003ch2\u003e 🚀 Integrating with \u003ca href=\"https://github.com/russellbanks/Komac\"\u003e \u003cimg src=\"https://rawcdn.githack.com/michidk/winget-updater/7ef56d9c40feb29e1592c0bf6c65eb1af3e77d4e/.github/images/komac-logo.svg\" height=\"24px\" style=\"vertical-align:bottom\" alt=\"Komac logo\" /\u003e \u003c/a\u003e\u003c/h2\u003e\n\nThis GitHub action leverages [Komac](https://github.com/russellbanks/komac) to generate and submit manifests to the [Windows Package Manager Community Repository](https://github.com/microsoft/winget-pkgs). Kudos to [Russell Banks](https://github.com/russellbanks) for developing Komac which powers this action.\nAlso huge thanks to [vedantmgoyal2009](https://github.com/vedantmgoyal2009) for creating an awesome GitHub action, which this one is heavily inspired from.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmichidk%2Fwinget-updater","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmichidk%2Fwinget-updater","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmichidk%2Fwinget-updater/lists"}