DELTA(1)                   POSIX Programmer's Manual                  DELTA(1)



PPRROOLLOOGG
       This manual page is part of the POSIX Programmer's Manual.  The OS
       implementation of this interface may differ (consult the corresponding
       OS manual page for details of OS behavior), or the interface may not be
       implemented on OS.


NNAAMMEE
       delta -- make a delta (change) to an SCCS file (DDEEVVEELLOOPPMMEENNTT)

SSYYNNOOPPSSIISS
       delta [[-nps]] [[-g _l_i_s_t]] [[-m _m_r_l_i_s_t]] [[-r _S_I_D]] [[-y[[_c_o_m_m_e_n_t]]]] _f_i_l_e...

DDEESSCCRRIIPPTTIIOONN
       The _d_e_l_t_a utility shall be used to permanently introduce into the named
       SCCS files changes that were made to the files retrieved by _g_e_t (called
       the _g_-_f_i_l_e_s, or generated files).

OOPPTTIIOONNSS
       The _d_e_l_t_a utility shall conform to the Base Definitions volume of
       POSIX.1-2008, _S_e_c_t_i_o_n _1_2_._2, _U_t_i_l_i_t_y _S_y_n_t_a_x _G_u_i_d_e_l_i_n_e_s, except that the
       --yy option has an optional option-argument. This optional option-
       argument shall not be presented as a separate argument.

       The following options shall be supported:

       --rr _S_I_D    Uniquely identify which delta is to be made to the SCCS file.
                 The use of this option shall be necessary only if two or more
                 outstanding _g_e_t commands for editing (_g_e_t --ee) on the same
                 SCCS file were done by the same person (login name). The SID
                 value specified with the --rr option can be either the SID
                 specified on the _g_e_t command line or the SID to be made as
                 reported by the _g_e_t utility; see _g_e_t.

       --ss        Suppress the report to standard output of the activity
                 associated with each _f_i_l_e.  See the STDOUT section.

       --nn        Specify retention of the edited _g_-_f_i_l_e (normally removed at
                 completion of delta processing).

       --gg _l_i_s_t   Specify a _l_i_s_t (see _g_e_t for the definition of _l_i_s_t) of deltas
                 that shall be ignored when the file is accessed at the change
                 level (SID) created by this delta.

       --mm _m_r_l_i_s_t Specify a modification request (MR) number that the
                 application shall supply as the reason for creating the new
                 delta. This shall be used if the SCCS file has the vv flag
                 set; see _a_d_m_i_n.

                 If --mm is not used and ''--'' is not specified as a file
                 argument, and the standard input is a terminal, the prompt
                 described in the STDOUT section shall be written to standard
                 output before the standard input is read; if the standard
                 input is not a terminal, no prompt shall be issued.

                 MRs in a list shall be separated by <blank> characters or
                 escaped <newline> characters. An unescaped <newline> shall
                 terminate the MR list. The escape character is <backslash>.

                 If the vv flag has a value, it shall be taken to be the name
                 of a program which validates the correctness of the MR
                 numbers. If a non-zero exit status is returned from the MR
                 number validation program, the _d_e_l_t_a utility shall terminate.
                 (It is assumed that the MR numbers were not all valid.)

       --yy[[_c_o_m_m_e_n_t]]
                 Describe the reason for making the delta. The _c_o_m_m_e_n_t shall
                 be an arbitrary group of lines that would meet the definition
                 of a text file. Implementations shall support _c_o_m_m_e_n_ts from
                 zero to 512 bytes and may support longer values. A null
                 string (specified as either --yy, --yy"""", or in response to a
                 prompt for a comment) shall be considered a valid _c_o_m_m_e_n_t.

                 If --yy is not specified and ''--'' is not specified as a file
                 argument, and the standard input is a terminal, the prompt
                 described in the STDOUT section shall be written to standard
                 output before the standard input is read; if the standard
                 input is not a terminal, no prompt shall be issued. An
                 unescaped <newline> shall terminate the comment text. The
                 escape character is <backslash>.

                 The --yy option shall be required if the _f_i_l_e operand is
                 specified as ''--''.

       --pp        Write (to standard output) the SCCS file differences before
                 and after the delta is applied in _d_i_f_f format; see _d_i_f_f.

OOPPEERRAANNDDSS
       The following operand shall be supported:

       _f_i_l_e      A pathname of an existing SCCS file or a directory. If _f_i_l_e
                 is a directory, the _d_e_l_t_a utility shall behave as though each
                 file in the directory were specified as a named file, except
                 that non-SCCS files (last component of the pathname does not
                 begin with ss..)  and unreadable files shall be silently
                 ignored.

                 If exactly one _f_i_l_e operand appears, and it is ''--'', the
                 standard input shall be read; each line of the standard input
                 shall be taken to be the name of an SCCS file to be
                 processed. Non-SCCS files and unreadable files shall be
                 silently ignored.

SSTTDDIINN
       The standard input shall be a text file used only in the following
       cases:

        *  To read an _m_r_l_i_s_t or a _c_o_m_m_e_n_t (see the --mm and --yy options).

        *  A _f_i_l_e operand shall be specified as ''--''.  In this case, the --yy
           option must be used to specify the comment, and if the SCCS file
           has the vv flag set, the --mm option must also be used to specify the
           MR list.

IINNPPUUTT FFIILLEESS
       Input files shall be text files whose data is to be included in the
       SCCS files. If the first character of any line of an input file is
       <SOH> in the POSIX locale, the results are unspecified. If this file
       contains more than 99999 lines, the number of lines recorded in the
       header for this file shall be 99999 for this delta.

EENNVVIIRROONNMMEENNTT VVAARRIIAABBLLEESS
       The following environment variables shall affect the execution of
       _d_e_l_t_a:

       _L_A_N_G      Provide a default value for the internationalization
                 variables that are unset or null. (See the Base Definitions
                 volume of POSIX.1-2008, _S_e_c_t_i_o_n _8_._2, _I_n_t_e_r_n_a_t_i_o_n_a_l_i_z_a_t_i_o_n
                 _V_a_r_i_a_b_l_e_s for the precedence of internationalization
                 variables used to determine the values of locale categories.)

       _L_C___A_L_L    If set to a non-empty string value, override the values of
                 all the other internationalization variables.

       _L_C___C_T_Y_P_E  Determine the locale for the interpretation of sequences of
                 bytes of text data as characters (for example, single-byte as
                 opposed to multi-byte characters in arguments and input
                 files).

       _L_C___M_E_S_S_A_G_E_S
                 Determine the locale that should be used to affect the format
                 and contents of diagnostic messages written to standard
                 error, and informative messages written to standard output.

       _N_L_S_P_A_T_H   Determine the location of message catalogs for the processing
                 of _L_C___M_E_S_S_A_G_E_S.

       _T_Z        Determine the timezone in which the time and date are written
                 in the SCCS file. If the _T_Z variable is unset or NULL, an
                 unspecified system default timezone is used.

AASSYYNNCCHHRROONNOOUUSS EEVVEENNTTSS
       If SIGINT is caught, temporary files shall be cleaned up and _d_e_l_t_a
       shall exit with a non-zero exit code. The standard action shall be
       taken for all other signals; see _S_e_c_t_i_o_n _1_._4, _U_t_i_l_i_t_y _D_e_s_c_r_i_p_t_i_o_n
       _D_e_f_a_u_l_t_s.

SSTTDDOOUUTT
       The standard output shall be used only for the following messages in
       the POSIX locale:

        *  Prompts (see the --mm and --yy options) in the following formats:

               ""MMRRss?? ""

               "comments? "

           The MR prompt, if written, shall always precede the comments
           prompt.

        *  A report of each file's activities (unless the --ss option is
           specified) in the following format:

               ""%%ss\\nn%%dd iinnsseerrtteedd\\nn%%dd ddeelleetteedd\\nn%%dd uunncchhaannggeedd\\nn"",, <<_N_e_w _S_I_D>,
                   <_n_u_m_b_e_r _o_f _l_i_n_e_s _i_n_s_e_r_t_e_d>, <_n_u_m_b_e_r _o_f _l_i_n_e_s _d_e_l_e_t_e_d>,
                   <_n_u_m_b_e_r _o_f _l_i_n_e_s _u_n_c_h_a_n_g_e_d>

SSTTDDEERRRR
       The standard error shall be used only for diagnostic messages.

OOUUTTPPUUTT FFIILLEESS
       Any SCCS files updated shall be files of an unspecified format.

EEXXTTEENNDDEEDD DDEESSCCRRIIPPTTIIOONN
   SSyysstteemm DDaattee aanndd TTiimmee
       When a delta is added to an SCCS file, the system date and time shall
       be recorded for the new delta. If a _g_e_t is performed using an SCCS file
       with a date recorded apparently in the future, the behavior is
       unspecified.

EEXXIITT SSTTAATTUUSS
       The following exit values shall be returned:

        0    Successful completion.

       >0    An error occurred.

CCOONNSSEEQQUUEENNCCEESS OOFF EERRRROORRSS
       Default.

       _T_h_e _f_o_l_l_o_w_i_n_g _s_e_c_t_i_o_n_s _a_r_e _i_n_f_o_r_m_a_t_i_v_e_.

AAPPPPLLIICCAATTIIOONN UUSSAAGGEE
       Problems can arise if the system date and time have been modified (for
       example, put forward and then back again, or unsynchronized clocks
       across a network) and can also arise when different values of the _T_Z
       environment variable are used.

       Problems of a similar nature can also arise for the operation of the
       _g_e_t utility, which records the date and time in the file body.

EEXXAAMMPPLLEESS
       None.

RRAATTIIOONNAALLEE
       None.

FFUUTTUURREE DDIIRREECCTTIIOONNSS
       None.

SSEEEE AALLSSOO
       _S_e_c_t_i_o_n _1_._4, _U_t_i_l_i_t_y _D_e_s_c_r_i_p_t_i_o_n _D_e_f_a_u_l_t_s, _a_d_m_i_n, _d_i_f_f, _g_e_t, _p_r_s, _r_m_d_e_l

       The Base Definitions volume of POSIX.1-2008, _C_h_a_p_t_e_r _8, _E_n_v_i_r_o_n_m_e_n_t
       _V_a_r_i_a_b_l_e_s, _S_e_c_t_i_o_n _1_2_._2, _U_t_i_l_i_t_y _S_y_n_t_a_x _G_u_i_d_e_l_i_n_e_s

CCOOPPYYRRIIGGHHTT
       Portions of this text are reprinted and reproduced in electronic form
       from IEEE Std 1003.1, 2013 Edition, Standard for Information Technology
       -- Portable Operating System Interface (POSIX), The Open Group Base
       Specifications Issue 7, Copyright (C) 2013 by the Institute of
       Electrical and Electronics Engineers, Inc and The Open Group.  (This is
       POSIX.1-2008 with the 2013 Technical Corrigendum 1 applied.) In the
       event of any discrepancy between this version and the original IEEE and
       The Open Group Standard, the original IEEE and The Open Group Standard
       is the referee document. The original Standard can be obtained online
       at http://www.unix.org/online.html .

       Any typographical or formatting errors that appear in this page are
       most likely to have been introduced during the conversion of the source
       files to man page format. To report such errors, see
       https://www.kernel.org/doc/man-pages/reporting_bugs.html .



IEEE/The Open Group                  2013                             DELTA(1)
