2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, writeText, nixosTests }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "limesurvey";
|
2024-01-25 14:12:00 +00:00
|
|
|
version = "6.4.1+240108";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "LimeSurvey";
|
|
|
|
repo = "LimeSurvey";
|
|
|
|
rev = version;
|
2024-01-25 14:12:00 +00:00
|
|
|
hash = "sha256-Cpf8X6igF7LdRbFihGudFmx/8aY0Kf0BE7jHnEF1DYA=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
phpConfig = writeText "config.php" ''
|
|
|
|
<?php
|
|
|
|
return require(getenv('LIMESURVEY_CONFIG'));
|
|
|
|
?>
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
mkdir -p $out/share/limesurvey
|
|
|
|
cp -r . $out/share/limesurvey
|
|
|
|
cp ${phpConfig} $out/share/limesurvey/application/config/config.php
|
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
passthru.tests = {
|
|
|
|
smoke-test = nixosTests.limesurvey;
|
|
|
|
};
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Open source survey application";
|
2024-06-05 15:53:02 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://www.limesurvey.org";
|
|
|
|
maintainers = with maintainers; [offline];
|
|
|
|
platforms = with platforms; unix;
|
|
|
|
};
|
|
|
|
}
|