From 340252533cdb7b39ce1e091adee9c94314c7b672 Mon Sep 17 00:00:00 2001 From: Simon Sapin Date: Fri, 17 Jul 2015 08:40:27 -0600 Subject: [PATCH] servo: Merge #6655 - Include private items in `./mach doc` and http://doc.servo.org/ (from servo:rustdoc-private); r=Manishearth See https://github.com/rust-lang/rust/issues/15347 Source-Repo: https://github.com/servo/servo Source-Revision: a24783df4be2641afab3aa72626f9c59f90d49af --- servo/etc/rustdoc-with-private | 4 ++++ servo/python/servo/post_build_commands.py | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100755 servo/etc/rustdoc-with-private diff --git a/servo/etc/rustdoc-with-private b/servo/etc/rustdoc-with-private new file mode 100755 index 000000000000..770469ac0640 --- /dev/null +++ b/servo/etc/rustdoc-with-private @@ -0,0 +1,4 @@ +#!/bin/sh +# Skip the strip-private and strip-hidden rustdoc passes +# https://github.com/rust-lang/rust/issues/15347 +rustdoc --no-defaults --passes "collapse-docs unindent-comments" "$@" diff --git a/servo/python/servo/post_build_commands.py b/servo/python/servo/post_build_commands.py index efa315158f84..fbeec5a61934 100644 --- a/servo/python/servo/post_build_commands.py +++ b/servo/python/servo/post_build_commands.py @@ -156,8 +156,10 @@ class MachCommands(CommandBase): else: copy2(full_name, destination) + env = self.build_env() + env['RUSTDOC'] = '../../etc/rustdoc-with-private' return subprocess.call(["cargo", "doc"] + params, - env=self.build_env(), cwd=self.servo_crate()) + env=env, cwd=self.servo_crate()) @Command('browse-doc', description='Generate documentation and open it in a web browser',