public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: app-shells/bash/
Date: Tue, 30 Sep 2025 20:14:51 +0000 (UTC)	[thread overview]
Message-ID: <1759263244.82ef038c820564201ffc9f7c3e742be12a6c421c.sam@gentoo> (raw)

commit:     82ef038c820564201ffc9f7c3e742be12a6c421c
Author:     Kerin Millar <kfm <AT> plushkava <DOT> net>
AuthorDate: Thu Sep 25 17:24:41 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Sep 30 20:14:04 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=82ef038c

app-shells/bash: overhaul SLOT 0 ebuilds; minimise their differences

The bash ebuilds in SLOT 0 continue to diverge from one another in small
but irksome ways, which makes working on them a chore. As such, the main
purpose of this commit is to minimise the differences between them.
Beyond that, several other changes have been made. All of the changes
are described herewith.

As regards the matter of difference minimisation:

- order the patterns of the first case statement in a consistent way
- declare BASH_COMMIT within the scope of the first case statement
- always declare BASH_COMMIT (even if as a null string or dead code)
- remove a redundant ;; operator from the first case statement
- always acknowledge that BASH_COMMIT might be set
- declare S within the scope of the second case statement
- consistently mention that Chet advises against the use of byacc

In pkg_postinst(), incorporate a warning to the effect of the
"15-gentoo-bashrc-check.bash" file being safe to delete.

Restructure the pkg_postinst() code so as to make it easier to
incorporate additional, version-dependent, upgrade notices.

In pkg_postinst(), if the terminal is found to be more than 80 columns
wide, invoke the fmt(1) utility so as to reflow the upgrade notice(s).

Signed-off-by: Kerin Millar <kfm <AT> plushkava.net>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 app-shells/bash/bash-5.2_p37-r4.ebuild             | 57 ++++++++++++++++++----
 app-shells/bash/bash-5.3_p3-r1.ebuild              | 44 +++++++++++++----
 app-shells/bash/bash-5.3_p3-r2.ebuild              | 44 +++++++++++++----
 .../bash/bash-5.4_alpha_pre20250918-r1.ebuild      | 44 +++++++++++++----
 app-shells/bash/bash-9999.ebuild                   | 40 ++++++++++++---
 5 files changed, 184 insertions(+), 45 deletions(-)

diff --git a/app-shells/bash/bash-5.2_p37-r4.ebuild b/app-shells/bash/bash-5.2_p37-r4.ebuild
index 50da6638e250..1066db240020 100644
--- a/app-shells/bash/bash-5.2_p37-r4.ebuild
+++ b/app-shells/bash/bash-5.2_p37-r4.ebuild
@@ -17,12 +17,15 @@ MY_PATCHES=()
 
 # Determine the patchlevel. See https://ftp.gnu.org/gnu/bash/bash-5.2-patches/.
 case ${PV} in
-	*_p*)
-		PLEVEL=${PV##*_p}
-		;;
 	9999|*_alpha*|*_beta*|*_rc*)
 		# Set a negative patchlevel to indicate that it's a pre-release.
 		PLEVEL=-1
+		if [[ ${PV} =~ _pre[0-9]{8}$ ]]; then
+			BASH_COMMIT=
+		fi
+		;;
+	*_p*)
+		PLEVEL=${PV##*_p}
 		;;
 	*)
 		PLEVEL=0
@@ -39,6 +42,14 @@ if [[ ${PV} == 9999 ]]; then
 	EGIT_REPO_URI="https://git.savannah.gnu.org/git/bash.git"
 	EGIT_BRANCH=devel
 	inherit git-r3
+elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
+	# It can be useful to have snapshots in the pre-release period once
+	# the first alpha is out, as various bugs get reported and fixed from
+	# the alpha, and the next pre-release is usually quite far away.
+	#
+	# i.e. if it's worth packaging the alpha, it's worth packaging a followup.
+	SRC_URI="https://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-${BASH_COMMIT}.tar.gz -> ${P}-${BASH_COMMIT}.tar.gz"
+	S=${WORKDIR}/${PN}-${BASH_COMMIT}
 else
 	my_urls=( "mirror://gnu/bash/${MY_P}.tar.gz" )
 
@@ -52,6 +63,7 @@ else
 	done
 
 	SRC_URI="${my_urls[*]} verify-sig? ( ${my_urls[*]/%/.sig} )"
+	S=${WORKDIR}/${MY_P}
 
 	unset -v my_urls my_p my_patch_idx my_patch_ver
 fi
@@ -60,8 +72,6 @@ if [[ ${GENTOO_PATCH_VER} ]]; then
 	SRC_URI+=" https://dev.gentoo.org/~${GENTOO_PATCH_DEV:?}/distfiles/${CATEGORY}/${PN}/${PN}-${GENTOO_PATCH_VER:?}-patches.tar.xz"
 fi
 
-S=${WORKDIR}/${MY_P}
-
 LICENSE="GPL-3+"
 SLOT="0"
 if (( PLEVEL >= 0 )); then
