[Bug 255670] Mk/Keywords/sample.ucl: Deleting any configuration files automatically is a bug
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 22 Nov 2021 17:34:19 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=255670 --- Comment #13 from dave@jetcafe.org --- (In reply to Baptiste Daroussin from comment #12) > When I remove a package I don't want any leftovers left behind by default. Ah! This implied policy speaks directly to my issue. :) I think I understand the intent of this code, thank you for that. However, the condition where the package sample file is the same as it's installed configuration file is (at least for the nginx package) created by the person who installed the package. In the case of nginx, for example, the "mime.types-dist" file might be copied to "mime.types". That is a local policy decision, right? Maybe the user has written some other tool that expects that file to be there. Note well that even if the files are the same, the original nginx pkg install does not create a "mime.types" file by default: > pkg info -l nginx | grep mime.types /usr/local/etc/nginx/mime.types-dist > So to create "mime.types", the -dist version of the file might be manually copied by the pkg user, which I believe is a valid use case. Are there packages that actually -do- copy dist files to target files? If so, those would be counter examples. > if we want to do what you want to do we should move this to post-deinstall, then pkg needs to be modified to allow this (which is doable, takes more time and is probably desirable). I'm not very familiar with the distinction between pre-deinstall and post-deinstall, so I'm not immediately understanding why moving the same code to post-deinstall would somehow prevent the case where (using my example above) the mime.types file would not be removed on a pkg upgrade. Are you talking about using my patch in post-deinstall instead of pre-deinstall? -- You are receiving this mail because: You are on the CC list for the bug.