feat: add msi support#1097
Open
djgilcrease wants to merge 6 commits into
Open
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1097 +/- ##
==========================================
+ Coverage 73.96% 74.18% +0.21%
==========================================
Files 22 23 +1
Lines 2777 3083 +306
==========================================
+ Hits 2054 2287 +233
- Misses 497 539 +42
- Partials 226 257 +31 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Deploying nfpm with
|
| Latest commit: |
e6ed5ff
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://8b3e6666.nfpm.pages.dev |
| Branch Preview URL: | https://msi-builder.nfpm.pages.dev |
There was a problem hiding this comment.
Pull request overview
This PR adds a new msi packager to nfpm, enabling generation of Windows Installer .msi packages (and associated config/schema/docs) using the pure-Go go-msi library, plus CI/acceptance coverage for MSI structure and Windows install verification.
Changes:
- Introduces a new
msipackager implementation and unit tests (msi/). - Extends nfpm configuration (
nfpm.go), schema (www/static/schema.json), and docs (www/content/docs/configuration.md) with MSI-specific fields. - Adds MSI acceptance test configs/scripts and wires them into Taskfile and GitHub Actions.
Reviewed changes
Copilot reviewed 15 out of 16 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| www/static/schema.json | Adds JSON schema definitions and references for the new msi config block. |
| www/content/docs/configuration.md | Documents MSI-specific configuration and conventions (Windows destinations, services, registry, signing). |
| testdata/acceptance/msi.install.yaml | Adds Windows install-test MSI config used by Taskfile/CI. |
| testdata/acceptance/msi.basic.yaml | Adds MSI acceptance config used by TestMSIStructure. |
| testdata/acceptance/install-msi.ps1 | Adds PowerShell script to install/uninstall MSI and verify installed binary. |
| Taskfile.yml | Adds Windows MSI packaging/install tasks for acceptance coverage. |
| nfpm.go | Adds MSI config structs and env-var expansion for MSI signing/manufacturer. |
| msi/msi.go | Implements the MSI packager (contents mapping, shortcuts, services, registry, signing). |
| msi/msi_test.go | Adds unit tests validating MSI structure, ICE checks, defaults, GUID derivation, and signing. |
| internal/cmd/root.go | Registers the MSI packager in the CLI via blank import. |
| go.mod | Adds dependencies for MSI generation and PKCS#12 support. |
| go.sum | Records checksums for newly added MSI-related dependencies. |
| files/files.go | Fixes an infinite loop when walking parent dirs for Windows drive-letter destinations. |
| files/files_test.go | Adds regression test for drive-letter destination termination. |
| acceptance_test.go | Adds an MSI acceptance test validating MSI CFB header and ICE findings. |
| .github/workflows/build.yml | Adds CI jobs for MSI structure validation (Linux) and install verification (Windows). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Uses the pure go https://github.com/digitalxero/go-msi to generate msi & msp (a installer patch) files
https://github.com/goreleaser/nfpm/actions/runs/27466651901/job/81190128643