Skip to content

Conversation

@iammukeshm
Copy link
Member

Summary

Implements the fsh upgrade --apply functionality to actually apply upgrades.

What's New

Services

  • PackageUpdater - Updates Directory.Packages.props with new versions

Features

  • fsh upgrade --apply now works:
    • Creates backup before changes
    • Updates package versions
    • Adds new packages from latest release
    • Shows warnings for removed packages
    • Updates manifest with new version
    • Offers rollback on failure

Flags

  • --dry-run - Preview changes without applying
  • --skip-breaking - Skip packages with breaking changes
  • --force - Skip confirmation prompt

Usage

# Preview upgrade
fsh upgrade --apply --dry-run

# Apply upgrade
fsh upgrade --apply

# Apply only safe updates
fsh upgrade --apply --skip-breaking

# Force apply without confirmation
fsh upgrade --apply --force

Part of CLI Upgrade System

  • Sprint 1: ✅ Manifest + version command
  • Sprint 2: ✅ Upgrade check
  • Sprint 3: ✅ Upgrade apply (this PR)
  • Sprint 4: 🔜 Polish + fsh add module

- Add PackageUpdater service for updating Directory.Packages.props
- Implement 'fsh upgrade --apply' functionality:
  - Fetches latest release and compares versions
  - Creates backup before making changes
  - Updates package versions in Directory.Packages.props
  - Adds new packages from latest release
  - Shows warnings for removed packages (manual review)
  - Updates manifest with new version and timestamp
  - Supports --dry-run for preview without changes
  - Supports --skip-breaking to skip breaking changes
  - Supports --force to skip confirmation
  - Offers rollback on failure

Sprint 3 deliverables:
- [x] Package version updater
- [x] Safe (non-breaking) auto-apply with --skip-breaking
- [x] Backup and restore functionality
- [x] Interactive confirmation (skippable with --force)
- [x] Dry run mode
@iammukeshm iammukeshm merged commit 744fda9 into develop Jan 27, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants