1 # Copyright 2024 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
6 MY_PV="${PV/_pre/-devel}"
8 DESCRIPTION="A line editor written in pure Bash with enhanced features"
9 HOMEPAGE="https://github.com/akinomyoga/ble.sh"
11 if [[ ${PV} == 9999 ]] ; then
13 EGIT_REPO_URI="https://github.com/akinomyoga/ble.sh.git"
15 GIT_COMMIT_CONTRIB=9700c79eb97b3b5f0f06f7019097dc9d3ee93404
16 BLESH_CONTRIB_PV="0_pre20230403"
18 https://github.com/akinomyoga/ble.sh/archive/refs/tags/v${MY_PV}.tar.gz -> ${P}.tar.gz
19 https://github.com/akinomyoga/blesh-contrib/archive/${GIT_COMMIT_CONTRIB}.tar.gz
20 -> blesh-contrib-${BLESH_CONTRIB_PV}.tar.gz
22 S="${WORKDIR}/ble.sh-${MY_PV}"
29 RDEPEND=">=app-shells/bash-3.0"
31 PATCHES=( "${FILESDIR}/${P}-no-git.patch" )
33 if [[ ${PV} != 9999 ]]; then
34 PATCHES+=( "${FILESDIR}/${P}-optional-docs.patch" )
38 if [[ ${PV} == 9999 ]] ; then
42 rmdir "${S}/contrib" || die
43 mv "${WORKDIR}/blesh-contrib-${GIT_COMMIT_CONTRIB}" "${S}/contrib" || die
48 emake USE_DOC=$(usex doc)
55 PREFIX="${EPREFIX}/usr" \
56 INSDIR_DOC="${ED}/usr/share/doc/${PF}"
57 insinto /usr/share/blesh/lib
58 doins "${FILESDIR}/_package.bash"
62 elog "Remember to enable ble.sh in your ~/.bashrc"
63 elog "by adding this line at the top of ~/.bashrc:"
64 elog '[[ $- == *i* ]] && source /usr/share/blesh/ble.sh --noattach'
65 elog "and add this line at the end of ~/.bashrc:"
66 elog '[[ ${BLE_VERSION-} ]] && ble-attach'