msmtp: specify that msmtpq is a wrapper

Consider this Nix expression:

  let
    pkgs = import /path/to/nixpkgs { };
  in pkgs.binlore.collect {
    drvs = [ pkgs.msmtp ];
  }

Building that expression will allow you to inspect the binlore for
msmtp. Before this change, the lore said that msmtpq might be able to
execute its arguments. It would be more correct to say that msmtpq can
run its arguments because msmtpq forwards most of its arguments to
msmtp [1] and msmtp can run its arguments [2].

This commit makes sure that the msmtp package’s lore declares that the
msmtpq command is a wrapper for the msmtp command. This way, anything
that accesses msmtpq’s lore will know that msmtpq has the same verdict
as msmtp.

[1]: <https://github.com/marlam/msmtp/blob/msmtp-1.8.26/scripts/msmtpq/msmtpq#L301>
[2]: <https://marlam.de/msmtp/msmtp.html#index-_002d_002dpasswordeval>
This commit is contained in:
Jason Yundt
2024-09-22 18:51:15 -04:00
parent bb8884d3b7
commit 1d3fd9f92d
@@ -21,6 +21,8 @@
, systemd
, withScripts ? true
, gitUpdater
, binlore
, msmtp
}:
let
@@ -139,6 +141,12 @@ if withScripts then
paths = [ binaries scripts ];
passthru = {
inherit binaries scripts src;
# msmtpq forwards most of its arguments to msmtp [1].
#
# [1]: <https://github.com/marlam/msmtp/blob/msmtp-1.8.26/scripts/msmtpq/msmtpq#L301>
binlore.out = binlore.synthesize msmtp ''
wrapper bin/msmtpq bin/msmtp
'';
updateScript = gitUpdater { rev-prefix = "msmtp-"; };
};
} else binaries