Update your service template
Your project records the template version it was scaffolded from in
.copier-answers.yml. Updating replays the newer template over your project
with a three-way merge, preserving your local changes.
Run the update
From a clean working tree:
copier update --trust --skip-answered--skip-answered keeps your original answers (project name, namespace, and so
on); --trust is required because the template runs tasks and migrations. To
update to a specific version rather than the latest release:
copier update --trust --skip-answered -r v1.42.0Commit the result as a normal MR. Your current template version is always
visible in .copier-answers.yml under _commit.
Resolve conflicts
Where your local edits overlap a template change, copier writes the template’s
side to a *.rej file next to the conflicted file. Apply what makes sense,
delete the .rej, and commit. A clean update produces no .rej files —
searching for them is the quickest completeness check:
find . -name '*.rej' -not -path './.git/*'Migrations run automatically
The template ships _migrations — one-off commands that restructure existing
projects when a template change can’t be expressed as a file diff (for
example, converting tool-version files to a newer format). They run during
copier update for every version between yours and the target, in order. You
don’t invoke them; if one fails, the update stops with that command’s error.
Tested daily. This exact flow — including a synthetic migration proving the machinery end-to-end — is exercised by the update-migration journey test against the latest template releases.
Related reading
- Get Started — scaffolding the project this guide updates
- copier documentation — the underlying update semantics