Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Oct 22, 2025

  • Initial plan
  • Add native DEB package builder and remove fpm dependency
  • Fix New-NativeDeb function: handle symlinks and control file format
  • Remove Get-FpmArguments function and all fpm references
  • Address code review feedback:
    • Use cp command directly from PowerShell instead of bash
    • Use dpkg-deb directly from PowerShell instead of bash
    • Replace find commands with Get-ChildItem -Directory and Get-ChildItem -File
    • Add comments explaining file permission meanings (755, 644)
    • Install dpkg on Mariner for DEB package building
    • Add DEB package validation tests to test/packaging/linux/package-validation.tests.ps1
    • Install azurelinux-repos-extended before dpkg on Mariner
  • Fix DEB packaging CI errors:
    • Fix control file description format (multi-line descriptions must have leading space)
    • Exclude symlinks from chmod to avoid "cannot operate on dangling symlink" error
    • Fix wildcard expansion in cp command using bash
  • Code cleanup:
    • Remove unnecessary else block for extendedDescription
    • Simplify cp commands to use native wildcard expansion
    • Add verbose logging for directory paths during package building
    • Remove duplicate comments in Test-Dependencies function
    • Use Write-LogGroup function from build.psm1 to avoid code duplication
    • Wrap all native commands (chmod, cp, dpkg-deb) with Start-NativeExecution
    • Use -VerboseOutputOnError switch for dpkg-deb instead of manual error handling
    • Remove fpm installation code and Install-GlobalGem function (no longer needed after native packaging)
  • Fix package validation tests:
    • Update DEB regex to match actual package names (e.g., powershell-preview_7.6.0-preview.6-1.deb_amd64.deb)
    • Make DEB, RPM, and Tar.Gz tests fail when no packages found instead of skipping
Original prompt

Currently, we use a ruby gem called fpm to generate the DEB package. The packaging script is mainly in ‎tools/packaging/packaging.psm1. the fpm tools is installed in build.psm1 during bootstrapping phase.

Update the code to generate the DEB package directly without using fpm and any ruby gem.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot stopped work on behalf of daxian-dbw due to an error October 22, 2025 20:00
@daxian-dbw

This comment was marked as outdated.

Copilot AI and others added 3 commits October 22, 2025 20:09
Co-authored-by: daxian-dbw <127450+daxian-dbw@users.noreply.github.com>
Co-authored-by: daxian-dbw <127450+daxian-dbw@users.noreply.github.com>
Co-authored-by: daxian-dbw <127450+daxian-dbw@users.noreply.github.com>
@daxian-dbw daxian-dbw added the CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log label Oct 22, 2025
…k handling, and documentation

Co-authored-by: daxian-dbw <127450+daxian-dbw@users.noreply.github.com>
@TravisEz13
Copy link
Member

add tests to test/packaging/linux/package-validation.tests.ps1 for deb packages

@microsoft-github-policy-service microsoft-github-policy-service bot added the Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept label Oct 26, 2025
…or Mariner, and add DEB tests

Co-authored-by: daxian-dbw <127450+daxian-dbw@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Oct 27, 2025

add tests to test/packaging/linux/package-validation.tests.ps1 for deb packages

Added DEB package validation tests with pattern matching for package names. Fixed in 7e03559.

@microsoft-github-policy-service microsoft-github-policy-service bot removed the Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept label Oct 27, 2025
Copilot AI changed the title [WIP] Remove usage of fpm for DEB package generation Remove usage of fpm for DEB package generation Oct 27, 2025
Copilot AI requested a review from daxian-dbw October 27, 2025 20:41
Co-authored-by: daxian-dbw <127450+daxian-dbw@users.noreply.github.com>
@daxian-dbw daxian-dbw merged commit 7e1ef1f into master Oct 28, 2025
37 checks passed
@daxian-dbw daxian-dbw deleted the copilot/remove-fpm-deb-packaging branch October 28, 2025 23:39
pwshBot pushed a commit to pwshBot/PowerShell that referenced this pull request Oct 29, 2025
TravisEz13 pushed a commit to TravisEz13/PowerShell that referenced this pull request Nov 5, 2025
TravisEz13 pushed a commit to TravisEz13/PowerShell that referenced this pull request Nov 20, 2025
TravisEz13 pushed a commit to TravisEz13/PowerShell that referenced this pull request Nov 24, 2025
SIRMARGIN pushed a commit to SIRMARGIN/PowerShell that referenced this pull request Dec 12, 2025
kilasuit pushed a commit to kilasuit/PowerShell that referenced this pull request Jan 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Backport-7.4.x-Migrated BackPort-7.5.x-Consider BackPort-7.6.x-Done CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants