diff options
author | Julien Roy <julien@jroy.ca> | 2024-12-27 11:37:02 -0500 |
---|---|---|
committer | Julien Roy <julien@jroy.ca> | 2024-12-27 11:39:29 -0500 |
commit | 59f4f94535b98c6f45e0c93757a138c077a064d5 (patch) | |
tree | 9369c860af08da71b768fee173d6ea74e024aaff | |
parent | 626fdc72a24ac6caae2b16f503c0edd9246bd90d (diff) | |
download | wger-overlay-master.tar.gz wger-overlay-master.tar.bz2 wger-overlay-master.zip |
Signed-off-by: Julien Roy <julien@jroy.ca>
-rw-r--r-- | www-apps/wger/Manifest | 2 | ||||
-rw-r--r-- | www-apps/wger/wger-2.3_pre20241224.ebuild | 135 |
2 files changed, 137 insertions, 0 deletions
diff --git a/www-apps/wger/Manifest b/www-apps/wger/Manifest index d86757a..e0355a8 100644 --- a/www-apps/wger/Manifest +++ b/www-apps/wger/Manifest @@ -2,3 +2,5 @@ DIST wger-2.3_pre20241121-npm.tar.xz 5784904 BLAKE2B ea3649d90868c396b594d4b58ff DIST wger-2.3_pre20241121.gh.tar.gz 7942028 BLAKE2B bcbbc6d3d7c60129ca175e4dede7f3e129e73b8bb14a9f65a184b4dcde0f48897d9591a5081d6a9d3f8572e2ae2900563b00ef51a52c8d0d894accf729e9b2e3 SHA512 510339d4c5cbe1208abdcf00a225e2dc1893481921d510e9c3abc6a8a60ed834395c306b37cd92a8c38c69dc532db2a48501b0d70b53a982f508ddc2f2a03102 DIST wger-2.3_pre20241206-npm.tar.xz 5785140 BLAKE2B e36382e0ad1d8e6117ff81fd66f2bf4e9d86b639938508ba03d82f8c40940d3bf7fae18adb5cdacae8c38db6bad490794dbcf361418369027bc514d0fad3da47 SHA512 58221daefafee6a0faf7c9379f21b87870ba7c8f4a5566dac7747d80b32cf40fac15c20f15eb4499135b67a93730c0b1955c1edb70b774986b05372320f878da DIST wger-2.3_pre20241206.gh.tar.gz 7942028 BLAKE2B bcbbc6d3d7c60129ca175e4dede7f3e129e73b8bb14a9f65a184b4dcde0f48897d9591a5081d6a9d3f8572e2ae2900563b00ef51a52c8d0d894accf729e9b2e3 SHA512 510339d4c5cbe1208abdcf00a225e2dc1893481921d510e9c3abc6a8a60ed834395c306b37cd92a8c38c69dc532db2a48501b0d70b53a982f508ddc2f2a03102 +DIST wger-2.3_pre20241224-npm.tar.xz 5787148 BLAKE2B 168327da65304da05a8aec837d666abb2bc2ac6aeb3c0a235006bfc879ca7a6a664183b60cb594b0e44bbe712bd9392d301148eb7c1519b73dc9ed511404132e SHA512 facadf4c7fe703c3286ab510929d9bbee00bba58a1775060bda395c8bf38710327bfa5321280d090d0a34231e96d974cbea225fd81f793c4b1072a6869fbfe26 +DIST wger-2.3_pre20241224.gh.tar.gz 7942760 BLAKE2B 09c873be5792f7c34b86afcabf032debb5afd15cf38eb7c49a69b30eb5f2b421b9ae8882845efd2a883b9bae8385a6948438334bb5a2b8e3e0c8c2bbf7932f85 SHA512 c176527c0d0083a809b7135b3f82c7157de25b2fe6d5d29ce6da408200c34d07a5a1efcb15813ea0c93d36f23c05c88044f62231504af53291239d0c2e9b2e4f diff --git a/www-apps/wger/wger-2.3_pre20241224.ebuild b/www-apps/wger/wger-2.3_pre20241224.ebuild new file mode 100644 index 0000000..ab44abb --- /dev/null +++ b/www-apps/wger/wger-2.3_pre20241224.ebuild @@ -0,0 +1,135 @@ +# Copyright 2023-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{11..12} ) +DISTUTILS_USE_PEP517=hatchling + +inherit distutils-r1 + +COMMIT="36c58553898d0684dc4bceeeb0abf1a90681ac9b" +DESCRIPTION="FLOSS workout, fitness and weight manager/tracker" +HOMEPAGE="https://github.com/wger-project/wger" +SRC_URI=" + https://github.com/wger-project/wger/archive/${COMMIT}.tar.gz -> ${P}.gh.tar.gz + https://jroy.ca/dist/${P}-npm.tar.xz +" +S="${WORKDIR}/${PN}-${COMMIT}" + +LICENSE="AGPL-3" +SLOT="0" +KEYWORDS="~amd64" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +RDEPEND=" + ${PYTHON_DEPS} + acct-user/wger + acct-group/wger + + >=dev-python/django-4.2.16[${PYTHON_USEDEP}] + >=dev-python/bleach-6.1.0[${PYTHON_USEDEP}] + >=dev-python/celery-5.4.0[${PYTHON_USEDEP}] + >=dev-python/crispy-bootstrap5-2024.2[${PYTHON_USEDEP}] + >=dev-python/django-activity-stream-2.0.0[${PYTHON_USEDEP}] + >=dev-python/django-axes-7.0.0[${PYTHON_USEDEP}] + >=dev-python/django4-bootstrap-breadcrumbs-0.10.0[${PYTHON_USEDEP}] + >=dev-python/django-crispy-forms-2.3[${PYTHON_USEDEP}] + >=dev-python/django-email-verification-0.3.3[${PYTHON_USEDEP}] + >=dev-python/django-environ-0.11.2[${PYTHON_USEDEP}] + >=dev-python/django-formtools-2.5[${PYTHON_USEDEP}] + >=dev-python/django-prometheus-2.3.1[${PYTHON_USEDEP}] + >=dev-python/django-recaptcha-4.0.0[${PYTHON_USEDEP}] + >=dev-python/django-simple-history-3.7[${PYTHON_USEDEP}] + >=dev-python/django-storages-1.14[${PYTHON_USEDEP}] + >=dev-python/django-compressor-4.5[${PYTHON_USEDEP}] + >=dev-python/drf-spectacular-0.27.2[${PYTHON_USEDEP}] + >=dev-python/drf-spectacular-sidecar-2024.6.1[${PYTHON_USEDEP}] + >=dev-python/easy-thumbnails-2.10[${PYTHON_USEDEP}] + >=dev-python/flower-2.0.1[${PYTHON_USEDEP}] + >=dev-python/fontawesomefree-6.6.0[${PYTHON_USEDEP}] + >=dev-python/icalendar-6.0.1[${PYTHON_USEDEP}] + >=dev-python/invoke-2.2.0[${PYTHON_USEDEP}] + >=dev-python/openfoodfacts-2.2.0[${PYTHON_USEDEP}] + >=dev-python/pillow-10.4.0[${PYTHON_USEDEP}] + >=dev-python/reportlab-4.2.5[${PYTHON_USEDEP}] + >=dev-python/requests-2.32.3[${PYTHON_USEDEP}] + >=dev-python/tqdm-4.66.5[${PYTHON_USEDEP}] + >=dev-python/tzdata-2024.2[${PYTHON_USEDEP}] + >=dev-python/django-cors-headers-4.6.0[${PYTHON_USEDEP}] + >=dev-python/django-filter-24.3[${PYTHON_USEDEP}] + >=dev-python/djangorestframework-3.15.2[${PYTHON_USEDEP}] + >=dev-python/djangorestframework-simplejwt-5.3.1[${PYTHON_USEDEP}] + >=dev-python/django-sortedm2m-3.1[${PYTHON_USEDEP}] + >=dev-python/pymongo-4.10.1[${PYTHON_USEDEP}] + >=dev-python/django-extensions-3.2[${PYTHON_USEDEP}] + >=dev-python/django-debug-toolbar-4.4.5[${PYTHON_USEDEP}] + >=dev-python/psycopg-3.2.3[${PYTHON_USEDEP}] + >=dev-python/django-redis-5.4.0[${PYTHON_USEDEP}] +" +DEPEND="${RDEPEND}" +BDEPEND=" + net-libs/nodejs[npm] + >=sys-apps/yarn-1.22.21 + dev-lang/sassc +" + +PATCHES=( + # Remove yarn commands from tasks.py + # Since they are done in python_install + "${FILESDIR}"/yarn.patch +) + +eyarn() { + yarn \ + --non-interactive \ + --offline \ + --modules-folder "${BUILD_DIR}"/install"$(python_get_sitedir)"/"${PN}"/core/static/yarn/ \ + --cache-folder "${T}/yarn-cache" \ + --use-yarnrc "${S}"/.yarnrc || die +} + +src_unpack() { + default + cat << EOF > "${S}"/.yarnrc || die +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + +yarn-offline-mirror "../npm-packages-offline-cache" +EOF +} + +python_compile() { + distutils-r1_python_compile + + local WGER_PATH + WGER_PATH="${BUILD_DIR}/install$(python_get_sitedir)/${PN}/" + + cp "${S}"/package.json "${WGER_PATH}" || die + cp "${WORKDIR}"/yarn.lock "${WGER_PATH}" || die + cd "${WGER_PATH}" || die + eyarn + + sassc "${WGER_PATH}"core/static/scss/main.scss "${WGER_PATH}"core/static/yarn/bootstrap-compiled.css || die +} + +src_install() { + distutils-r1_src_install + + python_moduleinto wger + python_foreach_impl python_domodule "${S}"/wger/settings_global.py + + newinitd "${FILESDIR}/${PN}.initd" "${PN}" + newconfd "${FILESDIR}/${PN}.confd" "${PN}" +} + +pkg_postinst() { + einfo + elog "To configure wger, you need to generate a settings file and running the bootstrap using these command:" + elog "wger create-settings --settings-path=/etc/wger/settings.py --database-type={sqlite3,postgresql}" + elog "wger bootstrap --settings-path=/etc/wger/settings.py [--database-path=<sqlite3 database path>]" + elog "wger load-online-fixtures --settings-path=/etc/wger/settings.py" + elog "Make sure to review the other settings in settings.py" + elog "Refer to https://wger.readthedocs.io/en/latest/settings.html" + einfo +} |