The source-based method for preserving a Vivado project relies on the separation of project sources from their generated output products. Because 2020.2, all files added to a project reside In the project.srcs directory. All tool-generated output products reside in a parallel directory called project.gen. The source-based method of revision controlling can be achieved by:
- Keeping source files external to the project. Ideally, the source files are kept outside of the Vivado build directory.
- Managing revision control of the source repository. All sources should be managed by
the revision control system. Important: When Vivado is using the source files, they should be writable.
- Managing revision control of the project.xpr file.
- Managing revision control of the project.srcs directory.
- Testing your methodology. Ideally, to ensure no files are missed and the design rebuilds completely from design sources using a script, the design would be regressed at a regular cadence. By rebuilding the design regularly, any issues with the revision control methodology can be caught and addressed in a timely manner.
The project can be re-created by restoring the project.srcs directory and the project.xpr file. The project.xpr file can be opened and the user can proceed with synthesis and implementation.