From 44f51402f7038054074c7cd0df80a8af8f4525e8 Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Sun, 17 Oct 2021 21:06:57 +0200 Subject: [PATCH] Upgrade to zola 0.14.1 --- .github/workflows/blog.yml | 4 +- blog/config.toml | 64 +++++++++++++------ .../03-returning-from-exceptions/index.md | 2 +- .../edition-1/posts/08-kernel-heap/index.md | 2 +- blog/sass/css/edition-2/main.scss | 1 - blog/templates/edition-2/index.html | 18 +++--- blog/templates/edition-2/macros.html | 2 +- blog/templates/edition-2/page.html | 16 ++--- blog/templates/rss.xml | 2 +- 9 files changed, 65 insertions(+), 46 deletions(-) diff --git a/.github/workflows/blog.yml b/.github/workflows/blog.yml index 882b8fad..bce2bc34 100644 --- a/.github/workflows/blog.yml +++ b/.github/workflows/blog.yml @@ -20,7 +20,7 @@ jobs: - uses: actions/checkout@v1 - name: 'Download Zola' - run: curl -sL https://github.com/getzola/zola/releases/download/v0.12.1/zola-v0.12.1-x86_64-unknown-linux-gnu.tar.gz | tar zxv + run: curl -sL https://github.com/getzola/zola/releases/download/v0.14.1/zola-v0.14.1-x86_64-unknown-linux-gnu.tar.gz | tar zxv - name: 'Install Python Libraries' run: python -m pip install --user -r requirements.txt working-directory: "blog" @@ -46,7 +46,7 @@ jobs: - uses: actions/checkout@v1 - name: 'Download Zola' - run: curl -sL https://github.com/getzola/zola/releases/download/v0.12.1/zola-v0.12.1-x86_64-unknown-linux-gnu.tar.gz | tar zxv + run: curl -sL https://github.com/getzola/zola/releases/download/v0.14.1/zola-v0.14.1-x86_64-unknown-linux-gnu.tar.gz | tar zxv - name: "Run zola check" run: ../zola check diff --git a/blog/config.toml b/blog/config.toml index a7f45498..a67c2d01 100644 --- a/blog/config.toml +++ b/blog/config.toml @@ -1,24 +1,17 @@ -title = "Writing an OS in Rust" base_url = "https://os.phil-opp.com" -description = "This blog series creates a small operating system in the Rust programming language. Each post is a small tutorial and includes all needed code." -highlight_code = true -highlight_theme = "visual-studio-dark" generate_feed = true feed_filename = "rss.xml" compile_sass = true - -languages = [ - { code = "zh-CN" }, # Chinese (simplified) - { code = "zh-TW" }, # Chinese (traditional) - { code = "ja" }, # Japanese - { code = "fa" }, # Persian - { code = "ru" }, # Russian - { code = "fr" }, # French -] +minify_html = true ignored_content = ["*/README.md"] +[markdown] +highlight_code = true +highlight_theme = "visual-studio-dark" +smart_punctuation = true + [link_checker] skip_prefixes = [ "https://crates.io/crates", # see https://github.com/rust-lang/crates.io/issues/788 @@ -36,9 +29,14 @@ skip_anchor_prefixes = [ [extra] subtitle = "Philipp Oppermann's blog" author = { name = "Philipp Oppermann" } +default_language = "en" +languages = ["en", "zh-CN", "zh-TW", "fr", "ja", "fa", "ru"] -[translations.en] -lang_name = "English" +[languages.en] +title = "Writing an OS in Rust" +description = "This blog series creates a small operating system in the Rust programming language. Each post is a small tutorial and includes all needed code." +[languages.en.translations] +lang_name = "English (original)" toc = "Table of Contents" all_posts = "« All Posts" comments = "Comments" @@ -50,7 +48,11 @@ translated_content_notice = "This is a community translation of the objdump -d build/kernel-x86_64.bin | grep -B1 "110970:" 11096f: cc int3 110970: 48 c7 01 2a 00 00 00 movq $0x2a,(%rcx) diff --git a/blog/content/edition-1/posts/08-kernel-heap/index.md b/blog/content/edition-1/posts/08-kernel-heap/index.md index 82686151..9013ba56 100644 --- a/blog/content/edition-1/posts/08-kernel-heap/index.md +++ b/blog/content/edition-1/posts/08-kernel-heap/index.md @@ -675,7 +675,7 @@ I created the [linked_list_allocator] crate to handle all of these cases. It con We need to add the extern crate to our `Cargo.toml` and our `lib.rs`: -``` shell +``` bash > cargo add linked_list_allocator ``` diff --git a/blog/sass/css/edition-2/main.scss b/blog/sass/css/edition-2/main.scss index d8b8867b..c398ac01 100644 --- a/blog/sass/css/edition-2/main.scss +++ b/blog/sass/css/edition-2/main.scss @@ -377,7 +377,6 @@ tbody tr:nth-child(odd) th { /* Blog post or page title */ .page-title, -.post-title, .post-title a { color: var(--post-title-color); } diff --git a/blog/templates/edition-2/index.html b/blog/templates/edition-2/index.html index bab56839..38264785 100644 --- a/blog/templates/edition-2/index.html +++ b/blog/templates/edition-2/index.html @@ -70,16 +70,14 @@