4 Updating a workshop
One of the biggest strengths of Copier is that it allows you to easily update your workshop with any changes that have been made to the template since you first copied it. There are two ways to update (or sync) an existing workshop with the latest changes from the template: update and recopy.
Use
updateto apply template updates to your workshop without overwriting local changes.updatewill compare the version of the template you used when you first copied the template with the current version of the template, and then apply the changes that are different. This also means it won’t overwrite any changes you made to files in your current workshop, for example, if you deleted a file that was in the template, it won’t be copied back.Use
recopyif you want to reapply the template from scratch, which will overwrite any changes you made to the files that were copied from the template. This is useful if you want to reset the workshop to the state of the template. For example, if you deleted a file but want it back from the template or are simply curious to see if there are any new changes that you might want to use.
In both cases, the commands are very similar and also use many of the same options as the copy command. If you want to use the same answers as given when you first copied the template, you can use the --defaults option. Then it will only prompt you for the questions that have changed since the last time you copied the template.
Terminal
uvx copier update --defaults
# Or
uvx copier recopy --defaultsAs with the copy command, the workshop needs to be tracked by Git and must be in a clean state (no changes) for the update and recopy commands to work.