aedist(1) aedist(1) NNAAMMEE aedist - remotely distribute a change SSYYNNOOPPSSIISS aaeeddiisstt --SSeenndd [ _o_p_t_i_o_n... ] aaeeddiisstt --RReecceeiivvee [ _o_p_t_i_o_n... ] aaeeddiisstt --LLiisstt [ _o_p_t_i_o_n... ] aaeeddiisstt --HHeellpp aaeeddiisstt --VVEERRSSiioonn DDEESSCCRRIIPPTTIIOONN The _a_e_d_i_s_t command is used to send and receive change sets to facilitate geographically distributed development. The expected transport mechanism is e-mail, however other mechanisms are equally possible. The basic function is to reproduce a change, so a command like aedist -send | aedist -receive may be used to clone a change, though less efficiently than _a_e_c_l_o_n_e(1). The file format used is designed to withstand mail servers, so activities such as aedist -send | _e_-_m_a_i_l _| _a_e_d_i_s_t _-_r_e_c_e_i_v_e (where _e_-_m_a_i_l represents sending, transporting and receiving your e-mail) will reproduce the change on a remote system. With suitable tools (such as PGP) is it possible to aedist -send | encrypt | _e_-_m_a_i_l _| _d_e_c_r_y_p_t _| _a_e_d_i_s_t _-_r_e_c_e_i_v_e The mechanism is also designed to allow web-based distribution such as aedist -send | _w_e_b_-_s_e_r_v_e_r _-_> _w_e_b_-_b_r_o_w_s_e_r _| _a_e_d_i_s_t _-_r_e_c_e_i_v_e by the use of appropriate CGI scripts and mailcap entries. It is possible to support both a ``push'' model and a ``pull'' model using this command. For suggestions and ideas for various ways to do this, see the Aegis Users Guide. SSEENNDD The send variant takes a specified change, or baseline, and constructs a distribution package containing all of the change attributes and source file attributes and source file contents. The result is compressed, and encoded into a text format which can be sent as e-mail without being corrupted by the mail transfer agents along the way. OOppttiioonnss The following options are understood by the send variant: --BBaasseeLLiinnee This option may be used to specify the source of a project, rather than a change. Implies the _-_E_n_t_i_r_e___S_o_u_r_c_e option, unless over-ridden. --CChhaannggee _n_u_m_b_e_r This option may be used to specify a particular change within a project. When no --CChhaannggee option is specified, the _A_E_G_I_S___C_H_A_N_G_E environment variable is consulted. If that does not exist, the user's _$_H_O_M_E_/_._a_e_g_i_s_r_c file is examined for a default change field (see _a_e_u_c_o_n_f(5) for more information). If that does not exist, when the user is only working on one change within a project, that is the default change number. Otherwise, it is an error. --CCOOmmpprreessss This option may be used to specify that the output is to be compressed. This is the default. --NNoo__CCOOmmpprreessss This option may be used to specify that the output is not to be compressed. --DDeessccrriippttiioonn__HHeeaaddeerr This option may be used to add an RFC 822 style header to the change description being sent, with a From and Date line. This is the default. --NNoo__DDeessccrriippttiioonn__HHeeaaddeerr This option suppresses the description header. --EEnnttiirree__SSoouurrccee This option may be used to send the entire source of the project, as well as the change source files. --NNoott__EEnnttiirree__SSoouurrccee This option may be used to send only source files of a change. This is the default, except for the _-_B_a_s_e_L_i_n_e option. --CCoonntteenntt__TTrraannssffeerr__EEnnccooddiinngg _n_a_m_e This option may be used to specify the content transfer encoding to be used. It may take one of the folliwing values: None No content transfer encoding is to be performed. Base64 The MIME base 64 encoding is to be used. This is the default. Quoted_Printable The MIME quoted printable encoding is to be used. Unix_to_Unix_encode The ancient unix-to-unix encoding is to be used. These encodings may be abbreviated in the same way as comment line options. --AAsscciiii__AArrmmoorr This means the same as the ``-cte=base64'' option above. --NNoo__AAsscciiii__AArrmmoorr This means the same as the ``-cte=none'' option above. --DDEELLttaa _n_u_m_b_e_r This option may be used to specify a particular delta in the project's history to copy the file from, rather than the most current version. If the delta has been given a name (see _a_e_d_n(1) for how) you may use a delta name instead of a delta number. It is an error if the delta specified does not exist. Delta numbers start from 1 and increase; delta 0 is a special case meaning ``when the branch started''. --DDEELLttaa__DDaattee _s_t_r_i_n_g This option may be used to specify a particular date and time in the project's history to copy the file from, rather than the most current version. It is an error if the string specified cannot be interpreted as a valid date and time. Quote the string if you need to use spaces. --OOuuttppuutt _f_i_l_e_n_a_m_e This option may be used to specify the output file. The output is sent to the standard output by default. --PPrroojjeecctt _n_a_m_e This option may be used to select the project of interest. When no --PPrroojjeecctt option is specified, the _A_E_G_I_S___P_R_O_J_E_C_T environment variable is consulted. If that does not exist, the user's _$_H_O_M_E_/_._a_e_g_i_s_r_c file is examined for a default project field (see _a_e_u_c_o_n_f(5) for more information). If that does not exist, when the user is only working on changes within a single project, the project name defaults to that project. Otherwise, it is an error. RREECCEEIIVVEE The receive variant takes a change package created by the send variant and creates an Aegis change (see _a_e_n_c(1)) to implement the change within. Files are added to the change (see _a_e_n_f(1), _a_e_c_p(1), _a_e_r_m(1), _a_e_n_t(1)) and then the file contents are unpackaged into the development directory. The change is then built (see _a_e_b(1)), differenced (see _a_e_d(1)), and tested (see _a_e_t(1)). If all of this is successful, development of the change is ended (see _a_e_d(1)). The automatic process stops at this point, so that a local reviewer can confirm that the change is desired. OOppttiioonnss The following options are understood by the receive variant: --CChhaannggee _n_u_m_b_e_r This option may be used to choose the change number to be used, otherwise one will be chosen automatically. --DDEELLttaa _n_u_m_b_e_r This option may be used to specify a particular delta in the project's history to copy the file from, just as for the _a_e_c_p(1) command. You may also use a delta name instead of a delta number. --DDIIRReeccttoorryy _p_a_t_h This option may be used to specify which directory is to be used. It is an error if the current user does not have appropriate permissions to create the directory path given. This must be an absolute path. Caution: If you are using an automounter do not use `pwd` to make an absolute path, it usually gives the wrong answer. --FFiillee _f_i_l_e_n_a_m_e Read the change set from the specified file. The default is to read it from the standard input. The filename `-' is understood to mean the standard input. --PPrroojjeecctt _n_a_m_e This option may be used to set the project name. If not specified, the project name in the input package will be used, rather than the usual project name defaulting mechanism. --TTrroojjaann This option may be used to treat the change set as if it had a Trojan horse attack in it. --NNoo__TTrroojjaann This option may be used to treat the change set as if it definitely does not have a Trojan horse attack in it. _U_s_e _w_i_t_h _e_x_t_r_e_m_e _c_a_r_e_. You need to have authenticated the message with something like PGP first aanndd know the the author well. SSeeccuurriittyy Receiving changes by e-mail, and automatically committing them to the baseline without checking them, would be a recipe for disaster. A number of safeguards are provided: +o The format of the package is confirmed to be correct, and the package verified for internal consistency, before it is unpacked and acted upon. +o The automatic portion of the process stops when development ends. This ensures that a local reviewer validates the change before it is committed, preventing accidental or malicious damage. +o If the change seeks to update the project _c_o_n_f_i_g file, the automatic process terminates before the build or difference occurs. This is because this file could contain trojans for these operations, so a human must examine the file before the change proceeds any further. +o There is a _p_o_t_e_n_t_i_a_l___t_r_o_j_a_n___h_o_r_s_e _= _[ _s_t_r_i_n_g _]_; field in the project_c_o_n_f_i_g file. Nominate build config files, shell scripts, code generators, _e_t_c here to specify files in addition to the config file which should cause the automatic processing to halt. +o The use of e-mail authentication and encryption systems, such as PGP and GPG, are encouraged. However, it is expected that this processing will occur after _a_e_d_i_s_t _-_-_s_e_n_d has constructed the package and before _a_e_d_i_s_t _-_-_r_e_c_e_i_v_e examines and acts on the package. Verification of the sender is the surest defense against trojan horses. +o Automatic sending and receiving of packages is supported, but not implemented within the aedist command. It is expected that the aedist command will be used within shell scripts customized for your site and its unique security requirements. See the Aegis User Guide for several different ways to do this. +o The more you use Aegis' test management facilities (see _a_e_n_t(1) and _a_e_t(1)) the harder it is for an inadequate change to get into the baseline. DDuupplliiccaattee SSttoorrmmss In a distributed development environment, it is common for change sets to eventually be propagated back to the originator. There are situations (particularly in some star topologies) where several copies of the package will return to the originator. If these change sets are not detected at the review stage, and are propagated out yet again, there is the possibility of an exponential explosion of redundant packages being distributed again and again. To combat this, changes are checked after the files are unpacked, but before and build or difference or test is performed. The ``_a_e_c_p_u _-_-_u_n_c_h_a_n_g_e_d'' command is used to exclude all files that the local repository already has in the desired form. If no change files remain after this, the change is dropped entirely (see _a_e_d_b_u(1) and _a_e_n_c_u(1)). LLIISSTT The list variant can be used to list the contents of a package without actually unpacking it first. The output is reminiscent of the _a_e_g_i_s _-_l_i_s_t _c_h_a_n_g_e_-_d_e_t_a_i_l_s output. OOppttiioonnss The following options are understood by the list variant: --FFiillee _f_i_l_e_n_a_m_e Read the change set from the specified file. The default is to read it from the standard input. --OOuuttppuutt _f_i_l_e_n_a_m_e This option may be used to specify the output file. The output is sent to the standard output by default. Only useful with the -List option. OOPPTTIIOONNSS The following options to this command haven't been mentioned yet: --HHeellpp This option may be used to obtain more information about how to use the _a_e_d_i_s_t program. See also _a_e_g_i_s(1) for options common to all aegis commands. All options may be abbreviated; the abbreviation is documented as the upper case letters, all lower case letters and underscores (_) are optional. You must use consecutive sequences of optional letters. All options are case insensitive, you may type them in upper case or lower case or a combination of both, case is not important. For example: the arguments "-project, "-PROJ" and "-p" are all interpreted to mean the --PPrroojjeecctt option. The argument "-prj" will not be understood, because consecutive optional characters were not supplied. Options and other command line arguments may be mixed arbitrarily on the command line, after the function selectors. The GNU long option names are understood. Since all option names for _a_e_d_i_s_t are long, this means ignoring the extra leading '-'. The "----_o_p_t_i_o_n==_v_a_l_u_e" convention is also understood. FFIILLEE FFOORRMMAATT The file format re-uses existing formats, rather than introduce anything new. This means it is possible to extract the contents of a package even when aedist is unavailable. +o The source files and other information is stored as a _c_p_i_o(1) archive. +o The archive is compressed using the GNU gzip format. Typically primary source files are ASCII text, resulting in significant compression. +o The compressed result is encoded using the MIME base64 encoding. This makes the result approximately 33% larger than the compressed binary would be, but still smaller than the primary sources. The _c_p_i_o archive is used to store etc/project-name This contains the project name to apply the package to, unless over-ridden by the --project command line option. etc/change-set This contains the change attributes and the list of source files and usages, in _a_e_c_s_t_a_t_e(5) format. src/_f_i_l_e_n_a_m_e Each source file in the package (named in _e_t_c_/_c_h_a_n_g_e_-_s_e_t) appears under the _s_r_c_/ directory. Extra files, or files out of order, are a fatal error. EEXXIITT SSTTAATTUUSS The _a_e_d_i_s_t command will exit with a status of 1 on any error. The _a_e_d_i_s_t command will only exit with a status of 0 if there are no errors. EENNVVIIRROONNMMEENNTT VVAARRIIAABBLLEESS See _a_e_g_i_s(1) for a list of environment variables which may affect this command. CCOOPPYYRRIIGGHHTT aedist version .C001 Copyright (C) 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 Peter Miller; All rights reserved. The aedist program comes with ABSOLUTELY NO WARRANTY; for details use the '_a_e_d_i_s_t _-_V_E_R_S_i_o_n _L_i_c_e_n_s_e' command. This is free software and you are welcome to redistribute it under certain conditions; for details use the '_a_e_d_i_s_t _-_V_E_R_S_i_o_n _L_i_c_e_n_s_e' command. AAUUTTHHOORR Peter Miller E-Mail: millerp@canb.auug.org.au /\/\* WWW: http://www.canb.auug.org.au/~millerp/ CCRREEDDIITTSS This program evolved through discussion with a number of people. If I have forgotten anyone, it wasn't intentional. Ralf Fassel Catching trojan horses. Florian Xhumari On the need for pull interfaces. Graham Wheeler HTTP pull interfacing. Reference Manual Aegis 1