Publishing
Publishing changes, how long it takes and how to read the result.
When you're happy with the preview, tell your AI:
Publish it.Your AI saves your changes as a new version and runs npx -y @switchboard-host/cli@latest deploy. See
publishing for the first time for exactly what happens.
#How long does it take?
Usually one to three minutes. The first time after adding new building blocks it can take a little longer. Your website stays available in the meantime; at most visitors notice a few seconds' delay.
#Reading the result
Success. Your AI reports that your website is online and gives the address. Open it and check your change. Still seeing the old version? Refresh with Ctrl+F5 (Mac: ⌘ Cmd+Shift+R).
Failed. Your AI gets an explanation in plain language, for example:
✗ Building your website failed.
There's a mistake in src/routes/+page.svelte (line 12).
Your previous version is still online.Your previous version stays online, so there's no rush. Your AI usually fixes it right away and tries again. If not, say: "Publishing failed. Can you fix the error and try again?"
#Seeing all deployments
In the dashboard, open your website and go to Publishes. There you'll see:
- every version you've published, with date, time and description;
- which version is live right now;
- for a failed attempt: what went wrong, in plain language. Click a deployment for all the details.
From here you can also bring back one of your latest versions with one click. See undoing things.
#Publishing without AI
You can also do it yourself. Open your terminal in your website's folder and type:
npx -y @switchboard-host/cli@latest deploy -m "Updated opening hours"The text after -m is a short description of what you changed. You'll see it in the dashboard.