From b8a7e7fcc760218ab2fcdcf43086037b025fd6a5 Mon Sep 17 00:00:00 2001 From: Glitchbyte <49317853+0xGlitchbyte@users.noreply.github.com> Date: Mon, 29 Jan 2024 09:03:27 -0500 Subject: [PATCH] cleaned up redirection urls (#1969) * cleaned up redirection urls * add back modules, other best effort redirects * fmt --- src/ocamlorg_web/lib/redirection.ml | 47 ++++++++++++----------------- 1 file changed, 19 insertions(+), 28 deletions(-) diff --git a/src/ocamlorg_web/lib/redirection.ml b/src/ocamlorg_web/lib/redirection.ml index 8377199809..e7b0c288dc 100644 --- a/src/ocamlorg_web/lib/redirection.ml +++ b/src/ocamlorg_web/lib/redirection.ml @@ -198,14 +198,16 @@ let from_v2 = ( "/learn/tutorials/compiling_ocaml_projects.html", Url.tutorial "compiling-ocaml-projects" ); ( "/learn/tutorials/data_types_and_matching.fr.html", - Url.tutorial "data-types" ); + Url.tutorial "basic-data-types" ); ( "/learn/tutorials/data_types_and_matching.it.html", - Url.tutorial "data-types" ); + Url.tutorial "basic-data-types" ); ( "/learn/tutorials/data_types_and_matching.ja.html", - Url.tutorial "data-types" ); - ("/learn/tutorials/data_types_and_matching.html", Url.tutorial "data-types"); + Url.tutorial "basic-data-types" ); + ( "/learn/tutorials/data_types_and_matching.html", + Url.tutorial "basic-data-types" ); ( "/learn/tutorials/data_types_and_matching.zh.html", - Url.tutorial "data-types" ); + Url.tutorial "basic-data-types" ); + (Url.tutorial "data-types", Url.tutorial "basic-data-types"); ("/learn/tutorials/debug.html", Url.tutorial "debugging"); ("/learn/tutorials/error_handling.html", Url.tutorial "error-handling"); ( "/learn/tutorials/file_manipulation.ja.html", @@ -215,16 +217,17 @@ let from_v2 = Url.tutorial "file-manipulation" ); ("/learn/tutorials/format.fr.html", Url.tutorial "formatting-text"); ("/learn/tutorials/format.html", Url.tutorial "formatting-text"); - ( "/learn/tutorials/functional_programming.fr.html", - Url.tutorial "functional-programming" ); - ( "/learn/tutorials/functional_programming.it.html", - Url.tutorial "functional-programming" ); - ( "/learn/tutorials/functional_programming.ja.html", - Url.tutorial "functional-programming" ); - ( "/learn/tutorials/functional_programming.html", - Url.tutorial "functional-programming" ); - ( "/learn/tutorials/functional_programming.zh.html", - Url.tutorial "functional-programming" ); + (* FIXME: uncomment when higher-order-functions is merged ( + "/learn/tutorials/functional_programming.fr.html", Url.tutorial + "higher-order-functions" ); ( + "/learn/tutorials/functional_programming.it.html", Url.tutorial + "higher-order-functions" ); ( + "/learn/tutorials/functional_programming.ja.html", Url.tutorial + "higher-order-functions" ); ( + "/learn/tutorials/functional_programming.html", Url.tutorial + "higher-order-functions" ); ( + "/learn/tutorials/functional_programming.zh.html", Url.tutorial + "higher-order-functions" ); *) ("/learn/tutorials/functors.html", Url.tutorial "functors"); ( "/learn/tutorials/garbage_collection.ja.html", Url.tutorial "garbage-collection" ); @@ -273,16 +276,6 @@ let from_v2 = ("/learn/tutorials/modules.ko.html", Url.tutorial "modules"); ("/learn/tutorials/modules.html", Url.tutorial "modules"); ("/learn/tutorials/modules.zh.html", Url.tutorial "modules"); - ( "/learn/tutorials/null_pointers_asserts_and_warnings.fr.html", - Url.tutorial "null-pointers-asserts-and-warnings" ); - ( "/learn/tutorials/null_pointers_asserts_and_warnings.it.html", - Url.tutorial "null-pointers-asserts-and-warnings" ); - ( "/learn/tutorials/null_pointers_asserts_and_warnings.ja.html", - Url.tutorial "null-pointers-asserts-and-warnings" ); - ( "/learn/tutorials/null_pointers_asserts_and_warnings.html", - Url.tutorial "null-pointers-asserts-and-warnings" ); - ( "/learn/tutorials/null_pointers_asserts_and_warnings.zh.html", - Url.tutorial "null-pointers-asserts-and-warnings" ); ("/learn/tutorials/objects.ja.html", Url.tutorial "objects"); ("/learn/tutorials/objects.html", Url.tutorial "objects"); ("/learn/tutorials/objects.zh.html", Url.tutorial "objects"); @@ -291,13 +284,11 @@ let from_v2 = ("/learn/tutorials/performance_and_profiling.html", Url.tutorial "profiling"); ( "/learn/tutorials/performance_and_profiling_discussion.html", Url.tutorial "profiling" ); - ("/learn/tutorials/pointers.html", Url.tutorial "pointers"); - ("/learn/tutorials/pointers.zh.html", Url.tutorial "pointers"); ("/learn/tutorials/set.fr.html", Url.tutorial "sets"); ("/learn/tutorials/set.ja.html", Url.tutorial "sets"); ("/learn/tutorials/set.html", Url.tutorial "sets"); ("/learn/tutorials/set.zh.html", Url.tutorial "sets"); - ("/learn/tutorials/streams.html", Url.tutorial "streams"); + ("/learn/tutorials/streams.html", Url.tutorial "sequences"); ("/learn/tutorials/up_and_running.html", Url.tutorial "up-and-running"); (Url.tutorial "first-hour", Url.tutorial "tour-of-ocaml"); ("/meetings/index.fr.html", Url.community);