Commit graph

2 commits

Author SHA1 Message Date
3b412a0a6b
Refactor version tracking to separate validation and update logic
- Split ValidateAndUpdateVersion into validation-only function
- Add dedicated UpdatePluginCtlVersion function for version updates
- Update updateassets command to use new version update function
- Improve separation of concerns and code maintainability

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-07-31 12:14:45 +02:00
353cc9efc7
Add version tracking and validation to prevent downgrade issues
Store the last pluginctl version used in plugin.json props and validate
before running commands. Prevents issues when using older pluginctl
versions on plugins modified by newer versions.

- Add Version field to PluginCtlConfig struct
- Implement version validation before command execution
- Add WritePluginManifest and SavePluginCtlConfig helper functions
- Add comprehensive tests for version comparison logic
- Skip validation for 'version' command and when no plugin.json exists

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-07-31 11:54:46 +02:00
Renamed from plugin.go (Browse further)