summary refs log tree commit diff
path: root/pkgs/applications/office/treesheets/default.nix
blob: d316d42870728bdefb67bcd61246f5ab4ee4761f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
{ stdenv, fetchFromGitHub, wxGTK, makeWrapper }:

stdenv.mkDerivation rec {
  pname = "treesheets";
  version = "1.0.1";

  src = fetchFromGitHub {
    owner  = "aardappel";
    repo   = "treesheets";
    rev    = "v${version}";
    sha256 = "0krsj7i5yr76imf83krz2lmlmpbsvpwqg2d4r0jwxiydjfyj4qr4";
  };

  buildInputs = [ wxGTK makeWrapper ];

  preConfigure = "cd src";

  postInstall = ''
    mkdir "$out/share" -p
    cp -av ../TS "$out/share/libexec"

    mkdir "$out/bin" -p
    makeWrapper "$out/share/libexec/treesheets" "$out/bin/treesheets"

    mkdir "$out/share/doc" -p

    for f in readme.html docs examples
    do
      mv -v "$out/share/libexec/$f" "$out/share/doc"
      ln -sv "$out/share/doc/$f" "$out/share/libexec/$f"
    done

    mkdir "$out/share/applications" -p
    mv -v "$out/share/libexec/treesheets.desktop" "$out/share/applications"
    substituteInPlace "$out/share/applications/treesheets.desktop" \
      --replace "Icon=images/treesheets.svg" "Icon=$out/share/libexec/images/treesheets.svg"
  '';

  meta = with stdenv.lib; {
    description = "Free Form Data Organizer";

    longDescription = ''
      The ultimate replacement for spreadsheets, mind mappers, outliners,
      PIMs, text editors and small databases.

      Suitable for any kind of data organization, such as Todo lists,
      calendars, project management, brainstorming, organizing ideas,
      planning, requirements gathering, presentation of information, etc.
    '';

    homepage    = "http://strlen.com/treesheets/";
    maintainers = with maintainers; [ obadz avery ];
    platforms   = platforms.linux;
    license     = licenses.zlib;
  };
}