Skip to main content

Edit and publish protected apps

Once the app is protected, builders can make edits to the app from the app builder. Each thread in the Chat tab functions as a branch in the git model. Learn more about threading.

Opening a pull request and integrating changes into the main branch of the repository creates a new published version of your app. You can also choose to tag a release in order to pin a published version that you want end users to see.

Create a new published version

Use the following steps to create a new published version.

If you have never tagged a release, then creating a new published version using these steps means that app users will see the version of your app represented by your repository's main branch. If you want to manually release new versions of your app to users, tag a release.

  1. After you've made edits (either manually in the Code tab or using AI in the Chat tab), click Ask to publish in the top right corner of the app builder.
  2. Review the Publish checklist. Retool performs several checks to ensure that your app is ready to publish:
    • All function runs are approved. If there are unapproved functions, click Review functions to view the functions that still need approval.
    • Your changes do not conflict with the published version changes from other users. If there is a new published version of your app, click Integrate changes to ask the agent to resolve the conflict.
    • The shared preview is ready. This allows your PR reviewers to see your changes in an app preview.
  3. Click Open pull request.
  4. Review the details of your pull request, and create it.
  5. When you're ready, merge the pull request.
  6. In the app editor, open the Version History tab and click to sync the app builder with the remote changes. Create a new thread to continue building.

Tag a release

By default, when you create a new version of your published app with no tag, end users are automatically shown the most recent published version of your app. To show app users a particular published version of your app, tag a new release.

Tag a previously published version using the following steps:

  1. In the navbar, click to open the Version History pane. Switch to the Publish history tab, which shows all published versions.
  2. Find your desired published version, and click the icon.
  3. In the Publish release modal that opens, choose whether you want to tag your release as a Major, Minor, or Patch version.
  4. In response to Which version should be published?, choose one of several options:
    • Latest commit: The latest published version will be tagged as the new release, and all future published versions will be automatically released to users.
    • This tagged release: This published version will be tagged as the new release, and all end users of your app will see this version.
  5. Click Publish release.

Restore a previous version

You can restore a previous version of your app to a new feature branch using the following steps:

  1. In the navbar, click to open the Version History pane and click + to Start a new thread.
  2. In the Version History pane, switch to the Publish history tab, which shows all published versions.
  3. Find your desired published version, and click Restore. After a few moments, the preview canvas updates to show that version of the app.
  4. You can then make any further changes to your app.

To publish the restored version that is on your branch, follow the steps for creating a new published version.

Sync changes with remote

To sync the changes on your branch with remote, click to open the Version History pane, and click the button to sync. If your branch is out of sync, a banner appears in the status bar at the bottom of the app builder:

  • There is a new version of your branch: The banner shows a message that says Changes made by [contributor] are waiting for you.
  • There is a new version of the main branch: The banner shows a message that says A new version of this app has been published.

Click the alert in the status bar to ask the agent to integrate the changes.