Pierre Neidhardt <m...@ambrevar.xyz> skribis: > Ludovic Courtès <l...@gnu.org> writes:
[...] >> The daemon could have a special RPC: you give it a file name and it >> returns a store item (or package+version?) or #f. > > I think you meant "store itemS" (plural), no? Yes. >> Internally it’d call ‘guix substitute’ to fetch the file index from >> the substitute server, check its signature, cache it locally, and then >> look up the file. >> >> You should look at how NixOS does it for its ‘command-not-found’ support >> (I think it’s part of NixOS, not Nix). IIRC they distribute an SQLite >> database, but it’s a pretty ad-hoc mechanism without authentication. > > I could work on this, but that seems like a lot of work, especially for > me who knows nothing about the daemon (but hey, it's a great opportunity > to learn!). Note that the daemon would act as an intermediary, but in practice the functionality would be very much peripheral to the daemon. IOW, you don’t need to know about the daemon internals. Ludo’.