安装后设置文件权限

Set files permission after install

我找到了这个如何构建 deb 包的例子。

http://blog.noizeramp.com/2005/08/31/packaging-java-applications-for-ubuntu-and-other-debians/

我对安装文件后如何设置文件权限感兴趣?

Package: myapp
Version: _version_
Section: web
Priority: optional
Architecture: all
Maintainer: Aleksey Gureev 
Description: my first sample application which isn't
 doing anything special.
 .
 And other description goes
 here too.
 .

你不知道。相反,您在创建包时设置文件权限。

当使用 debhelper 进行打包时,这将类似于 debian/rules 中的以下内容:

override_dh_fixperms:
    dh_fixperms
    find debian -name '*.jar' -exec chmod 0644 {} +

你应该关注 proper Debian packaging tutorial 而不是随机的 10 年前的博文。