BodhiThis forum is for the discussion of Bodhi Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Yes, but it sounds like you have done that already. The problem with doing it that way is you cannot see if any errors occur because the terminal just goes away once the script exits, as you have discovered.
.sh files are scripts. I thought that scripts had to have at the beginning of the file #!/bin/bash. If this is req'd and not in the file,
it will not execute. sounds as if you have gone thru the steps req'd, but I think that this beginning tells the system where to
find the shell.
.sh files are scripts. I thought that scripts had to have at the beginning of the file #!/bin/bash. If this is req'd and not in the file,
No, it is only required if you want a specific shell to execute the script.
Normally the shell will start a child of ITSELF to execute it.
And anyway, a lot of scripts use /bin/sh instead of bash (especially in Debian, where /bin/sh makes a script startup much faster as they're using dash (the Debian Almquist SHell) for it instead of bash.
BTW, you need to tell that script is for executing.
chmod +x scriptname.sh
then run it
./scriptname.sh
Just for a record:
Doubleclick is also possible. You have to create a personal launcher with a name. This will create a personalname.desktop and then you can add the exec part with the script name. Then just run it from quick launcher or put it on the screen. But I also share the idea you need to do this only once in terminal. No need to make it repeatedly.
Stefan
Last edited by the_waiter; 05-18-2019 at 03:47 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.