[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Commands Reference, Volume 5

unget Command (SCCS)

Purpose

Cancels a previous get command.

Syntax

unget-rSID ] [ -s ] [ -n ] File ...

Description

The unget command allows you to restore a g-file created with get -e before the new delta is created. Any changes are therefore discarded. If you specify a - (dash) for the value of File, standard input is read, and each line of standard input is interpreted as the name of an SCCS file. An end-of-file character terminates input.

If you specify a directory for the File value, the unget command performs the requested actions on all SCCS files that are currently in the process of being edited (those files with the s. prefix).

Once you have run an unget command on a file, you must reissue a get -e command to make changes to the file. The unget command automatically deletes the g-file.

Flags

Each flag or group of flags applies independently to each named file.

-n Prevents the automatic deletion of the g-file. This flag allows you to retain the edited version of the file without making a delta.
-rSID Specifies the new delta that would have been created by the next use of the delta command. You must use this flag if you have two or more pending deltas to the file under the same login name. You can look at the p-file to see if you have more than one delta pending to a particular SID under the same login name. The SID specification must unambiguously specify only one SID to discard, or the unget command displays an error message and stops running.
-s Suppresses displaying the deleted SID.

Exit Status

This command returns the following exit values:

0 Successful completion.
>0 An error occurred.

Example

To discard the changes you have made to an SCCS file after running a get -e command, enter:

unget s.prog.c

Files

/usr/bin/unget Contains the path to the SCCS unget command.

Related Information

The delta command, get command, sact command.

The sccsfile file format.

List of SCCS Commands in AIX General Programming Concepts: Writing and Debugging Programs.

Source Code Control System (SCCS) Overview in AIX General Programming Concepts: Writing and Debugging Programs.


[ Previous | Next | Contents | Glossary | Home | Search ]