In order to better manage my development of Quartus HDL projects I decided to start using source control software. This allows me to easily see the changes I’ve made through the use of diff tools and actually forces me to document the changes I’m making, while giving me the ability to rollback those changes at any time.

A lot of the source control tools are designed for large traditional software development teams which include a lot of tools for branching and merging. I wanted a widely accepted tool, but one without too much of a learning curve and simple enough to work for the development team consisting of just me.

The big names in source control right now seem to be: Subversion, Git, and Mercurial. Some GUI tools are also available to help you from having to wrestle with the command line: TortoiseSVN, Git GUIs, and TortoiseHg .

After trying all three I found Mercurial with TortoiseHg was the best fit for my workflow.

Here is a nice Quick start Guide to TortoiseHg: http://tortoisehg.bitbucket.org/manual/1.1/quick.html

Even though I’m not doing much collaborative development right now, I think it’s good to understand the different collaboration models available in Mercurial, this link does a good job explaining them: http://hgbook.red-bean.com/read/collaborating-with-other-people.html


.hgignore File

One of the important bits needed to get Mercurial/TortoiseHg working with Quartus projects is correctly setting up the hgignore file. This is the file that tells Mercurial what files not to track. Typically, you only want source control tools to track human created code.

As of right now this is the hgignore file I’ve come up with, which I thought might be useful to share. (I haven’t done a ton of rolling back to test this yet, so your mileage may vary)

# use glob syntax
syntax: glob

*.flock
*.rpt
*.done
*.summary
*.smsg
*.qmsg
*.pof
*.sof
*.rbf
*.jdi
*.cdb
*.hdb
*.rdb
*.ddb
db/**
incremental_db/**

Feel free to leave a comment and let me know if this is useful to you, or if you have any recommended changes to the hgignore template above.