sccs(1)								      sccs(1)



NAME

  sccs - Administration program for Source Code Control System (SCCS) com-
  mands

SYNOPSIS

  sccs [-r] [-d pathname] [-p pathname] command [flags] [file ...]

  The sccs command is an administration program that incorporates the set of
  SCCS commands into the Operating System.

FLAGS

  -d[pathname]
      Specifies a root directory for the SCCS files.  The default is the
      current directory. The pathname argument is prepended to the entire
      pathname of a file. This flag takes precedence over the PROJECTDIR
      variable.

  -ppathname
      Specifies a pathname for the SCCS files. The default is the SCCS direc-
      tory.  The pathname argument is inserted before the final component of
      the pathname.  All flags specified after command are passed to that
      command during execution.	 (For a description of command flags, see the
      appropriate command description.)	 For example, the command sccs -d/x
      -py get a/b converts to get /x/a/y/s.b.  This can be used to create
      aliases.	For example, the command alias syssccs sccs -d/usr/abc/sccs
      makes syssccs an alias that can be used in commands like syssccs get
      cmd/who.c.

      If the PROJECTDIR environment variable is set, its value is used to
      determine the -d flag value. If PROJECTDIR begins with a / (slash), the
      value is used directly; otherwise, the home directory of a user of that
      name is examined for a subdirectory named src or source.	If found,
      that subdirectory is used.  Certain commands, such as the admin com-
      mand, cannot be run using the set user id command, as this would allow
      anyone to change the authorizations.  Such commands are always run as
      the real user.

  -r  Runs the sccs command as the real user, rather than as the effective
      user to which the sccs command is set.  Certain commands (admin, check,
      clean, diffs, info, rmdel, sccsdiff, tell) cannot be run set-user-ID by
      all users, since this would allow anyone to change the authorizations.
      These commands are always run as the real user.

DESCRIPTION

  The sccs command can be used to assign or reassign file ownership.

  The sccs command activates a specified command with the specified flags and
  arguments.  Each file is placed in a directory named SCCS and named
  s.filename.  The directory SCCS is assumed to exist relative to the current
  directory (unless the -p flag is used).

  Two types of commands can be used in the sccs command syntax sentence.  The
  first type are the 14 sccs commands that can be entered at a prompt.	The
  second type are called pseudocommands; they can be used only as part of the
  sccs command syntax. There are 12 pseudocommands, which perform the
  following actions:

  check
      Prints all the files being edited. Returns a nonzero exit status if a
      file is being edited.  The check program puts the nonzero status indi-
      cator in an install entry in a makefile to verify that the SCCS file is
      complete before installing a version. Nothing is printed if nothing is
      being edited.

      Flags:

      -b  Ignores branches in determining which files are being edited.

      -u [user]
	  Lists only the files being edited by you or the user named by user.

  clean
      Removes from the current directory or the named directory all files
      that can be recreated from SCCS files.  Does not remove files that are
      in the process of being edited.

      Flag:

      -b  Ignores branches in determining which files are being edited.
	  (Note: branches in the same directory can be lost.)

  create
      Creates an SCCS file, copying the initial contents from a file of the
      same name.  If the file creation is successful, the original file is
      renamed with a comma on the front.  It is not necessary for you to move
      or remove the original file (as is the case with the admin command).

      Flags: Accepts the same flags as the admin command.

  delget
      Performs a delta command on the named files and then gets a new ver-
      sion.  The new version of the files has expanded identification key-
      words, and cannot be edited.

      Flags:

      -m, -p, -r, -s, -y
	  Can be passed to the delta command.

      -b, -c, -e, -i, -k, -l, -s, -x
	  Can be passed to the get command.

  deledit
      Equivalent to the delget pseudocommand, except that the get portion of
      the sentence includes the -e flag.  The deledit option is useful for
      creating a checkpoint in your current editing session.

      Flags:

      -m, -p, -r, -s, -y
	  Can be passed to the delta command.

      -b, -c, -i, -l, -s, -x
	  Can be passed to the get command.

  diffs
      Shows the difference between the current version of the files you are
      editing and the versions in SCCS format.

      Flags:

      -r, -c, -i, -x, -t
	  Can be passed to the get command.

      -l, -s, -e, -f, -h, -b
	  Can be passed to the system diff (not SCCS) command.

       -C Can be passed to the system diff (not SCCS) command as a -c flag.

  edit
      Equivalent to the get -e command.

  enter
      Creates an SCCS file, copying the initial contents from a file of the
      same name.  If the file creation is successful, the original file is
      renamed with a , (comma) at the beginning of the old filename.  This
      pseudocommand is similar to create, except that enter does not perform
      the equivalent of an SCCS get command, and retrieves a read-only ver-
      sion of the newly created file.  This pseudocommand is useful when you
      want to use an SCCS edit command immediately after creating an SCCS
      file.

  fix Removes a named delta, but leaves a copy of the delta with changes
      intact.  This option is useful for fixing small compilation errors.
      This command does not keep a record of changes made to the file.	The
      -r must be followed by a SID option flag.

      Flag:

      -r  Required flag.

  info
      Lists all the files being edited.

      Flags:

      -b  Ignores branches in determining which files are being edited.

      -u [user]
	  Lists only the files being edited by you or the user named by user.

  print
      Prints information about named files.  This SCCS pseudocommand is
      equivalent to the SCCS command prs.

  tell
      Lists all the files being edited on standard output, with a newline
      after each entry.

      Flags:

      -b  Ignores branches in determining which files are being edited.

      -u [user]
	  Lists only the files being edited by you or the user named by user.

  unedit
      Equivalent to the unget command.	Note that any changes made since the
      get command was used are lost.


RESTRICTIONS

  In some other versions of the utility, the command runs with the UID of a
  pseudo-user named sccs.  This difference can create compatibility problems
  with permissions, especially in networked environments.

EXAMPLES

   1.  To get a file for editing, edit it, and produce a new delta, enter:
	    $ sccs get -e file.c
	    $ ex file.c
	    $ sccs delta file.c


   2.  To get a file from another directory, enter:
	    sccs -p/usr/abc/sccs get cc.c


   3.  To make a delta of a large number of files in the current directory,
       enter:
	    sccs delta *.c


   4.  To get a list of files being edited that are not on branches, enter:
	    sccs info -b


   5.  To make a delta of everything being edited by you, enter:
	    sccs delta `sccs tell -u`


   6.  In a makefile, to get source files from an SCCS file if it does not
       already exist, enter:
	    REL = 1.7
	    SRCS = 
	    $(SRCS):
		    sccs get $(REL) $@


RELATED INFORMATION

  Commands: admin(1), cdc(1), comb(1), delta(1), get(1), prs(1), rmdel(1),
  sact(1), sccsdiff(1), sccshelp(1), unget(1), val(1), what(1).

  Files:  sccsfile(4).