archrelease: copy trunk to community-any
[ArchLinux/community.git] / opensearch-notifications-plugin / trunk / PKGBUILD
blob5a681b6d185b90af372065cfb56ebfe3fb211c15
1 # Maintainer: Justin Kronotificationsinger <hashworks@archlinux.org>
3 pkgname=opensearch-notifications-plugin
4 pkgver=2.6.0.0
5 pkgrel=1
6 _opensearchver=2.6.0
7 _jdkver=11
8 pkgdesc="OpenSearch Notifications Plugin"
9 arch=('x86_64')
10 url="https://opensearch.org/docs/latest/notifications-plugin/index/"
11 license=('Apache')
12 depends=("opensearch=${_opensearchver}")
13 makedepends=("java-environment=${_jdkver}" 'unzip')
14 source=(
15   "${pkgname}-${pkgver}.tar.gz::https://github.com/opensearch-project/notifications/archive/${pkgver}.tar.gz"
17 sha256sums=('44958b32b2621af69c872e1f2100e58460d272df56d5dfc47100f4272a2af625')
19 build() {
20   cd "notifications-${pkgver}/notifications"
21   export JAVA_HOME="/usr/lib/jvm/java-${_jdkver}-openjdk"
22   export PATH="/usr/lib/jvm/java-${_jdkver}-openjdk/bin:$PATH"
23   export GRADLE_OPTS="-Dbuild.snapshot=false -Dopensearch.version=${_opensearchver}"
24   ./gradlew build \
25     --exclude-task "notifications:jacocoTestCoverageVerification" \
26     --exclude-task "opensearch-notifications-core:jacocoTestCoverageVerification" \
27     --exclude-task "opensearch-notifications-core-spi:jacocoTestCoverageVerification" \
28     --exclude-task "notifications:jacocoTestReport" \
29     --exclude-task "opensearch-notifications-core:jacocoTestReport" \
30     --exclude-task "opensearch-notifications-core-spi:jacocoTestReport" \
31     --exclude-task ":notifications:notificationsBwcCluster#fullRestartClusterTask" \
32     --exclude-task ":notifications:notificationsBwcCluster#mixedClusterTask" \
33     --exclude-task ":notifications:notificationsBwcCluster#oldVersionClusterTask0" \
34     --exclude-task ":notifications:notificationsBwcCluster#oldVersionClusterTask1" \
35     --exclude-task ":notifications:notificationsBwcCluster#rollingUpgradeClusterTask" \
36     --exclude-task ":notifications:notificationsBwcCluster#twoThirdsUpgradedClusterTask"
39 package() {
40   install -dm755 "${pkgdir}/usr/share/opensearch/plugins/opensearch-notifications"
41   cd "${pkgdir}/usr/share/opensearch/plugins/opensearch-notifications"
42   unzip "${srcdir}/notifications-${pkgver}/notifications/notifications/build/distributions/opensearch-notifications-${pkgver}.zip"
44   install -dm755 "${pkgdir}/usr/share/opensearch/plugins/opensearch-notifications-core"
45   cd "${pkgdir}/usr/share/opensearch/plugins/opensearch-notifications-core"
46   unzip "${srcdir}/notifications-${pkgver}/notifications/core/build/distributions/opensearch-notifications-core-${pkgver}.zip"
49   install -Dm644 "${srcdir}/notifications-${pkgver}/LICENSE.txt" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"