Skip to content

Commit d8a69ff

Browse files
committed
docs: update README files to clarify usage of XMLDiff and XMLPatch tools for directory processing
1 parent cab2fee commit d8a69ff

File tree

3 files changed

+57
-24
lines changed

3 files changed

+57
-24
lines changed

Docs/README.egosoft

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -214,22 +214,33 @@ For example, if the original XML file is [b]vanilla.xml[/b] and the output direc
214214

215215
[size=125][u]How to apply a tools to a directories[/u][/size]
216216

217-
You can apply the tools to directories. In this case, the tools will apply the diff or patch to all XML files in the directory.
218-
The logic will be a next:
217+
[size=120][u]Applying XMLDiff to directories[/u][/size]
218+
219+
You can apply the XMLDiff tool to directories. In this case, the tool will traverse the directory structure and create diff files for XML files with identical names and relative paths. The process is as follows:
219220
[list]
220-
[*] all input parameters are directories - the tools will apply the diff or patch to all XML files in the directories.
221-
[*] it will recursively gro thru the diff or changed XML files in the directories, respectively to the tool.
222-
[*] for each diff or changed files will be checked a corresponding original XML file in the original directory with the same relative path.
223-
[*] if the original XML file is not found - the diff or changed file will be skipped.
224-
[*] if the original XML file is found - the diff or changed file will be patched with the original XML file and created a new patched XML file in the output directory with the same relative path.
221+
[*] If all input parameters are directories, the tool will create diff files for all XML files in the directories.
222+
[*] The tool will recursively go through the directory structure, using modified files as a "keys" for it
223+
[*] For each changed file, the corresponding original XML file in the original directory with the same relative path will be checked.
224+
[*] If the original XML file is not found, the operation will be skipped.
225+
[*] If the original XML file is found, the diff file will be created in the output directory with the same relative path.
225226
[/list]
226227
Example:
227228

228229
[code=shell]
229230
XMLDiff.exe -o vanilla_dir -m modified_dir -d diff_dir
230231
[/code]
231232

232-
or
233+
[size=120][u]Applying XMLPatch to directories[/u][/size]
234+
235+
You can apply the XMLPatch tool to directories. In this case, the tool will traverse the directory structure and apply the patch to XML files with identical names and relative paths. The process is as follows:
236+
[list]
237+
[*] If all input parameters are directories, the tool will apply the patch to all XML files in the directories.
238+
[*] The tool will recursively go through the directory structure, using diff files as a "keys" for it
239+
[*] For each diff file, the corresponding original XML file in the original directory with the same relative path will be checked.
240+
[*] If the original XML file is not found, the operation will be skipped.
241+
[*] If the original XML file is found, the diff file will be patched with the original XML file, and a new patched XML file will be created in the output directory with the same relative path.
242+
[/list]
243+
Example:
233244

234245
[code=shell]
235246
XMLPatch.exe -o vanilla_dir -d diff_dir -u modified_dir

Docs/README.nexus

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -214,22 +214,33 @@ For example, if the original XML file is [b]vanilla.xml[/b] and the output direc
214214

215215
[size=3][u][i]How to apply a tools to a directories[/i][/u][/size]
216216

217-
You can apply the tools to directories. In this case, the tools will apply the diff or patch to all XML files in the directory.
218-
The logic will be a next:
217+
[size=3][u]Applying XMLDiff to directories[/u][/size]
218+
219+
You can apply the XMLDiff tool to directories. In this case, the tool will traverse the directory structure and create diff files for XML files with identical names and relative paths. The process is as follows:
219220
[list]
220-
[*] all input parameters are directories - the tools will apply the diff or patch to all XML files in the directories.
221-
[*] it will recursively gro thru the diff or changed XML files in the directories, respectively to the tool.
222-
[*] for each diff or changed files will be checked a corresponding original XML file in the original directory with the same relative path.
223-
[*] if the original XML file is not found - the diff or changed file will be skipped.
224-
[*] if the original XML file is found - the diff or changed file will be patched with the original XML file and created a new patched XML file in the output directory with the same relative path.
221+
[*] If all input parameters are directories, the tool will create diff files for all XML files in the directories.
222+
[*] The tool will recursively go through the directory structure, using modified files as a "keys" for it
223+
[*] For each changed file, the corresponding original XML file in the original directory with the same relative path will be checked.
224+
[*] If the original XML file is not found, the operation will be skipped.
225+
[*] If the original XML file is found, the diff file will be created in the output directory with the same relative path.
225226
[/list]
226227
Example:
227228

