[go: up one dir, main page]

File: history

package info (click to toggle)
srecord 1.58-1.1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, stretch
  • size: 5,144 kB
  • ctags: 2,732
  • sloc: cpp: 26,774; sh: 7,053; makefile: 2,889; awk: 187; vhdl: 15
file content (131 lines) | stat: -rw-r--r-- 5,365 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
#
#       srecord - The "srecord" program.
#       Copyright (C) 2007, 2011 Peter Miller
#
#       This program is free software; you can redistribute it and/or modify
#       it under the terms of the GNU General Public License as published by
#       the Free Software Foundation; either version 3 of the License, or
#       (at your option) any later version.
#
#       This program is distributed in the hope that it will be useful,
#       but WITHOUT ANY WARRANTY; without even the implied warranty of
#       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#       GNU General Public License for more details.
#
#       You should have received a copy of the GNU General Public License
#       along with this program. If not, see
#       <http://www.gnu.org/licenses/>.
#

/*
 * RCS uses a slightly different model than aegis wants, so some
 * maneuvering is required.  The command strings in this section assume
 * that the RCS commands ci and co and rcs and rlog are in the command
 * search PATH, but you may like to hard-wire the paths, or set PATH at
 * the start of each.  You should also note that the strings are always
 * handed to the Bourne shell to be executed, and are set to exit with
 * an error immediately a sub-command fails.
 *
 * In these commands, the RCS file is kept unlocked, since only the owner will
 * be checking changes in.  The RCS functionality for coordinating shared
 * access is not required.
 *
 * One advantage of using RCS version 5.6 or later is that binary files are
 * supported, should you want to have binary files in the baseline.
 */

/*
 * This command is used to create a new file history.
 * This command is always executed as the project owner.
 * The following substitutions are available:
 *
 * ${Input}
 *      absolute path of the source file
 * ${History}
 *      absolute path of the history file
 *
 * The "ci -f" option is used to specify that a copy is to be checked-in even
 *      if there are no changes.
 * The "ci -u" option is used to specify that an unlocked copy will remain in
 *      the baseline.
 * The "ci -d" option is used to specify that the file time rather than the
 *      current time is to be used for the new revision.
 * The "ci -M" option is used to specify that the mode date on the original
 *      file is not to be altered.
 * The "ci -t" option is used to specify that there is to be no description
 *      text for the new RCS file.
 * The "ci -m" option is used to specify that the change number is to be stored
 *      in the file log if this is actually an update (typically from aenf
 *      after aerm on the same file name).
 * The "rcs -U" option is used to specify that the new RCS file is to have
 *      unstrict locking.
 */
history_create_command =
    "ci -f -u -d -M -m$c -t/dev/null $i $h,v; rcs -U $h,v";

/*
 * This command is used to get a specific edit back from history.
 * This command is always executed as the project owner.
 * The following substitutions are available:
 *
 * ${History}
 *      absolute path of the history file
 * ${Edit}
 *      edit number, as given by history_\%query_\%command
 * ${Output}
 *      absolute path of the destination file
 *
 * The "co -r" option is used to specify the edit to be retrieved.
 * The "co -p" option is used to specify that the results be printed on the
 *      standard output; this is because the destination filename will never
 *      look anything like the history source filename.
 */
history_get_command =
    "co -r'$e' -p $h,v > $o";

/*
 * This command is used to add a new "top-most" entry to the history file.
 * This command is always executed as the project owner.
 * The following substitutions are available:
 *
 * ${Input}
 *      absolute path of source file
 * ${History}
 *      absolute path of history file
 *
 * The "ci -f" option is used to specify that a copy is to be checked-in even
 *      if there are no changes.
 * The "ci -u" option is used to specify that an unlocked copy will remain in
 *      the baseline.
 * The "ci -d" option is used to specify that the file time rather than the
 *      current time is to be used for the new revision.
 * The "ci -M" option is used to specify that the mode date on the original
 *      file is not to be altered.
 * The "ci -m" option is used to specify that the change number is to be stored
 *      in the file log, which allows rlog to be used to find the change
 *      numbers to which each revision of the file corresponds.
 *
 * It is possible for a a very cautious approach has been taken, in which case
 * the history_put_command may be set to the same string specified above for
 * the history_create_command.
 */
history_put_command =
    "ci -f -u -d -M -m$c $i $h,v";

/*
 * This command is used to query what the history mechanism calls the top-most
 * edit of a history file.  The result may be any arbitrary string, it need not
 * be anything like a number, just so long as it uniquely identifies the edit
 * for use by the history_get_command at a later date.  The edit number is to
 * be printed on the standard output.  This command is always executed as the
 * project owner.
 *
 * The following substitutions are available:
 *
 * ${History}
 *      absolute path of the history file
 */
history_query_command =
    "rlog -r $h,v | awk '/^head:/ {print $$2}'";

# vim: set ts=8 sw=4 et :