Friday, 5 June 2015

Creating startup scripts via terminal

Every time believing GUI is not helpful. We can also use GUI tool called "Startup Applications" in Ubuntu. If you run minimal server than GUI tool is not possible to help us.

Now am going to perform startup scripts via terminal
Consider i want to run terminal on system startup.
To do this, open terminal and create a shellscript file by using any text editor. In this i am using Vim. You can use any application or script. Now i am creating startup program for gnome-terminal.


Now, create .desktop file in ~/.config/autostart/ directory.

     $vim ~/.config/autostart/terminal.desktop
      [Desktop Entry]

      Exe= Executable file/script path
      Hidden is set to be true if you want to run the script in visible else we can hide it by set to be false.
       You are running a GUI based script, then it should be set to true else we can set to false
 Now restart the machine, you can able to run script on startup time.

No comments:

Post a Comment