From 71deace00d1a2b091313fe137ab7092418c6f87c Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 10 Feb 2020 21:05:55 +0000 Subject: gentoo resync : 10.02.2020 --- app-shells/Manifest.gz | Bin 8134 -> 8302 bytes app-shells/bash/Manifest | 7 +- app-shells/bash/bash-5.0_p16.ebuild | 264 ++++++++++++++++++++ app-shells/bash/bash-5.0_p9.ebuild | 265 --------------------- app-shells/fish/Manifest | 2 +- app-shells/fish/fish-3.0.2.ebuild | 4 +- app-shells/gentoo-bashcomp/Manifest | 4 +- .../gentoo-bashcomp-20180302.ebuild | 2 +- .../gentoo-bashcomp-20190211.ebuild | 2 +- app-shells/ksh/Manifest | 3 +- app-shells/ksh/files/CVE-2019-14868.patch | 89 +++++++ app-shells/ksh/ksh-2020.0.0-r1.ebuild | 50 ++++ app-shells/ksh/ksh-2020.0.0.ebuild | 49 ---- app-shells/zsh-syntax-highlighting/Manifest | 3 + app-shells/zsh-syntax-highlighting/metadata.xml | 8 + .../zsh-syntax-highlighting-0.7.0_beta1.ebuild | 42 ++++ 16 files changed, 471 insertions(+), 323 deletions(-) create mode 100644 app-shells/bash/bash-5.0_p16.ebuild delete mode 100644 app-shells/bash/bash-5.0_p9.ebuild create mode 100644 app-shells/ksh/files/CVE-2019-14868.patch create mode 100644 app-shells/ksh/ksh-2020.0.0-r1.ebuild delete mode 100644 app-shells/ksh/ksh-2020.0.0.ebuild create mode 100644 app-shells/zsh-syntax-highlighting/Manifest create mode 100644 app-shells/zsh-syntax-highlighting/metadata.xml create mode 100644 app-shells/zsh-syntax-highlighting/zsh-syntax-highlighting-0.7.0_beta1.ebuild (limited to 'app-shells') diff --git a/app-shells/Manifest.gz b/app-shells/Manifest.gz index 01fbc69ef3db..83268eeaaf7e 100644 Binary files a/app-shells/Manifest.gz and b/app-shells/Manifest.gz differ diff --git a/app-shells/bash/Manifest b/app-shells/bash/Manifest index c8a4e94684c8..cc0fff6501bc 100644 --- a/app-shells/bash/Manifest +++ b/app-shells/bash/Manifest @@ -386,6 +386,11 @@ DIST bash50-008 2622 BLAKE2B 9919e24840f32a44a9040fd8fa9fb482da1859223e70e75d21d DIST bash50-009 1095 BLAKE2B 4a9b2035173dd23f9c8ac5474e573080112d9edcf918816b5dd41e880f212f66c2c80dd41793ec62449c487fec1ad2c57b353a00c0976a782098fa6be76d0f23 SHA512 6b770dbd4ca1175f9b958931b1e725d96626a24fb270bac5414d1679dde05276c87654815e9957d6932c515e8792caf8a5f0e9f2dc108bdd041d8024cf75a833 DIST bash50-010 6407 BLAKE2B 94792141dedbb8d2c9f9355c94eec56b1fa84459291c61ac31e9ee9a67e80edb95234b67ab59c5f3f039d596275c9b154544439bc730256beaf303e6cbf99c4c SHA512 8ca2cea0264bc0401414207fd8752d4d6eda64be3bb10fdc22529fa2bcedb84e6ab257ba2badc7078ece7f2ae1e2964635926f227eea7aed58166e82871322c2 DIST bash50-011 1870 BLAKE2B 7307aa709810ea3e9fbc0db6a558cb6a660736677edf56904721599be5c0a6e69b74cc01fb3988f1b06e7f8bcce512a3b5d773b7ebb3a7397a0e4815e84f48ce SHA512 05833d6c85f3795a9c100246335f39155c1b5d190e073bf382269c2bbceb13a2de3f85dbe1dd5d4c7824fcca481febe3bdbb4c555e1f2de86bec05fcf6f5871e +DIST bash50-012 1571 BLAKE2B 3a107454439fa84b1416d0b17b81fd86cfd4cc046bb4c4ca820e09b4595f4bc95dd188f2957b2f2c83937a776eee3db19a7c070403014bfeb5d5778b26705aa1 SHA512 24d67358eec07cc4cd0457ec0c296567558f20bf713b917fc8a8e5095a83f1c5db880bb863d483ca0c9e003972ac5f56596a2eb10c26c82bf6326d0475784e7e +DIST bash50-013 2328 BLAKE2B 8797fe0b8e01027222af9798ee8d57d161bfbedb617b257e91402ef60e7010dd32fc68e2477487813746842800387c5ea0cdd853e039cf7065a2786fd6d6a182 SHA512 38fff9856c2259fbba607aacee027dd61e8733c6e5f476b7491bc43755fb5a63e82372f9f18663ec81e7480f0738b296271c948e1932e851f68f53cf3a1935b5 +DIST bash50-014 1747 BLAKE2B d52f9160d74b340fd5722725b572ac1abe74caf41add5421dfa56fd44916ead691e4d698de3ba118ff0f8fc8eadade7a980551134eb0daf18b0767ff9601a4b4 SHA512 e8f65be24b425ecaf66672eb4271e0efac2f495f882aeb559d60b52359a468b51852ed7aeeea0ab77cf648a48c9d37f2a00e263d06d29e9fa75b67a648399d91 +DIST bash50-015 2565 BLAKE2B 7df76369726332299c089db156c1e9bc6619fe2e925732da46ca47ca627f1bd7df4ea188a2c0f636e42623f2ee7ca40bc98551b5bd339ed4d5bee20b24ba38d0 SHA512 3a1a552d1f03dec9ed41be8d8c319fb3cbd01df9978ab25a7b37322913014beca6703980f342ea908250b666d72db95402d7b8219ffdd3df717acb36ed4b72b9 +DIST bash50-016 1534 BLAKE2B 8c9bb752a441b70b11655a9bd48e48ec9756a34d0513837faa94c64675c11d57ba1fb0bfc43a033040539f9c475a0efd00f375cf8ffe04a6d9d1d1c19575572e SHA512 dbc3bd0fe3bddad8f6417b210fc5638a9c0c545f9d27638d63bac48aba9d3b93181a4f2e9898584d231b658589573fad5e4627ccbcf3e9d87e7663ac730b51aa EBUILD bash-2.05b_p13.ebuild 4604 BLAKE2B 0813fddad287f8ad0424e39ccd0f3155bc312d833856e22123c8454c110022bd0a1c1daa33fd88f39ae936bf04a080e9a54b8cd49342c8f99a851b8ad3e17a0e SHA512 059d1e4464566c9c9785125a8a393184ea0a4445f43c7898fcaab5201b0988b65445812c57a97ce6b0b6a7c1cc65fddc06b001d80915d4c54af4dc6f9124bcfd EBUILD bash-3.0_p22.ebuild 4737 BLAKE2B 6ca8a22f0aace907dbf7eb57804c602ed39395198045a94fa31b34c98b3f4b80b7077247dabee7351639043a33f797ea861d7cbbc1f6327805b3bc289d27adf9 SHA512 53aad975e2703a6d0766b2a9399cefb3e031a151df5dc63fbdb648868e86bcab647d818efc0b7f473f4e57bfb83d8758f595dabc41cf8d1209432537bd8e843b EBUILD bash-3.1_p23.ebuild 4418 BLAKE2B af3f33a9cb2cdcb95956d2aa7c674411efc12777779ebee5b929f7e74c7deaa894ae799e20451f444d572e382ddd0c863841aa98751779d12329179a8874708f SHA512 e80b15131bcffa55092dfef44172d8514cd8740ae4f4a5814354bc000a318f563833c8c84bcbe88983d02360ed122ff904ad7a3374d70a01b1b9a40e0a14227d @@ -396,5 +401,5 @@ EBUILD bash-4.2_p53.ebuild 4323 BLAKE2B c228182e505b67d7d598a1b3b707c785302615fa EBUILD bash-4.3_p48-r2.ebuild 5621 BLAKE2B 7197e814c59e552720f8c25e634c283c12eaaf18910e25b29deff79ce53031fef0599372f6f6a3380cd98c34a234cae02b9a136053af10f56ab57d67b789a017 SHA512 6959eecb84e85f77e415f16e0df5314f2fa2b0fbef90723de6878e7f5539732a340f119c12a92ff915e3fbce5f7eff20a039ca642fd5d5f963e0b97a0c9e6e83 EBUILD bash-4.4_p23-r1.ebuild 7368 BLAKE2B 7f070e824465c6868d2c09cbb97b44570be88a52f0930984db2c4cf1b9715e7897e227dfc8ff556c3c995d00b63b9073b7f5c4974bd05ee270ae483c49457aa6 SHA512 a9c6a27d042f003344f05fee3b3c68441dca8fca5ef16df81e118f8905b2ef43aa68f1028e16def30ae32bfb9abb7b28ea495e176b00f7529c14dd058cb436cd EBUILD bash-5.0_p11.ebuild 7428 BLAKE2B a912551c6ab6cbcdd504baa74286935b7f83ef31c3db4fe144a93fb3ac24b2cfa057331710b9ab88aa1d9a4cb46b4ea48eaa427ca0c696a880f926ed346dc406 SHA512 36735b4668d3e65cc18db9bdacf7bd3030f7a5629f4876317ddd24f660194dc8ff661587fabdf4da0aa8f30b2bd3d0f355e915cea97aa51f7c67f7b5c698da82 -EBUILD bash-5.0_p9.ebuild 7488 BLAKE2B 1de7e377d32bb1b08699fe8b418f5fbbbf7cf92fa865f2bc14dddc3010fa78b0803aa4dfa489888a812698b5646bcceb4bfdb7951fe647454b6f5cc90cf48b0f SHA512 f63c093db4c160bfe41ff2605d42f4aa184bac33ff6b0d89fb025571c88907bea3a2a5b71486bfac238ca1d842abf93fe671147b68bead2c0f9b5d498a4428d0 +EBUILD bash-5.0_p16.ebuild 7428 BLAKE2B 2ec57c0463ecfcb9a663099f8af5516aab2e36a1236c0510d4b3a85467d7a25d9dd40774501f112538744c29061002dc4a8a37bdb9f2ee305568aa1150411bfd SHA512 3337e6e8927d017fa0a8c71b9e893b34d1e1191b2c7291d0d4314033a3426e729f1478769edb6ba144b174989341e5caec483978758fc49337934ad0b170b670 MISC metadata.xml 734 BLAKE2B 242fda202379209b74e12c1726c4f4aa487eb09423d2249d13cae38cb9b077a285beff221a824647c826c39f7400178cd04d6082915ad9c23287ea70da9ef961 SHA512 a9301e8d2347e0cf90a97325d9a705076150c00609d28338e5d7d72c135468e4f0531b2a4077b69679ae6ccf89eee691e0e5f0748caab60689f5f017afb544f1 diff --git a/app-shells/bash/bash-5.0_p16.ebuild b/app-shells/bash/bash-5.0_p16.ebuild new file mode 100644 index 000000000000..dadb54e7e863 --- /dev/null +++ b/app-shells/bash/bash-5.0_p16.ebuild @@ -0,0 +1,264 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit flag-o-matic toolchain-funcs multilib prefix + +# Official patchlevel +# See ftp://ftp.cwru.edu/pub/bash/bash-5.0-patches/ +PLEVEL=${PV##*_p} +MY_PV=${PV/_p*} +MY_PV=${MY_PV/_/-} +MY_P=${PN}-${MY_PV} +is_release() { + case ${PV} in + *_alpha*|*_beta*|*_rc*) return 1 ;; + *) return 0 ;; + esac +} +[[ ${PV} != *_p* ]] && PLEVEL=0 +patches() { + local opt=$1 plevel=${2:-${PLEVEL}} pn=${3:-${PN}} pv=${4:-${MY_PV}} + [[ ${plevel} -eq 0 ]] && return 1 + eval set -- {1..${plevel}} + set -- $(printf "${pn}${pv/\.}-%03d " "$@") + if [[ ${opt} == -s ]] ; then + echo "${@/#/${DISTDIR}/}" + else + local u + for u in ftp://ftp.cwru.edu/pub/bash mirror://gnu/${pn} ; do + printf "${u}/${pn}-${pv}-patches/%s " "$@" + done + fi +} + +# The version of readline this bash normally ships with. +READLINE_VER="8.0" + +DESCRIPTION="The standard GNU Bourne again shell" +HOMEPAGE="http://tiswww.case.edu/php/chet/bash/bashtop.html" +if is_release ; then + SRC_URI="mirror://gnu/bash/${MY_P}.tar.gz $(patches)" +else + SRC_URI="ftp://ftp.cwru.edu/pub/bash/${MY_P}.tar.gz" +fi + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="afs bashlogger examples mem-scramble +net nls plugins +readline" + +DEPEND=" + >=sys-libs/ncurses-5.2-r2:0= + nls? ( virtual/libintl ) + readline? ( >=sys-libs/readline-${READLINE_VER}:0= ) +" +RDEPEND=" + ${DEPEND} + ! +Date: Thu, 12 Dec 2019 18:46:50 -0800 +Subject: [PATCH] Harden env var imports + +--- + src/cmd/ksh93/sh/arith.c | 37 ++++++++++++++++++++++----------- + src/cmd/ksh93/tests/subshell.sh | 23 ++++++++++++++++++++ + +diff --git a/src/cmd/ksh93/sh/arith.c b/src/cmd/ksh93/sh/arith.c +index 30b3067590a2..8e68cbdc868a 100644 +--- a/src/cmd/ksh93/sh/arith.c ++++ b/src/cmd/ksh93/sh/arith.c +@@ -567,19 +567,32 @@ Sfdouble_t sh_strnum(Shell_t *shp, const char *str, char **ptr, int mode) { + char *last; + + if (*str == 0) { +- if (ptr) *ptr = (char *)str; +- return 0; +- } +- errno = 0; +- d = number(str, &last, shp->inarith ? 0 : 10, NULL); +- if (*last) { +- if (*last != '.' || last[1] != '.') { +- d = strval(shp, str, &last, arith, mode); +- Varsubscript = true; ++ d = 0.0; ++ last = (char *)str; ++ } else { ++ d = number(str, &last, shp->inarith ? 0 : 10, NULL); ++ if (*last && !shp->inarith && sh_isstate(shp, SH_INIT)) { ++ // This call is to handle "base#value" literals if we're importing untrusted env vars. ++ d = number(str, &last, 0, NULL); ++ } ++ if (*last) { ++ if (sh_isstate(shp, SH_INIT)) { ++ // Initializing means importing untrusted env vars. Since the string does not appear ++ // to be a recognized numeric literal give up. We can't safely call strval() since ++ // that allows arbitrary expressions which would create a security vulnerability. ++ d = 0.0; ++ } else { ++ if (*last != '.' || last[1] != '.') { ++ d = strval(shp, str, &last, arith, mode); ++ Varsubscript = true; ++ } ++ if (!ptr && *last && mode > 0) { ++ errormsg(SH_DICT, ERROR_exit(1), e_lexbadchar, *last, str); ++ } ++ } ++ } else if (d == 0.0 && *str == '-') { ++ d = -0.0; + } +- if (!ptr && *last && mode > 0) errormsg(SH_DICT, ERROR_exit(1), e_lexbadchar, *last, str); +- } else if (!d && *str == '-') { +- d = -0.0; + } + if (ptr) *ptr = last; + return d; +diff --git a/src/cmd/ksh93/tests/subshell.sh b/src/cmd/ksh93/tests/subshell.sh +index b63a8051ed5c..3faba475d6de 100644 +--- a/src/cmd/ksh93/tests/subshell.sh ++++ b/src/cmd/ksh93/tests/subshell.sh +@@ -856,3 +856,26 @@ for exp in 65535 65536 + do got=$($SHELL -c 'x=$(printf "%.*c" '$exp' x); print ${#x}' 2>&1) + [[ $got == $exp ]] || log_error "large command substitution failed" "$exp" "$got" + done ++ ++# ========== ++# Verify that importing untrusted env vars does not allow evaluating arbitrary expressions but does ++# recognize all integer literals recognized by ksh. ++expect=8 ++actual=$(env SHLVL='7' $SHELL -c 'echo $SHLVL') ++[[ $actual == $expect ]] || log_error "decimal int literal not recognized" "$expect" "$actual" ++ ++expect=14 ++actual=$(env SHLVL='013' $SHELL -c 'echo $SHLVL') ++[[ $actual == $expect ]] || log_error "leading zeros int literal not recognized" "$expect" "$actual" ++ ++expect=4 ++actual=$(env SHLVL='2#11' $SHELL -c 'echo $SHLVL') ++[[ $actual == $expect ]] || log_error "base#value int literal not recognized" "$expect" "$actual" ++ ++expect=12 ++actual=$(env SHLVL='16#B' $SHELL -c 'echo $SHLVL') ++[[ $actual == $expect ]] || log_error "base#value int literal not recognized" "$expect" "$actual" ++ ++expect=1 ++actual=$(env SHLVL="2#11+x[\$($bin_echo DANGER WILL ROBINSON >&2)0]" $SHELL -c 'echo $SHLVL') ++[[ $actual == $expect ]] || log_error "expression allowed on env var import" "$expect" "$actual" diff --git a/app-shells/ksh/ksh-2020.0.0-r1.ebuild b/app-shells/ksh/ksh-2020.0.0-r1.ebuild new file mode 100644 index 000000000000..3c4891ea637e --- /dev/null +++ b/app-shells/ksh/ksh-2020.0.0-r1.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit meson + +if [[ ${PV} == 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/att/ast" +else + KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86" + MY_PV="${PV/_/-}" + MY_P="${PN}-${MY_PV}" + SRC_URI="https://github.com/att/ast/releases/download/${MY_PV}/${MY_P}.tar.gz" + S="${WORKDIR}/${MY_P}" +fi + +DESCRIPTION="The Original Korn Shell, 1993 revision (ksh93)" +HOMEPAGE="https://github.com/att/ast" + +LICENSE="CPL-1.0 EPL-1.0" +SLOT="0" + +RDEPEND="!app-shells/pdksh" + +PATCHES=( + "${FILESDIR}"/ksh-2020.0.0-ensure-user-set.patch + "${FILESDIR}"/ksh-2020.0.0-skip-api-test.patch + "${FILESDIR}"/CVE-2019-14868.patch +) + +src_test() { + # https://bugs.gentoo.org/702570 + addwrite /proc/self + local cmd=( + meson test + -C "${BUILD_DIR}" + --num-processes "$(makeopts_jobs ${NINJAOPTS:-${MAKEOPTS}})" + ) + echo "${cmd[@]}" >&2 + # https://github.com/att/ast/issues/1392 + env -u T "${cmd[@]}" || die +} + +src_install() { + meson_src_install + dodir /bin + mv "${ED}/usr/bin/ksh" "${ED}/bin/ksh" || die +} diff --git a/app-shells/ksh/ksh-2020.0.0.ebuild b/app-shells/ksh/ksh-2020.0.0.ebuild deleted file mode 100644 index 6b40cd312997..000000000000 --- a/app-shells/ksh/ksh-2020.0.0.ebuild +++ /dev/null @@ -1,49 +0,0 @@ -# Copyright 1999-2019 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit meson - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/att/ast" -else - KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86" - MY_PV="${PV/_/-}" - MY_P="${PN}-${MY_PV}" - SRC_URI="https://github.com/att/ast/releases/download/${MY_PV}/${MY_P}.tar.gz" - S="${WORKDIR}/${MY_P}" -fi - -DESCRIPTION="The Original Korn Shell, 1993 revision (ksh93)" -HOMEPAGE="https://github.com/att/ast" - -LICENSE="CPL-1.0 EPL-1.0" -SLOT="0" - -RDEPEND="!app-shells/pdksh" - -PATCHES=( - "${FILESDIR}"/ksh-2020.0.0-ensure-user-set.patch - "${FILESDIR}"/ksh-2020.0.0-skip-api-test.patch -) - -src_test() { - # https://bugs.gentoo.org/702570 - addwrite /proc/self - local cmd=( - meson test - -C "${BUILD_DIR}" - --num-processes "$(makeopts_jobs ${NINJAOPTS:-${MAKEOPTS}})" - ) - echo "${cmd[@]}" >&2 - # https://github.com/att/ast/issues/1392 - env -u T "${cmd[@]}" || die -} - -src_install() { - meson_src_install - dodir /bin - mv "${ED}/usr/bin/ksh" "${ED}/bin/ksh" || die -} diff --git a/app-shells/zsh-syntax-highlighting/Manifest b/app-shells/zsh-syntax-highlighting/Manifest new file mode 100644 index 000000000000..afd63a49bc94 --- /dev/null +++ b/app-shells/zsh-syntax-highlighting/Manifest @@ -0,0 +1,3 @@ +DIST zsh-syntax-highlighting-0.7.0_beta1.tar.gz 130063 BLAKE2B cf0f6319af22b47cb8a280de682a69b0479dc59033be5ce84840507b77dd2df0441b8d260af55bccb303c87d7f5a7e4cc6db9f46860aee040b4b8115c76f5e07 SHA512 1692015aad58103c752e2dd4161ea87f26aaa09d34eb2faec1f651fea1d9bfad29226455468017160a5393a87c1f7ed0514b09b0802b1810377beef72bfa6c87 +EBUILD zsh-syntax-highlighting-0.7.0_beta1.ebuild 1001 BLAKE2B c57f7c1481dfddccf9757faf2956563382bd43b32faceb7edaa47feb228c331064a664c4177e9cfac0066cbecef42b5b43ffc7fd9bdd7bb9d0ad4a30e4c1462b SHA512 37a1966be8434416fbd1a3a992a0cc3b0dc1a49293763b63a9f009060372208275f44c70304ecf707f002248bb5a41541680089a782a92f86506111074a9aace +MISC metadata.xml 243 BLAKE2B f7576f14be2c0aa21ca2c7147133e4a4132d6559cca1519745dd2f4ea912b3856950c7645e13d2317f38c80ba93b13d47370260920241a5ab60a4eae59f2cf33 SHA512 0dc1f228861badffd9c4175af734b72435dc7c60d369a3d9ff946c5b98b3f2f49af7d433f7ec5fc2afee7015b8f75259e8debe150b1bcffa0cb66425bed10d8d diff --git a/app-shells/zsh-syntax-highlighting/metadata.xml b/app-shells/zsh-syntax-highlighting/metadata.xml new file mode 100644 index 000000000000..203fa55c746f --- /dev/null +++ b/app-shells/zsh-syntax-highlighting/metadata.xml @@ -0,0 +1,8 @@ + + + + + zlogene@gentoo.org + Mikle Kolyada + + diff --git a/app-shells/zsh-syntax-highlighting/zsh-syntax-highlighting-0.7.0_beta1.ebuild b/app-shells/zsh-syntax-highlighting/zsh-syntax-highlighting-0.7.0_beta1.ebuild new file mode 100644 index 000000000000..8ca8ffb2e2b8 --- /dev/null +++ b/app-shells/zsh-syntax-highlighting/zsh-syntax-highlighting-0.7.0_beta1.ebuild @@ -0,0 +1,42 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit readme.gentoo-r1 + +if [[ -z ${PV%%*9999} ]]; then + EGIT_REPO_URI="https://github.com/zsh-users/${PN}.git" + inherit git-r3 +else + MY_PV=$(ver_rs 3 -) + SRC_URI="https://github.com/zsh-users/zsh-syntax-highlighting/archive/${MY_PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" + S="${WORKDIR}/${PN}-${MY_PV}" +fi + +DESCRIPTION="Fish shell like syntax highlighting for zsh" +HOMEPAGE="https://github.com/zsh-users/zsh-syntax-highlighting" + +LICENSE="BSD" +SLOT="0" + +RDEPEND="app-shells/zsh" + +DISABLE_AUTOFORMATTING="true" +DOC_CONTENTS="In order to use ${CATEGORY}/${PN} add +. /usr/share/zsh/site-functions/zsh-syntax-highlighting.zsh +at the end of your ~/.zshrc" + +src_prepare() { + sed -i -e 's/COPYING.md//' Makefile || die + default +} + +src_install() { + emake \ + SHARE_DIR="${ED}/usr/share/zsh/site-functions" \ + DOC_DIR="${ED}/usr/share/doc/${PF}" \ + install + readme.gentoo_create_doc +} -- cgit v1.2.3