summaryrefslogtreecommitdiff
path: root/libre/jedit
diff options
context:
space:
mode:
authorOmar Vega Ramos <ovruni@gnu.org.pe>2016-06-27 07:56:17 -0500
committerOmar Vega Ramos <ovruni@gnu.org.pe>2016-06-27 07:56:17 -0500
commitd3bead6e6ee8703915dcc7c501fd3e198899ba5c (patch)
treee6c493754df3ed95d05e50775fc2d3abd00ffd50 /libre/jedit
parent1cba537c2b57e0b3d656d257c8cec2750e0c41a6 (diff)
downloadabslibre-d3bead6e6ee8703915dcc7c501fd3e198899ba5c.tar.gz
abslibre-d3bead6e6ee8703915dcc7c501fd3e198899ba5c.tar.bz2
abslibre-d3bead6e6ee8703915dcc7c501fd3e198899ba5c.zip
jedit: add new package to [libre]
Diffstat (limited to 'libre/jedit')
-rw-r--r--libre/jedit/PKGBUILD92
-rw-r--r--libre/jedit/jedit-fix_build.patch11
-rw-r--r--libre/jedit/jedit.install13
-rw-r--r--libre/jedit/jedit.props62
-rw-r--r--libre/jedit/jedit.sh16
-rw-r--r--libre/jedit/jeditbg.sh3
6 files changed, 197 insertions, 0 deletions
diff --git a/libre/jedit/PKGBUILD b/libre/jedit/PKGBUILD
new file mode 100644
index 000000000..bd6dfab86
--- /dev/null
+++ b/libre/jedit/PKGBUILD
@@ -0,0 +1,92 @@
+# Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe>
+
+pkgname=jedit
+pkgver=5.3.0
+pkgrel=1.parabola1
+pkgdesc='Text editor for programmers'
+arch=('any')
+url='http://www.jedit.org/'
+license=('GPL')
+depends=('java-runtime')
+makedepends=('apache-ant' 'apache-ant-contrib' 'apache-ivy' 'beanshell2'
+ 'gendesk' 'java-hamcrest' 'jsr305' 'junit')
+optdepends=('java-environment: for java development'
+ 'ttf-fira-mono: usable font')
+options=('!emptydirs')
+install=$pkgname.install
+source=("http://sourceforge.net/projects/$pkgname/files/$pkgname/$pkgver/jedit${pkgver}source.tar.bz2"
+ 'jedit.sh'
+ 'jeditbg.sh'
+ 'jedit.props'
+ 'jedit-fix_build.patch')
+sha256sums=('8d56d036be4dd45254748f063ade01293b862a615cdff6aed274ab58085f6304'
+ 'b2e5a8f2f4818b336b5d71f677114f1bc01e929d7fa60918675cc2234dae1a3a'
+ 'a1dd1b688f08c5c967861fe80df13cac201afa6dcfcecc9a289b2c3bec7c8915'
+ '1a8c6e51810abc9ff56606b61042e2e980cb4b479fa0099b3c93acd7e4b9295b'
+ '6e582bf78458783fcc620d2a850474d2eb787ecf2e3950031ec4bdda48cafeb9')
+
+prepare() {
+ gendesk -f -n --pkgname "$pkgname" --pkgdesc "$pkgdesc" --exec 'jeditbg %U' \
+ --name 'jEdit' --genericname 'Editor'
+
+ cd jEdit
+ mkdir -p lib/{ant-contrib,compile,ivy,default-plugins,scripting,test}
+ ln -sf /usr/share/java/ant-contrib.jar lib/ant-contrib/ant-contrib.jar
+ ln -sf /usr/share/java/bsh.jar lib/ant-contrib/bsh.jar
+ ln -sf /usr/share/java/hamcrest-core.jar lib/test/hamcrest-core.jar
+ ln -sf /usr/share/java/hamcrest-library.jar lib/test/hamcrest-library.jar
+ ln -sf /usr/share/java/jsr305.jar lib/compile/jsr305.jar
+ ln -sf /usr/share/java/junit.jar lib/test/junit.jar
+ patch -Np1 -i "${srcdir}/jedit-fix_build.patch"
+}
+
+build() {
+ cd jEdit
+ ant build \
+ -lib /usr/share/java/apache-ivy/ivy.jar \
+ -Divy.done=true
+}
+
+package() {
+ cd jEdit
+
+ # Install license file
+ install -Dm644 doc/COPYING.txt "$pkgdir/usr/share/licenses/$pkgname/COPYING.txt"
+ install -Dm644 doc/COPYING.PLUGINS.txt "$pkgdir/usr/share/licenses/$pkgname/COPYING.PLUGINS.txt"
+ install -Dm644 doc/COPYING.DOC.txt "$pkgdir/usr/share/licenses/$pkgname/COPYING.DOC.txt"
+
+ # Install documentation
+ install -m755 -d "$pkgdir/usr/share/java/$pkgname"
+ cp -ru doc "$pkgdir/usr/share/java/$pkgname/doc"
+# install -d "$pkgdir/usr/share/doc/$pkgname"
+# cp -r build/javadoc "${pkgdir}/usr/share/doc/${pkgname}"
+
+ # Install jars
+ install -D -m644 build/$pkgname.jar "$pkgdir/usr/share/java/$pkgname/$pkgname.jar"
+
+ # Install keymaps
+ cp -r build/keymaps "${pkgdir}/usr/share/java/${pkgname}"
+
+ # Install macros
+ cp -r build/macros "${pkgdir}/usr/share/java/${pkgname}"
+
+ # Install modes
+ cp -r build/modes "${pkgdir}/usr/share/java/${pkgname}"
+
+ # Install properties
+ cp -r build/properties "${pkgdir}/usr/share/java/${pkgname}"
+
+ # Install startup
+ cp -r build/startup "${pkgdir}/usr/share/java/${pkgname}"
+
+ # Man pages
+ install -Dm644 package-files/linux/$pkgname.1 "$pkgdir/usr/share/man/man1/$pkgname.1"
+
+ # Launchers, properties and desktop shortcuts
+ install -d "$pkgdir/usr/bin"
+ install -Dm755 "$srcdir/$pkgname.sh" "$pkgdir/usr/bin/$pkgname"
+ install -Dm755 "$srcdir/${pkgname}bg.sh" "$pkgdir/usr/bin/${pkgname}bg"
+ install -Dm644 "$srcdir/$pkgname.props" "$pkgdir/usr/share/$pkgname/default.props"
+ install -Dm644 "$srcdir/$pkgname.desktop" "$pkgdir/usr/share/applications/$pkgname.desktop"
+ install -Dm644 doc/$pkgname.png "$pkgdir/usr/share/pixmaps/$pkgname.png"
+}
diff --git a/libre/jedit/jedit-fix_build.patch b/libre/jedit/jedit-fix_build.patch
new file mode 100644
index 000000000..367dfdf7c
--- /dev/null
+++ b/libre/jedit/jedit-fix_build.patch
@@ -0,0 +1,11 @@
+--- jEdit.orig/build.xml 2015-10-20 12:56:08.000000000 -0500
++++ jEdit/build.xml 2016-06-27 03:39:13.537041553 -0500
+@@ -119,7 +119,7 @@
+
+ <target name="retrieve"
+ description="retrieve the dependencies"
+- depends="init,init-ivy"
++ depends="init"
+ unless="ivy.done">
+ <ivy:retrieve sync="true"/>
+ <ivy:retrieve pattern="${lib.dir}/ivy/[artifact]-[revision].[ext]"
diff --git a/libre/jedit/jedit.install b/libre/jedit/jedit.install
new file mode 100644
index 000000000..7c0a944ef
--- /dev/null
+++ b/libre/jedit/jedit.install
@@ -0,0 +1,13 @@
+post_upgrade() {
+ update-desktop-database -q
+}
+
+post_install() {
+ post_upgrade
+}
+
+post_remove() {
+ post_upgrade
+}
+
+# vim:set ts=2 sw=2 et:
diff --git a/libre/jedit/jedit.props b/libre/jedit/jedit.props
new file mode 100644
index 000000000..022ffba5e
--- /dev/null
+++ b/libre/jedit/jedit.props
@@ -0,0 +1,62 @@
+# --- Arch Linux defaults for jEdit ---
+#
+# Just remove this file (~/.jedit/properties) to use the original jEdit defaults.
+#
+# startup
+firstTime=false
+tip.show=false
+# buffers
+buffer.tabSize=4
+buffer.indentSize=4
+buffer.encoding=UTF-8
+buffer.maxLineLen=99
+# look and feel, fonts and colors
+icon-theme=tango
+lookAndFeel=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
+view.fontsize=14
+view.font=Fira Mono
+view.selectionFg=false
+view.caretColor=\#333333
+view.lineHighlightColor=\#deebfb
+view.thickCaret=false
+view.selectionFgColor=\#000000
+view.extendedState=0
+view.wrapGuideColor=\#dedede
+view.structureHighlightColor=\#3d9bc4
+view.selectionColor=\#cccccc
+view.status.show-caret-virtual=true
+view.status.foreground=\#000000
+view.status.show-caret-linenumber=true
+view.status.show-caret-bufferlength=true
+view.status.background=\#ffffff
+view.status.show-caret-dot=true
+view.status.memory.background=\#66699a
+view.status.show-caret-offset=true
+view.style.invalid=color\:\#ff1e00 bgColor\:\#ffffcc
+view.style.digit=color\:\#330066
+view.style.literal4=color\:\#0182bc
+view.style.literal3=color\:\#0700cc
+view.style.literal2=color\:\#760000
+view.style.literal1=color\:\#90001c
+view.style.comment4=color\:\#a2a2a2
+view.style.label=color\:\#009500
+view.style.comment3=color\:\#868686
+view.style.comment2=color\:\#383838
+view.style.comment1=color\:\#434343
+view.style.keyword4=color\:\#00a228
+view.style.keyword3=color\:\#0b2700
+view.style.keyword2=color\:\#000066
+view.style.keyword1=color\:\#0033cc
+view.style.function=color\:\#006600
+view.style.operator=color\:\#000000
+view.gutter.fontsize=14
+view.gutter.font=Courier 10 Pitch
+view.gutter.highlightColor=\#660000
+view.gutter.selectionAreaBgColor=\#f0f0f0
+view.gutter.highlightInterval=10
+view.gutter.focusBorderColor=\#ececec
+view.gutter.highlightCurrentLine=false
+view.gutter.bgColor=\#f0f0f0
+view.gutter.currentLineColor=\#006699
+view.gutter.fgColor=\#3c3c3c
+view.gutter.selectionAreaWidth=12
diff --git a/libre/jedit/jedit.sh b/libre/jedit/jedit.sh
new file mode 100644
index 000000000..f05359f2d
--- /dev/null
+++ b/libre/jedit/jedit.sh
@@ -0,0 +1,16 @@
+#!/bin/sh
+# Runs jEdit - Programmer's Text Editor
+
+# If $HOME/.jedit or $HOME/.jedit/properties exists, don't do anything.
+# If not, copy in a default property file.
+if [ ! -e $HOME/.jedit ]; then
+ if [ ! -e $HOME/.jedit/properties ]; then
+ mkdir $HOME/.jedit
+ cp /usr/share/jedit/default.props $HOME/.jedit/properties
+ fi
+fi
+
+# Set jvm heap initial and maximum sizes (in megabytes).
+JAVA_HEAP_MAX_SIZE=192
+
+exec java -Xmx${JAVA_HEAP_MAX_SIZE}M -Dawt.useSystemAAFontSettings=lcd -jar "/usr/share/java/jedit/jedit.jar" "$@"
diff --git a/libre/jedit/jeditbg.sh b/libre/jedit/jeditbg.sh
new file mode 100644
index 000000000..a0de84cb2
--- /dev/null
+++ b/libre/jedit/jeditbg.sh
@@ -0,0 +1,3 @@
+#!/bin/sh
+# Runs jEdit in background-mode, ready to reuse the running instance
+jedit -background -reuseview "$@"