Link to home
Start Free TrialLog in
Avatar of StephenMcGowan
StephenMcGowan

asked on

.profile on mac

Hi,

I have edited my .profile file in my home directory of Terminal. But have entered an incorrect path.

i.e.

Last login: Fri Jul  3 12:36:45 on console
-bash: export: `directory?]:/usr/local/mysql:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin': not a valid identifier
stephen-mcgowans-macbook-pro:~ stevey_mac2k2$ ls
-bash: ls: command not found
stephen-mcgowans-macbook-pro:~ stevey_mac2k2$ pwd
/Users/stevey_mac2k2
stephen-mcgowans-macbook-pro:~ stevey_mac2k2$ ls
-bash: ls: command not found
stephen-mcgowans-macbook-pro:~ stevey_mac2k2$ cd /
stephen-mcgowans-macbook-pro:/ stevey_mac2k2$ ls
-bash: ls: command not found
stephen-mcgowans-macbook-pro:/ stevey_mac2k2$ suod -s
-bash: suod: command not found
stephen-mcgowans-macbook-pro:/ stevey_mac2k2$ ls
-bash: ls: command not found
stephen-mcgowans-macbook-pro:/ stevey_mac2k2$ sudo -s
-bash: sudo: command not found
stephen-mcgowans-macbook-pro:/ stevey_mac2k2$ pico .profile
-bash: pico: command not found

Is there any way of getting into .profile and editing it?

Also if i want to change $PATH to usr/local/mysql how would i go about this... as i have done it incorrectly the first time round.

My echo $PATH currently reads:
/usr/local/mysql



Thanks.


Avatar of StephenMcGowan
StephenMcGowan

ASKER

Since then i've found that the command line:

stephen-mcgowans-macbook-pro:~ stevey_mac2k2$ export PATH=/usr/local/mysql:$PATH

does not come back with "command not found"

i've tried fixing the path in my command line to bring back my commands, but the directory above doesn't seem to be working.

i have also tried lines such as:

stephen-mcgowans-macbook-pro:~ stevey_mac2k2$ export PATH=/usr/local/mysql:
stephen-mcgowans-macbook-pro:~ stevey_mac2k2$ export PATH=/usr/local/mysql

but to no avail.

Is there any way of me retrieving my unix commands back in Terminal?

thanks.

ASKER CERTIFIED SOLUTION
Avatar of strung
strung
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial