File content types and line delimiters

When your team develops software on more than one kind of platform, differences in platform conventions for line delimiters (line termination characters) in text files can affect content merges and other development tasks. Rational Team Concert™ source control stores text files in a normalized format, and follows the workspace platform line delimiter convention when loading a file into a local workspace.

The operating systems that Rational Team Concert source control supports observe different conventions for writing line delimiters in text files. Utilities and applications on Linux® and the UNIX® system normally terminate lines with a single <LF> (line feed, or new line) character; Windows® utilities and applications terminate lines with a two-character <CR><LF> (carriage return, line feed) character sequence.

Differences in line-delimiter conventions can create problems in text files that are edited on computers running different supported operating systems. For example, a file that contains

abc
def
ghi

Would look like this if it were created by a Windows editor such as Notepad and read by a Linux or UNIX system-based editor such as vi:

abc^M
def^M
ghi^M

The text editor on the Linux or UNIX system renders the <CR> character as ^M. The same file would look like this if it were created by the system editor on Linux or the UNIX system and read by the Windows editor:

abc■def■ghi

How Rational Team Concert source control determines a line delimiter to use

By default, when you share a project or check in a newly-created file, Rational Team Concert source control examines the content and sets the file's line delimiter property to the value Platform. (If the file appears to be a binary file or has an inconsistent set of line delimiters, its line delimiter property is set to none (binary).) When you load a file with Platform line delimiter property into a local workspace, Rational Team Concert source control determines the file's MIME content type and sets the line delimiter to match the platform convention for that content type.

Rational Team Concert source control includes a file properties wizard that you can use when you need to change the line delimiter property of one or more files or specify a line delimiter convention to apply to a category of files (based on file name suffix). For more information, see Using the File Properties wizard.


Feedback

Did this help? You can provide feedback at Jazz.net (registration required): Comment in the forums or submit a bug