**Proposal for Improving Bolt.diy: A Seamless Update System**

Proposal for Improving Bolt.diy: A Seamless Update System

The Current Problem:

When Bolt.diy is updated on GitHub, users currently need to perform the following steps manually:

  1. Download the latest version of the project from GitHub.
  2. Delete (or move) the old version.
  3. Reinstall dependencies using pnpm install or similar.
  4. Sometimes, users may need to manually adjust configurations or files to be compatible with the new update.

This process is tedious and time-consuming, and it can lead to errors if the user doesn’t follow the steps correctly.

Proposed Solution: One-Click Update System

We propose adding a simplified update system within Bolt.diy that allows users to update the project with a single click. This can be achieved through:

  1. “Update” Button in the Interface: Adding a clear “Update” button in the Bolt.diy user interface.
  2. Using Git: Since Bolt.diy relies on Git, Git commands like git pull can be used to fetch the latest changes from the GitHub repository.
  3. Automatic Dependency Management: After fetching the updates, the system should automatically run the dependency installation command (pnpm install or similar) to ensure all libraries and dependencies are correctly installed.
  4. Update Availability Check: The system can periodically check (e.g., on startup or manually via a button) for new updates on GitHub.
  5. Displaying Update Information: Before updating, a simple summary of the changes to be applied (changelog) can be displayed to the user.

Additional Enhancements:

  • Update Options: Provide users with options to control the update process, such as:
    • Automatic updates on startup.
    • Manual updates only.
    • The ability to select a specific branch to update from (e.g., main or develop).
  • Error Handling: The system should be able to handle errors that may occur during the update, such as internet connection issues or file conflicts. Clear error messages should be displayed to the user, along with possible solutions.
  • Update Rollback: Provide the ability to rollback an update in case of problems. This can be achieved using Git commands like git revert.
  • Individual Component Updates: Instead of updating the entire project every time, consider providing the ability to update individual components (e.g., a specific library) separately.
  • Using Service Workers: Service Workers could be used to download updates in the background and install them seamlessly.

Benefits of this System:

  • Ease of Use: Updating the project with a single click.
  • Time and Effort Savings: No need to perform manual steps.
  • Error Reduction: Avoiding human errors that can occur during manual updates.
  • Improved User Experience: A smoother and more convenient user experience.

I know this is probably not what you were looking for as you want all this in the UI. But you could actually do this quite easily already.

For local build, just modify the pnpm run dev command, something like this (and maybe add a revert command):

"dev": "node pre-start.cjs && pnpm update && git pull && remix vite:dev",

Note: It would also just update the branch you had selected but maybe add explicit options such as pnpm run dev:stable or something.

For Cloudflare Pages, it’s easy enough to create an action that pulls the latest from the given branch and re-deploys. I have a doc on setting up Cloudflare Pages and have the process done for automating updates on Bolt.diy repo change (by branch selected) with action, I just need to finalize it.

I personally create a run.bat to set some parameters first Bolt.diy, with customized icon I can just click on my taskbar. Its launches a Chrome shortcut instead of in another tab (full screen without the navigation bar, etc.), making it feel more like a native app. And I don’t need to jump into the terminal.

image

P.S. But ultimately, I think it would be nice to compiled “build” releases that can run without the need for pnpm, remix, etc. Either using something like Electron or npx serve (but including the binary would be nice, so that no setup or dependencies were required, such as git, npm, pnpm, etc.). That’s the direction I imagine which would also take care of adding an icon, etc.

1 Like

What about Docker Compose and Watchtower?