Overview
Thedevcpc update command updates your DevCPC installation to the latest version from GitHub Releases, preserving your configuration and projects.
Syntax
Update Process
The command follows these steps:- Check current version - Displays installed version
- Query GitHub API - Fetches latest release information
- Compare versions - Determines if update is available
- Confirm update - Asks for user confirmation
- Download release - Downloads latest tar.gz from GitHub
- Extract files - Unpacks the archive
- Update installation - Replaces files in
~/.DevCPC - Set permissions - Ensures executable permissions
- Verify update - Confirms new version installed
Output Example (Update Available)
Output Example (Already Updated)
What Gets Updated
The update replaces:bin/- DevCPC executablelib/- Shell librariestools/- Python tools (ABASM, dsk.py, cdt.py, etc.)templates/- Project templates
What Gets Preserved
The update preserves:- Your projects (outside
~/.DevCPC) - Shell configuration (
~/.bashrc,~/.zshrc) - PATH configuration
Version Checking
The command queries GitHub API:tag_name field to determine the latest version.
Manual Update
If automatic update fails, you can update manually:Verification
After updating, verify the new version:Automated Updates
You can automate update checks in your workflow:Update Frequency
Check for updates:- Before starting new projects
- After seeing release announcements
- Periodically (weekly/monthly)
Release Notes
After updating, check release notes:Rollback
If you need to rollback to a previous version:Error Handling
No Internet Connection
Download Failed
- Check internet connection
- Verify GitHub is accessible
- Try manual update
Extraction Failed
- Check disk space
- Verify tar.gz is not corrupted
- Try manual update
Permission Denied
Network Requirements
The update requires:- Internet connection
- Access to
github.com - Access to
api.github.com - Ability to download ~2-5 MB
Update Size
Typical update downloads:- Small update: 1-2 MB (bug fixes)
- Medium update: 2-4 MB (new features)
- Large update: 4-8 MB (major version)
Version Numbering
DevCPC uses semantic versioning:- Major: Breaking changes, major new features
- Minor: New features, backward compatible
- Patch: Bug fixes, minor improvements
Update Notifications
DevCPC automatically checks for updates when running:Related Commands
devcpc version- Check current versiondevcpc help- View help after update