Skip to content

Commit ee59e22

Browse files
committed
Remove the book.multilingual field
As it is seems it has never been in real use. See rust-lang#2636
1 parent 4f698f8 commit ee59e22

File tree

3 files changed

+2
-8
lines changed

3 files changed

+2
-8
lines changed

examples/nop-preprocessor.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,6 @@ mod nop_lib {
117117
"book": {
118118
"authors": ["AUTHOR"],
119119
"language": "en",
120-
"multilingual": false,
121120
"src": "src",
122121
"title": "TITLE"
123122
},

src/config.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -420,8 +420,6 @@ pub struct BookConfig {
420420
pub description: Option<String>,
421421
/// Location of the book source relative to the book's root directory.
422422
pub src: PathBuf,
423-
/// Does this book support more than one language?
424-
pub multilingual: bool,
425423
/// The main language of the book.
426424
pub language: Option<String>,
427425
/// The direction of text in the book: Left-to-right (LTR) or Right-to-left (RTL).
@@ -436,7 +434,6 @@ impl Default for BookConfig {
436434
authors: Vec::new(),
437435
description: None,
438436
src: PathBuf::from("src"),
439-
multilingual: false,
440437
language: Some(String::from("en")),
441438
text_direction: None,
442439
}
@@ -820,7 +817,6 @@ mod tests {
820817
title = "Some Book"
821818
authors = ["Michael-F-Bryan <[email protected]>"]
822819
description = "A completely useless book"
823-
multilingual = true
824820
src = "source"
825821
language = "ja"
826822
@@ -859,7 +855,6 @@ mod tests {
859855
title: Some(String::from("Some Book")),
860856
authors: vec![String::from("Michael-F-Bryan <[email protected]>")],
861857
description: Some(String::from("A completely useless book")),
862-
multilingual: true,
863858
src: PathBuf::from("source"),
864859
language: Some(String::from("ja")),
865860
text_direction: None,

tests/init.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ fn base_mdbook_init_should_create_default_content() {
2929
let contents = fs::read_to_string(temp.path().join("book.toml")).unwrap();
3030
assert_eq!(
3131
contents,
32-
"[book]\nauthors = []\nlanguage = \"en\"\nmultilingual = false\nsrc = \"src\"\n"
32+
"[book]\nauthors = []\nlanguage = \"en\"\nsrc = \"src\"\n"
3333
);
3434
}
3535

@@ -94,7 +94,7 @@ fn run_mdbook_init_with_custom_book_and_src_locations() {
9494
let contents = fs::read_to_string(temp.path().join("book.toml")).unwrap();
9595
assert_eq!(
9696
contents,
97-
"[book]\nauthors = []\nlanguage = \"en\"\nmultilingual = false\nsrc = \"in\"\n\n[build]\nbuild-dir = \"out\"\ncreate-missing = true\nextra-watch-dirs = []\nuse-default-preprocessors = true\n"
97+
"[book]\nauthors = []\nlanguage = \"en\"\nsrc = \"in\"\n\n[build]\nbuild-dir = \"out\"\ncreate-missing = true\nextra-watch-dirs = []\nuse-default-preprocessors = true\n"
9898
);
9999
}
100100

0 commit comments

Comments
 (0)