mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-10-04 19:48:34 +03:00
Merge pull request #336883 from AndrewKvalheim/gcalcli/issue-326353
gcalcli: enable tests
This commit is contained in:
commit
77e2fa9398
@ -1,32 +1,44 @@
|
||||
{ stdenv, lib, fetchFromGitHub, python3
|
||||
, libnotify ? null }:
|
||||
{
|
||||
stdenv,
|
||||
lib,
|
||||
fetchFromGitHub,
|
||||
python3Packages,
|
||||
libnotify,
|
||||
}:
|
||||
|
||||
with python3.pkgs;
|
||||
|
||||
buildPythonApplication rec {
|
||||
python3Packages.buildPythonApplication rec {
|
||||
pname = "gcalcli";
|
||||
version = "4.3.0";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "insanum";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "0s5fhcmz3n0dwh3vkqr4aigi59q43v03ch5jhh6v75149icwr0df";
|
||||
owner = "insanum";
|
||||
repo = "gcalcli";
|
||||
rev = "refs/tags/v${version}";
|
||||
hash = "sha256-roHMWUwklLMNhLJANsAeBKcSX1Qk47kH5A3Y8SuDrmg=";
|
||||
};
|
||||
|
||||
postPatch = lib.optionalString stdenv.isLinux ''
|
||||
substituteInPlace gcalcli/argparsers.py \
|
||||
--replace "'notify-send" "'${libnotify}/bin/notify-send"
|
||||
--replace-fail "'notify-send" "'${lib.getExe libnotify}"
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [
|
||||
python-dateutil gflags httplib2 parsedatetime six vobject
|
||||
google-api-python-client oauth2client uritemplate
|
||||
build-system = with python3Packages; [ setuptools ];
|
||||
|
||||
dependencies = with python3Packages; [
|
||||
python-dateutil
|
||||
gflags
|
||||
httplib2
|
||||
parsedatetime
|
||||
six
|
||||
vobject
|
||||
google-api-python-client
|
||||
oauth2client
|
||||
uritemplate
|
||||
libnotify
|
||||
];
|
||||
|
||||
# There are no tests as of 4.0.0a4
|
||||
doCheck = false;
|
||||
nativeCheckInputs = with python3Packages; [ pytestCheckHook ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "CLI for Google Calendar";
|
||||
|
Loading…
Reference in New Issue
Block a user