Merge pull request #64687 from pacien/riot-web-config-fix
riot-web: fallback to example config
This commit is contained in:
commit
0394aae7a8
1 changed files with 6 additions and 3 deletions
|
@ -3,7 +3,6 @@
|
|||
# Note for maintainers:
|
||||
# Versions of `riot-web` and `riot-desktop` should be kept in sync.
|
||||
|
||||
let configFile = writeText "riot-config.json" conf; in
|
||||
stdenv.mkDerivation rec {
|
||||
name= "riot-web-${version}";
|
||||
version = "1.2.2";
|
||||
|
@ -13,10 +12,14 @@ stdenv.mkDerivation rec {
|
|||
sha256 = "19nb6gyjaijah068ika6hvk18hraivm71830i9cd4ssl6g5j4k8x";
|
||||
};
|
||||
|
||||
installPhase = ''
|
||||
installPhase = let
|
||||
configFile = if (conf != null)
|
||||
then writeText "riot-config.json" conf
|
||||
else "$out/config.sample.json";
|
||||
in ''
|
||||
mkdir -p $out/
|
||||
cp -R . $out/
|
||||
${lib.optionalString (conf != null) "ln -s ${configFile} $out/config.json"}
|
||||
ln -s ${configFile} $out/config.json
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
|
Loading…
Reference in a new issue