How to run command on start up?


#1

Hi im trying to learn how to run command: “xset led on” because my keyboard needs to be backlit but I don’t want to type this command everytime I run Xubutunu on vm. Is there a way to run when I start up Xubuntu?


#2

Create an empty file in desktop and name it script.sh
Type in the command
The inside of script.sh should just contain:
xset led on

Open up your terminal and type the following commands
$ cd Desktop
$ chmod +x script.sh
Close terminal

Then go to Settings and find the program “Session and Startup”
Click the tab “Application Autostart”
Click Add
Set the name as “start script”
Set the command as the path to script.sh, in my case it was /home/user/Desktop/script.sh

Restart Xubuntu and it should hopefully work


#3

Nice, works perfectly! Thanks!