nixpkgs/pkgs/servers/web-apps/restya-board/default.nix
Profpatsch 4a7f99d55d treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
2021-01-11 10:38:22 +01:00

50 lines
1.2 KiB
Nix

{ lib, stdenv, fetchurl, unzip }:
let
hide-card-id = fetchurl {
url = "https://github.com/RestyaPlatform/board-apps/releases/download/v2/r_hide_card_id-v0.1.2.zip";
sha256 = "1scm696rs8wx0z2y0g6r9vf01b0yay79azw8n785c6zdvrbqw7dp";
};
togetherjs = fetchurl {
url = "https://github.com/RestyaPlatform/board-apps/releases/download/v2/r_togetherjs-v0.1.2.zip";
sha256 = "1kms7z0ci15plwbs6nxvz15w0ym3in39msbncaj3cn0p72kvx5cm";
};
in
stdenv.mkDerivation rec {
pname = "rstya-board";
version = "0.6";
src = fetchurl {
url = "https://github.com/RestyaPlatform/board/releases/download/v${version}/board-v${version}.zip";
sha256 = "1js8c69qmga7bikp66fqhch3n2vw49918z32q88lz3havqzai8gd";
};
nativeBuildInputs = [ unzip ];
buildCommand = ''
mkdir $out
unzip -d $out $src
cd $out
patch -p1 < ${./fix_request-uri.patch}
chmod +x $out/server/php/shell/*.sh
mkdir $out/client/apps
unzip -d $out/client/apps ${hide-card-id}
unzip -d $out/client/apps ${togetherjs}
'';
meta = with lib; {
description = "Web-based kanban board";
license = licenses.osl3;
homepage = "https://restya.com";
maintainers = with maintainers; [ tstrobel ];
platforms = platforms.linux;
};
}