2019-03-14 02:43:50 +01:00
|
|
|
{ stdenv, fetchFromGitHub, writeText }:
|
2015-02-07 21:20:53 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-03-06 13:40:22 +01:00
|
|
|
pname = "limesurvey";
|
2019-08-24 14:15:13 +02:00
|
|
|
version = "3.17.12+190823";
|
2015-02-07 21:20:53 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "LimeSurvey";
|
|
|
|
repo = "LimeSurvey";
|
|
|
|
rev = version;
|
2019-08-24 14:15:13 +02:00
|
|
|
sha256 = "1i7jpxndrbya5ggl4babscwzmxx4c0jwri5kpl7h2ihqrn90m4b5";
|
2015-02-07 21:20:53 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
phpConfig = writeText "config.php" ''
|
|
|
|
<?php
|
|
|
|
return require(getenv('LIMESURVEY_CONFIG'));
|
|
|
|
?>
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
2019-08-24 14:15:13 +02:00
|
|
|
runHook preInstall
|
|
|
|
|
2019-03-14 02:43:50 +01:00
|
|
|
mkdir -p $out/share/limesurvey
|
|
|
|
cp -r . $out/share/limesurvey
|
2015-02-07 21:20:53 +01:00
|
|
|
cp ${phpConfig} $out/share/limesurvey/application/config/config.php
|
2019-08-24 14:15:13 +02:00
|
|
|
|
|
|
|
runHook postInstall
|
2015-02-07 21:20:53 +01:00
|
|
|
'';
|
|
|
|
|
2019-03-14 02:43:50 +01:00
|
|
|
meta = with stdenv.lib; {
|
2015-02-07 21:20:53 +01:00
|
|
|
description = "Open source survey application";
|
|
|
|
license = licenses.gpl2;
|
2019-03-14 02:43:50 +01:00
|
|
|
homepage = "https://www.limesurvey.org";
|
2015-02-07 21:20:53 +01:00
|
|
|
maintainers = with maintainers; [offline];
|
2016-08-02 19:50:55 +02:00
|
|
|
platforms = with platforms; unix;
|
2015-02-07 21:20:53 +01:00
|
|
|
};
|
|
|
|
}
|