Version Control Flashcards
Version Control System (VCS)
A system for storing and retrieving variants of items.
Version
A collection of items is a variant of the collection resulting from some modification of one or more of its constituents
Revision
A version stored in a VCS
Baseline
The first revision of a collection of items storied in a VCS
Repository
The store in which a VCS records revisions
Checked in/Committed
When a version is stored in the repository
Checked out/updated
When a version is retrieved from the repository
Working copy
A checked out version of an item
Initial Commit
A collection of items enters a VCS as this.
Trunk
Main line of succession of revisions s is called a trunk and the other lines of succession are branches
Tags
Identifiers to keep track of each revision.
Head revision/tip
The latest revision of a branch
2 main policies to control incompatible commits
File Locking
Concurrent modification and merge
File Locking
Policy to control incompatible commits (1 out of 2) : Items can be retrieved from repository with individual files checked out either read-only or for modification. When for modification files locked, so no one else can check it out for modification until checked in again. One at a time check-out. Avoid incompatible commits.
Concurrent modification and merge
Policy to control incompatible commits (2 out of 2) : Anyone can edit at same time, but once one person commits a new version of working copy, the next person who tries to commit will not be able to until they update his or her working copy. VCS attempts to create new working copy incorporating all changes.
Conflict
If same portion of a file has changes in both the repository and in the old working copy. Then they are asked to resolve it. Resulting version of working copy is then stored as the current revision.
Centralized VCS
It has one repository
Distributed VCS
It has several repositories none of which are considered authoritative
- introduces problems b/c new opportunities for conflicting revisions because a commit to a repository can cause a conflict with a changed revision in that repository there can be conflicts between revisions in different repositories. Only good if there is some advantage to distrusting the repository such as greatly decreased check-in and check-out times
Subversion is Centralized or Descentralized?
Centralized
What kind of commits are in SVN
Atomic
How are SVN repositories referred
To using URLs so that clients can get to them across the internet
How does SVN record entire directory trees
As revisions, so when you commit a file, everything in the directory tree is considered a new revision
How does SVN distinguish Revisions
Natural numbers (empty project has version 0) first commit is version 1 and so on
What happens if someone makes a commit in a project you are working on in SVN?
Your working copy will not be modified and you will not get any sort of notice that this has occurred. Must always ask for the latest version by doing an update.
Always update before doing anything