Skip to main content

Managing Non-Application Files in Your Environment Branch

Safely update non-application files (README.md, workflows, scripts) in your environment branch using Manage branch files. Avoid sync issues - use pull requests instead of direct commits.

Kirk DeBaets avatar
Written by Kirk DeBaets
Updated over a week ago

What is "Manage branch files"?

The "Manage branch files" feature lets you safely update files in your environment branch that aren't part of your application configuration. This includes files like:

  • README.md

  • GitHub Action workflows

  • Automated testing scripts

  • Documentation files

  • CI/CD configurations

Why can't I just update these files directly in Git?

Important: If you update branch files directly in your Git repository (through GitHub, GitLab, etc.), Salto will lose the ability to synchronize with that branch. When this happens, Salto must roll back all commits to the last point where it could successfully update the branch. This means you could lose work and create conflicts.

Think of it this way: Salto needs to be the one "driving" when it comes to updates on your environment branch, even for non-configuration files.

The correct process

  1. Create a feature branch in your Git repository (not directly on your environment branch)

    • Name it something descriptive like update-readme or fix-github-workflow

  2. Make your changes on the feature branch and commit them

    • Make sure your changes do not include any .nacl files or other application configuration changes

  3. Create a Pull Request from your feature branch to your environment branch

  4. Navigate to Salto:

    • Go to your environment's Settings tab

    • Select Version Control

    • Click the "Select pull request to merge" button under "Manage branch files"

  5. Select your PR and let Salto merge it

That's it! Salto will safely merge your changes while maintaining synchronization.

What if I already updated files directly?

If you've already committed changes directly to your environment branch, you'll need to roll back those commits to the last point where Salto could successfully update the branch. Contact support if you need help with this recovery process.

Quick reminder

βœ… Do: Create a feature branch β†’ Create a PR β†’ Use "Manage branch files"
❌ Don't: Commit directly to the environment branch or include .nacl files in your PR

Did this answer your question?