summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKenton Groombridge <concord@gentoo.org>2024-06-20 17:38:44 -0400
committerKenton Groombridge <concord@gentoo.org>2024-06-20 18:22:41 -0400
commit56160157cf92d84d4d96b5831e4c0af7a852a95c (patch)
tree60f24164df80e95f3e62dbe4e32fb36480a66d83 /www-apps/miniflux
parentgames-puzzle/xpired: Fix prefix, fix deps, EAPI 8 (diff)
downloadgentoo-56160157cf92d84d4d96b5831e4c0af7a852a95c.tar.gz
gentoo-56160157cf92d84d4d96b5831e4c0af7a852a95c.tar.bz2
gentoo-56160157cf92d84d4d96b5831e4c0af7a852a95c.zip
www-apps/miniflux: add 2.1.3
Signed-off-by: Kenton Groombridge <concord@gentoo.org>
Diffstat (limited to 'www-apps/miniflux')
-rw-r--r--www-apps/miniflux/Manifest2
-rw-r--r--www-apps/miniflux/miniflux-2.1.3.ebuild107
2 files changed, 109 insertions, 0 deletions
diff --git a/www-apps/miniflux/Manifest b/www-apps/miniflux/Manifest
index 5169c94d3eb0..c5d6dc64c541 100644
--- a/www-apps/miniflux/Manifest
+++ b/www-apps/miniflux/Manifest
@@ -2,3 +2,5 @@ DIST miniflux-2.0.45-deps.tar.xz 38551640 BLAKE2B b4dfe2c8bb4d96ba9b4adcb23078b7
DIST miniflux-2.0.45.tar.gz 580517 BLAKE2B 804c109a7cda5cd4aa4a65130b70c4d1ebb00decbdbb15c6175e14726aa1d0944d9803898e8ace8bdca083e4668f1fe2230a588793082b63967ef11d7e68827f SHA512 f2770105b05251d8ec1cd63fc8fde4ac45ba6d734c2bd96b574a4c0e33b6a9c8ce67af48d9adb29794a292c47f2f7059fea8a6e20708d0fefa6de4cbaa647328
DIST miniflux-2.0.49-deps.tar.xz 38155476 BLAKE2B 9631c23af181cf86bd197066a453c84b09840cc71a870eba0ad4e7cdb2720fe952fca7f6a93f3e9e2e2d8c9a13629da0f758b21a4afe5849186d653b44a3f097 SHA512 c51228a3f70d73788be63ed5e7f24baeee9a369351e07bd7715a60c6b340d3e90ebd25adfb50d3e2144a8b0c7d609fca3bacdd51a1d61ff7916e6a7a439b6dc1
DIST miniflux-2.0.49.tar.gz 614888 BLAKE2B 77fae7eafcc55d02e3e00e6c008cb6727ff48423512e9dde420b84a63858e6ba9ed33dfd61907a46ca686b211f604d452e2ad5944b709094263ca0949a6128c8 SHA512 59505f5e60228ff94cf2cabc872117cd08c06edb0df6dfb4487153add27cc4e485d7cb71330333df155f158eb650f684d55f0460ba5404f5e26b9603123fd860
+DIST miniflux-2.1.3-deps.tar.xz 43436720 BLAKE2B 97a6aa1509bcde6da4368d50de9bac9a0cedf2752e020f2521cc29f38644fc9de53f14052649c9d42b4d450e1ffac6209787c9b94c1c90d0f2ba1dc31811356d SHA512 6113f5288da2ecd77cbb21c81a60ea331943f369c9304241330b75d57e0e2f65c74d2ddcc4f920e9c572289cea30c50a673029b66877da47d1d2c13700e51081
+DIST miniflux-2.1.3.tar.gz 710470 BLAKE2B ed4f5cb60b26db797e0374d497ebf0bf6d063308bb83938ec5b90a146ba1cc1ab7f5c8c2ecc92cae77d8c683b1f212bead22828cfdad432f7400b58addddde8d SHA512 93f9c91edfdbdd47aaaafa2a45ba4d0af08351465e84231b9f9f0886042897b0649932e02adc6680fc4952828415edcda8b634224dc21015f053c25d0e24f9cb
diff --git a/www-apps/miniflux/miniflux-2.1.3.ebuild b/www-apps/miniflux/miniflux-2.1.3.ebuild
new file mode 100644
index 000000000000..8a64f1ec2999
--- /dev/null
+++ b/www-apps/miniflux/miniflux-2.1.3.ebuild
@@ -0,0 +1,107 @@
+# Copyright 2020-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit go-module systemd
+
+# git rev-parse --short HEAD
+MY_GIT_COMMIT="4d3ee0d1"
+
+DESCRIPTION="Minimalist and opinionated feed reader"
+HOMEPAGE="https://miniflux.app https://github.com/miniflux/v2"
+SRC_URI="https://github.com/${PN}/v2/archive/${PV}.tar.gz -> ${P}.tar.gz"
+SRC_URI+=" https://dev.gentoo.org/~concord/distfiles/${P}-deps.tar.xz"
+
+LICENSE="Apache-2.0 BSD BSD-2 MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64 ~riscv"
+
+RESTRICT="test" # requires network access
+
+DEPEND="acct-user/miniflux"
+RDEPEND="${DEPEND}
+ >=dev-db/postgresql-9.5
+"
+
+S="${WORKDIR}/v2-${PV}"
+
+src_compile() {
+ ego build -ldflags="
+ -s -w
+ -X 'miniflux.app/v2/internal/version.Version=${PV}'
+ -X 'miniflux.app/v2/internal/version.Commit=${MY_GIT_COMMIT}'
+ -X 'miniflux.app/v2/internal/version.BuildDate=$(date +%FT%T%z)'
+ " -o miniflux main.go
+}
+
+src_install() {
+ dobin miniflux
+
+ insinto /etc
+ doins "${FILESDIR}/${PN}.conf"
+
+ newconfd "${FILESDIR}/${PN}.confd" ${PN}
+
+ newinitd "${FILESDIR}/${PN}.initd-r1" ${PN}
+ systemd_dounit "${FILESDIR}/${PN}.service"
+
+ fowners miniflux:root /etc/${PN}.conf
+ fperms o-rwx /etc/${PN}.conf
+
+ local DOCS=(
+ ChangeLog
+ README.md
+ "${FILESDIR}"/README.gentoo
+ )
+
+ # Makefile has no install target, so call einstalldocs directly
+ einstalldocs
+
+ doman "${PN}".1
+}
+
+pkg_postinst() {
+ if [[ -z "${REPLACING_VERSIONS}" ]]; then
+ # This is a new installation
+
+ echo
+ elog "Before using miniflux, you must first create and initialize the database"
+ elog "and enable the hstore extension for it."
+ elog ""
+ elog "Afterwards, create your first admin user by running:"
+ elog " miniflux -create-admin"
+ else
+ # This is an existing installation
+
+ echo
+ elog "If you are upgrading from a previous version, schema migrations must be performed."
+ elog "To perform the migrations, stop the daemon, backup your database, and run:"
+ elog " emerge --config =${PF}"
+ fi
+
+ echo
+ elog "Please read"
+ elog ""
+ elog " ${EPREFIX}/usr/share/doc/${PF}/README.gentoo*"
+ elog ""
+ elog "for more information."
+}
+
+pkg_config() {
+ # To be safe, avoid doing migrations if miniflux is running
+ if pgrep miniflux; then
+ die "miniflux appears to be running, refusing to continue."
+ fi
+
+ # Extract the database URL variable instead of just sourcing the config file
+ # because miniflux itself may interpret quotes as part of the URL
+ local DATABASE_URL="$(sed -n 's/^DATABASE_URL=\(.*\)/\1/p' "${EROOT}/etc/${PN}.conf")"
+ [[ -n "${DATABASE_URL}" ]] || die "Failed getting DATABASE_URL from config file"
+
+ DATABASE_URL="${DATABASE_URL}" "${EROOT}"/usr/bin/miniflux -migrate \
+ || die "miniflux -migrate failed. Please check the above output for errors."
+
+ echo
+ elog "Database migrations complete."
+}