Give every code block a type to fix rendering issue

This commit is contained in:
Catalin Constantin Mititiuc 2025-05-10 12:14:17 -07:00
parent b5771c94c9
commit 184730a51c
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
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.
```
```elixir
defmodule Files do
@starts_with [".", "_"]
@ -39,7 +39,7 @@ end
The data structure holding the results of the file search.
```
```iex
iex(1)> directory_tree = Files.find("hello")
{"hello",
[
@ -77,7 +77,7 @@ iex(1)> directory_tree = Files.find("hello")
Sort alphabetically, with directories last. Downcase before comparing strings.
```
```elixir
defmodule Paths do
def puts(dir_tree), do: dir_tree |> print() |> Enum.join("\n") |> IO.puts()
@ -103,7 +103,7 @@ end
Print all the files sorted.
```
```iex
iex(2)> Paths.puts(directory_tree)
hello/mix.exs
hello/README.md