10 php.buildComposerProject (finalAttrs: {
14 src = fetchFromGitHub {
17 rev = "v${finalAttrs.version}";
18 hash = "sha256-aX3DMy9Jv8rNp1/VIvUtNXYXGBrCgBMs5GsDf4XXSj0=";
21 vendorHash = "sha256-KaYvA0Rd4pd1s/L8QbVUgkE+SjH+jv4+6RvIaGOpews=";
23 offlineCache = fetchYarnDeps {
24 yarnLock = finalAttrs.src + "/yarn.lock";
25 hash = "sha256-UvWY8+qSRvzJbm7z3CmLyeUHxemzNUB7dHYP95ZVtcI=";
33 # Upstream composer.json file is missing the name, description and license fields
34 composerStrictValidation = false;
36 # NOTE: if patches are created from a git checkout, those should be modified
37 # with `unix2dos` to make sure those apply here.
39 ./0001-Define-configs-with-env-vars.patch
40 ./0002-Remove-check-for-config-file-as-it-s-stored-in-etc-g.patch
46 export HOME=$(mktemp -d)
47 yarn config --offline set yarn-offline-mirror $offlineCache
48 fixup-yarn-lock yarn.lock
49 yarn install --offline --frozen-lockfile --no-progress --non-interactive
57 mv $out/share/php/grocy/* $out
63 passthru.tests = { inherit (nixosTests) grocy; };
66 license = licenses.mit;
67 maintainers = with maintainers; [ n0emis ];
68 description = "ERP beyond your fridge - grocy is a web-based self-hosted groceries & household management solution for your home";
69 homepage = "https://grocy.info/";