Tags:
create new tag
, view all tags

Differences Between Subversion and CVS

Subversion is designed as a drop-in replacement for CVS, so it's similar in many ways. However, there are a few changes:

  • Updates always add missing directories, as with the CVS -d flag.
  • Files and directories can be copied, moved, and renamed, all with full versioning and change history maintained back through all name changes.
  • Branches/tags aren't supported as a separate feature. Instead, they are created by simply making server-side versioned copies of the project into a different path. From a conceptual standpoint, if nobody ever commits to the copy, it's a tag. If someone does, it's a branch. Subversion doesn't care -- to it, a branch or tag is simply a new set of names for particular versions of existing files and directories. New commits don't affect other names, so they create a branch in the version history; both branches will show the common revisions toward the root in their logs.
  • Commits are atomic. If a commit fails at any point, all changes are rolled back.
  • Individual files don't have revision numbers. Instead, the entire repository has a single revision number that's incremented for every commit. As such, finding an entire atomic changeset is simply asking for the difference between any two adjacent revisions.
  • Subversion is binary-clean by default, and uses a binary diffing algorithm to maintain space-efficient versioning even on binary files.
  • Subversion has "properties", which are arbitrary versioned key-value pairs that can be attached to any file or directory. It reserves key names starting with "svn:" for special usage by the VCS. Some common keys are:
    • svn:ignore: Instead of using .cvsignore files, Subversion checks the contents of this property.
    • svn:keywords: Unlike CVS, Subversion does not replace $Keyword$ instances by default. This property can be set on a file to list which keywords should be substituted in the file on checkout. For example, Rev will provide the current repository revision.
    • svn:executable: This is actually a boolean setting. If present on a file, Subversion sets the execute permissions on checkout. This is obviously not applicable in a Windows environment.
    • svn:eol-style: Subversion also does not do any line-ending conversion by default. This property can be set to a variety of values to maintain any desired line-ending convention. The most common setting is native, which converts the file to the client platform's appropriate line-endings on checkout, and canonicalizes to LF on checkin.
    • svn:mime-type: Subversion can store the MIME type of a file. Unless set to something besides text/*, Subversion will assume files are human-readable and attempt to provide context diffs for the svn diff command.
  • Subversion has a client configuration file that can be used to set up "autoproperties," which derive appropriate settings for the above based on filename pattern matching.

-- WalterMundt - 29 May 2004

SubversionLineEndings

-- MartinCleaver - 09 Dec 2004

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r3 - 2004-12-09 - MartinCleaver
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.