script wont work?
-hello guys i wrote a script containing this line
Quote:
|
Is your bin directory in your path (type echo $PATH)? Is the file executable (type ls -l /home/yourusername/bin/scriptname)? Do you have something like #!/bin/sh as the first line of the script? What do you get when you type ls -l /usr/local/squid/sbin/squid? Does your user account have permissions to the /usr/local/squid/sbin directory?
Sorry it's just a lot of questions... :) |
Code:
cd your-bin-directory-in-your-home-directory The above sequence will only change PATH in your current bash session, e.g. if you run other instance of bash you will need to set it again. To place your directory in PATH in all new bash sessions for all users, enlist it in the /etc/profile file in the export command. Or you can simply add this code to your ~/.bash_profile, which runs only for you. |
To find out, how bash works, try man bash
Use '/' for searching, 'n' to go to the next result, and 'h' for help on other browsing functions. Have fun |
- i tried putting my bin directory into the PATH using
Quote:
Quote:
|
If you're using bash as your shell, you should be able to put the following in ~/.bash_profile:
Code:
export PATH=$PATH:~/bin |
See my post ^^
you should put it in the /etc/profile for all users (it executes first) OR in ~/.bash_profile only for you |
-this is my echo $PATH
Quote:
Quote:
Quote:
Quote:
-i think i will try manually editing my .bash_profile this is its content: Quote:
Quote:
Quote:
|
I'd use:
Code:
export PATH=$PATH:/home/administrator/bin |
All times are GMT -5. The time now is 11:54 PM. |