2019-11-19 18:17:13 +00:00
|
|
|
{ appimageTools, fetchurl, lib, runCommandNoCC, stdenv, gsettings-desktop-schemas, gtk3, zlib }:
|
2019-02-13 05:27:58 +00:00
|
|
|
|
|
|
|
let
|
|
|
|
name = "${pname}-${version}";
|
2019-11-19 18:17:13 +00:00
|
|
|
pname = "minetime";
|
2019-12-05 19:48:22 +00:00
|
|
|
version = "1.7.3";
|
2019-11-19 18:17:13 +00:00
|
|
|
appimage = fetchurl {
|
|
|
|
url = "https://github.com/marcoancona/MineTime/releases/download/v${version}/${name}.AppImage";
|
2019-12-05 19:48:22 +00:00
|
|
|
sha256 = "0zz6p3mwxg9gm1sqzs582pq2nkb10lv0c3r542b9llqyzk9qv5aa";
|
2019-11-19 18:17:13 +00:00
|
|
|
};
|
|
|
|
extracted = appimageTools.extractType2 {
|
|
|
|
inherit name;
|
|
|
|
src = appimage;
|
2019-02-13 05:27:58 +00:00
|
|
|
};
|
2019-11-19 18:17:13 +00:00
|
|
|
patched = runCommandNoCC "minetime-patchelf" {} ''
|
|
|
|
cp -av ${extracted} $out
|
|
|
|
|
|
|
|
x=$out/resources/app.asar.unpacked/services/scheduling/dist/MinetimeSchedulingService
|
|
|
|
chmod +w $x
|
|
|
|
|
|
|
|
patchelf \
|
|
|
|
--set-interpreter ${stdenv.cc.bintools.dynamicLinker} \
|
|
|
|
--replace-needed libz.so.1 ${zlib}/lib/libz.so.1 \
|
|
|
|
$x
|
|
|
|
'';
|
|
|
|
in
|
|
|
|
appimageTools.wrapAppImage rec {
|
|
|
|
inherit name;
|
|
|
|
src = patched;
|
2019-02-13 05:27:58 +00:00
|
|
|
|
|
|
|
profile = ''
|
2019-04-24 02:43:04 +01:00
|
|
|
export LC_ALL=C.UTF-8
|
|
|
|
export XDG_DATA_DIRS=${gsettings-desktop-schemas}/share/gsettings-schemas/${gsettings-desktop-schemas.name}:${gtk3}/share/gsettings-schemas/${gtk3.name}:$XDG_DATA_DIRS
|
2019-02-13 05:27:58 +00:00
|
|
|
'';
|
|
|
|
|
2019-04-24 02:43:04 +01:00
|
|
|
multiPkgs = null; # no 32bit needed
|
2019-11-19 18:17:13 +00:00
|
|
|
extraPkgs = ps:
|
|
|
|
appimageTools.defaultFhsEnvArgs.multiPkgs ps
|
|
|
|
++ (with ps; [ at-spi2-core at-spi2-atk libsecret libnotify ]);
|
2019-04-24 02:43:04 +01:00
|
|
|
extraInstallCommands = "mv $out/bin/{${name},${pname}}";
|
|
|
|
|
2019-02-13 05:27:58 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Modern, intuitive and smart calendar application";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://minetime.ai";
|
2019-02-13 05:27:58 +00:00
|
|
|
license = licenses.unfree;
|
|
|
|
# Should be cross-platform, but for now we just grab the appimage
|
|
|
|
platforms = [ "x86_64-linux" ];
|
|
|
|
maintainers = with maintainers; [ dtzWill ];
|
|
|
|
};
|
|
|
|
}
|