Producing Docs
Once you initialized your repository, writting docs can be done as usual: Use your favorite Microsoft Office apps.
Preview
When committing your OpenXML files, DocAsCode pre-commit and post-commit will automatically convert your .docx
to a markdown preview.
If the source file is located at /path/to/file.docx
, then the preview file can be found at .docascode/markdown/path/to/file.md
and embedded images are location at .docascode/markdown/path/to/file
.
Diff
At any time in the writing process, you may need to see the diff of your files. The usual
git diff
will print the text diff into your console. Otherwise, you can use the following command:
docascode diff --file /path/to/file.docx --base [base revision or base version] --new [new revision or new version]
DocAsCode will produce a comparison of the selected file. Each added or removed item will be displayed as revision marks.
Options --base
and --new
can be either a git revision (branch, tag, commit ID) or a Maven deploy version, provided the file is referenced in chrono.xml.
Notice that this diff feature is only available on Windows, with Powershell and Word Application.