09.06.2013 Views

Intel XENIX 286 Programmers Guide (86) - Tenox.tc

Intel XENIX 286 Programmers Guide (86) - Tenox.tc

Intel XENIX 286 Programmers Guide (86) - Tenox.tc

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>XENIX</strong> Programming sees: Source Code Control System<br />

Creating an s-file<br />

You can create an s-file from an existing text file using the -i (for "initialize") option of<br />

the admin command. The command has the form<br />

admin -ifilename s. filename<br />

where -ifilename gives the name of the text file from which the s-file is to be created,<br />

and s.filename is the name of the new s-file. The name must begin with s. and must be<br />

unique; no other s-file in the same directory may have the same name. For example,<br />

suppose the file named demo.c contains the short C language program<br />

#include <br />

main ()<br />

{<br />

printf("This is version 1.1 \n");<br />

}<br />

To create an s-file, type<br />

admin -idemo.c s.demo.c<br />

This command creates the s-file s.demo.c and copies the first delta describing the<br />

contents of demo.c to this new file. The first delta is numbered 1.1.<br />

After creating an s-file, the original text file should be removed using the rm command.<br />

It is no longer needed. If you wish to view the text file or make changes to it, you can<br />

retrieve the file using the get command described in the next section.<br />

When you are first creating an s-file, the admin command may display the warning<br />

message<br />

No id keywords (cm7)<br />

In general, this message can be ignored unless you have specifically included keywords in<br />

your file (see the section "Using Identification Keywords" later in this chapter).<br />

Note that only a user with write permission in the directory containing the s-file may<br />

use the admin command on that file. This protects the file from adm inistration by<br />

unauthorized users.<br />

Retrieving a File for Reading<br />

You can retrieve a file for reading from a given s-file by using the get command. The<br />

command has the form<br />

get s.filename • • .<br />

5-5

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!