1SUMMARY="Intellij IDEA Community Edition"
2DESCRIPTION="A Java Integrated Development Environment to develop computer \
3software."
4HOMEPAGE="https://www.jetbrains.com/idea/"
5COPYRIGHT="2023 JetBrains s.r.o."
6LICENSE="Apache v2"
7REVISION="1"
8buildVersion="233.15026.9"
9SOURCE_URI="https://download.jetbrains.com/idea/ideaIC-$portVersion.tar.gz#noarchive"
10CHECKSUM_SHA256="5e376677d4b9810f4171700ce9d9d3ece58f245ce8d9f2011b05966df5dd7ddd"
11ADDITIONAL_FILES="IntelliJ_IDEA_Logo.hvif"
12
13ARCHITECTURES="any"
14DISABLE_SOURCE_PACKAGE="true"
15
16PROVIDES="
17	idea_community_bin = $portVersion
18	"
19REQUIRES="
20	haiku
21	java:environment == 17
22	"
23
24BUILD_PREREQUIRES="
25	"
26
27INSTALL()
28{
29	mkdir -p $appsDir
30	tar xvf ideaIC-$portVersion.tar.gz -C $appsDir
31	mv $appsDir/idea-IC-$buildVersion $appsDir/idea
32	rm -rvf $appsDir/idea/jbr
33	cat << EOF > $appsDir/idea/idea.sh
34#!/bin/sh -l
35export PATH=\$JDK17_HOME/bin:\$PATH
36$appsDir/idea/bin/idea.sh &
37EOF
38	chmod 755 $appsDir/idea/idea.sh
39
40	addattr -t icon -f $portDir/additional-files/IntelliJ_IDEA_Logo.hvif \
41		"BEOS:ICON" "$appsDir/idea/idea.sh"
42	addAppDeskbarSymlink $appsDir/idea/idea.sh 'IDEA IntelliJ CE'
43}
44