3 ms·
> I don't get why we would want to allow packages to run any scripts before/after the installation. That’s because you probably never built a package managemen
by tinus_hn 8y ago
> I don't get why we would want to allow packages to run any scripts before/after the installation.
That’s because you probably never built a package management system. If you limit the package management system to the actions you propose it’s only usable for iOS type apps and that could be useful but then you still need a solution for managing the rest of the system.
- Stammon 8y agoPlease have a look at nix and solaris first. Both are making a compelling case against your answer
- tinus_hn 8y agoSolaris is dead. I looked at Nix and it has postInstall actions which can run arbitrary commands and scripts, so it doesn’t fit the description.
- dtzWill 8y agoYou might have misunderstood "postInstall" -- rather understandably so since elsewhere (debian packages, ...) for precisely the issue discussed in the article: arbitrary scripts executed after package installation. In Nix postInstall (and preInstall, as well as preBuild/postBuild, etc) specifying commands to execute before/after the corresponding "phase" -- so if a package is "almost" good to go with just "make install", you could use postInstall to do something like copy a file omitted by upstream's installation target. The point is that postInstall in Nix is part of how the package itself is constructed-- in contrast to commands run after installing the package. There is no equivalent for this in Nix in a fundamental way (not by policy or for technical reasons).