diff options
Diffstat (limited to 'app-emacs/emacs-bazel-mode')
5 files changed, 77 insertions, 0 deletions
diff --git a/app-emacs/emacs-bazel-mode/Manifest b/app-emacs/emacs-bazel-mode/Manifest new file mode 100644 index 000000000000..8f4dd7554ba7 --- /dev/null +++ b/app-emacs/emacs-bazel-mode/Manifest @@ -0,0 +1,5 @@ +AUX 50emacs-bazel-mode-gentoo.el 80 BLAKE2B 393d859edf88c571c79460da1b2ff957d8f3229bfdac1b2953c6d637cf3fffa94f3aa9febd0ed792675ec71da3ec36e40bba39c6c6d483dd58f901801603fd97 SHA512 d70a9b373db290cbd48745d7fc6beb1d6f146317f4db93b51971bd1a9f2aa1b82b0973ada357ef432eb10e412a23729f80dc6c9a589ce801c291e7bbc2688995 +AUX emacs-bazel-mode-bazel-test--directory.patch 347 BLAKE2B d07d715cb067c440d15b141f9c637f4253c17147f934e07ac53377ff8dab52113c53c61de3147ca7197143a3c852590a632716f89245e0037a6d4769ddd73ddd SHA512 4db0faae1b291594dcb9bf3dde191e62fcdcecf75fbb1b412ac6e708e2d1b327adbe984087504889fae87a84a7a0a61a5fbfeba27d5cf947a9c3a644bf9c57fd +DIST emacs-bazel-mode-0_p20220707.tar.gz 63821 BLAKE2B fadd0a26c02d0fd6ee92d34ca70cbb1ae3ea873317f97195849993ed94c55e404cfa1eae3f0e94eb81b80ec814dbf5e705ef98f1b23bfc7158a8a14ed32e6276 SHA512 cf654de1b46e562a090b933bc08e2651a5c88b9a01502413cc38f86d849cd1fd698e52d7ad737f4d0b43ea49180fb33eb200c5102ac57df1ca9b65bd175f431d +EBUILD emacs-bazel-mode-0_p20220707.ebuild 880 BLAKE2B 43d41209fb261d51d8645dd26b684c5ef2a44f49b2b96bc8f17f5b7f3cee8af80eb958256e3d8079ce003dbce89fa3de196ac0d39e91281bbbc0b10306bd1f92 SHA512 2586e360e9a73c6890a9bf19cff65c6f0811d66d67aa4670c8de2a4be63daf503047d05bc628e450cdaac40677b928dafcd41aff6cd0d6fd7654fccaeced3d71 +MISC metadata.xml 750 BLAKE2B 71387f057a94c8d607a85b0af75605881130932144e35f5252e53effbfd22b42cee21a3ea0054fce44af96c83eacbd33b8bc4f92949ed5b7b6f97cff9f9d548f SHA512 ef65e5f3efbf4e6826c6f8917134448c3857600d041d4547c2ae97673c0fe7894cdac01ac3658883d2d1a2cfdec41dcad18428023409379c0392e8707429e14d diff --git a/app-emacs/emacs-bazel-mode/emacs-bazel-mode-0_p20220707.ebuild b/app-emacs/emacs-bazel-mode/emacs-bazel-mode-0_p20220707.ebuild new file mode 100644 index 000000000000..d25b697c94b8 --- /dev/null +++ b/app-emacs/emacs-bazel-mode/emacs-bazel-mode-0_p20220707.ebuild @@ -0,0 +1,40 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +H=8f7875998f233d248097006df224a33873bbc4f2 +NEED_EMACS=27.1 + +inherit elisp + +DESCRIPTION="Emacs major modes for the Bazel build system support" +HOMEPAGE="https://bazel.build/ + https://github.com/bazelbuild/emacs-bazel-mode/" +SRC_URI="https://github.com/bazelbuild/${PN}/archive/${H}.tar.gz + -> ${P}.tar.gz" +S="${WORKDIR}"/${PN}-${H} + +LICENSE="Apache-2.0" +KEYWORDS="~amd64 ~x86" +SLOT="0" + +DOCS=( CONTRIBUTING.md README.md ) +PATCHES=( "${FILESDIR}"/${PN}-bazel-test--directory.patch ) +SITEFILE="50${PN}-gentoo.el" + +src_compile() { + elisp-compile bazel.el + elisp-make-autoload-file +} + +src_test() { + ${EMACS} ${EMACSFLAGS} ${BYTECOMPFLAGS} \ + -l ./test.el -f ert-run-tests-batch-and-exit || die "Testing failed" +} + +src_install() { + rm test.el || die + + elisp_src_install +} diff --git a/app-emacs/emacs-bazel-mode/files/50emacs-bazel-mode-gentoo.el b/app-emacs/emacs-bazel-mode/files/50emacs-bazel-mode-gentoo.el new file mode 100644 index 000000000000..a45c0a3b76c7 --- /dev/null +++ b/app-emacs/emacs-bazel-mode/files/50emacs-bazel-mode-gentoo.el @@ -0,0 +1,2 @@ +(add-to-list 'load-path "@SITELISP@") +(load "emacs-bazel-mode-autoloads" nil t) diff --git a/app-emacs/emacs-bazel-mode/files/emacs-bazel-mode-bazel-test--directory.patch b/app-emacs/emacs-bazel-mode/files/emacs-bazel-mode-bazel-test--directory.patch new file mode 100644 index 000000000000..81cdce53e80f --- /dev/null +++ b/app-emacs/emacs-bazel-mode/files/emacs-bazel-mode-bazel-test--directory.patch @@ -0,0 +1,11 @@ +--- a/test.el ++++ b/test.el +@@ -47,7 +47,7 @@ + + (defconst bazel-test--directory + ;; https://docs.bazel.build/versions/2.2.0/test-encyclopedia.html#initial-conditions. +- (substitute-in-file-name "$TEST_SRCDIR/$TEST_WORKSPACE/") ++ (substitute-in-file-name "$PWD/") + "Directory with data dependencies for this package.") + + ;;;; Helper macros diff --git a/app-emacs/emacs-bazel-mode/metadata.xml b/app-emacs/emacs-bazel-mode/metadata.xml new file mode 100644 index 000000000000..a5544ccebfd0 --- /dev/null +++ b/app-emacs/emacs-bazel-mode/metadata.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> + +<pkgmetadata> + <maintainer type="project"> + <email>gnu-emacs@gentoo.org</email> + <name>Gentoo GNU Emacs project</name> + </maintainer> + <longdescription> + The library provides major modes for editing Bazel BUILD files, WORKSPACE + files, .bazelrc files, as well as Starlark files. It also provides commands + to run Bazel commands and integration with core GNU Emacs infrastructure + like compilation and xref. + </longdescription> + <upstream> + <bugs-to>https://github.com/bazelbuild/emacs-bazel-mode/issues/</bugs-to> + <remote-id type="github">bazelbuild/emacs-bazel-mode</remote-id> + </upstream> +</pkgmetadata> |