Skip to content

Commit 1c3979c

Browse files
author
Bastian Gruber
committed
Add book.toml to tools/unstable, add copy_book_toml to scipt
1 parent 20dbf28 commit 1c3979c

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
[book]
22
title = "The Rust Unstable Book"
3+
author = "The Rust Community"

src/tools/unstable-book-gen/src/main.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,11 @@ fn copy_recursive(path: &Path, to: &Path) {
116116
}
117117
}
118118

119+
fn copy_book_toml(path: &Path) {
120+
let mut file = t!(File::create(&path.join("book.toml")));
121+
t!(file.write_fmt(format_args!(include_str!("book.toml"));
122+
}
123+
119124
fn main() {
120125
let src_path_str = env::args_os().skip(1).next().expect("source path required");
121126
let dest_path_str = env::args_os().skip(2).next().expect("destination path required");
@@ -141,4 +146,6 @@ fn main() {
141146
copy_recursive(&doc_src_path, &dest_path);
142147

143148
generate_summary(&dest_path, &lang_features, &lib_features);
149+
150+
copy_book_toml(&dest_path);
144151
}

0 commit comments

Comments
 (0)