From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 6E27915800F for ; Sun, 19 Feb 2023 16:14:37 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 1DEC8E08AD; Sun, 19 Feb 2023 16:14:35 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 0832DE08AD for ; Sun, 19 Feb 2023 16:14:34 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id DBFDC340EC9 for ; Sun, 19 Feb 2023 16:14:33 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 0A0238B3 for ; Sun, 19 Feb 2023 16:14:32 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1676823246.de7a2ae7c416efe0fa75443f9174b05b1c6bbc5b.sam@gentoo> Subject: [gentoo-commits] proj/gentoo-functions:master commit in: / X-VCS-Repository: proj/gentoo-functions X-VCS-Files: functions.sh X-VCS-Directories: / X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: de7a2ae7c416efe0fa75443f9174b05b1c6bbc5b X-VCS-Branch: master Date: Sun, 19 Feb 2023 16:14:32 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 6c38afb1-1cf0-4b29-9b63-65434dd6ee7f X-Archives-Hash: fa8544f2b7fb7a2755c74cace0506531 commit: de7a2ae7c416efe0fa75443f9174b05b1c6bbc5b Author: Kerin Millar plushkava net> AuthorDate: Sat Feb 18 06:11:53 2023 +0000 Commit: Sam James gentoo org> CommitDate: Sun Feb 19 16:14:06 2023 +0000 URL: https://gitweb.gentoo.org/proj/gentoo-functions.git/commit/?id=de7a2ae7 Explain the composition and naming conventions of gentoo-functions.sh Signed-off-by: Kerin Millar plushkava.net> Signed-off-by: Sam James gentoo.org> functions.sh | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/functions.sh b/functions.sh index 2918558..3b56b1d 100644 --- a/functions.sh +++ b/functions.sh @@ -2,8 +2,15 @@ # Distributed under the terms of the GNU General Public License v2 # shellcheck shell=sh disable=3043 +# This file contains a series of function declarations followed by some +# initialization code. Functions intended for internal use shall be prefixed +# with an and shall not be considered as being a part of the public +# API. With the exception of those declared by the local builtin, all variables +# intended for internal use shall be prefixed with "genfun_" to indicate so, +# and to reduce the probability of name space conflicts. + # -# This is a private function, called by ebegin, eerrorn, einfon, and ewarnn. +# Called by ebegin, eerrorn, einfon, and ewarnn. # _eprint() { local color @@ -23,7 +30,6 @@ _eprint() { # # hard set the indent used for e-commands. # num defaults to 0 -# This is a private function. # _esetdent() { @@ -201,9 +207,6 @@ ebegin() # indicate the completion of process, called from eend/ewend # if error, show errstr via efunc # -# This function is private to functions.sh. Do not call it from a -# script. -# _eend() { local cols efunc is_tty msg retval @@ -462,8 +465,7 @@ is_int() { } # -# Determine whether the first operand contains any visible characters. This -# is intended to be a private function. +# Determine whether the first operand contains any visible characters. # _is_visible() { ! case $1 in *[[:graph:]]*) false ;; esac