summaryrefslogtreecommitdiff
path: root/net-im
diff options
context:
space:
mode:
authorConrad Kostecki <conikost@gentoo.org>2022-03-19 19:08:07 +0100
committerConrad Kostecki <conikost@gentoo.org>2022-03-19 19:24:12 +0100
commit87bc82dc082c5df7b2ec14685170099c6b29b207 (patch)
tree6ed5b5a104959e7f78fb45efa38d059ac47a2026 /net-im
parentnet-im/prosody: add 0.12.0 (diff)
downloadgentoo-87bc82dc082c5df7b2ec14685170099c6b29b207.tar.gz
gentoo-87bc82dc082c5df7b2ec14685170099c6b29b207.tar.bz2
gentoo-87bc82dc082c5df7b2ec14685170099c6b29b207.zip
net-im/prosody-modules: add 0_pre20220319
Signed-off-by: Conrad Kostecki <conikost@gentoo.org>
Diffstat (limited to 'net-im')
-rw-r--r--net-im/prosody-modules/Manifest1
-rw-r--r--net-im/prosody-modules/prosody-modules-0_pre20220319.ebuild55
2 files changed, 56 insertions, 0 deletions
diff --git a/net-im/prosody-modules/Manifest b/net-im/prosody-modules/Manifest
index a85626a0d7c8..941aac7b0531 100644
--- a/net-im/prosody-modules/Manifest
+++ b/net-im/prosody-modules/Manifest
@@ -1 +1,2 @@
DIST prosody-modules-0_pre20211027.tar.xz 1214428 BLAKE2B a514d5d66475c68d6e7eb3040b648530b1f525fc555e85773f53fa982e2634e10fca3721e463ca6a714a2b058213d5a923e8181f332d509b91bba5b6cc15b3b0 SHA512 0d9fc8f167f7a93ee3d46ea517a7943d1a448a7513776e9e6d0003362cc24be938ed185e8c8ce33570aa91e0b1fd66dc4e0f7cc863d97e108f3213e86085b863
+DIST prosody-modules-0_pre20220319.tar.xz 1221828 BLAKE2B bb9482a60b15fd456125b512017ee93223bd139ed5b664236db4313b65985729ad4f5b8adb5d76bb9099ff4de816457fffd1277b7d36c556d00ce789d8ecf15f SHA512 a288d082e3bc2f9450c0b09e4f02816322d0db073134b315b2fa19be4d176037b399d763854c6c9a006eef85153c7bbbabddf5da85225d599082bfc7c0101450
diff --git a/net-im/prosody-modules/prosody-modules-0_pre20220319.ebuild b/net-im/prosody-modules/prosody-modules-0_pre20220319.ebuild
new file mode 100644
index 000000000000..a120ace96588
--- /dev/null
+++ b/net-im/prosody-modules/prosody-modules-0_pre20220319.ebuild
@@ -0,0 +1,55 @@
+# Copyright 2020-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit savedconfig
+
+DESCRIPTION="A collection of community-maintained modules for Prosody"
+HOMEPAGE="https://modules.prosody.im"
+SRC_URI="https://dev.gentoo.org/~conikost/distfiles/${P}.tar.xz"
+S="${WORKDIR}/${PN}"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+
+RDEPEND="net-im/prosody"
+
+src_prepare() {
+ default
+
+ # Exclude 'misc' folder from install, since it does not provide any modules.
+ echo "# Remove all modules from this list, which you don't want to install." > prosody-modules.conf || die
+ find * -maxdepth 0 -type d ! -name misc >> prosody-modules.conf || die
+
+ use savedconfig && restore_config prosody-modules.conf
+}
+
+src_install() {
+ insinto "/usr/$(get_libdir)/prosody/community-modules"
+ while read prosody_module; do
+ if ! [[ "${prosody_module}" = \#* ]]; then
+ if [[ -f "${prosody_module}/README.markdown" ]]; then
+ newdoc "${prosody_module}/README.markdown" "README.${prosody_module}"
+ rm "${prosody_module}/README.markdown" || die
+ fi
+
+ doins -r "${prosody_module}"
+ fi
+ done <prosody-modules.conf
+
+ save_config prosody-modules.conf
+
+ einstalldocs
+}
+
+pkg_postinst() {
+ savedconfig_pkg_postinst
+
+ einfo "In order to use the community modules on an existing instance, you have to add"
+ einfo "'/usr/$(get_libdir)/prosody/community-modules' into 'plugin_paths'"
+ einfo "into your prosody configuration file '/etc/jabber/prosody.cfg.lua.'"
+ einfo ""
+ einfo "Example: plugin_paths = { \"/usr/$(get_libdir)/prosody/modules\", \"/usr/$(get_libdir)/prosody/community-modules\" };"
+}