Commit c6d03336 authored by Eric Roman's avatar Eric Roman Committed by Commit Bot

Remove //net/docs/README.txt in favor of a shell script.

The comments regarding generating HTML files no longer seems relevant, as the
canonical reference for working with markdown files in Chromium is
https://chromium.googlesource.com/chromium/src/+/master/docs/README.md#Creating-Documentation

This leaves only some notes about how to re-generate the svg files, which seems
better suited for a shell script.

Change-Id: I943b1d387ae578b698d72a30fe7282fe455b8e63
Reviewed-on: https://chromium-review.googlesource.com/1024511Reviewed-by: default avatarMatt Menke <mmenke@chromium.org>
Commit-Queue: Eric Roman <eroman@chromium.org>
Cr-Commit-Position: refs/heads/master@{#552824}
parent c6a41358
To generate the output HTML from an input markdown file on Unix
machines, execute the command:
PYTHONPATH=../../third_party python -m markdown -f <output>.html <input>.md
On Windows machines, execute:
set PYTHONPATH=..\..\third_party
python -m markdown -f <output>.html <input>.md
(This command line assumes that the net/docs directory is the current
directory; if that's not the case, adjust the path to src/third_party
to be accurate from whatever directory the command is executed from.)
The diagrams included in the network stack documentation were
generated with Graphviz, and both source (.dot) and output (.svg) are
included in the repository. If graphviz is installed, the output may
be regenerated from the source via:
dot dot -Tsvg <name>.dot > <name>.svg
#!/usr/bin/python
# Copyright 2018 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""The diagrams included in the network stack documentation were
generated with Graphviz, and both source (.dot) and output (.svg) are
included in the repository. If graphviz is installed, the output may
be regenerated by running this script."""
import glob
import os
import subprocess
def main():
for dot_filename in glob.glob("*.dot"):
svg_filename = os.path.splitext(dot_filename)[0] + ".svg"
print "Generating %s from %s" % (svg_filename, dot_filename)
subprocess.check_call(["dot", "-Tsvg", dot_filename, "-o", svg_filename])
if __name__ == "__main__":
main()
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment