防止创建配置文件 [英] Prevent creation of conffiles
问题描述
我正在尝试构建一个包,该包在 /etc
下有一些不是配置的文件.即使我在 debian
目录中创建了一个空的 package.conffiles
,它们也会自动包含在 conffiles
中.
I'm trying to build a package which has some files under /etc
that are not configuration. They are included in the conffiles
automatically even if I create an empty package.conffiles
in the debian
directory.
如何阻止 dh_installdeb
这样做?
推荐答案
最初,这个答案建议提供您自己的 debian/conffiles
文件,仅列出要安装的实际配置文件.显然,这只用于添加更多配置文件,但不会覆盖整个 conffiles
文件.
Originally, this answer suggested providing your own debian/conffiles
files only listing actual configuration files to be installed. Apparently that only serves to add more configuration files but won't override the whole conffiles
file.
但是,我不明白你为什么想要那个.如果文件不是配置文件,用户将不会编辑它们,因此任何自动配置文件处理都不会妨碍您进行升级.此外,如果它们实际上不是配置文件,我强烈建议将它们简单地安装到/etc 以外的位置,也可以避免您的问题.
However, I can't quite see why you'd even want that. If the files are not configuration files, the user won't edit them, so none of the automatic conffile handling will get in your way on upgrades. Also, if they're not actually config files, I'd highly recommend to simply install them to a place other than /etc, avoiding your issue as well.
这篇关于防止创建配置文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!