我试图创建一个自定义发行版基于Ubuntu使用立方。我已经安装了Plank,当启动到立方提供的vm时,它在使用Try区域屏幕时工作得很好。我已经将一些木板主题文件复制到正确的目录中,但我不知道如何从终端中设置木板的默认主题。
我尝试了以下几点:
gsettings set net.launchpad.plank.dock.settings:/net/launchpad/plank/docks/dock1/ theme 'myiostheme'当我做一个get时,它显示主题已经改变,但是当从live引导时,它显示了默认Plank主题。
如果我能得到任何帮助,我将不胜感激
发布于 2021-10-10 15:46:23
Gsetting在运行时工作。但你需要永久的环境。您可以使用dconf将其应用于立方映像创建,如下所示:
sudo mkdir -p /etc/dconf/profile
cat <<EOF | sudo tee /etc/dconf/profile/user
user-db:user
system-db:local
EOF
sudo mkdir -p /etc/dconf/db/local.d
cat <<EOF | sudo tee /etc/dconf/db/local.d/00-cubic
[net/launchpad/plank/docks/dock1]
theme='Matte'
EOF
sudo dconf update其他可能的方法是为所有用户创建桌面自动启动文件,并将其放入/etc/xdg/autostart中,如下所示:
cat <<EOF | sudo tee /etc/xdg/autostart/plank-theme.desktop
[Desktop Entry]
Name=Set Plank Theme
Comment=Set Plank Theme
Exec="gsettings set net.launchpad.plank.dock.settings:/net/launchpad/plank/docks/dock1/ theme 'myiostheme'"
Terminal=false
NoDisplay=true
Type=Application
EOF它将在登录时执行。
https://askubuntu.com/questions/1368448
复制相似问题