Give every code block a type to fix rendering issue

This commit is contained in:
Catalin Constantin Mititiuc 2025-06-16 20:18:04 -07:00
parent 458ea4c16b
commit e829af2bc1
2 changed files with 5 additions and 4 deletions

View File

@ -6,3 +6,4 @@ RUN apt-get update && apt-get install -y python3-pygments
RUN luarocks install sitegen RUN luarocks install sitegen
CMD ["sh", "-c", "openresty -p `pwd` -g 'daemon off;'"] CMD ["sh", "-c", "openresty -p `pwd` -g 'daemon off;'"]
# CMD ["openresty", "-p", "/opt/app", "-g", "daemon off;"]

View File

@ -8,7 +8,7 @@ We wish to print a list of all the files in a directory, ignoring files beginnin
Finds all files in the `path` directory recursively, ignoring any files or directories that start with any of the characters in the `@starts_with` module attribute. Finds all files in the `path` directory recursively, ignoring any files or directories that start with any of the characters in the `@starts_with` module attribute.
``` ```elixir
defmodule Files do defmodule Files do
@starts_with [".", "_"] @starts_with [".", "_"]
@ -39,7 +39,7 @@ end
The data structure holding the results of the file search. The data structure holding the results of the file search.
``` ```iex
iex(1)> directory_tree = Files.find("hello") iex(1)> directory_tree = Files.find("hello")
{"hello", {"hello",
[ [
@ -77,7 +77,7 @@ iex(1)> directory_tree = Files.find("hello")
Sort alphabetically, with directories last. Downcase before comparing strings. Sort alphabetically, with directories last. Downcase before comparing strings.
``` ```elixir
defmodule Paths do defmodule Paths do
def puts(dir_tree), do: dir_tree |> print() |> Enum.join("\n") |> IO.puts() def puts(dir_tree), do: dir_tree |> print() |> Enum.join("\n") |> IO.puts()
@ -103,7 +103,7 @@ end
Print all the files sorted. Print all the files sorted.
``` ```iex
iex(2)> Paths.puts(directory_tree) iex(2)> Paths.puts(directory_tree)
hello/mix.exs hello/mix.exs
hello/README.md hello/README.md