Skip to content

Commit c0bd668

Browse files
authored
docs: Add horizontal spacers around filenames in custom toolchain guide (bazel-contrib#2563)
This improves readability by clearly marking the beginnings and ends of the three involved source files. Follow-up of bazel-contrib#2512, as discussed.
1 parent 1aa0d9f commit c0bd668

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

docs/toolchains.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,10 @@ Here, we show an example for a semi-complicated toolchain suite, one that is:
411411
Defining toolchains for this might look something like this:
412412

413413
```
414+
# -------------------------------------------------------
414415
# File: toolchain_impl/BUILD
416+
# Contains the tool definitions (runtime, headers, libs).
417+
# -------------------------------------------------------
415418
load("@rules_python//python:py_cc_toolchain.bzl", "py_cc_toolchain")
416419
load("@rules_python//python:py_exec_tools_toolchain.bzl", "py_exec_tools_toolchain")
417420
load("@rules_python//python:py_runtime.bzl", "py_runtime")
@@ -453,9 +456,11 @@ cc_binary(name = "python3.12", ...)
453456
cc_library(name = "headers", ...)
454457
cc_library(name = "libs", ...)
455458
459+
# ------------------------------------------------------------------
456460
# File: toolchains/BUILD
457461
# Putting toolchain() calls in a separate package from the toolchain
458-
# implementations minimizes Bazel loading overhead
462+
# implementations minimizes Bazel loading overhead.
463+
# ------------------------------------------------------------------
459464
460465
toolchain(
461466
name = "runtime_toolchain",
@@ -480,8 +485,10 @@ toolchain(
480485
exec_comaptible_with = ["@platforms/os:linux"]
481486
)
482487
488+
# -----------------------------------------------
483489
# File: MODULE.bazel or WORKSPACE.bazel
484-
# These toolchains will considered before others
490+
# These toolchains will considered before others.
491+
# -----------------------------------------------
485492
register_toolchains("//toolchains:all")
486493
```
487494

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy