summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO21
-rw-r--r--.editorconfig9
-rw-r--r--.gitignore6
-rw-r--r--PKGBUILD73
-rw-r--r--filebot-arch.sh23
-rw-r--r--filebot.install43
-rwxr-xr-xfilebot.sh69
7 files changed, 154 insertions, 90 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 5fd620413e61..51a368e775b8 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,29 +1,30 @@
pkgbase = filebot
pkgdesc = The ultimate TV and Movie Renamer
- pkgver = 4.8.5
- pkgrel = 1
+ pkgver = 5.1.3
+ pkgrel = 3
url = https://www.filebot.net/
+ install = filebot.install
arch = i686
arch = x86_64
arch = aarch64
arch = armv7l
arch = armv7h
license = Commercial
- depends = java-openjfx
- depends = jre8-openjdk
+ depends = java-runtime
depends = fontconfig
depends = chromaprint
optdepends = libzen: Required by libmediainfo
optdepends = libmediainfo: Read media info such as video codec, resolution or duration
- optdepends = java-p7zip-binding: Extract archives
optdepends = gvfs: Drag-n-Drop from GVFS remote filesystems
provides = filebot
conflicts = filebot47
conflicts = filebot-git
- source = https://get.filebot.net/filebot/FileBot_4.8.5/FileBot_4.8.5-aur.tar.xz
- source = filebot-arch.sh
- md5sums = 91827d5a16358316c475e58ee86b552e
- md5sums = 7c1128f94fcd9f4e29225a12eac83704
+ source = https://get.filebot.net/filebot/FileBot_5.1.3/FileBot_5.1.3-aur.tar.xz
+ source = https://get.filebot.net/filebot/FileBot_5.1.3/FileBot_5.1.3-aur.tar.xz.asc
+ source = filebot.sh
+ validpgpkeys = B0976E51E5C047AD0FD051294E402EBF7C3C6A71
+ sha256sums = 6adee7746fae1b656a8fc94841c019eecd5f31c3c2003ec0fdb88d6b3f08cfa1
+ sha256sums = SKIP
+ sha256sums = 2a6926291fcaacfca99c8b1ecf2c3ea9ee73ad6842c51a592256349ddb6fe885
pkgname = filebot
-
diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 000000000000..244634887b77
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,9 @@
+[*]
+indent_style = space
+indent_size = 2
+trim_trailing_whitespace = true
+insert_final_newline = true
+
+shell_variant = bash
+keep_padding = true
+case_indent = true
diff --git a/.gitignore b/.gitignore
index 656715da99b3..d892f99ad9ab 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,8 @@
*.xz
+*.xz.asc
+*.tar.gz
+*.tar.gz.asc
+*.pkg.tar*
src/
pkg/
-filebot/ \ No newline at end of file
+filebot/
diff --git a/PKGBUILD b/PKGBUILD
index 9bdb3efe8eb9..3d7ee4548b99 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,70 +5,41 @@
# Contributor: said
# Contributor: Kaurin <milos dot kaurin at gmail>
# Contributor: Nathan Owe <ndowens04 at gmail>
+# Contributor: Bernhard Bermeitinger <bernhard.bermeitinger at gmail.com>
pkgname=filebot
-pkgver=4.8.5
-pkgrel=1
+pkgver=5.1.3
+pkgrel=3
pkgdesc="The ultimate TV and Movie Renamer"
arch=('i686' 'x86_64' 'aarch64' 'armv7l' 'armv7h')
url="https://www.filebot.net/"
license=('Commercial')
-install=$pkgname.install
-install=()
-depends=('java-openjfx' 'jre8-openjdk' 'fontconfig' 'chromaprint')
+depends=('java-runtime' 'fontconfig' 'chromaprint')
makedepends=()
-provides=('filebot')
-conflicts=('filebot47' 'filebot-git')
-
-[[ $CARCH == "i686" ]] && _intarch=i686
-[[ $CARCH == "x86_64" ]] && _intarch=amd64
-[[ $CARCH == "armv7l" ]] && _intarch=armv7l
-[[ $CARCH == "armv7h" ]] && _intarch=armv7l
-[[ $CARCH == "aarch64" ]] && _intarch=armv8
-
-source=(#"https://get.filebot.net/filebot/FileBot_${pkgver}/FileBot_${pkgver}-portable.tar.xz"
- "https://get.filebot.net/filebot/FileBot_${pkgver}/FileBot_${pkgver}-aur.tar.xz"
- $pkgname-arch.sh
- #$pkgname.svg
- #$pkgname.desktop
- )
-
-md5sums=('91827d5a16358316c475e58ee86b552e'
- '7c1128f94fcd9f4e29225a12eac83704')
+checkdepends=()
optdepends=('libzen: Required by libmediainfo'
- 'libmediainfo: Read media info such as video codec, resolution or duration'
- 'java-p7zip-binding: Extract archives'
- 'gvfs: Drag-n-Drop from GVFS remote filesystems')
-
-prepare() {
- cd "$srcdir"
-}
+ 'libmediainfo: Read media info such as video codec, resolution or duration'
+ 'gvfs: Drag-n-Drop from GVFS remote filesystems')
-build() {
- cd $srcdir
-}
-
-package() {
- mkdir -p $pkgdir/usr/share/java/$pkgname/
-
- install -Dm755 $pkgname-arch.sh "$pkgdir/usr/bin/$pkgname"
-
- cd "$srcdir/usr/share"
+provides=('filebot')
- install -Dm644 $pkgname/lib/$CARCH/libjnidispatch.so "$pkgdir/usr/share/java/$pkgname/libjnidispatch.so"
- cp -dpr --no-preserve=ownership $pkgname/jar/* "$pkgdir/usr/share/java/$pkgname/"
+conflicts=('filebot47' 'filebot-git')
+install=$pkgname.install
+source=("https://get.filebot.net/filebot/FileBot_${pkgver}/FileBot_${pkgver}-aur.tar.xz"
+ "https://get.filebot.net/filebot/FileBot_${pkgver}/FileBot_${pkgver}-aur.tar.xz.asc"
+ "filebot.sh")
- cp -dpr --no-preserve=ownership icons/* "$pkgdir/usr/share/icons/"
+sha256sums=('6adee7746fae1b656a8fc94841c019eecd5f31c3c2003ec0fdb88d6b3f08cfa1'
+ 'SKIP'
+ '2a6926291fcaacfca99c8b1ecf2c3ea9ee73ad6842c51a592256349ddb6fe885')
+validpgpkeys=('B0976E51E5C047AD0FD051294E402EBF7C3C6A71')
- #install -Dm644 $pkgname.svg "$pkgdir/usr/share/pixmaps/$pkgname.svg"
- #install -Dm644 icons/hicolor/scalable/apps/$pkgname.svg "$pkgdir/usr/share/pixmaps/$pkgname.svg"
+package() {
+ mkdir -p "${pkgdir}/usr/bin"
+ mkdir -p "${pkgdir}/usr/share/${pkgname}"
- #install -Dm644 applications/*.desktop "$pkgdir/usr/share/applications/$pkgname.desktop"
- mkdir -p $pkgdir/usr/share/applications/
- cp -dpr --no-preserve=ownership applications/* "$pkgdir/usr/share/applications/"
+ install -Dm755 "${pkgname}.sh" "${pkgdir}/usr/bin/${pkgname}"
- mkdir -p $pkgdir/usr/share/mime/packages/
- cp -dpr --no-preserve=ownership mime/* "$pkgdir/usr/share/mime/"
-
+ cp -dpr --no-preserve=ownership "${srcdir}/etc" "${srcdir}/usr" "${pkgdir}"
}
diff --git a/filebot-arch.sh b/filebot-arch.sh
deleted file mode 100644
index b66e5028bbea..000000000000
--- a/filebot-arch.sh
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/bin/bash
-
-# force JVM language and encoding settings
-export LANG="en_US.UTF-8"
-export LC_ALL="en_US.UTF-8"
-
-APP_ROOT=/usr/share/java/filebot
-
-# add APP_ROOT to LD_LIBRARY_PATH
-if [ ! -z "$LD_LIBRARY_PATH" ]; then
- export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$APP_ROOT"
-else
- export LD_LIBRARY_PATH="$APP_ROOT"
-fi
-
-# choose extractor
-EXTRACTOR="ApacheVFS" # use Apache Commons VFS2 with junrar plugin
-# EXTRACTOR="SevenZipExecutable" # use the 7z executable
-# EXTRACTOR="SevenZipNativeBindings" # use the lib7-Zip-JBinding.so native library
-
-# start filebot
-/usr/lib/jvm/java-8-openjdk/bin/java -Dunixfs=false -DuseGVFS=false -DuseExtendedFileAttributes=true -DuseCreationDate=false -Djava.net.useSystemProxies=false -Dapplication.deployment=AUR -Dfile.encoding="UTF-8" -Dsun.jnu.encoding="UTF-8" -Djna.nosys=false -Djna.nounpack=true -Dnet.filebot.Archive.extractor="$EXTRACTOR" -Dnet.filebot.AcoustID.fpcalc="fpcalc" -Dapplication.dir=$HOME/.config/filebot -Djava.io.tmpdir=/tmp/filebot -Dapplication.update=skip -Djna.library.path=/usr/share/java/filebot $JAVA_OPTS -cp /usr/share/java/filebot/filebot.jar net.filebot.Main "$@"
-
diff --git a/filebot.install b/filebot.install
index 0260d16f0dad..491af46f2348 100644
--- a/filebot.install
+++ b/filebot.install
@@ -1,11 +1,44 @@
+#!/usr/bin/env bash
+
+# get default file manager
+_xdg_mime_default=$(xdg-mime query default inode/directory)
+
+pre_install() {
+ if [ -d "/usr/share/filebot/openjfx" ]; then
+ if [ -L "/usr/share/filebot/openjfx" ]; then
+ echo "Installing"
+ else
+ echo "Removing /usr/share/filebot/openjfx directory leftover"
+ rm -r /usr/share/filebot/openjfx
+ fi
+ fi
+}
+
post_install() {
-echo -e "\e[1;33m==>\e[0m if you use OpenJDK as Java VM you \e[1;31mmust\e[0m also install OpenJFX"
-echo -e "\e[1;33m==>\e[0m \e[1;36mhttps://wiki.archlinux.org/index.php/Java#OpenJFX\e[0m"
-echo ""
-echo -e "\e[1;33m==>\e[0m \e[1;31mfilebot --license license.file\e[0m will activate your license.file
+ echo ""
+ echo -e "\e[1;33m==>\e[0m \e[1;31m filebot --license license.file \e[0m will activate your license.file"
+ echo ""
+
+ echo -e "\e[1;33m==>\e[0m To enable system extractor for archives please run"
+ echo ""
+ echo -e "\e[1;33m==>\e[0m \e[1;31m filebot -script fn:properties --def net.filebot.archive.extractor=ShellExecutables \e[0m"
+ echo ""
+ echo "Set default file manager to pre-install file manager"
+ echo $_xdg_mime_default
+ xdg-mime default $_xdg_mime_default inode/directory
+ echo ""
+}
+
+pre_upgrade() {
+ pre_install "${1}"
}
post_upgrade() {
- post_install $1
+ post_install "${1}"
}
+pre_remove() {
+ # no filebot/openjfx workaround
+ echo -e "\e[1;33m==>\e[0m Removing OpenJFX symlinks leftover"
+ rm /usr/share/filebot/openjfx 2>/dev/null
+}
diff --git a/filebot.sh b/filebot.sh
new file mode 100755
index 000000000000..e0528973dc2b
--- /dev/null
+++ b/filebot.sh
@@ -0,0 +1,69 @@
+#!/usr/bin/env bash
+FILEBOT_HOME="/usr/share/filebot"
+
+# sanity check
+if [ -z "${HOME}" ]; then
+ echo "\$HOME must be set"
+ exit 1
+fi
+
+if [ "$(id -u)" = "0" ]; then
+ echo "$0 must NOT run as root"
+fi
+
+# select application data folder
+APP_DATA="${HOME}/.config/filebot"
+LIBRARY_PATH="${FILEBOT_HOME}/lib/$(uname -m):/lib64"
+
+# Disable wayland and force xwayland
+# workaround for bug https://www.filebot.net/forums/viewtopic.php?t=13567
+# as of 09.03.2024 seems relevant under KDE 6.0 using Wayland and nvidia/amd gpu
+WAYLAND_DISPLAY=
+
+# shellcheck disable=SC2086
+java \
+ -Dapplication.deployment=aur \
+ --add-modules ALL-MODULE-PATH \
+ -Dnet.filebot.archive.extractor=ShellExecutables \
+ --add-opens=java.base/java.lang=ALL-UNNAMED \
+ --add-opens=java.base/java.lang.reflect=ALL-UNNAMED \
+ --add-opens=java.base/java.lang.invoke=ALL-UNNAMED \
+ --add-opens=java.base/java.util=ALL-UNNAMED \
+ --add-opens=java.base/java.util.function=ALL-UNNAMED \
+ --add-opens=java.base/java.util.regex=ALL-UNNAMED \
+ --add-opens=java.base/java.net=ALL-UNNAMED \
+ --add-opens=java.base/java.io=ALL-UNNAMED \
+ --add-opens=java.base/java.nio=ALL-UNNAMED \
+ --add-opens=java.base/java.nio.file=ALL-UNNAMED \
+ --add-opens=java.base/java.nio.file.attribute=ALL-UNNAMED \
+ --add-opens=java.base/java.nio.channels=ALL-UNNAMED \
+ --add-opens=java.base/java.nio.charset=ALL-UNNAMED \
+ --add-opens=java.base/java.time=ALL-UNNAMED \
+ --add-opens=java.base/java.time.chrono=ALL-UNNAMED \
+ --add-opens=java.base/java.util.concurrent=ALL-UNNAMED \
+ --add-opens=java.base/java.text=ALL-UNNAMED \
+ --add-opens=java.base/sun.nio.fs=ALL-UNNAMED \
+ --add-opens=java.logging/java.util.logging=ALL-UNNAMED \
+ --add-opens=java.desktop/java.awt=ALL-UNNAMED \
+ --add-opens=java.desktop/sun.awt=ALL-UNNAMED \
+ --add-opens=java.desktop/sun.swing=ALL-UNNAMED \
+ --add-opens=java.desktop/javax.swing.text.html=ALL-UNNAMED \
+ --add-opens=java.prefs/java.util.prefs=ALL-UNNAMED \
+ -XX:+DisableAttachMechanism \
+ -Djna.boot.library.path="${LIBRARY_PATH}" \
+ -Djna.boot.library.name=jnidispatch \
+ -Djna.library.path="${LIBRARY_PATH}" \
+ -Djava.library.path="${LIBRARY_PATH}" \
+ -Dapplication.dir="${APP_DATA}" \
+ -Dapplication.cache="${APP_DATA}/cache" \
+ -Djava.io.tmpdir="${APP_DATA}/tmp" \
+ -Dfile.encoding="UTF-8" \
+ -Dsun.jnu.encoding="UTF-8" \
+ -Dawt.useSystemAAFontSettings=on \
+ -Dprism.order=sw \
+ -Dnet.filebot.theme=Darcula \
+ -DuseGVFS=true \
+ -Dnet.filebot.gio.GVFS="${XDG_RUNTIME_DIR}/gvfs" \
+ ${JVM_OPTS} ${JAVA_OPTS} ${FILEBOT_OPTS} \
+ -jar "${FILEBOT_HOME}/jar/filebot.jar" \
+ "$@"