228229
[code]
229230
XMLDiff.exe -o vanilla_dir -m modified_dir -d diff_dir
230231
[/code]
231232

232-
or
233+
[size=3][u]Applying XMLPatch to directories[/u][/size]
234+
235+
You can apply the XMLPatch tool to directories. In this case, the tool will traverse the directory structure and apply the patch to XML files with identical names and relative paths. The process is as follows:
236+
[list]
237+
[*] If all input parameters are directories, the tool will apply the patch to all XML files in the directories.
238+
[*] The tool will recursively go through the directory structure, using diff files as a "keys" for it
239+
[*] For each diff file, the corresponding original XML file in the original directory with the same relative path will be checked.
240+
[*] If the original XML file is not found, the operation will be skipped.
241+
[*] If the original XML file is found, the diff file will be patched with the original XML file, and a new patched XML file will be created in the output directory with the same relative path.
242+
[/list]
243+
Example:
233244

234245
[code]
235246
XMLPatch.exe -o vanilla_dir -d diff_dir -u modified_dir

README.md

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -212,22 +212,33 @@ For example, if the original XML file is `vanilla.xml` and the output directory
212212

213213
### How to apply a tools to a directories
214214

215-
You can apply the tools to directories. In this case, the tools will apply the diff or patch to all XML files in the directory.
216-
The logic will be a next:
215+
#### Applying XMLDiff to directories
217216

218-
- all input parameters are directories - the tools will apply the diff or patch to all XML files in the directories.
219-
- it will recursively gro thru the diff or changed XML files in the directories, respectively to the tool.
220-
- for each diff or changed files will be checked a corresponding original XML file in the original directory with the same relative path.
221-
- if the original XML file is not found - the diff or changed file will be skipped.
222-
- if the original XML file is found - the diff or changed file will be patched with the original XML file and created a new patched XML file in the output directory with the same relative path.
217+
You can apply the XMLDiff tool to directories. In this case, the tool will traverse the directory structure and create diff files for XML files with identical names and relative paths. The process is as follows:
218+
219+
- If all input parameters are directories, the tool will create diff files for all XML files in the directories.
220+
- The tool will recursively go through the directory structure, using modified files as a "keys" for it
221+
- For each changed file, the corresponding original XML file in the original directory with the same relative path will be checked.
222+
- If the original XML file is not found, the operation will be skipped.
223+
- If the original XML file is found, the diff file will be created in the output directory with the same relative path.
223224

224225
Example:
225226

226227
```shell
227228
XMLDiff.exe -o vanilla_dir -m modified_dir -d diff_dir
228229
```
229230

230-
or
231+
#### Applying XMLPatch to directories
232+
233+
You can apply the XMLPatch tool to directories. In this case, the tool will traverse the directory structure and apply the patch to XML files with identical names and relative paths. The process is as follows:
234+
235+
- If all input parameters are directories, the tool will apply the patch to all XML files in the directories.
236+
- The tool will recursively go through the directory structure, using diff files as a "keys" for it
237+
- For each diff file, the corresponding original XML file in the original directory with the same relative path will be checked.
238+
- If the original XML file is not found, the operation will be skipped.
239+
- If the original XML file is found, the diff file will be patched with the original XML file, and a new patched XML file will be created in the output directory with the same relative path.
240+
241+
Example:
231242

232243
```shell
233244
XMLPatch.exe -o vanilla_dir -d diff_dir -u modified_dir

0 commit comments

Comments
 (0)