Skip to content

v0.0.3

Choose a tag to compare

@bizzkoot bizzkoot released this 25 Jan 03:44
· 10 commits to master since this release

OpenCode Backup & Removal Manager v0.0.3

πŸŽ‰ Major Release: Complete Architecture Refactor

This release brings significant improvements including a new unified dispatcher, shared library system, OpenCode installation capability, and interactive menu.


✨ New Features

πŸ”§ Unified Dispatcher (opencode.sh)

  • Single entry point for all OpenCode operations
  • Interactive menu when run without arguments
  • Command routing to backup, restore, install, and remove tools
  • Consistent UX matching backup/removal scripts

πŸ“¦ OpenCode Installation

  • Auto-detection of best installation method
  • 8 installation methods supported:
    • brew (Homebrew - macOS/Linux, recommended)
    • npm (Node.js package - any OS)
    • scoop (Windows)
    • choco (Chocolatey - Windows)
    • paru (Arch Linux AUR)
    • mise (Multi-language runtime)
    • nix (Nix package manager)
    • curl (YOLO installer)
  • Interactive confirmation for curl installer
  • Fallback options when package manager not detected

πŸ—οΈ Shared Library System (lib/common.sh)

  • Centralized helpers for all scripts
  • OS detection (Linux, macOS, Windows)
  • Color helpers (info, success, warning, error)
  • Command wrappers for safe execution
  • Package manager detection
  • Installation functions

πŸ“‹ Interactive Menu

  • Organized layout: Backup & Restore, Installation & Removal
  • 6 main options: Create Backup, Restore, List Backups, Settings, Install, Remove
  • Platform detection displayed in header
  • Seamless navigation with clear prompts

πŸ”§ Improvements

Code Architecture

  • Extracted shared logic into lib/common.sh
  • Reduced code duplication across scripts
  • Graceful fallback when library is missing (main scripts still work)
  • Dispatcher enforces library presence for clean architecture

Documentation

  • New architecture section explaining scripts structure
  • Library system documentation with fallback behavior
  • Installation guide with all supported methods
  • Interactive mode documentation with menu examples
  • Enhanced README with images and collapsible sections
  • Updated QUICKSTART for dispatcher workflow

User Experience

  • Single entry point for all operations
  • No need to memorize command-line options
  • Consistent menus across all scripts
  • Clear error messages with actionable suggestions

πŸ”„ Breaking Changes

None. All existing command-line usage continues to work as before.


πŸ“Š Statistics

  • 7 new commits since v0.0.1
  • 1,034 lines added, 148 lines removed
  • 9 files changed:
    • lib/common.sh (new file - shared library)
    • opencode.sh (new file - dispatcher)
    • opencode-backup.sh (refactored)
    • opencode-removal.sh (refactored)
    • Documentation updates (README.md, QUICKSTART.md)
    • New UI images (Backup.png, Removal.png, Icon.png)

πŸ“ Usage Examples

Interactive Menu

./opencode.sh  # Launch interactive menu

Command Line

./opencode.sh backup              # Create backup
./opencode.sh restore             # Restore backup
./opencode.sh install              # Install OpenCode (auto-detect)
./opencode.sh install brew         # Install via Homebrew
./opencode.sh remove --remove-all   # Remove OpenCode

Direct Script Invocation (still supported)

./opencode-backup.sh backup
./opencode-removal.sh --help

πŸš€ Upgrade Instructions

Easiest Method (Download & Extract):

  1. Download the Asset file from this release
  2. Extract the zip to your backup folder
  3. Overwrite existing files when prompted
  4. Done! All features are now available

Alternative (Git Pull):

cd /path/to/opencode-backups
git pull origin master
./opencode.sh  # Try new interactive menu!

πŸ› Bug Fixes

  • Removal tool: Enhanced macOS-specific detection
  • Removal tool: Added post-removal verification

πŸ™ Acknowledgments

This release includes improvements based on user feedback for better workflow and ease of use.