Only run additional update steps when the source has been updated
This commit is contained in:
parent
fd669bc868
commit
de8ad39e87
8 changed files with 33 additions and 16 deletions
|
@ -74,8 +74,10 @@ in
|
||||||
passthru = {
|
passthru = {
|
||||||
updateScript = writeScript "update-pleroma-fe" ''
|
updateScript = writeScript "update-pleroma-fe" ''
|
||||||
${../../scripts/update-git.sh} https://akkoma.dev/AkkomaGang/admin-fe.git akkoma/admin-fe/source.json
|
${../../scripts/update-git.sh} https://akkoma.dev/AkkomaGang/admin-fe.git akkoma/admin-fe/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
if [ "$(git diff -- akkoma/admin-fe/source.json)" ]; then
|
||||||
${../../scripts/update-yarn.sh} $SRC_PATH akkoma/admin-fe
|
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
||||||
|
${../../scripts/update-yarn.sh} $SRC_PATH akkoma/admin-fe
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -214,8 +214,10 @@ in
|
||||||
inherit mixNixDeps;
|
inherit mixNixDeps;
|
||||||
updateScript = writeScript "update-akkoma" ''
|
updateScript = writeScript "update-akkoma" ''
|
||||||
${../scripts/update-git.sh} https://akkoma.dev/AkkomaGang/akkoma.git akkoma/source.json
|
${../scripts/update-git.sh} https://akkoma.dev/AkkomaGang/akkoma.git akkoma/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
if [ "$(git diff -- akkoma/source.json)" ]; then
|
||||||
${../scripts/update-mix.sh} $SRC_PATH akkoma/mix.nix
|
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
||||||
|
${../scripts/update-mix.sh} $SRC_PATH akkoma/mix.nix
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -59,8 +59,10 @@ in
|
||||||
passthru = {
|
passthru = {
|
||||||
updateScript = writeScript "update-pleroma-fe" ''
|
updateScript = writeScript "update-pleroma-fe" ''
|
||||||
${../../scripts/update-git.sh} https://akkoma.dev/AkkomaGang/pleroma-fe.git akkoma/pleroma-fe/source.json
|
${../../scripts/update-git.sh} https://akkoma.dev/AkkomaGang/pleroma-fe.git akkoma/pleroma-fe/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
if [ "$(git diff -- akkoma/pleroma-fe/source.json)" ]; then
|
||||||
${../../scripts/update-yarn.sh} $SRC_PATH akkoma/pleroma-fe
|
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
||||||
|
${../../scripts/update-yarn.sh} $SRC_PATH akkoma/pleroma-fe
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -36,6 +36,9 @@ in
|
||||||
};
|
};
|
||||||
passthru.updateScript = writeScript "update-matrix-media-repo" ''
|
passthru.updateScript = writeScript "update-matrix-media-repo" ''
|
||||||
${../../scripts/update-git.sh} "https://github.com/drone-runners/drone-runner-docker" ci/drone-runner-docker/source.json
|
${../../scripts/update-git.sh} "https://github.com/drone-runners/drone-runner-docker" ci/drone-runner-docker/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
if [ "$(git diff -- ci/drone-runner-docker/source.json)" ]; then
|
||||||
${../../scripts/update-go.sh} ./ci/drone-runner-docker ci/drone-runner-docker/goVendor.hash '';
|
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
||||||
|
${../../scripts/update-go.sh} ./ci/drone-runner-docker ci/drone-runner-docker/goVendor.hash
|
||||||
|
fi
|
||||||
|
'';
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,7 +25,9 @@ in
|
||||||
};
|
};
|
||||||
passthru.updateScript = writeScript "update-nasin-nanpa" ''
|
passthru.updateScript = writeScript "update-nasin-nanpa" ''
|
||||||
${../../scripts/update-git.sh} https://github.com/ETBCOR/nasin-nanpa fonts/nasin-nanpa/source.json
|
${../../scripts/update-git.sh} https://github.com/ETBCOR/nasin-nanpa fonts/nasin-nanpa/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).nasin-nanpa.src')
|
if [ "$(git diff -- fonts/nasin-nanpa/source.json)" ]; then
|
||||||
ls $SRC_PATH/ffversions/*/*.sfd | sort | tail -n1 | sed 's|[/-]| |g' | sed 's/.sfd//' | awk '{print "{\"major\": \"" $6 "\", \"minor\": \"" $9 "\"}" }' > fonts/nasin-nanpa/version.json
|
SRC_PATH=$(nix-build -E '(import ./. {}).nasin-nanpa.src')
|
||||||
|
ls $SRC_PATH/ffversions/*/*.sfd | sort | tail -n1 | sed 's|[/-]| |g' | sed 's/.sfd//' | awk '{print "{\"major\": \"" $6 "\", \"minor\": \"" $9 "\"}" }' > fonts/nasin-nanpa/version.json
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,7 +37,9 @@ in
|
||||||
};
|
};
|
||||||
passthru.updateScript = writeScript "update-matrix-media-repo" ''
|
passthru.updateScript = writeScript "update-matrix-media-repo" ''
|
||||||
${../../scripts/update-git.sh} "https://github.com/turt2live/matrix-media-repo" matrix/matrix-media-repo/source.json
|
${../../scripts/update-git.sh} "https://github.com/turt2live/matrix-media-repo" matrix/matrix-media-repo/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
if [ "$(git diff -- matrix/matrix-media-repo/source.json)" ]; then
|
||||||
${../../scripts/update-go.sh} ./matrix/matrix-media-repo matrix/matrix-media-repo/vendor.sha256
|
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
||||||
|
${../../scripts/update-go.sh} ./matrix/matrix-media-repo matrix/matrix-media-repo/vendor.sha256
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,9 @@ in
|
||||||
};
|
};
|
||||||
passthru.updateScript = writeScript "update-matrix-media-repo" ''
|
passthru.updateScript = writeScript "update-matrix-media-repo" ''
|
||||||
${../../scripts/update-git.sh} "https://github.com/mautrix/discord" matrix/mautrix-discord/source.json
|
${../../scripts/update-git.sh} "https://github.com/mautrix/discord" matrix/mautrix-discord/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
if [ "$(git diff -- matrix/mautrix-discord/source.json)" ]; then
|
||||||
${../../scripts/update-go.sh} ./matrix/mautrix-discord matrix/mautrix-discord/vendor.sha256
|
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
||||||
|
${../../scripts/update-go.sh} ./matrix/mautrix-discord matrix/mautrix-discord/vendor.sha256
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,7 +29,9 @@ in
|
||||||
};
|
};
|
||||||
passthru.updateScript = writeScript "update-mautrix-whatsapp" ''
|
passthru.updateScript = writeScript "update-mautrix-whatsapp" ''
|
||||||
${../../scripts/update-git.sh} "https://github.com/mautrix/whatsapp" matrix/mautrix-whatsapp/source.json
|
${../../scripts/update-git.sh} "https://github.com/mautrix/whatsapp" matrix/mautrix-whatsapp/source.json
|
||||||
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
if [ "$(git diff -- matrix/mautrix-whatsapp/source.json)" ]; then
|
||||||
${../../scripts/update-go.sh} ./matrix/mautrix-whatsapp matrix/mautrix-whatsapp/vendor.sha256
|
SRC_PATH=$(nix-build -E '(import ./. {}).${pname}.src')
|
||||||
|
${../../scripts/update-go.sh} ./matrix/mautrix-whatsapp matrix/mautrix-whatsapp/vendor.sha256
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
Reference in a new issue