app-vim/gentoo-syntax: Sync with Gentoo

It's from Gentoo commit d0fd4ca962a9dc174ebb1e5a9312c1565e08655a.
This commit is contained in:
Flatcar Buildbot 2025-06-30 07:07:28 +00:00
parent 776072f5a8
commit 8b89c8a89b
2 changed files with 43 additions and 0 deletions

View File

@ -1 +1,2 @@
DIST gentoo-syntax-15.tar.bz2 21018 BLAKE2B 2b0ead6d5701f14f321ad02b1cd3fe426b8e98e4d80e66331387f0543d88a2ac6b5d78a1f8c9125dadf24f3508c34d915fa896dc2fb85a8664984d771b48a29e SHA512 69cdcd58933b4f83da81ecc943e205689591748c283005b2e6cd342e623d8e0643979d913ec6a9464ca2b49431ea2317dfb0e6454143d6757f6ba287286d24f1
DIST gentoo-syntax-16.tar.bz2 21034 BLAKE2B 71f42dcd81e99e688f73e1df8913bc90e97acbcfdb1649348a7550a2c0888cced976f450406c305e4c8326fe4d405e460ea5d545bcd951ef64ba194b1f504820 SHA512 07baa98902b02dc920cb18a2a12877b59a3ae83558987cad956f9910c0b674f9bbe3f0087e512baac08f407e07e75c51f336562f7574b2600812594fa921bb22

View File

@ -0,0 +1,42 @@
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit vim-plugin
DESCRIPTION="vim plugin: Gentoo and Portage syntax highlighting"
HOMEPAGE="https://github.com/gentoo/gentoo-syntax"
SRC_URI="https://gitweb.gentoo.org/proj/gentoo-syntax.git/snapshot/${P}.tar.bz2"
LICENSE="vim"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
IUSE="ignore-glep31"
VIM_PLUGIN_HELPFILES="gentoo-syntax"
VIM_PLUGIN_MESSAGES="filetype"
src_prepare() {
default
if use ignore-glep31 ; then
for f in ftplugin/*.vim ; do
ebegin "Removing UTF-8 rules from ${f} ..."
sed -i -e 's~\(setlocal fileencoding=utf-8\)~" \1~' ${f} \
|| die "waah! bad sed voodoo. need more goats."
eend $?
done
fi
}
pkg_postinst() {
vim-plugin_pkg_postinst
if [[ -z ${REPLACING_VERSIONS} ]] ; then
if use ignore-glep31 1>/dev/null ; then
ewarn "You have chosen to disable the rules which ensure GLEP 31"
ewarn "compliance. When editing ebuilds, please make sure you get"
ewarn "the character set correct."
fi
fi
}