@@ -121,6 +131,8 @@ src_unpack() {
 
 	if [[ ${PV} == 9999 ]]; then
 		git-r3_src_unpack
+	elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
+		default
 	else
 		if use verify-sig; then
 			verify-sig_verify_detached "${DISTDIR}/${MY_P}.tar.gz"{,.sig}
@@ -172,8 +184,10 @@ src_configure() {
 	# Upstream only test with Bison and require GNUisms like YYEOF and
 	# YYERRCODE. The former at least may be in POSIX soon:
 	# https://www.austingroupbugs.net/view.php?id=1269.
+	#
 	# configure warns on use of non-Bison but doesn't abort. The result
-	# may misbehave at runtime.
+	# may misbehave at runtime. Chet also advises against use of byacc:
+	# https://lists.gnu.org/archive/html/bug-bash/2025-08/msg00115.html
 	unset -v YACC
 
 	# bash 5.3 drops unprototyped functions, earlier versions are
@@ -380,6 +394,11 @@ pkg_postinst() {
 		ln -sf -- bash "${EROOT}"/bin/sh || die
 	fi
 
+	if [[ -e ${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash ]]; then
+		ewarn "The following file is no longer packaged and can safely be deleted:"
+		ewarn "${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash"
+	fi
+
 	read -rd '' -a versions <<<"${REPLACING_VERSIONS}"
 	for ver in "${versions[@]}"; do
 		if [[ ! ${old_ver} ]] || ver_test "${ver}" -lt "${old_ver}"; then
@@ -387,13 +406,21 @@ pkg_postinst() {
 		fi
 	done
 
-	if [[ ! $old_ver ]]; then
-		:
-	elif ver_test "$old_ver" -ge "5.2" && ver_test "$old_ver" -ge "5.2_p26-r8"; then
+	if [[ ! ${old_ver} ]]; then
 		return
 	fi
 
-	while read -r; do ewarn "${REPLY}"; done <<'EOF'
+	{
+		if ver_test "${old_ver}" -ge "5.2" \
+			&& ver_test "${old_ver}" -ge "5.2_p26-r8"
+		then
+			:
+		elif ver_test "${old_ver}" -lt "5.2" \
+			&& ver_test "${old_ver}" -ge "5.1_p16-r8"
+		then
+			:
+		else
+			cat <<'EOF'
 Files under /etc/bash/bashrc.d must now have a suffix of .sh or .bash.
 
 Gentoo now defaults to defining PROMPT_COMMAND as an array. Depending on the
@@ -416,4 +443,14 @@ Those who would prefer for bash never to interfere with the window title may
 now opt out of the default title setting behaviour, either with the "unset -v
 PROMPT_COMMAND" command or by re-defining PROMPT_COMMAND as desired.
 EOF
+		fi
+	} \
+	| if [[ ${COLUMNS} == [1-9]*([0-9]) ]] && (( COLUMNS > 80 )); then
+		fmt -w "$(( COLUMNS - 3 ))"
+	else
+		cat
+	fi \
+	| while read -r; do
+		ewarn "${REPLY}"
+	done
 }

diff --git a/app-shells/bash/bash-5.3_p3-r1.ebuild b/app-shells/bash/bash-5.3_p3-r1.ebuild
index fe9698321a81..beed9733e70d 100644
--- a/app-shells/bash/bash-5.3_p3-r1.ebuild
+++ b/app-shells/bash/bash-5.3_p3-r1.ebuild
@@ -20,13 +20,15 @@ case ${PV} in
 	9999|*_alpha*|*_beta*|*_rc*)
 		# Set a negative patchlevel to indicate that it's a pre-release.
 		PLEVEL=-1
+		if [[ ${PV} =~ _pre[0-9]{8}$ ]]; then
+			BASH_COMMIT=
+		fi
 		;;
 	*_p*)
 		PLEVEL=${PV##*_p}
 		;;
 	*)
 		PLEVEL=0
-		;;
 esac
 
 # The version of readline this bash normally ships with. Note that we only use
@@ -40,13 +42,12 @@ if [[ ${PV} == 9999 ]]; then
 	EGIT_REPO_URI="https://git.savannah.gnu.org/git/bash.git"
 	EGIT_BRANCH=devel
 	inherit git-r3
-elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 	# It can be useful to have snapshots in the pre-release period once
 	# the first alpha is out, as various bugs get reported and fixed from
 	# the alpha, and the next pre-release is usually quite far away.
 	#
 	# i.e. if it's worth packaging the alpha, it's worth packaging a followup.
-	BASH_COMMIT="b35866a2891a9b069e37ca5684d4309c0391e261"
 	SRC_URI="https://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-${BASH_COMMIT}.tar.gz -> ${P}-${BASH_COMMIT}.tar.gz"
 	S=${WORKDIR}/${PN}-${BASH_COMMIT}
 else
@@ -124,7 +125,7 @@ src_unpack() {
 
 	if [[ ${PV} == 9999 ]]; then
 		git-r3_src_unpack
-	elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+	elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 		default
 	else
 		if use verify-sig; then
@@ -168,8 +169,10 @@ src_configure() {
 	# Upstream only test with Bison and require GNUisms like YYEOF and
 	# YYERRCODE. The former at least may be in POSIX soon:
 	# https://www.austingroupbugs.net/view.php?id=1269.
+	#
 	# configure warns on use of non-Bison but doesn't abort. The result
-	# may misbehave at runtime.
+	# may misbehave at runtime. Chet also advises against use of byacc:
+	# https://lists.gnu.org/archive/html/bug-bash/2025-08/msg00115.html
 	unset -v YACC
 
 	if tc-is-cross-compiler; then
@@ -372,6 +375,11 @@ pkg_postinst() {
 		ln -sf -- bash "${EROOT}"/bin/sh || die
 	fi
 
+	if [[ -e ${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash ]]; then
+		ewarn "The following file is no longer packaged and can safely be deleted:"
+		ewarn "${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash"
+	fi
+
 	read -rd '' -a versions <<<"${REPLACING_VERSIONS}"
 	for ver in "${versions[@]}"; do
 		if [[ ! ${old_ver} ]] || ver_test "${ver}" -lt "${old_ver}"; then
@@ -379,13 +387,21 @@ pkg_postinst() {
 		fi
 	done
 
-	if [[ ! $old_ver ]]; then
-		:
-	elif ver_test "$old_ver" -ge "5.2" && ver_test "$old_ver" -ge "5.2_p26-r8"; then
+	if [[ ! ${old_ver} ]]; then
 		return
 	fi
 
-	while read -r; do ewarn "${REPLY}"; done <<'EOF'
+	{
+		if ver_test "${old_ver}" -ge "5.2" \
+			&& ver_test "${old_ver}" -ge "5.2_p26-r8"
+		then
+			:
+		elif ver_test "${old_ver}" -lt "5.2" \
+			&& ver_test "${old_ver}" -ge "5.1_p16-r8"
+		then
+			:
+		else
+			cat <<'EOF'
 Files under /etc/bash/bashrc.d must now have a suffix of .sh or .bash.
 
 Gentoo now defaults to defining PROMPT_COMMAND as an array. Depending on the
@@ -408,4 +424,14 @@ Those who would prefer for bash never to interfere with the window title may
 now opt out of the default title setting behaviour, either with the "unset -v
 PROMPT_COMMAND" command or by re-defining PROMPT_COMMAND as desired.
 EOF
+		fi
+	} \
+	| if [[ ${COLUMNS} == [1-9]*([0-9]) ]] && (( COLUMNS > 80 )); then
+		fmt -w "$(( COLUMNS - 3 ))"
+	else
+		cat
+	fi \
+	| while read -r; do
+		ewarn "${REPLY}"
+	done
 }

diff --git a/app-shells/bash/bash-5.3_p3-r2.ebuild b/app-shells/bash/bash-5.3_p3-r2.ebuild
index b04e96695eaa..7e1f47f54895 100644
--- a/app-shells/bash/bash-5.3_p3-r2.ebuild
+++ b/app-shells/bash/bash-5.3_p3-r2.ebuild
@@ -20,13 +20,15 @@ case ${PV} in
 	9999|*_alpha*|*_beta*|*_rc*)
 		# Set a negative patchlevel to indicate that it's a pre-release.
 		PLEVEL=-1
+		if [[ ${PV} =~ _pre[0-9]{8}$ ]]; then
+			BASH_COMMIT=
+		fi
 		;;
 	*_p*)
 		PLEVEL=${PV##*_p}
 		;;
 	*)
 		PLEVEL=0
-		;;
 esac
 
 # The version of readline this bash normally ships with. Note that we only use
@@ -40,13 +42,12 @@ if [[ ${PV} == 9999 ]]; then
 	EGIT_REPO_URI="https://git.savannah.gnu.org/git/bash.git"
 	EGIT_BRANCH=devel
 	inherit git-r3
-elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 	# It can be useful to have snapshots in the pre-release period once
 	# the first alpha is out, as various bugs get reported and fixed from
 	# the alpha, and the next pre-release is usually quite far away.
 	#
 	# i.e. if it's worth packaging the alpha, it's worth packaging a followup.
-	BASH_COMMIT="b35866a2891a9b069e37ca5684d4309c0391e261"
 	SRC_URI="https://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-${BASH_COMMIT}.tar.gz -> ${P}-${BASH_COMMIT}.tar.gz"
 	S=${WORKDIR}/${PN}-${BASH_COMMIT}
 else
@@ -124,7 +125,7 @@ src_unpack() {
 
 	if [[ ${PV} == 9999 ]]; then
 		git-r3_src_unpack
-	elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+	elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 		default
 	else
 		if use verify-sig; then
@@ -168,8 +169,10 @@ src_configure() {
 	# Upstream only test with Bison and require GNUisms like YYEOF and
 	# YYERRCODE. The former at least may be in POSIX soon:
 	# https://www.austingroupbugs.net/view.php?id=1269.
+	#
 	# configure warns on use of non-Bison but doesn't abort. The result
-	# may misbehave at runtime.
+	# may misbehave at runtime. Chet also advises against use of byacc:
+	# https://lists.gnu.org/archive/html/bug-bash/2025-08/msg00115.html
 	unset -v YACC
 
 	if tc-is-cross-compiler; then
@@ -373,6 +376,11 @@ pkg_postinst() {
 		ln -sf -- bash "${EROOT}"/bin/sh || die
 	fi
 
+	if [[ -e ${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash ]]; then
+		ewarn "The following file is no longer packaged and can safely be deleted:"
+		ewarn "${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash"
+	fi
+
 	read -rd '' -a versions <<<"${REPLACING_VERSIONS}"
 	for ver in "${versions[@]}"; do
 		if [[ ! ${old_ver} ]] || ver_test "${ver}" -lt "${old_ver}"; then
@@ -380,13 +388,21 @@ pkg_postinst() {
 		fi
 	done
 
-	if [[ ! $old_ver ]]; then
-		:
-	elif ver_test "$old_ver" -ge "5.2" && ver_test "$old_ver" -ge "5.2_p26-r8"; then
+	if [[ ! ${old_ver} ]]; then
 		return
 	fi
 
-	while read -r; do ewarn "${REPLY}"; done <<'EOF'
+	{
+		if ver_test "${old_ver}" -ge "5.2" \
+			&& ver_test "${old_ver}" -ge "5.2_p26-r8"
+		then
+			:
+		elif ver_test "${old_ver}" -lt "5.2" \
+			&& ver_test "${old_ver}" -ge "5.1_p16-r8"
+		then
+			:
+		else
+			cat <<'EOF'
 Files under /etc/bash/bashrc.d must now have a suffix of .sh or .bash.
 
 Gentoo now defaults to defining PROMPT_COMMAND as an array. Depending on the
@@ -409,4 +425,14 @@ Those who would prefer for bash never to interfere with the window title may
 now opt out of the default title setting behaviour, either with the "unset -v
 PROMPT_COMMAND" command or by re-defining PROMPT_COMMAND as desired.
 EOF
+		fi
+	} \
+	| if [[ ${COLUMNS} == [1-9]*([0-9]) ]] && (( COLUMNS > 80 )); then
+		fmt -w "$(( COLUMNS - 3 ))"
+	else
+		cat
+	fi \
+	| while read -r; do
+		ewarn "${REPLY}"
+	done
 }

diff --git a/app-shells/bash/bash-5.4_alpha_pre20250918-r1.ebuild b/app-shells/bash/bash-5.4_alpha_pre20250918-r1.ebuild
index 657225a804f9..10edeed625e6 100644
--- a/app-shells/bash/bash-5.4_alpha_pre20250918-r1.ebuild
+++ b/app-shells/bash/bash-5.4_alpha_pre20250918-r1.ebuild
@@ -20,13 +20,15 @@ case ${PV} in
 	9999|*_alpha*|*_beta*|*_rc*)
 		# Set a negative patchlevel to indicate that it's a pre-release.
 		PLEVEL=-1
+		if [[ ${PV} =~ _pre[0-9]{8}$ ]]; then
+			BASH_COMMIT="cf8a2518c8b94f75b330d398f5daa0ee21417e1b"
+		fi
 		;;
 	*_p*)
 		PLEVEL=${PV##*_p}
 		;;
 	*)
 		PLEVEL=0
-		;;
 esac
 
 # The version of readline this bash normally ships with. Note that we only use
@@ -40,13 +42,12 @@ if [[ ${PV} == 9999 ]]; then
 	EGIT_REPO_URI="https://git.savannah.gnu.org/git/bash.git"
 	EGIT_BRANCH=devel
 	inherit git-r3
-elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 	# It can be useful to have snapshots in the pre-release period once
 	# the first alpha is out, as various bugs get reported and fixed from
 	# the alpha, and the next pre-release is usually quite far away.
 	#
 	# i.e. if it's worth packaging the alpha, it's worth packaging a followup.
-	BASH_COMMIT="cf8a2518c8b94f75b330d398f5daa0ee21417e1b"
 	SRC_URI="https://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-${BASH_COMMIT}.tar.gz -> ${P}-${BASH_COMMIT}.tar.gz"
 	S=${WORKDIR}/${PN}-${BASH_COMMIT}
 else
@@ -123,7 +124,7 @@ src_unpack() {
 
 	if [[ ${PV} == 9999 ]]; then
 		git-r3_src_unpack
-	elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+	elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 		default
 	else
 		if use verify-sig; then
@@ -167,8 +168,10 @@ src_configure() {
 	# Upstream only test with Bison and require GNUisms like YYEOF and
 	# YYERRCODE. The former at least may be in POSIX soon:
 	# https://www.austingroupbugs.net/view.php?id=1269.
+	#
 	# configure warns on use of non-Bison but doesn't abort. The result
-	# may misbehave at runtime.
+	# may misbehave at runtime. Chet also advises against use of byacc:
+	# https://lists.gnu.org/archive/html/bug-bash/2025-08/msg00115.html
 	unset -v YACC
 
 	if tc-is-cross-compiler; then
@@ -369,6 +372,11 @@ pkg_postinst() {
 		ln -sf -- bash "${EROOT}"/bin/sh || die
 	fi
 
+	if [[ -e ${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash ]]; then
+		ewarn "The following file is no longer packaged and can safely be deleted:"
+		ewarn "${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash"
+	fi
+
 	read -rd '' -a versions <<<"${REPLACING_VERSIONS}"
 	for ver in "${versions[@]}"; do
 		if [[ ! ${old_ver} ]] || ver_test "${ver}" -lt "${old_ver}"; then
@@ -376,13 +384,21 @@ pkg_postinst() {
 		fi
 	done
 
-	if [[ ! $old_ver ]]; then
-		:
-	elif ver_test "$old_ver" -ge "5.2" && ver_test "$old_ver" -ge "5.2_p26-r8"; then
+	if [[ ! ${old_ver} ]]; then
 		return
 	fi
 
-	while read -r; do ewarn "${REPLY}"; done <<'EOF'
+	{
+		if ver_test "${old_ver}" -ge "5.2" \
+			&& ver_test "${old_ver}" -ge "5.2_p26-r8"
+		then
+			:
+		elif ver_test "${old_ver}" -lt "5.2" \
+			&& ver_test "${old_ver}" -ge "5.1_p16-r8"
+		then
+			:
+		else
+			cat <<'EOF'
 Files under /etc/bash/bashrc.d must now have a suffix of .sh or .bash.
 
 Gentoo now defaults to defining PROMPT_COMMAND as an array. Depending on the
@@ -405,4 +421,14 @@ Those who would prefer for bash never to interfere with the window title may
 now opt out of the default title setting behaviour, either with the "unset -v
 PROMPT_COMMAND" command or by re-defining PROMPT_COMMAND as desired.
 EOF
+		fi
+	} \
+	| if [[ ${COLUMNS} == [1-9]*([0-9]) ]] && (( COLUMNS > 80 )); then
+		fmt -w "$(( COLUMNS - 3 ))"
+	else
+		cat
+	fi \
+	| while read -r; do
+		ewarn "${REPLY}"
+	done
 }

diff --git a/app-shells/bash/bash-9999.ebuild b/app-shells/bash/bash-9999.ebuild
index 7e576e31249a..6211b96f2a29 100644
--- a/app-shells/bash/bash-9999.ebuild
+++ b/app-shells/bash/bash-9999.ebuild
@@ -20,13 +20,15 @@ case ${PV} in
 	9999|*_alpha*|*_beta*|*_rc*)
 		# Set a negative patchlevel to indicate that it's a pre-release.
 		PLEVEL=-1
+		if [[ ${PV} =~ _pre[0-9]{8}$ ]]; then
+			BASH_COMMIT=
+		fi
 		;;
 	*_p*)
 		PLEVEL=${PV##*_p}
 		;;
 	*)
 		PLEVEL=0
-		;;
 esac
 
 # The version of readline this bash normally ships with. Note that we only use
@@ -40,13 +42,12 @@ if [[ ${PV} == 9999 ]]; then
 	EGIT_REPO_URI="https://git.savannah.gnu.org/git/bash.git"
 	EGIT_BRANCH=devel
 	inherit git-r3
-elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 	# It can be useful to have snapshots in the pre-release period once
 	# the first alpha is out, as various bugs get reported and fixed from
 	# the alpha, and the next pre-release is usually quite far away.
 	#
 	# i.e. if it's worth packaging the alpha, it's worth packaging a followup.
-	BASH_COMMIT="b35866a2891a9b069e37ca5684d4309c0391e261"
 	SRC_URI="https://git.savannah.gnu.org/cgit/bash.git/snapshot/bash-${BASH_COMMIT}.tar.gz -> ${P}-${BASH_COMMIT}.tar.gz"
 	S=${WORKDIR}/${PN}-${BASH_COMMIT}
 else
@@ -123,7 +124,7 @@ src_unpack() {
 
 	if [[ ${PV} == 9999 ]]; then
 		git-r3_src_unpack
-	elif (( PLEVEL < 0 )) && [[ ${PV} == *_p* ]] ; then
+	elif (( PLEVEL < 0 )) && [[ ${BASH_COMMIT} ]]; then
 		default
 	else
 		if use verify-sig; then
@@ -374,6 +375,11 @@ pkg_postinst() {
 		ln -sf -- bash "${EROOT}"/bin/sh || die
 	fi
 
+	if [[ -e ${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash ]]; then
+		ewarn "The following file is no longer packaged and can safely be deleted:"
+		ewarn "${EROOT}/etc/bash/bashrc.d/15-gentoo-bashrc-check.bash"
+	fi
+
 	read -rd '' -a versions <<<"${REPLACING_VERSIONS}"
 	for ver in "${versions[@]}"; do
 		if [[ ! ${old_ver} ]] || ver_test "${ver}" -lt "${old_ver}"; then
@@ -381,13 +387,21 @@ pkg_postinst() {
 		fi
 	done
 
-	if [[ ! $old_ver ]]; then
-		:
-	elif ver_test "$old_ver" -ge "5.2" && ver_test "$old_ver" -ge "5.2_p26-r8"; then
+	if [[ ! ${old_ver} ]]; then
 		return
 	fi
 
-	while read -r; do ewarn "${REPLY}"; done <<'EOF'
+	{
+		if ver_test "${old_ver}" -ge "5.2" \
+			&& ver_test "${old_ver}" -ge "5.2_p26-r8"
+		then
+			:
+		elif ver_test "${old_ver}" -lt "5.2" \
+			&& ver_test "${old_ver}" -ge "5.1_p16-r8"
+		then
+			:
+		else
+			cat <<'EOF'
 Files under /etc/bash/bashrc.d must now have a suffix of .sh or .bash.
 
 Gentoo now defaults to defining PROMPT_COMMAND as an array. Depending on the
@@ -410,4 +424,14 @@ Those who would prefer for bash never to interfere with the window title may
 now opt out of the default title setting behaviour, either with the "unset -v
 PROMPT_COMMAND" command or by re-defining PROMPT_COMMAND as desired.
 EOF
+		fi
+	} \
+	| if [[ ${COLUMNS} == [1-9]*([0-9]) ]] && (( COLUMNS > 80 )); then
+		fmt -w "$(( COLUMNS - 3 ))"
+	else
+		cat
+	fi \
+	| while read -r; do
+		ewarn "${REPLY}"
+	done
 }


             reply	other threads:[~2025-09-30 20:15 UTC|newest]

Thread overview: 384+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-30 20:14 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-10-08  4:42 [gentoo-commits] repo/gentoo:master commit in: app-shells/bash/ Sam James
2025-10-01 20:02 Sam James
2025-09-30 20:14 Sam James
2025-09-30 20:14 Sam James
2025-09-20 20:24 Sam James
2025-09-19 12:50 Sam James
2025-09-18 21:35 Sam James
2025-09-18 21:35 Sam James
2025-09-18 21:35 Sam James
2025-09-18 21:35 Sam James
2025-09-18 21:35 Sam James
2025-09-18 21:35 Sam James
2025-09-07  3:39 Arthur Zamarin
2025-09-06 22:26 Sam James
2025-09-06 22:06 Sam James
2025-09-06 22:06 Sam James
2025-09-06 22:06 Sam James
2025-09-06 22:05 Sam James
2025-09-06 21:32 Sam James
2025-09-06 21:32 Sam James
2025-09-06 21:32 Sam James
2025-08-25  3:00 Sam James
2025-08-23  6:44 Sam James
2025-08-20 18:24 Sam James
2025-08-18 15:55 Sam James
2025-08-18 15:55 Sam James
2025-08-15 17:00 Sam James
2025-08-08 19:07 Sam James
2025-08-04 20:59 Sam James
2025-08-03  1:07 Sam James
2025-07-24  4:24 Sam James
2025-07-19 14:47 Sam James
2025-07-18 18:24 Sam James
2025-07-11 23:50 Sam James
2025-07-04 19:02 Sam James
2025-07-04 19:02 Sam James
2025-07-04 18:12 Sam James
2025-06-29  3:19 Sam James
2025-06-21 18:04 Sam James
2025-06-21  5:50 Arthur Zamarin
2025-06-16 21:00 Sam James
2025-06-15  5:21 Arthur Zamarin
2025-06-15  0:33 Sam James
2025-06-15  0:33 Sam James
2025-06-15  0:33 Sam James
2025-06-06 22:24 Sam James
2025-06-03  2:38 Sam James
2025-06-02 19:09 Sam James
2025-06-02 18:45 Sam James
2025-05-30 18:51 Sam James
2025-05-27  9:23 James Le Cuirot
2025-05-27  9:23 James Le Cuirot
2025-05-20 19:29 Sam James
2025-05-07 16:08 Sam James
2025-05-07 16:08 Sam James
2025-05-07 14:52 Sam James
2025-05-05  9:30 Sam James
2025-05-04  5:02 Sam James
2025-05-02  6:12 Sam James
2025-05-02  6:11 Sam James
2025-05-01  0:54 Sam James
2025-04-23 16:42 Sam James
2025-04-18 23:54 Sam James
2025-04-09 14:22 Sam James
2025-04-07 20:17 Sam James
2025-04-05  1:00 Sam James
2025-03-31 23:42 Sam James
2025-03-31 20:01 Sam James
2025-03-24 23:20 Sam James
2025-03-14  5:32 Sam James
2025-03-07 16:33 Sam James
2025-02-25  7:28 Sam James
2025-02-25  6:13 Sam James
2025-02-23  1:45 Sam James
2025-02-12 17:09 Sam James
2025-02-10 23:58 Sam James
2025-01-25  5:20 Sam James
2025-01-16  0:28 Sam James
2025-01-10  4:17 Sam James
2025-01-09  0:08 Sam James
2025-01-09  0:08 Sam James
2024-12-31  7:04 Sam James
2024-12-23 10:52 Sam James
2024-12-17 15:25 Sam James
2024-12-13 15:46 Sam James
2024-12-10 18:53 Sam James
2024-12-07  2:33 Sam James
2024-12-06 16:07 Sam James
2024-12-06 13:04 Sam James
2024-11-23  3:33 Sam James
2024-11-21 17:15 Sam James
2024-11-16  9:19 Sam James
2024-11-16  9:19 Sam James
2024-11-15 21:57 Sam James
2024-11-09  3:54 Sam James
2024-11-05  1:21 Sam James
2024-11-03  8:21 Sam James
2024-11-02  3:23 Sam James
2024-10-28 21:30 Sam James
2024-10-27  2:53 Sam James
2024-10-23 17:03 Sam James
2024-10-18 19:16 Sam James
2024-10-17  4:40 Sam James
2024-10-17  4:40 Sam James
2024-10-15 21:00 Sam James
2024-10-13 22:12 Sam James
2024-10-12 23:35 Sam James
2024-10-12 22:19 Sam James
2024-10-11 16:40 Sam James
2024-10-08 21:50 Jakov Smolić
2024-10-08 18:49 Sam James
2024-10-05 11:48 Arthur Zamarin
2024-10-05  9:44 Sam James
2024-10-05  9:07 Arthur Zamarin
2024-10-05  9:06 Arthur Zamarin
2024-10-05  7:28 Sam James
2024-09-27 17:26 Sam James
2024-09-24  6:35 Sam James
2024-09-24  6:32 Sam James
2024-09-24  6:32 Sam James
2024-09-11 22:13 Sam James
2024-09-05  7:17 Sam James
2024-08-30 14:59 Ionen Wolkens
2024-08-28 22:31 Sam James
2024-08-26 22:54 Sam James
2024-08-24  8:10 Sam James
2024-08-22  2:13 Sam James
2024-08-15 21:38 Sam James
2024-08-15 21:38 Sam James
2024-08-10 21:03 Sam James
2024-07-31 18:44 Sam James
2024-07-26 18:10 Sam James
2024-07-19  4:55 Sam James
2024-07-16  3:51 Sam James
2024-07-07  1:54 Sam James
2024-07-07  1:54 Sam James
2024-07-06 22:10 Sam James
2024-07-01 23:14 Sam James
2024-06-21  4:23 Arthur Zamarin
2024-06-20 21:46 Sam James
2024-06-20 21:46 Sam James
2024-06-20 20:17 Arthur Zamarin
2024-06-20 20:16 Arthur Zamarin
2024-06-20 20:14 Arthur Zamarin
2024-06-20 19:36 Arthur Zamarin
2024-06-20 18:28 Sam James
2024-06-20 18:28 Sam James
2024-06-14  6:47 Sam James
2024-06-13 17:57 Sam James
2024-06-13 17:57 Sam James
2024-06-13  2:28 Sam James
2024-06-13  2:28 Sam James
2024-06-13  2:28 Sam James
2024-06-13  2:28 Sam James
2024-05-22  4:35 Sam James
2024-05-18 17:06 Sam James
2024-05-18 17:06 Sam James
2024-04-30  2:37 Sam James
2024-04-23 13:56 Sam James
2024-04-23 13:56 Sam James
2024-04-23 13:56 Sam James
2024-03-12  0:29 Sam James
2024-03-04 10:24 Sam James
2023-12-28  4:59 Sam James
2023-10-12 12:13 Sam James
2023-10-12 12:05 Sam James
2023-10-12  5:48 Sam James
2023-06-02 21:47 Sam James
2023-05-31  4:59 Sam James
2023-05-22 16:26 David Seifert
2023-01-28 20:24 Mike Gilbert
2023-01-15 22:41 Sam James
2023-01-07  0:06 Sam James
2023-01-04  5:33 Sam James
2023-01-04  5:32 Sam James
2022-12-13 19:37 Sam James
2022-12-13 19:37 Sam James
2022-11-23 23:29 Sam James
2022-11-08  2:54 Sam James
2022-10-29  5:45 Arthur Zamarin
2022-10-28 20:53 Sam James
2022-10-28 20:44 Sam James
2022-10-28 20:44 Sam James
2022-10-28 20:44 Sam James
2022-10-28 20:44 Sam James
2022-10-28 20:44 Sam James
2022-10-28 20:27 Sam James
2022-10-18  2:47 Sam James
2022-10-08 14:54 Sam James
2022-10-06 14:45 Sam James
2022-10-06 14:45 Sam James
2022-09-26 17:54 Sam James
2022-09-26 17:53 Sam James
2022-09-23  2:09 Sam James
2022-09-10  0:29 Sam James
2022-08-26 22:54 Sam James
2022-08-26 22:54 Sam James
2022-08-14 22:01 Sam James
2022-07-31 16:55 Mike Gilbert
2022-07-31  3:54 Sam James
2022-07-26  4:10 Sam James
2022-07-26  4:10 Sam James
2022-07-26  2:17 Sam James
2022-06-17 20:31 Sam James
2022-06-17 20:25 Sam James
2022-06-17 19:33 Sam James
2022-04-19 19:06 Sam James
2022-04-19 19:04 Sam James
2022-04-19 18:59 Sam James
2022-04-13 17:51 Sam James
2022-04-07  0:09 Sam James
2022-04-06 23:58 Sam James
2022-02-08 19:38 Arthur Zamarin
2022-02-08 19:38 Arthur Zamarin
2022-02-08 19:37 Arthur Zamarin
2022-02-08  7:24 Agostino Sarubbo
2022-02-08  7:23 Agostino Sarubbo
2022-02-08  7:22 Agostino Sarubbo
2022-02-08  5:50 Sam James
2022-02-08  5:50 Sam James
2022-01-21 23:50 Sam James
2022-01-21 23:43 Sam James
2022-01-05 11:38 Sam James
2022-01-05 11:28 Sam James
2021-11-18  4:30 Sam James
2021-11-18  4:30 Sam James
2021-10-14  8:46 Sam James
2021-06-21 18:16 Mike Gilbert
2021-05-13 20:58 Lars Wendler
2021-05-13 19:02 Sam James
2021-05-13 18:56 Sam James
2021-05-13 16:59 Sam James
2021-05-13 16:55 Sam James
2021-05-13 16:54 Sam James
2021-05-13 16:44 Sam James
2021-05-13 16:29 Sam James
2021-05-13 13:55 David Seifert
2021-05-04 19:50 Lars Wendler
2021-05-04 19:50 Lars Wendler
2021-01-24  4:32 Sam James
2021-01-17 11:41 Sergei Trofimovich
2021-01-12 15:02 Lars Wendler
2021-01-10  9:35 Sam James
2021-01-07 11:15 Sam James
2021-01-07 10:06 Sam James
2021-01-07  8:09 Fabian Groffen
2021-01-07  5:10 Sam James
2021-01-07  5:10 Sam James
2021-01-07  5:10 Sam James
2021-01-07  2:35 Sam James
2021-01-06 13:26 Fabian Groffen
2020-12-27 14:01 Fabian Groffen
2020-12-20 10:34 Lars Wendler
2020-12-07 11:50 Lars Wendler
2020-11-29 19:11 Lars Wendler
2020-11-29 19:11 Lars Wendler
2020-11-29 19:11 Lars Wendler
2020-11-29 19:11 Lars Wendler
2020-11-18  8:28 Lars Wendler
2020-11-18  8:26 Lars Wendler
2020-11-04 15:49 Lars Wendler
2020-09-24 15:41 Lars Wendler
2020-09-03 23:57 Sam James
2020-09-01  4:17 Sam James
2020-08-21 15:36 Agostino Sarubbo
2020-08-21 15:31 Agostino Sarubbo
2020-08-21 15:30 Agostino Sarubbo
2020-08-21 15:27 Agostino Sarubbo
2020-08-21 15:25 Agostino Sarubbo
2020-08-21  7:36 Sam James
2020-08-10  7:53 Lars Wendler
2020-08-10  7:52 Lars Wendler
2020-07-11  7:22 Lars Wendler
2020-05-30 19:20 Sergei Trofimovich
2020-05-11 11:38 Agostino Sarubbo
2020-05-06  6:28 Agostino Sarubbo
2020-05-06  6:27 Agostino Sarubbo
2020-05-04  6:16 Mart Raudsepp
2020-05-03 10:25 Agostino Sarubbo
2020-05-03 10:22 Agostino Sarubbo
2020-04-26  8:32 Lars Wendler
2020-04-26  2:41 Lars Wendler
2020-04-26  1:20 Lars Wendler
2020-02-09  0:35 Lars Wendler
2020-02-09  0:35 Lars Wendler
2019-09-02  7:54 Lars Wendler
2019-08-18 23:02 Lars Wendler
2019-08-15 10:50 Lars Wendler
2019-05-03 23:57 Mikle Kolyada
2019-04-21  9:16 Lars Wendler
2019-03-20 14:31 Lars Wendler
2019-03-20 14:31 Lars Wendler
2019-03-07 22:19 Lars Wendler
2019-02-16 13:39 Mikle Kolyada
2019-02-16 13:39 Mikle Kolyada
2019-01-31 14:23 Tobias Klausmann
2019-01-29 11:40 Mikle Kolyada
2019-01-23 13:41 Mikle Kolyada
2019-01-21 10:23 Lars Wendler
2019-01-17 22:41 Sergei Trofimovich
2019-01-17  8:31 Sergei Trofimovich
2019-01-17  8:29 Sergei Trofimovich
2019-01-17  8:08 Sergei Trofimovich
2019-01-17  8:01 Sergei Trofimovich
2019-01-16 10:52 Mikle Kolyada
2019-01-16 10:50 Mikle Kolyada
2019-01-15 22:10 Thomas Deutschmann
2019-01-15 10:36 Mart Raudsepp
2019-01-13 11:18 Lars Wendler
2019-01-07 23:08 Lars Wendler
2018-12-28 10:25 Fabian Groffen
2018-09-19 11:31 Mikle Kolyada
2018-09-17 14:49 Lars Wendler
2018-09-17 14:49 Lars Wendler
2018-06-07  0:34 Thomas Deutschmann
2018-05-30 22:25 Aaron Bauman
2018-05-11 19:52 Mikle Kolyada
2018-04-21 20:54 Mart Raudsepp
2018-03-22 17:35 Mikle Kolyada
2018-03-04  8:16 Tobias Klausmann
2018-02-11  2:03 Lars Wendler
2018-02-01 20:31 Lars Wendler
2018-01-10  6:19 Markus Meier
2018-01-05  9:35 Lars Wendler
2018-01-03 17:20 Mikle Kolyada
2018-01-03  9:28 Sergei Trofimovich
2018-01-03  9:04 Sergei Trofimovich
2017-06-17 21:36 Lars Wendler
2017-06-17 21:36 Lars Wendler
2017-02-09 19:16 Patrick McLean
2017-01-20 22:56 Mike Frysinger
2017-01-09 21:09 Lars Wendler
2016-12-15 21:49 Mike Frysinger
2016-12-06 11:53 Agostino Sarubbo
2016-12-06 11:50 Agostino Sarubbo
2016-12-05 15:49 Tobias Klausmann
2016-12-04 16:09 Lars Wendler
2016-11-14 20:15 Mike Frysinger
2016-11-10 14:05 Mike Frysinger
2016-11-10  6:07 Mike Frysinger
2016-10-24  0:35 Benda XU
2016-10-18 19:47 Markus Meier
2016-10-13  8:32 Lars Wendler
2016-10-11 14:18 Tobias Klausmann
2016-10-08 12:43 Jeroen Roovers
2016-10-07 13:27 Agostino Sarubbo
2016-10-07 13:27 Agostino Sarubbo
2016-10-07  9:06 Lars Wendler
2016-10-07  9:06 Lars Wendler
2016-09-29 13:28 Agostino Sarubbo
2016-09-29 13:14 Agostino Sarubbo
2016-09-29 12:35 Agostino Sarubbo
2016-09-22 13:00 Jeroen Roovers
2016-09-21 13:18 Agostino Sarubbo
2016-09-21 11:32 Tobias Klausmann
2016-09-16  7:44 Lars Wendler
2016-09-15 18:38 Lars Wendler
2016-09-15 18:38 Lars Wendler
2016-08-23  9:07 Lars Wendler
2016-06-13  7:21 Benda XU
2016-05-16 18:20 Mike Frysinger
2016-02-24 16:01 Mike Frysinger
2016-02-03 18:52 Mike Frysinger
2016-01-26  7:52 Mike Frysinger
2016-01-26  7:52 Mike Frysinger
2016-01-11 10:46 Mike Frysinger
2016-01-06 13:34 Agostino Sarubbo
2016-01-04 12:38 Lars Wendler
2015-12-28  7:54 Jeroen Roovers
2015-12-26 23:32 Agostino Sarubbo
2015-09-21 11:27 Agostino Sarubbo
2015-09-01 15:54 Markus Meier
2015-08-30 13:23 Tobias Klausmann
2015-08-27  0:05 Mike Frysinger
2015-08-24 13:48 Mikle Kolyada
2015-08-24  5:16 Jeroen Roovers
2015-08-18 14:37 Mike Frysinger
2015-08-18  4:32 Jeroen Roovers
2015-08-16 17:45 Mikle Kolyada
2015-08-16 11:30 Justin Lecher
2015-08-14 21:25 Mikle Kolyada
2015-08-14  2:13 Mike Frysinger
2015-08-13  6:28 Mike Frysinger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1759263244.82ef038c820564201ffc9f7c3e742be12a6c421c.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox