Skip to content

Backing up an App to GitHub ​

You can connect your own GitHub account and back up an App to a repository — with its complete edit history, not just its current state. You can also import a repository as a new App, and pull changes from GitHub back into your App. Everything here applies to Apps; other artifact types don't use GitHub.

Find it in the App editor: open your App, choose File, after the three tabs on the left of the top bar, then Export, then GitHub. GitHub is linked to your own account, so it is the App owner's alone — a collaborator doesn't see it.

Connect your GitHub account ​

In the GitHub window, choose Connect GitHub. A window opens for you to sign in to GitHub and approve access, then closes on its own. If your browser blocks that window, the editor says Popup blocked — allow pop-ups and choose Connect GitHub again. Once connected, the window shows the account you're connected as, and you can Disconnect at any time. You only connect once — the same connection is used for backing up, importing, and syncing.

Back up your App to a repository ​

In Export, enter a Repository name, tick Private repository if you want it, and select Export to GitHub. Your App's code is pushed to that repository on your GitHub account, and the repository opens so you can confirm it landed. If the repository doesn't exist yet, it's created for you. The backup holds your App's code and settings; the pictures, video and other files in its Assets are not pushed to GitHub — to keep a copy of everything, including those files, use Download (.zip).

Your App's full edit history comes along ​

Backing up pushes your App's entire version history — every saved version becomes a commit in the repository, in order, exactly like a normal project's history. It is not flattened into one commit. This means your GitHub repository is a faithful, browsable record of how your App evolved, and re-backing-up later adds your newer versions on top rather than replacing what's there.

Every publish backs up too ​

Once your App has been backed up to a repository, every publish also pushes it there. The published version in your File menu then shows the GitHub commit it was exported at, under its Restore list.

If GitHub can't be reached, or you have disconnected your account, the publish still goes through; your App is simply not backed up that time. Back up again from the GitHub window, or publish again once GitHub is reachable.

Files that let your App run on its own ​

The backup includes a few extra files so the repository can run without MotherFluxer: a Dockerfile, a docker-compose.yml, a .env.example listing the settings to fill in, and an EJECT.md that explains how each feature maps to standard tools. Its pages serve straight away, but anything your App used from MotherFluxer — its data, AI, storage or email — stops at the first call until you provide your own version of it. EJECT.md lists each one with its standard equivalent, so you can start with the features your App actually uses and leave the rest. If your App already includes its own version of one of these files, yours is kept. If your App uses its own private database, the example settings point at it so your data comes with you.

When a backup asks you to overwrite ​

If the repository already has changes that don't line up with your App's history — for example, someone committed to it directly on GitHub, or you pulled GitHub's changes into your App and then tried to back up again — the backup stops and asks before doing anything. Its confirmation, Replace the GitHub history?, says what each choice does — To keep both, Export under another name — or choose Overwrite history to replace the repository's contents with your App's version. Overwriting can't be undone, so it always asks first.

Separately, if someone happens to push to the repository during the few seconds a backup takes, the backup is refused rather than applied. Nothing of theirs is overwritten and nothing of yours is lost — back up again and it builds on top of their commit.

Import a repository as a new App ​

In Import, enter the Repository to import as owner/repo — or paste its github.com address — and select Import from GitHub. If what you typed doesn't name a repository, the panel says Enter a repo as owner/repo under the field, and the button waits until it does.

MotherFluxer pulls the repository's text files and assembles them into a brand-new App, and the panel reports how it goes right under the button: the button reads Importing… while the App is assembled, then a line says the import is done and that you can open the new App from your gallery. If it failed, a message at the centre of the screen says so, and why. A large repository can take a while; the line then says it is still importing, and the App appears in your gallery when it is ready. Importing never changes the App you're currently in — it always creates a new one.

Keep your App and its repository in sync ​

Once an App is linked to a repository, Sync shows its Repository and the sync status — whether your App is up to date, has local changes not yet backed up, or the repository has new commits you haven't pulled.

Choose Pull from GitHub to bring the repository's latest changes into your App. The pull runs on our side, so you can keep working: the button reads Pulling… until it finishes. A clean pull says, right there in the panel, to reopen the App to see the merged files. A pull that failed, or couldn't start, says so at the centre of the screen, with the reason. If you come back to an App whose last pull failed, Sync still shows it under Last pull, with the reason, until you pull again.

If a change on GitHub and a change you made in the App touch the same lines, the panel says how many conflicts the last pull had. The pull marks each one inline in the file with <<<<<<< markers, so reopen the App, resolve them in the editor, then back up or publish again — the same way you'd resolve a merge conflict anywhere.

Backing up is not publishing ​

Backing up to GitHub saves your App's code to a repository you control; it does not put your App online for others to open. To share a running App by link, QR code, or your own domain, publish it in Manage › Publish instead.