Sun WorkShop TeamWare 2.1 User's Guide

How to Notify Users of Changes to Workspaces

You can request Configuring to notify you (through an electronic mail message) when a variety of Configuring events occur in a workspace. Notification requests are entered in the file named notification in the Codemgr_wsdata directory.

A notification request consists of the following items:

The following is an example of a notification file that contains three requests:


chip@mach1 bringover-to
BEGIN
dir1/foo.cc
dir2
END
biff@mach2 bringover-to putback-to
BEGIN
.
END
biff@mach2 workspace-move

In the first entry, the user chip@mach1 requests to be notified when the file dir1/foo.cc and any file in the directory dir2 (path names are relative to the workspace root directory) are brought over to the workspace.


Note -

File and directory entries for each event are bracketed by BEGIN/END statements. An empty list, a missing list, or a list that consists of only the "." character indicate that all files and directories in the workspace are registered for notification.


In the second entry, user biff@mach2 requests to be notified when any file in the workspace is brought over to, or put back to, the workspace. The "." character represents all files in the workspace.

In the third entry, biff@mach2 requests to be notified if the workspace is moved. Events that involve entire workspaces (delete, move, reparent) do not accept directory/file lists.

Table 7-5 lists the events for which you can register notification requests:

Table 7-5 Notification Events

Event Name 

Description 

bringover-from 

Send mail whenever files are brought over from the workspace in which the notification file is located.

bringover-to 

Send mail whenever files are brought over to the workspace in which the notification file is located.

putback-from 

Send mail whenever files are put back from the workspace in which the notification file is located.

putback-to 

Send mail whenever files are put back to the workspace in which the notification file is located.

undo 

Send mail whenever a transaction is "undone" in the workspace in which the notification file is located. 

workspace-delete 

Send mail if the workspace in which the notification file is located is deleted. 

workspace-move 

Send mail if the workspace in which the notification file is located is moved. 

workspace-reparent 

Send mail if the workspace in which the notification file is reparented. 

workspace-reparent-to 

Send mail if the workspace becomes the new parent of an existing workspace. 

Viewing and Changing Notification Entries

To view and change notification entries, select a workspace icon in the Workspace Graph pane and choose Options > Workspace. Select Notification from the Category list box. The requests contained in the notification file are similar to those displayed in the Workspace Properties dialog box.

Use the buttons to modify, create, and delete notification entries. Clicking Create Entry or Edit Entry opens the Notification Entry dialog box.

Creating a New Notification Entry

To create a new notification entry:

  1. Click Create Entry with no items selected.

  2. The Notifications Entry dialog box opens; use this dialog box to specify the following information:

    1. Type the mail address to which notification mail is to be sent in the Mail To text box.

      The mail address can be any valid mail address, including an alias.

    2. Select the appropriate radio button for the event about which notification mail is to be sent.

    3. Select the appropriate radio button for the files to which the notification event applies:

      - All for any file in the workspace

      - Specify for specific directories or files

  3. If you choose to specify files or directories, create the list of directories and files in the Files text pane.

    • To add files to the list, click Add to List and select files in the Add Notification Files dialog box

    • To delete files from the list, click Delete or Delete All.

  4. Click Apply to add the entry to the global Notification list.

  5. Click Apply in the Workspace Properties dialog box to apply changes to the notifications file.

Modifying a Existing Entry

To modify an existing entry:

  1. Select the entry in the Notification pane of the Workspace Properties dialog box and click Edit Entry.

  2. Use the Notification Entry dialog box to modify the entry.

  3. Click Apply to modify the entry in the global Notification list.

  4. Click Apply in the Workspace Properties dialog box to apply changes to the notifications file.


    Note -

    The following events involve entire workspaces and thus do not require a directory/file list:workspace-delete, workspace-move, workspace-reparent, workspace-reparent-to.



    Note -

    When a directory is specified in the list, all files hierarchically beneath it are automatically registered.