diff options
Diffstat (limited to 'app-emacs/yasnippet-snippets')
-rw-r--r-- | app-emacs/yasnippet-snippets/Manifest | 7 | ||||
-rw-r--r-- | app-emacs/yasnippet-snippets/files/50yasnippet-snippets-gentoo.el | 9 | ||||
-rw-r--r-- | app-emacs/yasnippet-snippets/files/yasnippet-snippets-dir.patch | 18 | ||||
-rw-r--r-- | app-emacs/yasnippet-snippets/yasnippet-snippets-0.3-r1.ebuild (renamed from app-emacs/yasnippet-snippets/yasnippet-snippets-1.0-r1.ebuild) | 16 | ||||
-rw-r--r-- | app-emacs/yasnippet-snippets/yasnippet-snippets-1.0-r2.ebuild (renamed from app-emacs/yasnippet-snippets/yasnippet-snippets-0.3.ebuild) | 26 |
5 files changed, 60 insertions, 16 deletions
diff --git a/app-emacs/yasnippet-snippets/Manifest b/app-emacs/yasnippet-snippets/Manifest index e97c0233a0a1..554fce91c49a 100644 --- a/app-emacs/yasnippet-snippets/Manifest +++ b/app-emacs/yasnippet-snippets/Manifest @@ -1,6 +1,7 @@ -AUX 50yasnippet-snippets-gentoo.el 161 BLAKE2B af28f32bcf248a9557c25e4afd50110b6fdeb8f376b41ba645da1ee3c39429cf6b967bc77ce60f29a28d7dc01903a620997cb9a6bf7a62628bd3ff7495f8a015 SHA512 f675ccdd153f0c386d384df2db90598c08f2d49cadc434d1bba7707a7681b0d1dfa410bf188250b05003544c17bba11b132d9d8f3741865cf64ccce5b117c4d4 +AUX 50yasnippet-snippets-gentoo.el 221 BLAKE2B 608ecd2c72d3ff72c7775bfaeb3edbbc4e066a7ed9e1f10720fb93023319e0141e9694c6bbbb697264b62f9f47721f2f0ac186286a38d1859bf3e5529e8ae118 SHA512 a7a89ab8d5e0c66ada64b04b9bc0917df6c20537c80cebea43ee1210635b20e8b34549455c21217fdaa169dc5eafaa9c5c0032605a17716276437e982653428d +AUX yasnippet-snippets-dir.patch 523 BLAKE2B b9e0712cae1b65b947b04d5349bb25007ee6f7db0cd8dd56ff7db15192932d88f7c9ab1b1fca77fca450152a52ec19f275f568f947879eab68b755731b48a5ad SHA512 f1a2c1c3db8a752a38e32147d2a8ffbae0666de4657b647ee126b96db0e4a499384148e3d316a72dcfdb5083c06c7c9eb0a47f329a24ac68532052acf994f79d DIST yasnippet-snippets-0.3.tar.gz 97229 BLAKE2B 26fe83c35be1b20b6a1e414144149cf1feaf4463833634bbd0a3db6f56b1da46d8e379c3dd19217cfd36f12cb9dc796eac4efef5c2ba472ce79f8c8b8d816969 SHA512 4aaac9d7c880642a1e802abb98bd6d6c94557fe0e609db5ce5b4ce2af921235d3e6bb2488c052adbe2940d41e85297520081ae0847b52642bc97610e6614727f DIST yasnippet-snippets-1.0.tar.gz 178027 BLAKE2B 0b44c94c3ad3f2a1208aefba110945aeae74e7278c93078c59677985efc89767b670c99b4b8303b56ea0b748375762ada1e45653e02922b248273af5818514d4 SHA512 2df010f24e51d0156bcb3d488cd6a63a47d2d92e4c5f3cd081e377dc91426d630bde41db6f79d1b5ac1e932e4d0ab11f9be945e94fb35d50b1789adab19bd15b -EBUILD yasnippet-snippets-0.3.ebuild 614 BLAKE2B 73559131e05601b6a1f80ee513e8a2eef5f718d9b037476adfe2dfdb9d15162ee0dc6e2b249851aa1e3aef2ebf0b9363eab6f9e2996adf1d5c19496d75b3012c SHA512 d9d3d0044e4a527ce6b8b0e93f9ec4e63ac0a331d2834c9d283d9cd5f00c0627ece69b5ae17e346401cd345ec32a2daf97f7c86e1833980de2689b85bf0bb89b -EBUILD yasnippet-snippets-1.0-r1.ebuild 747 BLAKE2B cb4f16c89083b1cd22fc38c6988808a6dd6a7b77fcdf45216503dd13e39ce0e4f162ac357ad7d9aec9c7085969c0416d39f06bd14fa3281f8d18d5829e462770 SHA512 36d4c6c34ec69e8fcbc003abdbff220f24662f403d38c101d386c3a0f830b46a7afedac12ed830fce911a344020e73ac0a2c2fb1812580ff5fd1f9d1c65455da +EBUILD yasnippet-snippets-0.3-r1.ebuild 883 BLAKE2B 002e62e94373174fe0ac3d6c5c73c55a264ca375e9516db3d4611bc77088d3058be7ec40fb9b0ce77ccc6d40d63054284d32dd2c78b68b8a6fbab83207d05d2f SHA512 61e17064bc2d8f575759665b64bb3bdf639e95634d9f17254e122a3318b58d6c0204a60c057302de296975ddf2f5087b0901a7ca50c0b32752c7fe1c5c431d61 +EBUILD yasnippet-snippets-1.0-r2.ebuild 883 BLAKE2B 002e62e94373174fe0ac3d6c5c73c55a264ca375e9516db3d4611bc77088d3058be7ec40fb9b0ce77ccc6d40d63054284d32dd2c78b68b8a6fbab83207d05d2f SHA512 61e17064bc2d8f575759665b64bb3bdf639e95634d9f17254e122a3318b58d6c0204a60c057302de296975ddf2f5087b0901a7ca50c0b32752c7fe1c5c431d61 MISC metadata.xml 377 BLAKE2B 78f369ac63a6ba16eabfbc21367b0e29221a94a8460b877e58b23e4c4176e3d4393ac7cb657057fe239298fc9836365b8a5d6ec789251ed552e684590b40e6e4 SHA512 72e8f247f2bb604ea52229c1aa68abf0fdd6649c87ffaad7f2893131f522cc3d7283251d8e365def16ac5eea831c98472a0ebe591cb6188132e0d7696b559b55 diff --git a/app-emacs/yasnippet-snippets/files/50yasnippet-snippets-gentoo.el b/app-emacs/yasnippet-snippets/files/50yasnippet-snippets-gentoo.el index 2db51796990b..4c85ffac5510 100644 --- a/app-emacs/yasnippet-snippets/files/50yasnippet-snippets-gentoo.el +++ b/app-emacs/yasnippet-snippets/files/50yasnippet-snippets-gentoo.el @@ -1,4 +1,5 @@ -(eval-after-load "yasnippet" - '(let ((snippets-dir "@SITEETC@")) - (add-to-list 'yas-snippet-dirs snippets-dir t) - (yas-load-directory snippets-dir t))) +(add-to-list 'load-path "@SITELISP@") +(autoload 'yasnippet-snippets-initialize "yasnippet-snippets" + "Load the `yasnippet-snippets' snippets directory." t) +(eval-after-load 'yasnippet + '(yasnippet-snippets-initialize)) diff --git a/app-emacs/yasnippet-snippets/files/yasnippet-snippets-dir.patch b/app-emacs/yasnippet-snippets/files/yasnippet-snippets-dir.patch new file mode 100644 index 000000000000..2d5c8f2e483b --- /dev/null +++ b/app-emacs/yasnippet-snippets/files/yasnippet-snippets-dir.patch @@ -0,0 +1,18 @@ +index 078ac04..1c84318 100644 +--- a/yasnippet-snippets.el ++++ b/yasnippet-snippets.el +@@ -35,13 +35,7 @@ + (defconst yasnippet-snippets-dir + (expand-file-name + "snippets" +- (file-name-directory +- ;; Copied from ‘f-this-file’ from f.el. +- (cond +- (load-in-progress load-file-name) +- ((and (boundp 'byte-compile-current-file) byte-compile-current-file) +- byte-compile-current-file) +- (:else (buffer-file-name)))))) ++ "@SITEETC@")) + + ;;;###autoload + (defun yasnippet-snippets-initialize () diff --git a/app-emacs/yasnippet-snippets/yasnippet-snippets-1.0-r1.ebuild b/app-emacs/yasnippet-snippets/yasnippet-snippets-0.3-r1.ebuild index 3b465cd3954b..e1d0818702d5 100644 --- a/app-emacs/yasnippet-snippets/yasnippet-snippets-1.0-r1.ebuild +++ b/app-emacs/yasnippet-snippets/yasnippet-snippets-0.3-r1.ebuild @@ -16,16 +16,26 @@ KEYWORDS="~amd64 ~x86" RDEPEND="app-emacs/yasnippet" BDEPEND="${RDEPEND}" +DOCS=( README.md ) +PATCHES=( "${FILESDIR}"/${PN}-dir.patch ) SITEFILE="50${PN}-gentoo.el" +src_prepare() { + elisp_src_prepare + + sed "s|@SITEETC@|${EPREFIX}${SITEETC}/${PN}|" -i ${PN}.el || die +} + src_compile() { + elisp_src_compile + ${EMACS} ${EMACSFLAGS} --eval "(require 'yasnippet)" \ --eval "(yas-compile-directory \"${S}/snippets\")" || die } src_install() { - elisp-site-file-install "${FILESDIR}/${SITEFILE}" + elisp_src_install + insinto "${SITEETC}/${PN}" - doins -r snippets/. - dodoc README.md + doins -r snippets } diff --git a/app-emacs/yasnippet-snippets/yasnippet-snippets-0.3.ebuild b/app-emacs/yasnippet-snippets/yasnippet-snippets-1.0-r2.ebuild index 693935e3fecf..e1d0818702d5 100644 --- a/app-emacs/yasnippet-snippets/yasnippet-snippets-0.3.ebuild +++ b/app-emacs/yasnippet-snippets/yasnippet-snippets-1.0-r2.ebuild @@ -1,7 +1,7 @@ -# Copyright 1999-2018 Gentoo Foundation +# Copyright 1999-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 inherit elisp @@ -14,14 +14,28 @@ SLOT="0" KEYWORDS="~amd64 ~x86" RDEPEND="app-emacs/yasnippet" +BDEPEND="${RDEPEND}" +DOCS=( README.md ) +PATCHES=( "${FILESDIR}"/${PN}-dir.patch ) SITEFILE="50${PN}-gentoo.el" -src_compile() { :; } +src_prepare() { + elisp_src_prepare + + sed "s|@SITEETC@|${EPREFIX}${SITEETC}/${PN}|" -i ${PN}.el || die +} + +src_compile() { + elisp_src_compile + + ${EMACS} ${EMACSFLAGS} --eval "(require 'yasnippet)" \ + --eval "(yas-compile-directory \"${S}/snippets\")" || die +} src_install() { - elisp-site-file-install "${FILESDIR}/${SITEFILE}" + elisp_src_install + insinto "${SITEETC}/${PN}" - doins -r snippets/. - dodoc README.md + doins -r snippets } |