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 using threads in the Chat tab or manually in the Code tab. Branches are managed from the Change History tab. Learn more about threads and branches.

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 changes as 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.

note

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 Open pull request 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. If you need to make any further changes, add them to your pull request by clicking Push changes.
  6. When you're ready, merge the pull request.
  7. In the app editor, open the Change History tab and click to sync the app builder with the remote changes. Continue building on the same branch, or click + to create a new branch.

Tag a release

By default, published changes to your app are visible to all users who have View access to that app. Leverage release tagging to apply semantic versioning to your app releases, and configure publishing behavior to show users a particular release.

  1. While publishing your app, expand the Tags & publishing section.
  2. Choose whether you want to tag your changes as a Major, Minor, or Patch release.
  3. In response to Which tag should be pinned for publishing?, choose:
  • Latest changes: The latest published changes are automatically shown to app users.
  • Current tag: The currently published tag will remain published.
  • This tag: These changes will be tagged as a new release, and all end users of your app will see this version.

Configure publishing behavior

After tagging changes as a release, you can configure your app's publishing behavior from the footer of the Change History > Publish history tab at any time. In response to Which tag should be pinned for publishing?, choose:

  • Always publish latest changes: The latest published changes are automatically shown to app users.
  • Select from a list of tagged releases.

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 Change History pane and click + to Start a new thread.
  2. In the Change 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 Change 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.