Fetch User Keys - simple tool for fetching SSH keys from various sources
1# SPDX-FileCopyrightText: 2024 Łukasz Niemier <#@hauleth.dev>
2#
3# SPDX-License-Identifier: EUPL-1.2
4{
5 lib,
6 rustPlatform,
7 stdenv,
8 darwin,
9 libiconv,
10 scdoc,
11 pkg-config,
12 openssl,
13}:
14rustPlatform.buildRustPackage {
15 pname = "fuk";
16 version = "0.1.0";
17
18 src = ./..;
19
20 cargoHash = "sha256-a8fK+EBNrv/S7tl3b8f+/01naboI4lcHzEEk6I/35M4=";
21
22 nativeBuildInputs = [scdoc pkg-config];
23
24 preInstall = ''
25 OUT=$out/man cargo xtask
26 '';
27
28 buildInputs =
29 [openssl]
30 ++ lib.lists.optionals stdenv.isDarwin (with darwin.apple_sdk; [
31 frameworks.Foundation
32 frameworks.CoreFoundation
33 frameworks.SystemConfiguration
34 frameworks.Security
35 libiconv
36 ]);
37
38 meta = with lib; {
39 description = "Simple tool for fetching SSH keys from various sources";
40 homepage = "https://git.sr.ht/~hauleth/fuk";
41 mainProgram = "fuk";
42 };
43}