简体   繁体   English

XServer启动后运行shell脚本吗?

[英]Run shell script after XServer is started?

How to run shell script when XServer is started and lightdm also. 启动XServer以及lightdm时如何运行shell脚本。 I tried with init.d and rc.local in /etc directory, but my script is calling an gui application so that the reason I need to run it after XServer is started. 我尝试在/ etc目录中使用init.d和rc.local,但是我的脚本正在调用gui应用程序,因此启动XServer后需要运行它的原因。

I am using Debian Jessie. 我正在使用Debian Jessie。

According to this link .xinitrc in your home directory will be read and executed, otherwise the default /etc/X11/xinit/xinitrc is used. 根据此链接 ,将读取并执行主目录中的.xinitrc,否则将使用默认的/etc/X11/xinit/xinitrc So you should be able to create this file and have the shell script started. 因此,您应该能够创建此文件并启动Shell脚本。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM