diff --git a/blog/content/first-edition/extra/_index.md b/blog/content/first-edition/extra/_index.md index 72c0bc40..3d923d19 100644 --- a/blog/content/first-edition/extra/_index.md +++ b/blog/content/first-edition/extra/_index.md @@ -2,5 +2,5 @@ title = "Extra Content" insert_anchor_links = "left" render = false -sort_by = "order" +sort_by = "weight" +++ diff --git a/blog/content/first-edition/extra/cross-compile-binutils.md b/blog/content/first-edition/extra/cross-compile-binutils.md index cae2b448..85389bc2 100644 --- a/blog/content/first-edition/extra/cross-compile-binutils.md +++ b/blog/content/first-edition/extra/cross-compile-binutils.md @@ -2,7 +2,7 @@ title = "Cross Compile Binutils" template = "plain.html" path = "cross-compile-binutils" -order = 2 +weight = 2 +++ The [GNU Binutils] are a collection of various binary tools such as `ld`, `as`, `objdump`, or `readelf`. These tools are platform-specific, so you need to compile them again if your host system and target system are different. In our case, we need `ld` and `objdump` for the x86_64 architecture. diff --git a/blog/content/first-edition/extra/cross-compile-libcore.md b/blog/content/first-edition/extra/cross-compile-libcore.md index 5add26dc..2d85428e 100644 --- a/blog/content/first-edition/extra/cross-compile-libcore.md +++ b/blog/content/first-edition/extra/cross-compile-libcore.md @@ -2,7 +2,7 @@ title = "Cross Compiling: libcore" template = "plain.html" path = "cross-compile-libcore" -order = 3 +weight = 3 +++ If you get an `error: can't find crate for 'core'`, you're probably compiling for a different target (e.g. you're passing the `target` option to `cargo build`). Now the compiler complains that it can't find the `core` library. This document gives a quick overview how to fix this problem. For more details, see the [rust-cross] project. diff --git a/blog/content/first-edition/extra/naked-exceptions/01-catching-exceptions/index.md b/blog/content/first-edition/extra/naked-exceptions/01-catching-exceptions/index.md index d6003481..b2592100 100644 --- a/blog/content/first-edition/extra/naked-exceptions/01-catching-exceptions/index.md +++ b/blog/content/first-edition/extra/naked-exceptions/01-catching-exceptions/index.md @@ -1,6 +1,6 @@ +++ title = "Catching Exceptions" -order = 1 +weight = 1 path = "catching-exceptions" date = 2016-05-28 template = "first-edition/page.html" diff --git a/blog/content/first-edition/extra/naked-exceptions/02-better-exception-messages/index.md b/blog/content/first-edition/extra/naked-exceptions/02-better-exception-messages/index.md index 7be988aa..df81dfc5 100644 --- a/blog/content/first-edition/extra/naked-exceptions/02-better-exception-messages/index.md +++ b/blog/content/first-edition/extra/naked-exceptions/02-better-exception-messages/index.md @@ -1,6 +1,6 @@ +++ title = "Better Exception Messages" -order = 2 +weight = 2 path = "better-exception-messages" date = 2016-08-03 template = "first-edition/page.html" diff --git a/blog/content/first-edition/extra/naked-exceptions/03-returning-from-exceptions/index.md b/blog/content/first-edition/extra/naked-exceptions/03-returning-from-exceptions/index.md index d88f8f78..e9524628 100644 --- a/blog/content/first-edition/extra/naked-exceptions/03-returning-from-exceptions/index.md +++ b/blog/content/first-edition/extra/naked-exceptions/03-returning-from-exceptions/index.md @@ -1,6 +1,6 @@ +++ title = "Returning from Exceptions" -order = 3 +weight = 3 path = "returning-from-exceptions" date = 2016-09-21 template = "first-edition/page.html" diff --git a/blog/content/first-edition/extra/naked-exceptions/_index.md b/blog/content/first-edition/extra/naked-exceptions/_index.md index 0d18019f..5cf9cdbe 100644 --- a/blog/content/first-edition/extra/naked-exceptions/_index.md +++ b/blog/content/first-edition/extra/naked-exceptions/_index.md @@ -1,6 +1,6 @@ +++ title = "Handling Exceptions using naked Functions" -sort_by = "order" +sort_by = "weight" template = "first-edition/handling-exceptions-with-naked-fns.html" insert_anchor_links = "left" +++ diff --git a/blog/content/first-edition/extra/set-up-gdb/index.md b/blog/content/first-edition/extra/set-up-gdb/index.md index c344d3e1..2acbb2ad 100644 --- a/blog/content/first-edition/extra/set-up-gdb/index.md +++ b/blog/content/first-edition/extra/set-up-gdb/index.md @@ -2,7 +2,7 @@ title = "Set Up GDB" template = "plain.html" path = "set-up-gdb" -order = 4 +weight = 4 +++ There are a lot of things that can go wrong when developing an OS. So it's a good idea to add a debugger to our toolset, which allows us to set breakpoints and examine variables. We will use [GDB](https://www.gnu.org/software/gdb/) as QEMU supports it out of the box. diff --git a/blog/content/first-edition/extra/talks.md b/blog/content/first-edition/extra/talks.md index 6035baf4..86ca164b 100644 --- a/blog/content/first-edition/extra/talks.md +++ b/blog/content/first-edition/extra/talks.md @@ -2,7 +2,7 @@ title = "Talks" path = "talks" template = "plain.html" -order = 1 +weight = 1 +++ ## 2018 diff --git a/blog/content/first-edition/posts/01-multiboot-kernel/index.md b/blog/content/first-edition/posts/01-multiboot-kernel/index.md index 41ffc4c4..2db3ba1c 100644 --- a/blog/content/first-edition/posts/01-multiboot-kernel/index.md +++ b/blog/content/first-edition/posts/01-multiboot-kernel/index.md @@ -1,6 +1,6 @@ +++ title = "A minimal Multiboot Kernel" -order = 1 +weight = 1 path = "multiboot-kernel/" date = 2015-08-18 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/02-entering-longmode/index.md b/blog/content/first-edition/posts/02-entering-longmode/index.md index 464d9f68..13aa54c8 100644 --- a/blog/content/first-edition/posts/02-entering-longmode/index.md +++ b/blog/content/first-edition/posts/02-entering-longmode/index.md @@ -1,6 +1,6 @@ +++ title = "Entering Long Mode" -order = 2 +weight = 2 path = "entering-longmode" date = 2015-08-25 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/03-set-up-rust/index.md b/blog/content/first-edition/posts/03-set-up-rust/index.md index 84e7e8d3..5fb7c061 100644 --- a/blog/content/first-edition/posts/03-set-up-rust/index.md +++ b/blog/content/first-edition/posts/03-set-up-rust/index.md @@ -1,6 +1,6 @@ +++ title = "Set Up Rust" -order = 3 +weight = 3 path = "set-up-rust" date = 2015-09-02 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/04-printing-to-screen/index.md b/blog/content/first-edition/posts/04-printing-to-screen/index.md index bec4ad71..5952d1b5 100644 --- a/blog/content/first-edition/posts/04-printing-to-screen/index.md +++ b/blog/content/first-edition/posts/04-printing-to-screen/index.md @@ -1,6 +1,6 @@ +++ title = "Printing to Screen" -order = 4 +weight = 4 path = "printing-to-screen" date = 2015-10-23 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/05-allocating-frames/index.md b/blog/content/first-edition/posts/05-allocating-frames/index.md index 49ae008c..8739b417 100644 --- a/blog/content/first-edition/posts/05-allocating-frames/index.md +++ b/blog/content/first-edition/posts/05-allocating-frames/index.md @@ -1,6 +1,6 @@ +++ title = "Allocating Frames" -order = 5 +weight = 5 path = "allocating-frames" date = 2015-11-15 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/06-page-tables/index.md b/blog/content/first-edition/posts/06-page-tables/index.md index aeba0d3b..7a27ee78 100644 --- a/blog/content/first-edition/posts/06-page-tables/index.md +++ b/blog/content/first-edition/posts/06-page-tables/index.md @@ -1,6 +1,6 @@ +++ title = "Page Tables" -order = 6 +weight = 6 path = "page-tables" date = 2015-12-09 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/07-remap-the-kernel/index.md b/blog/content/first-edition/posts/07-remap-the-kernel/index.md index 36da9ec9..d1889b3e 100644 --- a/blog/content/first-edition/posts/07-remap-the-kernel/index.md +++ b/blog/content/first-edition/posts/07-remap-the-kernel/index.md @@ -1,6 +1,6 @@ +++ title = "Remap the Kernel" -order = 7 +weight = 7 path = "remap-the-kernel" date = 2016-01-01 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/08-kernel-heap/index.md b/blog/content/first-edition/posts/08-kernel-heap/index.md index 343a7fe6..b0d069bc 100644 --- a/blog/content/first-edition/posts/08-kernel-heap/index.md +++ b/blog/content/first-edition/posts/08-kernel-heap/index.md @@ -1,6 +1,6 @@ +++ title = "Kernel Heap" -order = 8 +weight = 8 path = "kernel-heap" date = 2016-04-11 updated = "2017-11-19" diff --git a/blog/content/first-edition/posts/09-handling-exceptions/index.md b/blog/content/first-edition/posts/09-handling-exceptions/index.md index 70e50439..351f8d5d 100644 --- a/blog/content/first-edition/posts/09-handling-exceptions/index.md +++ b/blog/content/first-edition/posts/09-handling-exceptions/index.md @@ -1,6 +1,6 @@ +++ title = "Handling Exceptions" -order = 9 +weight = 9 path = "handling-exceptions" date = 2017-03-26 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/10-double-faults/index.md b/blog/content/first-edition/posts/10-double-faults/index.md index 388fdc8e..2fcf4ed3 100644 --- a/blog/content/first-edition/posts/10-double-faults/index.md +++ b/blog/content/first-edition/posts/10-double-faults/index.md @@ -1,6 +1,6 @@ +++ title = "Double Faults" -order = 10 +weight = 10 path = "double-faults" date = 2017-01-02 template = "first-edition/page.html" diff --git a/blog/content/first-edition/posts/_index.md b/blog/content/first-edition/posts/_index.md index bd698bdf..610d3f17 100644 --- a/blog/content/first-edition/posts/_index.md +++ b/blog/content/first-edition/posts/_index.md @@ -1,6 +1,6 @@ +++ title = "Posts" -sort_by = "order" +sort_by = "weight" insert_anchor_links = "left" render = false +++ diff --git a/blog/content/pages/404.md b/blog/content/pages/404.md deleted file mode 100644 index a6ff4dcf..00000000 --- a/blog/content/pages/404.md +++ /dev/null @@ -1,13 +0,0 @@ -+++ -title = "Page not found" -path = "404.html" -template = "plain.html" -+++ - -Sorry, we've misplaced that URL or it's pointing to something that doesn't exist. - -[Head back home](/) to try finding it again. - -If you followed a link on this site, please [report it]! - -[report it]: https://github.com/phil-opp/blog_os/issues diff --git a/blog/content/second-edition/extra/_index.md b/blog/content/second-edition/extra/_index.md index 72c0bc40..3d923d19 100644 --- a/blog/content/second-edition/extra/_index.md +++ b/blog/content/second-edition/extra/_index.md @@ -2,5 +2,5 @@ title = "Extra Content" insert_anchor_links = "left" render = false -sort_by = "order" +sort_by = "weight" +++ diff --git a/blog/content/second-edition/extra/building-on-android/index.md b/blog/content/second-edition/extra/building-on-android/index.md index e0bdd60a..4e2ef1cc 100644 --- a/blog/content/second-edition/extra/building-on-android/index.md +++ b/blog/content/second-edition/extra/building-on-android/index.md @@ -1,6 +1,6 @@ +++ title = "Building on Android" -order = 3 +weight = 3 template = "second-edition/extra.html" +++ diff --git a/blog/content/second-edition/extra/disable-red-zone/index.md b/blog/content/second-edition/extra/disable-red-zone/index.md index b677b625..44df06e9 100644 --- a/blog/content/second-edition/extra/disable-red-zone/index.md +++ b/blog/content/second-edition/extra/disable-red-zone/index.md @@ -1,6 +1,6 @@ +++ title = "Disable the Red Zone" -order = 1 +weight = 1 path = "red-zone" template = "second-edition/extra.html" +++ diff --git a/blog/content/second-edition/extra/disable-simd/index.md b/blog/content/second-edition/extra/disable-simd/index.md index 785c8b2e..ba591e57 100644 --- a/blog/content/second-edition/extra/disable-simd/index.md +++ b/blog/content/second-edition/extra/disable-simd/index.md @@ -1,6 +1,6 @@ +++ title = "Disable SIMD" -order = 2 +weight = 2 path = "disable-simd" template = "second-edition/extra.html" +++ diff --git a/blog/content/second-edition/posts/01-freestanding-rust-binary/index.md b/blog/content/second-edition/posts/01-freestanding-rust-binary/index.md index 9c24629b..39de7f4a 100644 --- a/blog/content/second-edition/posts/01-freestanding-rust-binary/index.md +++ b/blog/content/second-edition/posts/01-freestanding-rust-binary/index.md @@ -1,6 +1,6 @@ +++ title = "A Freestanding Rust Binary" -order = 1 +weight = 1 path = "freestanding-rust-binary" date = 2018-02-10 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/02-minimal-rust-kernel/index.md b/blog/content/second-edition/posts/02-minimal-rust-kernel/index.md index ded32df8..fe226e0c 100644 --- a/blog/content/second-edition/posts/02-minimal-rust-kernel/index.md +++ b/blog/content/second-edition/posts/02-minimal-rust-kernel/index.md @@ -1,6 +1,6 @@ +++ title = "A Minimal Rust Kernel" -order = 2 +weight = 2 path = "minimal-rust-kernel" date = 2018-02-10 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/03-vga-text-buffer/index.md b/blog/content/second-edition/posts/03-vga-text-buffer/index.md index f94281a6..f87f7115 100644 --- a/blog/content/second-edition/posts/03-vga-text-buffer/index.md +++ b/blog/content/second-edition/posts/03-vga-text-buffer/index.md @@ -1,6 +1,6 @@ +++ title = "VGA Text Mode" -order = 3 +weight = 3 path = "vga-text-mode" date = 2018-02-26 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/04-unit-testing/index.md b/blog/content/second-edition/posts/04-unit-testing/index.md index ae8962e2..0e76651b 100644 --- a/blog/content/second-edition/posts/04-unit-testing/index.md +++ b/blog/content/second-edition/posts/04-unit-testing/index.md @@ -1,6 +1,6 @@ +++ title = "Unit Testing" -order = 4 +weight = 4 path = "unit-testing" date = 2018-04-29 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/05-integration-tests/index.md b/blog/content/second-edition/posts/05-integration-tests/index.md index de9e3f00..78ff82cc 100644 --- a/blog/content/second-edition/posts/05-integration-tests/index.md +++ b/blog/content/second-edition/posts/05-integration-tests/index.md @@ -1,6 +1,6 @@ +++ title = "Integration Tests" -order = 5 +weight = 5 path = "integration-tests" date = 2018-06-15 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/06-cpu-exceptions/index.md b/blog/content/second-edition/posts/06-cpu-exceptions/index.md index a218b4bd..1e84d3de 100644 --- a/blog/content/second-edition/posts/06-cpu-exceptions/index.md +++ b/blog/content/second-edition/posts/06-cpu-exceptions/index.md @@ -1,6 +1,6 @@ +++ title = "CPU Exceptions" -order = 6 +weight = 6 path = "cpu-exceptions" date = 2018-06-17 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/07-double-faults/index.md b/blog/content/second-edition/posts/07-double-faults/index.md index 9ba739e8..f430674d 100644 --- a/blog/content/second-edition/posts/07-double-faults/index.md +++ b/blog/content/second-edition/posts/07-double-faults/index.md @@ -1,6 +1,6 @@ +++ title = "Double Faults" -order = 7 +weight = 7 path = "double-fault-exceptions" date = 2018-06-18 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/08-hardware-interrupts/index.md b/blog/content/second-edition/posts/08-hardware-interrupts/index.md index ee9fde7d..70578167 100644 --- a/blog/content/second-edition/posts/08-hardware-interrupts/index.md +++ b/blog/content/second-edition/posts/08-hardware-interrupts/index.md @@ -1,6 +1,6 @@ +++ title = "Hardware Interrupts" -order = 8 +weight = 8 path = "hardware-interrupts" date = 2018-10-22 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/09-paging-introduction/index.md b/blog/content/second-edition/posts/09-paging-introduction/index.md index 83c51912..46f01bb3 100644 --- a/blog/content/second-edition/posts/09-paging-introduction/index.md +++ b/blog/content/second-edition/posts/09-paging-introduction/index.md @@ -1,6 +1,6 @@ +++ title = "Introduction to Paging" -order = 9 +weight = 9 path = "paging-introduction" date = 2019-01-14 template = "second-edition/page.html" diff --git a/blog/content/second-edition/posts/_index.md b/blog/content/second-edition/posts/_index.md index bd698bdf..610d3f17 100644 --- a/blog/content/second-edition/posts/_index.md +++ b/blog/content/second-edition/posts/_index.md @@ -1,6 +1,6 @@ +++ title = "Posts" -sort_by = "order" +sort_by = "weight" insert_anchor_links = "left" render = false +++ diff --git a/blog/static/css/main.css b/blog/static/css/main.css index 6f3b589a..222f589f 100644 --- a/blog/static/css/main.css +++ b/blog/static/css/main.css @@ -243,7 +243,7 @@ a code { color: #268bd2; } -a.gutenberg-anchor { +a.zola-anchor { opacity: 0; position: absolute; margin-left: -1.5em; @@ -253,12 +253,12 @@ a.gutenberg-anchor { line-height: 2em; } -:hover>a.gutenberg-anchor { +:hover>a.zola-anchor { opacity: 1; text-decoration: none; } -a.gutenberg-anchor:hover { +a.zola-anchor:hover { text-decoration: none; } diff --git a/blog/templates/404.html b/blog/templates/404.html new file mode 100644 index 00000000..ac8b05b7 --- /dev/null +++ b/blog/templates/404.html @@ -0,0 +1,12 @@ +{% extends "second-edition/base.html" %} + +{% block title %}Page not found | {{ config.title }}{% endblock title %} + +{% block main %} +
Sorry, this address is not valid.
+ + + +If you followed a link on this site, please report it!
+{% endblock main %} diff --git a/blog/templates/first-edition/index.html b/blog/templates/first-edition/index.html index 0934b052..22a3a33f 100644 --- a/blog/templates/first-edition/index.html +++ b/blog/templates/first-edition/index.html @@ -6,7 +6,7 @@ {% block main %} {% set posts_section = get_section(path = "first-edition/posts/_index.md") %} -{% set posts = posts_section.pages | reverse %} +{% set posts = posts_section.pages %}This blog series creates a small operating system in the @@ -50,10 +50,11 @@ {% set extra = get_section(path = "first-edition/extra/_index.md") %}