aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAustin Hellyer <[email protected]>2016-11-29 06:56:44 -0800
committerAustin Hellyer <[email protected]>2016-11-29 06:56:44 -0800
commite9ca881b42ed82231d1103b6eb8003be020fac23 (patch)
treeb25c0855e2c2ee940acf7a37a65272c408904e50
parentAdd missing REST methods (diff)
downloadserenity-e9ca881b42ed82231d1103b6eb8003be020fac23.tar.xz
serenity-e9ca881b42ed82231d1103b6eb8003be020fac23.zip
Use html_logo_url instead of a doc script
The script was made with the eventual purpose to build custom docs. This has been replaced by [cargo-external-doc], which was released a few days after the script was added. Since the only other purpose of the script besides adding the image has been fulfilled by another crate, we can just utilize a rustdoc attribute to do this.
-rw-r--r--docs.py12
-rw-r--r--src/lib.rs1
2 files changed, 1 insertions, 12 deletions
diff --git a/docs.py b/docs.py
deleted file mode 100644
index ef00822..0000000
--- a/docs.py
+++ /dev/null
@@ -1,12 +0,0 @@
-import glob
-
-for filename in glob.glob("target/doc/serenity/**/*.html"):
- print('Parsing {}'.format(filename))
- with open(filename) as f:
- content = f.read()
-
- new_content = content.replace('<nav class="sidebar">\n', '<nav class="sidebar"><img src="https://docs.austinhellyer.me/serenity.rs/docs_header.png">\n', 1)
-
- if new_content != content:
- with open(filename, 'w') as f:
- f.write(new_content)
diff --git a/src/lib.rs b/src/lib.rs
index eb8ed78..68402ad 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -75,6 +75,7 @@
//! [examples]: https://github.com/zeyla/serenity.rs/tree/master/examples
//! [`validate_token`]: client/fn.validate_token.html
#![allow(doc_markdown, inline_always, unknown_lints)]
+#![doc(html_logo_url = "https://docs.austinhellyer.me/serenity.rs/docs_header.png")]
#![warn(dead_code, enum_glob_use, if_not_else)]
#[macro_use]