Compiler Update - Version Control!
After a very successful beta, the mbed Compiler now officially supports built-in workspace Version Control!
You'll now see new "Commit" and "Revisions" buttons in the toolbar, and driving it should be pretty self explanatory, especially for those familiar with DVCS such as git or mercurial.
Here is the video that shows how you get started:
For anyone who missed the beta introduction, here are the main details:
Overview
You can use the version control features to let you version, branch and merge code, with a nice representation of the state of your project history:
The approach we're taking should be familiar to those of you with experience of distributed version control models (as used by mercurial/git); each program has its own local repository, so you can commit and perform actions on it within your own workspace (such as updating, branching, showing changes).
The main things you can do so far include:
- Commit a version of your project, and view the revision history
- View changes a version made, and compare changes between versions
- Update or revert to a different version
- Branch and merge
Note that you can't do any collaboration aspects with this yet; no pulling, pushing, named branches etc; it is all just local to your workspace project for now. But you can guess what we're working on next...
The Basics
Your program, as before, is the "Working Copy". You can "Commit" changes to its local repository to create new "Revisions". You can see the changes between your current working copy to the previous revision, and changes between revisions.
You can choose to "Update" to a particular revision, which updates your working copy to that revision (e.g. a state of your program in the past). This is the way you can "Branch"; do some commits, update to a previous revision, do some more commits; you now have two branches of development derived from a common revision.
You can then "Merge" a revision, often the head of one branch, in to your working copy. This creates a working copy that is the merge of these two branches, and when you commit, your back to one (less) branch of development.
There is also the option to "Discard" your working copy, and "Revert" your working copy to a particular revision; unlike "Update", this creates a working copy with the changes you need to get back to that previous state, more like an "undo" than a branch.
We hope you find this useful!
That RULES. Thank you!!!!! Can't wait to make use of it.