Skip to content

Conversation

@Pterjudin
Copy link

Summary

This PR implements update channel support for CortexIDE's update system, enhancing the existing custom update service with channel-based GitHub API checks.

Changes

Core Features

  • ✅ Add update.updateChannel configuration setting (stable/beta/nightly)
  • ✅ Enhance CortexideMainUpdateService with channel-based GitHub API checks
  • ✅ Replace fetch() with IRequestService for cross-platform compatibility
  • ✅ Support channel selection in standard VS Code update services
  • ✅ Fix hardcoded URLs (voideditor.com → opencortexide.com)
  • ✅ Update Linux update service to use channel parameter
  • ✅ Ensure truthful UX for Linux (no fake auto-updates)

Files Modified

  • src/vs/platform/update/common/update.config.contribution.ts - Added channel config
  • src/vs/platform/update/electron-main/abstractUpdateService.ts - Channel support
  • src/vs/platform/update/electron-main/updateService.*.ts - Platform-specific channel support
  • src/vs/workbench/contrib/cortexide/electron-main/cortexideUpdateMainService.ts - Enhanced with channel support
  • src/vs/workbench/contrib/cortexide/browser/cortexideUpdateActions.ts - Fixed URLs and indentation
  • src/vs/workbench/contrib/update/browser/update.*.ts - Channel switcher UI

Implementation Details

Channel Support

  • Stable: Uses /releases/latest endpoint (non-prerelease only)
  • Beta/Nightly: Uses /releases?per_page=1 endpoint (includes prereleases)
  • Channel is read from update.updateChannel config setting
  • Defaults to stable if not set (backward compatible)

Cross-Platform Compatibility

  • Uses IRequestService instead of fetch() for proper HTTP handling
  • Works on Windows, macOS, and Linux
  • Respects proxy settings and network configuration
  • Handles all Linux packaging formats (deb/rpm/AppImage/Snap)

Linux-Specific Behavior

  • Snap packages: Auto-updates via system package manager
  • Other formats: Shows "Update available" → opens download page (truthful UX)

Testing

  • Code compiles without errors
  • No dead code or unused imports
  • Indentation fixed (tabs, not spaces)
  • Works on all platforms (Windows, macOS, Linux)

Notes

  • This is Option A implementation: Enhanced custom service with channel support
  • Maintains backward compatibility with existing update flow
  • No breaking changes to existing functionality

Tajudeen added 2 commits December 29, 2025 18:07
- Add update.updateChannel configuration (stable/beta/nightly)
- Enhance CortexideMainUpdateService with channel-based GitHub API checks
- Replace fetch() with IRequestService for cross-platform compatibility
- Support channel selection in standard VS Code update services
- Fix hardcoded URLs (voideditor.com -> opencortexide.com)
- Update Linux update service to use channel parameter
- Ensure truthful UX for Linux (no fake auto-updates)
- Fix indentation issues in cortexideUpdateActions.ts

This implementation:
- Works on all platforms (Windows, macOS, Linux)
- Uses IRequestService for proper HTTP handling
- Maintains backward compatibility
- Provides channel switching via configuration
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