homerjj Posted September 7, 2005 Report Share Posted September 7, 2005 (edited) Hi , i have a problem with ANT. when i try to run it from root i get a "bash: ant: command not found 2 message but when i run it from normal mode it's fine. i have the following entry in my .bashrc file, where am i going wrong? export PATH="$PATH:/usr/local/apache-ant-1.6.5/bin:." . Edited September 7, 2005 by homerjj Quote Link to comment Share on other sites More sharing options...
ramfree17 Posted September 7, 2005 Report Share Posted September 7, 2005 (edited) is that entry in your bashrc file already existing when you started the terminal wherein the error occurs? if not then you have source it again so the changes will take effect. $ . $HOME/.bashrc if it was present then it probably is a permission problem. check the following: - make sure that /usr/local/apache-ant-1.6.5/bin exists. - make sure that /usr/local/apache-ant-1.6.5/bin and all its parent directories have read and execute permission for your current user. - make sure that the binaries/executables in /usr/local/apache-ant-1.6.5/bin are executable by your user. and for good measure define a "ANT_HOME" variable that points to "/usr/local/apache-ant-1.6.5/bin". one last thing, remove that trailing period on your path. it is a security risk and prepending your command with "./" (if they reside on the current directory) is good practice to make you subconciously aware that the command you are executing are where they are supposed to be. ciao! Edited September 7, 2005 by ramfree17 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.