Adding gedit to my PATH

Solution 1:

You only need to add the path to the folder containing the gedit binary, not the path to the binary.

Try this

export PATH=/opt/local/bin:/Applications/gedit.app/Contents/MacOS:/opt/local/sbin:$PATH

Solution 2:

Note: On OS X, you don't need /Application apps to be in the PATH to launch them.

open -a gedit

Check man open