From patchwork Tue Dec 1 15:22:49 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Trevor Woerner X-Patchwork-Id: 106828 Received: from mail-oi1-f176.google.com (mail-oi1-f176.google.com [209.85.167.176]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.13186.1796138611984344962 for ; Tue, 01 Dec 2026 07:23:32 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20260707 header.b=xcXyBUy7; spf=pass (domain: gmail.com, ip: 209.85.167.176, mailfrom: twoerner@gmail.com) Received: by mail-oi1-f176.google.com with SMTP id 5614622812f47-51f2e9e6987so8647949b6e.1 for ; Tue, 01 Dec 2026 07:23:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20260707; t=1796138611; x=1796743411; darn=lists.yoctoproject.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to:content-type; bh=CKkqP9ohAd0EUXJpZ2p41I2Du6eq1kZw1lBms39Y7HU=; b=xcXyBUy7Mr9nrwbh/O1GeKYZmn6jH2XypyLsY5jRS9azVIOHYrnjyKolJeF4w3/esz u+o0l/vOeOXORb5nPDyiorW7HMb5WZ3TS+o5WfmVE/hurDnMn7xdgeLj8k15YYtOpk+s Rxu9+mZJTSWz7yqeFHDHXHT1UEVGpr23EBo+U76xpL2TJuGLgp7jQqDyZ+EoY4GXhgFc liR5eBfrhJTce4o+t2dEmBJUZTwbjCSQ70dsAeTuDHlWMTraK03j60WBD/PtOygP8msB u3jViJ0w+GEUl1lDiUS1s1VitU6asdctmnOv9KSYY1vIGKWoMtiTMV5K7rAxpDzQ/oTq odKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796138611; x=1796743411; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg: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q7ArXughJ2ps4+ThA24z5F4x3OPhv3BLWU L4E+/gMLTZbI4n2PzVgft0PfyU6beD+amt/C8tcLULBYLfHLRCU73xV9IlFDUSn31NFA1WC7MLR wZf+6UulMyA5C3lnCSycw/R7srzIOeCbywohwaZlbNdzZXng/wkoGXlz52QKdLD5gH9numPXdf9 nDiKwX0oSj2hYbh8PDJ76VQIWNIeMjiibE8a3ut9z/uYWL/itxOdM X-Received: by 2002:a05:6808:c1f4:b0:53f:b2f9:1220 with SMTP id 5614622812f47-57a095fea41mr27745888b6e.5.1796138611074; Tue, 01 Dec 2026 07:23:31 -0800 (PST) Return-Path: Received: from localhost.localdomain (pppoe-209-91-167-254.vianet.ca. [209.91.167.254]) by smtp.gmail.com with ESMTPSA id 5614622812f47-57a31929223sm27818249b6e.1.2026.12.01.07.23.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Dec 2026 07:23:28 -0800 (PST) From: Trevor Woerner To: docs@lists.yoctoproject.org Subject: [PATCH 16/16] standards: describe how a code block states its language Date: Tue, 1 Dec 2026 10:22:49 -0500 Message-ID: <20261201152251.2742634-17-twoerner@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20261201152251.2742634-1-twoerner@gmail.com> References: <20261201152251.2742634-1-twoerner@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by lin-tor-korg-lkml-alma10-1 with HTTPS for ; Tue, 01 Dec 2026 15:23:42 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/docs/message/10875 The manuals highlight a code block as BitBake unless it says otherwise, which is a rule a contributor can only discover by reading conf.py. Write it down, along with the languages the other blocks use and what to do with a block the BitBake lexer cannot read. AI-Generated: codex/claude-opus 5.5 (xhigh) Signed-off-by: Trevor Woerner --- documentation/standards.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/documentation/standards.md b/documentation/standards.md index 152a90923401..2614220ef0e1 100644 --- a/documentation/standards.md +++ b/documentation/standards.md @@ -134,6 +134,28 @@ Note that only "absolute" paths (starting with a '/') are allowed. The root directory of that path is documentation/, that is, :doc:`/bsp-manual/index` points at documentation/bsp-manual/index.rst. +### Code blocks + +A code block is highlighted as BitBake unless it says otherwise, because +most of the code in the manuals is BitBake metadata. A block of anything +else states its language: + + .. code-block:: console + + $ bitbake core-image-minimal + +Use the language the block actually is, not the one it resembles. A +session with a prompt is `console`, a script without one is `shell`, and +a listing of paths or program output is `text`. + +If the BitBake lexer cannot read a valid BitBake block, show it as `text` +and say why in a comment above it, so it can be switched back once the +lexer is fixed: + + .. Shown as text: the Pygments BitBake lexer misreads this block. + + .. code-block:: text + ## Adding screenshots The preferred format for adding screenshots is