main
1{
2 lib,
3 php,
4 fetchFromGitHub,
5}:
6(
7 php.buildComposerProject2 (finalAttrs: {
8 pname = "shimmie2-unwrapped";
9 version = "2.12.2";
10
11 src = fetchFromGitHub {
12 owner = "shish";
13 repo = "shimmie2";
14 tag = "v${finalAttrs.version}";
15 hash = "sha256-hhQ37nrnndBgv5NRZ8wuwqCSPNNk4LlhLBlRdf+vlGE=";
16 };
17
18 vendorHash = "sha256-qItFGSLgwq0ryx5ByTbMwXSjwD5ev0iOb0E3Y9JF3XU=";
19
20 postInstall = ''
21 mkdir -p $out/share/php/${finalAttrs.pname}/data
22 '';
23
24 meta = {
25 description = "An easy-to-install community image gallery (aka booru)";
26 homepage = "https://github.com/shish/shimmie2";
27 licence = lib.licenses.gpl2Only;
28 platforms = lib.platforms.linux;
29 };
30 })
31).overrideAttrs (_: prev: {
32 # Fix FOD nix store path reference error and non-reproducible error
33 # See https://phip1611.de/blog/fixing-illegal-path-references-in-fixed-output-derivation-in-nix/
34 #
35 # I use overrideAttrs because composerVendor has too many default args
36 composerVendor = prev.composerVendor.overrideAttrs {
37 preInstall = ''
38 rm -rf vendor/ifixit/php-akismet/.git
39 '';
40 };
41})