Listing files

You can display two categories of files. Objects under Rational® Synergy control are discussed in the -l command option. Files that exist only in the file system are discussed in the -m command option.

A new pseudo-property named relative_path is available for all controlled objects listed by a ccm ls command. This property is the relative path within the context project for that object, using a directory field separator of / on all platforms. If the object is not a member of the specified context project, by default the property is shown as an empty string.

About this task

The ls command operates on UNIX operating systems only.

ccm ls -p|-project [-m] ([-l] | [-f|-format format]) [-R] [-nf|-noformat] 
        ([-ch|-column_header] | [-nch|-nocolumn_header]) 
        [-sep|-separator separator] ([-sby|-sortby sortspec] | 
        [-ns|-nosort|-no_sort]) [-gby|-groupby groupformat] project_spec...
ccm ls [-m] ([-l] | [-f|-format format]) [-R] [-nf|-noformat] 
        ([-ch|-column_header] | [-nch|-nocolumn_header]) 
        [-sep|-separator separator] ([-sby|-sortby sortspec] | 
        [-ns|-nosort|-no_sort]) [-gby|-groupby groupformat] 
        [path_or_file_spec...]
-ch|-column_header
Specifies to use a column header in the output format. See -ch|-column_header for details.
-f|-format format
Specifies the command output format. See -f|-format for details.

A keyword can be built in (%fullname, %displayname, %objectname) or the name of any existing attribute such as %modify_time or %status.

See Built-in keywords for a list of keywords.

-gby|-groupby groupformat
Specifies how to group the command output. See -gby|-groupby for details.
-l
Specifies to use a long default format. Use this format when a user-defined format is not specified with -f|-format.
-m
Shows both uncontrolled files and directories and controlled ones. If no user-defined format has been specified with the -f|-format option, the default format (short or long form) includes a column that indicates the synchronization status for files as follows:
  • Local copy ((LC)

    Denotes files that are in the project, but have a local copy rather than a symbolic link in the work area.

    If files are displayed with this mark and your work area is link-based, perform a reconcile operation. For more information, see the reconcile command.

  • Not synchronized (NS)

    Denotes files that are in the project, but not in the work area. This situation occurs when you add files to the project, but your work area is not visible, or when the link or local copy of a file is deleted.

    If most of the files in your work area are displayed with this mark, perform a reconcile operation. For more information, see the reconcile command.

  • Uncontrolled (UC)

    Denotes files that are in the work area, but not in the project. To view uncontrolled files marked with UC, you must use the -m option with the -l option.

    In user-defined formats, you can use the %Sync keyword to show the synchronization status.

    If the object is more than six months old, the year is shown instead of the time.

-nch|-nocolumn_header
Specifies not to use a column header in the output format. See -nch|-nocolumn_header for details.
-nf|-noformat
Specifies not to use column alignment. See -nf|-noformat for details.
-ns|-nosort|-no_sort
Specifies not to sort the command output. See -ns|-nosort for details.
path_or_file_spec
Specifies the path to be listed. You can set the path_or_file_spec to a project, directory, or file defined in the database. This path can also be an empty directory entry. If omitted, the current working directory is listed. See File specification for details.
-p|-project
Shows the history of a project.
project_spec
Specifies the project to list. See Project specification for details.
-R
Displays subdirectory members recursively. The command does not recurse into subprojects.
-sby|-sortby sortspec
Specifies how to sort the command output. See -sby|-sortby for details.
-sep|-separator separator
Used only with the -f|-format option. Specifies a different separator character. See -sep|-separator for details.

Example

List the current directory in the long format.

ccm ls -l

working john 2008-07-25 11:56 csrc 1 alias.c-4.5 27
working john 2008-07-25 11:56 csrc 1 diff.c-4.5 27
working john 2008-07-25 11:56 csrc 1 move.c-4.5 27
working john 2008-07-25 11:57 csrc 1 start.c-4.5 27


Feedback