new to linux/Ubuntu/shell scripting . . .
Mike Bird
mgb-ubuntu at yosemite.net
Sun Dec 4 09:16:21 UTC 2005
On Sun, 2005-12-04 at 00:52, Rachael C. wrote:
> For this assignment I installed Ubuntu (onto a spare hard drive I had)
> and have found what I want to put into my little shell script. I used
> a text editor in Ubuntu and saved the file as a .sh. Now my problem
> is trying to run it so as to test it. based on what I have found
> online, I opened Konsole and can do some commands, but still can't get
> the darn thing to run. I have the file I want to run on my desktop,
> and put it in its own folder (has two .txt files, that it will use, in
> the folder with it). I can type "ls" and see the folders desktop and
> workspace, but I can't seem to get into desktop to run the program. I
> have tried different ways of typing the command to go into that folder
> (used this to help me:
> http://www.axisoftime.com/linux/docs/new2unix.html#sect2.3.1), but
> have still no luck with it yet.
You don't need a ".sh" extension, and it's not usual, but it is OK.
Make sure the script is executable (man chmod). Since the dir it's
in is probably not in your path, you'll either have to run it by
"/full/path/to/dir/script" or else "cd /full/path/to/dir" followed
by "./script".
--Mike Bird
More information about the ubuntu-users
mailing list