##// END OF EJS Templates
fix: highlight the required configuration and behavior of the fixer tools...
Matt Harbison -
r51335:f4ff5558 stable
parent child Browse files
Show More
@@ -9,6 +9,13 b''
9 Provides a command that runs configured tools on the contents of modified files,
9 Provides a command that runs configured tools on the contents of modified files,
10 writing back any fixes to the working copy or replacing changesets.
10 writing back any fixes to the working copy or replacing changesets.
11
11
12 Fixer tools are run in the repository's root directory. This allows them to read
13 configuration files from the working copy, or even write to the working copy.
14 The working copy is not updated to match the revision being fixed. In fact,
15 several revisions may be fixed in parallel. Writes to the working copy are not
16 amended into the revision being fixed; fixer tools MUST always read content to
17 be fixed from stdin, and write fixed file content back to stdout.
18
12 Here is an example configuration that causes :hg:`fix` to apply automatic
19 Here is an example configuration that causes :hg:`fix` to apply automatic
13 formatting fixes to modified lines in C++ code::
20 formatting fixes to modified lines in C++ code::
14
21
@@ -113,13 +120,6 b' perform other post-fixing work. The supp'
113 mapping fixer tool names to lists of metadata values returned from
120 mapping fixer tool names to lists of metadata values returned from
114 executions that modified a file. This aggregates the same metadata
121 executions that modified a file. This aggregates the same metadata
115 previously passed to the "postfixfile" hook.
122 previously passed to the "postfixfile" hook.
116
117 Fixer tools are run in the repository's root directory. This allows them to read
118 configuration files from the working copy, or even write to the working copy.
119 The working copy is not updated to match the revision being fixed. In fact,
120 several revisions may be fixed in parallel. Writes to the working copy are not
121 amended into the revision being fixed; fixer tools should always write fixed
122 file content back to stdout as documented above.
123 """
123 """
124
124
125
125
@@ -239,7 +239,8 b" usage = _(b'[OPTION]... [FILE]...')"
239 def fix(ui, repo, *pats, **opts):
239 def fix(ui, repo, *pats, **opts):
240 """rewrite file content in changesets or working directory
240 """rewrite file content in changesets or working directory
241
241
242 Runs any configured tools to fix the content of files. Only affects files
242 Runs any configured tools to fix the content of files. (See
243 :hg:`help -e fix` for details about configuring tools.) Only affects files
243 with changes, unless file arguments are provided. Only affects changed lines
244 with changes, unless file arguments are provided. Only affects changed lines
244 of files, unless the --whole flag is used. Some tools may always affect the
245 of files, unless the --whole flag is used. Some tools may always affect the
245 whole file regardless of --whole.
246 whole file regardless of --whole.
@@ -84,10 +84,11 b' Help text for fix.'
84
84
85 rewrite file content in changesets or working directory
85 rewrite file content in changesets or working directory
86
86
87 Runs any configured tools to fix the content of files. Only affects files
87 Runs any configured tools to fix the content of files. (See 'hg help -e
88 with changes, unless file arguments are provided. Only affects changed
88 fix' for details about configuring tools.) Only affects files with
89 lines of files, unless the --whole flag is used. Some tools may always
89 changes, unless file arguments are provided. Only affects changed lines of
90 affect the whole file regardless of --whole.
90 files, unless the --whole flag is used. Some tools may always affect the
91 whole file regardless of --whole.
91
92
92 If --working-dir is used, files with uncommitted changes in the working
93 If --working-dir is used, files with uncommitted changes in the working
93 copy will be fixed. Note that no backup are made.
94 copy will be fixed. Note that no backup are made.
@@ -125,6 +126,13 b' Help text for fix.'
125 Provides a command that runs configured tools on the contents of modified
126 Provides a command that runs configured tools on the contents of modified
126 files, writing back any fixes to the working copy or replacing changesets.
127 files, writing back any fixes to the working copy or replacing changesets.
127
128
129 Fixer tools are run in the repository's root directory. This allows them to
130 read configuration files from the working copy, or even write to the working
131 copy. The working copy is not updated to match the revision being fixed. In
132 fact, several revisions may be fixed in parallel. Writes to the working copy
133 are not amended into the revision being fixed; fixer tools MUST always read
134 content to be fixed from stdin, and write fixed file content back to stdout.
135
128 Here is an example configuration that causes 'hg fix' to apply automatic
136 Here is an example configuration that causes 'hg fix' to apply automatic
129 formatting fixes to modified lines in C++ code:
137 formatting fixes to modified lines in C++ code:
130
138
@@ -231,13 +239,6 b' Help text for fix.'
231 executions that modified a file. This aggregates the same metadata
239 executions that modified a file. This aggregates the same metadata
232 previously passed to the "postfixfile" hook.
240 previously passed to the "postfixfile" hook.
233
241
234 Fixer tools are run in the repository's root directory. This allows them to
235 read configuration files from the working copy, or even write to the working
236 copy. The working copy is not updated to match the revision being fixed. In
237 fact, several revisions may be fixed in parallel. Writes to the working copy
238 are not amended into the revision being fixed; fixer tools should always write
239 fixed file content back to stdout as documented above.
240
241 list of commands:
242 list of commands:
242
243
243 fix rewrite file content in changesets or working directory
244 fix rewrite file content in changesets or working directory
General Comments 0
You need to be logged in to leave comments. Login now