Updating Your Project¶
Keep your project in sync with the latest template changes using Copier's update mechanism.
Update Command¶
The --exclude flags prevent Copier from overwriting your source code and tests during the update. Only template infrastructure files (configs, CI workflows, Makefile, etc.) are updated.
How It Works¶
Copier uses the .copier-answers.yml file in your project root to track which template version and answers were used. During an update, it computes a three-way diff between:
- The previous template version (your current answers)
- The new template version
- Your local modifications
This allows it to merge template updates with your customizations.
Do not modify .copier-answers.yml
Do not delete or manually edit the .copier-answers.yml file. Copier relies on it to perform updates correctly. If this file is missing or corrupted, Copier cannot determine what has changed and the update will fail.
Reviewing Changes¶
After running the update: