Guide to Choosing Version Control For Your PCB Design Projects

Zachariah Peterson
|  Created: April 5, 2021  |  Updated: April 6, 2021
Guide to version control

Version control gives development teams the ability to do just as its name implies: control which version of a project or data repository is the master version of a project, with all changes between versions being tracked and timestamped. Version control systems are great for tracking and maintaining entire codebases without the old-school copying, pasting, zipping, and emailing steps most PCB designers are familiar with. There’s also the matter of cloning projects and building a revision history from a code repository.

If you’re a hardware designer, how can you take advantage of version control systems for your hardware project? External version control systems impose an extra step in your workflow, where files need to be checked out, modified, and revisions committed back into version control. Altium Designer users can take advantage of the sync capabilities in Altium 365 to help them mirror their version control system in a managed cloud platform. Users can also migrate their external SVN or Git repository into the version control system on Altium 365.

Why Use Version Control in Your PCB Design Software?

After talking about this topic with multiple designers, I’ve found that larger companies have some interesting ways of cataloging and organizing their projects, PCB docs, schematics, libraries, and any information needed in PCB design projects. Probably the two most common methods for organizing design data is by project, or by file type and part/project number. In any case, when there is an absence of a version control system, a team is probably holding a big group of projects in a folder somewhere.

There are a few instances where it’s a good idea to place your hardware and PCB projects into a version control system

  • There are multiple collaborators working on a project
  • Project revisions need to be tracked over time without making repeated copies of projects
  • A team may need to rollback to a previous version of a project
  • A project needs to be quickly cloned for later reuse
  • Specific files in a project may need to cloned, tracked, and rolled back

Version control systems help streamline all of these tasks, and the choice for a PCB design team is which version control system they should use. Altium Designer users have the option of using the built-in Git repository in Altium 365.

Internal or External Version Control?

The benefit of using the internal version control system in Altium 365 is that any projects in version control can be synced and opened directly in Altium Designer. There’s no manual file checkout process, and project revisions can be synced back into Altium 365 with a few clicks. In addition, everything in a PCB project is eligible for syncing and migration into Altium 365.

However, there are times where keeping an external version control system around is important. PCB design projects can be very complex and can be about much more than just the circuit board, involving mechanicals, a range of documentation, code for embedded software/firmware, and other essentials that are not yet present as managed objects in Altium 365. There’s also the case where a company is dealing with privileged data for a design and is not permitted to place data on a server they don’t directly control. In those cases, it makes sense to sync only the relevant PCB project data, while other data can be kept in the external repository.

Syncing to Internal Version Control with Simple Sync

If you’ve ever used Altium Designer with a version control system, you may have noticed a hidden “.git” folder in your project folders. This folder is Altium Designer’s cue that a version control system is active for this project. As soon this .git folder is recognized in a project folder, Altium Designer will enter Simple Sync mode and will prepare to sync back to Altium 365.

Version control Git
This folder is your cue that a version control system is active for this set of files.

There are a few options for syncing to version control locally:

Create the .git folder locally using the following Git Bash command line entries from your project folder:

  • git init
  • git add *.*
  • git remote add [repo_name] [https://repo_address]

Use TortoiseGit or another tool to create the local .git folder

Use the “Make Available Online” command in the Projects Panel

Once you open the project in Altium Designer, the presence of the .git folder will trigger Simple Sync. You can then use the standard Push and Commit commands to place the project in Altium 365’s formal version control. Using external version control tools allows these repositories to be created locally in batches, and they can be synced back to an Altium 365 Workspace when needed.

Turning Off External Version Control and Migration

When a managed project is opened in Altium Designer, the files are checked out from internal or external version control in the same way. This is a great way for companies with a large amount of data in an external VC as they can ensure their Altium projects are synced up with their primary version control system. However, if you want to migrate entirely to the version control system in Altium 365, there are a few ways to do this.

The simplest way to turn off version control for the project is to delete the .git folder in your project folder. Unfortunately, this removes all the revision history, so it’s not the cleanest way to pull a project out of your external version control system.

Once you do pull the project from your external system, you can then immediately enter the project into Altium 365’s internal version control system with the options listed above. Probably the best option is to use the Project Packager:

  1. Pull the existing managed project from external version control.
  2. Open the pulled project in Altium Designer.
  3. Use the Project Packager within Altium Designer to create a copy of the project.
  4. Sync this new project to the internal version control in Altium 365 using the “Make Available Online” command in the Projects Panel.

The Project Packager will create a snapshot of your project, without the baggage of version control. It will also strip any links to the project if it was previously made available in your Workspace.

Version control Git
Two essential commands for removing a project from external version control.

You can now delete the project from the old repository or abandon the repository altogether. You could also leave this repo for other uses that may be relevant to your project but don’t involve tasks in Altium Designer.

Finally, if you’re more adventurous and want everything synced across version control systems, you’ll need to create a script that performs mirroring. Ari Mahpour was generous enough to write some great articles on creating a Git-based workflow for Altium Designer users:

Also, everything above has been discussed in terms of Git, but you can create managed SVN repositories with version control. Read this guide in the documentation to learn more.

Today’s PCB manufacturers and PCB designers can share project data and easily collaborate using the Altium 365™ platform. PCB design teams can use the internal version control features for design data management, and everything integrates with the world-class design tools in Altium Designer®. Altium 365 lets you share your project data with other designers, manufacturers, and customers in a secure environment.

We have only scratched the surface of what is possible to do with Altium Designer on Altium 365. You can check the product page for a more in-depth feature description or one of the On-Demand Webinars.

About Author

About Author

Zachariah Peterson has an extensive technical background in academia and industry. He currently provides research, design, and marketing services to companies in the electronics industry. Prior to working in the PCB industry, he taught at Portland State University and conducted research on random laser theory, materials, and stability. His background in scientific research spans topics in nanoparticle lasers, electronic and optoelectronic semiconductor devices, environmental sensors, and stochastics. His work has been published in over a dozen peer-reviewed journals and conference proceedings, and he has written 2500+ technical articles on PCB design for a number of companies. He is a member of IEEE Photonics Society, IEEE Electronics Packaging Society, American Physical Society, and the Printed Circuit Engineering Association (PCEA). He previously served as a voting member on the INCITS Quantum Computing Technical Advisory Committee working on technical standards for quantum electronics, and he currently serves on the IEEE P3186 Working Group focused on Port Interface Representing Photonic Signals Using SPICE-class Circuit Simulators.

Related Resources

Related Technical Documentation

Back to Home
Thank you, you are now subscribed to updates.