On 10Jul2013 15:52, highsky...@yahoo.de <highsky...@yahoo.de> wrote: | > | What directory should I use for own files? | > | > Normally, $HOME/bin. So: | > - log in | > - type "pwd" to check that you are in you home directory | > - type "mkdir bin" to create a directory called "bin" in your home | > directory | * | Is it better for not confuse myself to name it mybin | ?
Your call. But since it is in your home directory, it should already be obvious that it is for you. | > Then you need to put $HOME/bin into your $PATH. | > | > You can do this by running the command: | > | > PATH=$PATH:$HOME/bin | > export PATH | * | Thank You. | | Then Linux is searching | when I give comand like dothisnow | in the | directory | bin or mybin | for | dothisnow.sh. | | ? No. It searches for an executable file named "dothisnow". Windows does that oddball "add an extension". In UNIX, what you type is what is looked for. Normally you do not end _commands_ in an extension saying what the language is. Instead, for scripts the leading shebang line: #!/bin/sh tells the kernel what program will be used to run the script. So you make a script and store it as "/home/user1/bin/dothisnow". It starts with the line: #!/bin/sh When you issue the command "dothisnow a b c", if the kernel finds your script it will execute the actual command: /bin/sh /home/user1/bin/dothisnow a b c getting the "/bin/sh" from the first line of the script. In this way you can write scripts in different languages depending on your needs, and make them up so that the kernel knows how to run them. As another example, a Python script would normally have a shebang line like: #!/usr/bin/python | > That does it only for the shell you ran it in. | * | This does mean | I close the terminal | and Linux will forget it. Yes. Cheers, -- Cameron Simpson <c...@zip.com.au> The punishment which the wise suffer who refuse to take part in government is to live under the government of worse men. - Plato ------------------------------------ To unsubscribe from this list, please email linux_newbies-unsubscr...@yahoogroups.com & you will be removed.Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/LINUX_Newbies/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/LINUX_Newbies/join (Yahoo! ID required) <*> To change settings via email: linux_newbies-dig...@yahoogroups.com linux_newbies-fullfeatu...@yahoogroups.com <*> To unsubscribe from this group, send an email to: linux_newbies-unsubscr...@yahoogroups.com <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/