nixpkgs/pkgs/applications/misc/udiskie/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

109 lines
2.2 KiB
Nix
Raw Normal View History

2021-03-02 21:51:32 +01:00
{ lib
, asciidoc
2021-03-02 21:51:32 +01:00
, fetchFromGitHub
, gobject-introspection
, gtk3
, installShellFiles
2021-03-02 21:51:32 +01:00
, libappindicator-gtk3
, libnotify
, librsvg
, python3
2021-03-02 21:51:32 +01:00
, udisks2
, wrapGAppsHook3
2024-01-27 16:49:08 +01:00
, testers
, udiskie
}:
python3.pkgs.buildPythonApplication rec {
pname = "udiskie";
version = "2.5.2";
pyproject = true;
src = fetchFromGitHub {
owner = "coldfix";
repo = "udiskie";
2021-03-02 21:51:32 +01:00
rev = "v${version}";
hash = "sha256-r9ppuWYY3e2thsfFh4ooOgfqNvmCVw7fS0SpJCJcysQ=";
};
patches = [
./locale-path.patch
];
postPatch = ''
substituteInPlace udiskie/locale.py --subst-var out
'';
2022-01-04 23:37:48 +01:00
nativeBuildInputs = [
asciidoc # Man page
gobject-introspection
installShellFiles
python3.pkgs.setuptools
wrapGAppsHook3
];
dontWrapGApps = true;
buildInputs = [
gtk3
libappindicator-gtk3
2021-03-02 21:51:32 +01:00
libnotify
2022-01-04 23:37:48 +01:00
librsvg # SVG icons
2021-03-02 21:51:32 +01:00
udisks2
];
propagatedBuildInputs = with python3.pkgs; [
docopt
keyutils
pygobject3
pyyaml
];
2022-01-04 23:37:48 +01:00
postBuild = ''
make -C doc
'';
postInstall = ''
installManPage doc/udiskie.8
2023-10-03 19:39:32 +02:00
installShellCompletion \
--bash completions/bash/* \
--zsh completions/zsh/*
'';
preFixup = ''
makeWrapperArgs+=("''${gappsWrapperArgs[@]}")
2019-03-04 00:10:07 +01:00
'';
nativeCheckInputs = with python3.pkgs; [
pytestCheckHook
];
2024-01-27 16:49:08 +01:00
passthru.tests.version = testers.testVersion {
package = udiskie;
};
meta = with lib; {
2021-03-02 21:51:32 +01:00
homepage = "https://github.com/coldfix/udiskie";
changelog = "https://github.com/coldfix/udiskie/blob/${src.rev}/CHANGES.rst";
description = "Removable disk automounter for udisks";
2021-03-02 21:51:32 +01:00
longDescription = ''
udiskie is a udisks2 front-end that allows to manage removeable media such
as CDs or flash drives from userspace.
Its features include:
- automount removable media
- notifications
- tray icon
- command line tools for manual un-/mounting
- LUKS encrypted devices
- unlocking with keyfiles (requires udisks 2.6.4)
- loop devices (mounting iso archives)
- password caching (requires python keyutils 0.3)
'';
license = licenses.mit;
maintainers = with maintainers; [ AndersonTorres dotlambda ];
};
}