(Linux Newb) How do i execute shell scripts on linux?


OSNN Senior Addict
How do i run a ".sh" file on linux? How can i compile a ".c" file on linux.

If there are command lines and GUI methods of doing this please tell me both, as i am trying to learn linux.
The C code can be compiled with gcc.

The shell scripts (who won't need a .sh extension because Linux doesn't care about extensions) must have two things:
- First row must be: #!/usr/bin/sh or whatever the path to sh is (or whatever shell you plan to use).
- You must have permission to execute the file. For instance do chmod 755 script-file to set the permissions.

Members online

No members online now.

Latest posts

Latest profile posts

Perris Calderon wrote on Electronic Punk's profile.
Ep, glad to see you come back and tidy up...did want to ask a one day favor, I want to enhance my resume , was hoping you could make me administrator for a day, if so, take me right off since I won't be here to do anything, and don't know the slightest about the board, but it would be nice putting "served administrator osnn", if can do, THANKS

Been running around Quora lately, luv it there https://tinyurl.com/ycpxl
Electronic Punk wrote on Perris Calderon's profile.
All good still mate?
Hello, is there anybody in there? Just nod if you can hear me ...
What a long strange trip it's been. =)

Forum statistics

Latest member