#!/bin/bash
# Zotero runs on the Gecko runtime that firefox-esr provides; zotero-bin is a
# copy of its launcher so that the runtime directory is /usr/lib/zotero.
set -e

export MOZ_ALLOW_DOWNGRADE=1
export MOZ_LEGACY_PROFILES=1
if [ -n "${WAYLAND_DISPLAY:-}" ]; then
	export MOZ_ENABLE_WAYLAND=1
fi
ulimit -n 4096 2>/dev/null || true

exec /usr/lib/zotero/zotero-bin -app /usr/lib/zotero/app/application.ini "$@"
