Table of Contents

Name

wmap - create or modify a workspace-to-snapshot mapping.

Synopsis

wmap add [-Nname -hHost -SSnapshot -DDir] [-M/mountPath -s/SnapshotDir] [-w{concurrent|locking}] [-i{unix|win|mac}] [-{E|I|a} path] ... [-fnqV]
wmap addmount -Nname [-hHost -SSnapshot -M/mountPath] [-s/snapshotDir] [-w{concurrent|locking}] [-i{unix|win|mac}] [-{E|I|a} path] ...
wmap find [-DDir]
wmap list [-Nname] [-hHost] [-SSnapshot] [-DDir]
wmap remove {-Nname | -DDir}
wmap removemount -Nname -M/mountPath
wmap update -Nname [-DDir] [-hHost] [-SSnapshot] [-{a|r|x} path] [-w{concurrent|locking}] [-i{unix|win|mac}] [-{E|I|a} path] ...
wmap update -DDir [-Nname] [-hHost] [-SSnapshot] [-{a|r|x} path] [-w{concurrent|locking}] [-i{unix|win|mac}] [-{E|I|a} path] ...
wmap updatemount -Nname -M/mountPath [-hHost -SSnapshot] [-s/snapshotDir] [-w{concurrent|locking}] [-i{unix|win|mac}] [-{E|I|a} path] ...
wmap validate [-Nname] [-hHost] [-SSnapshot] [-DDir]
wmap listfilters
wmap addignore pattern ...
wmap addimport pattern ...
wmap setignore pattern ...
wmap setimport pattern ...

wmap editserver oldName newName

Description

A workspace is where a user interacts with versions of files stored in the SnapshotCM repository. A workspace consists of a local directory hierarchy, plus some mapping information that associates (or maps) one or more snapshots into the workspace.

wmap creates and manipulates the user's workspace mapping information. A workspace mapping specifies the local directory for a workspace, which snapshots to mount, where in the workspace to mount them, and any mount options.

A workspace must have at least one mounted snapshot. Snapshots can be mounted anywhere in a workspace, including on the root directory of the worskpace, or within another snapshot mount hierarchy. In this case, the more specific mount hides the containing mount.

Actions

add
Add a new workspace mapping. Omitted but required values will be prompted for interactively.
addmount
Add an additional mount to a workspace. Omitted but required values will be prompted for interactively.
find
Find and print a workspace mapping for a directory. The current directory is used if none is specified.
list
List all selected workspace entries. If no selection filters are specified, all entries are selected.
remove
Remove the selected workspace mapping. Entries may be uniquely selected by name or by workspace directory.
removemount
Remove the selected mount definition from the workspace.
update
Update the selected workspace mapping with new information. The first name or directory option selects the workspace mapping to modify.
updatemount
Update the selected mount definition with new information.
validate
Verify the existence of the host and snapshot referenced in the selected workspace entries. Update any correctable information. If no selection filters are specified, all entries are selected.
listfilters
Display the ignore and import filters.
addignore pattern ...
setignore pattern ...
Add to (set) the ignore filter. Files matching the ignore filter are not displayed, and not checked out. See wls(1) for a description of the enhanced shell wild card syntax.
addimport pattern ...
setimport pattern ...
Add to (set) the auto import filter. Files matching the auto import filter are automatically marked for import. See wls(1) for a description of the enhanced shell wild card syntax.
editserver old new
Edit all mappings to update the SnapshotCM server name. The new server name will be the canonical name of the new server, not necessarily the string passed in. This option is designed to edit workspace mappings following a move of a SnapshotCM server to another machine.

Options

-a/workspace/path    (deprecated)
Add /workspace/path to the working set, mark non-recursive.
-DWorkspaceDirectory
Set the local directory path to the root of the workspace. This can be a relative or absolute path.
-E/workspace/path
Exclude the /workspace/path hierarchy from the working set. See also the -I option. The longest path takes precedence.
-f
Force the operation even if it can not be validated. Changes will normally fail if they can not be validated.
-i{unix|win|mac}
Set the end-of-line format for writing 'text' (I/O mode) files in the workspace. Use to override the platform default for situations where the SnapshotCM workspace is to be accessed from a system type different than the SnapshotCM execution platform. SnapshotCM supports 3 end-of-line substitutions:
unix format character: '\n'
win format characters: '\r\n'
mac format character: '\r'
-I/workspace/path
Include the /workspace/path hierarchy in the working set. See also the -E option. The longest path takes precedence.
-hHost
Set the SnapshotCM server containing the snapshot to map. Host can be a name or IP address.
-M/mountPath
Specify workspace directory on which to mount the snapshot. The path is a full path name from the workspace root directory. The default is "/" (snapshot maps to whole workspace).
-n
Show the operations that would happen, but do not execute them.
-NworkspaceName
Set the name of a workspace mapping.
-s/snapshotDirPath
Specify which portion of the snapshot to mount. Default is to mount "/" (the whole snapshot).
-SSnapshotPath
Set the full path of the snapshot to map.
-q
Quiet, do not display normal output messages.
-V
Print internal version and exit.
-w{concurrent|locking}
Set the workspace type. In a concurrent workspace, files are normally left writable and no version control lock is needed to make a change. In a locking workspace, files are normally read-only, and made writable when a version control lock is set. The locking workspace type helps coordinate changes with others using the same snapshot. The concurrent workspace type is great for workspaces attached to private snapshots, and also works better with tools not integrated with SnapshotCM.
-x/workspace/path
Remove /workspace/path from the working set.

Discussion

Earlier versions of SnapshotCM only supported mapping one full snapshot to a full workspace. This version allows multiple snapshots to be mounted. For this to work, each snapshot must be mounted in a different location. Use the -M/mountPath option to specify where to

mount

This version also allows part of a snapshot, specified with the -s option, to be mounted.

Diagnostics

Exit status is 0 if the operation succeeds, 1 if it fails, and >1 if there was a bad option or a network error.

Examples

To create a new workspace mapping (named work) of snapshot /Proj/Rev1 to the directory /work/Rev1, and add all files to the working set, run:

wmap add -Nwork -hHost -S/Proj/Rev1 -D/work/Rev1 -M/ -s/ -I/

To update the working set to exclude the /doc hierarchy, run:

wmap update -N work -E/doc

To rename the workspace mapping to Rev1Work, run:

wmap update -D/work/Rev1 -NRev1Work

To automatically mark all .cpp and .h files for import:

wmap addimport '*.cpp' '*.h'

Files

$HOME/.SnapshotCM.wmap - user mapping table (unix).
%USERPROFILE%\Application Data\SnapshotCM.wmap - user mapping table (windows).
$SNAPSHOTCM_WMAP - environment variable to override above.

See Also

wci(1) , wco(1) , wdiff(1) , whist(1) , wls(1) , wmerge(1) , wremove(1) , wrename(1) , wset(1) , wupdate(1) .


Table of Contents