14

I am trying to open the content of a directory using text mate by mate . command.

But, I am getting the message :

-bash: mate: command not found

I tried the following command to fix it :

ln -s /Applications/TextMate.app/Contents/SharedSupport/Support/bin/mate /usr/local/bin/mate

but, unfortunately this did not do the trick for me. It gives me the message :

ln: /usr/local/bin/mate: File exists

How to fix this problem ?

2
  • Try apple.stackexchange.com.
    – trojanfoe
    Aug 15, 2013 at 17:46
  • Check what the existing /usr/local/bin/mate file is; and them rm it. You should be able to run your ln -s command afterward.
    – user2062950
    Aug 26, 2013 at 19:18

5 Answers 5

16

For me TextMate shell command was not installed that is why i was getting this error. To fix this, go to TextMate preferences, click on Terminal icon then click on 'install' shell command if it's not already installed (if it's already installed you will get option to 'uninstall').

13
ln -s /Applications/TextMate.app/Contents/SharedSupport/Support/bin/mate /usr/local/bin/mate 

worked for me after installing a MAC 10.9

2
  • This doesn't work with TextMate version 2 and macOS Hight Sierra Mar 20, 2018 at 19:39
  • For newer versions, see user2299985's answer.
    – mommi84
    May 14, 2018 at 15:14
9

You can install the shell support in TextMate menu by the following steps:

Textmate -> Preference -> Terminal -> Install

enter image description here

1
4
ln -s /Applications/TextMate.app/Contents/Resources/mate /usr/local/bin/mate

works for mate 2.10

1

Make sure /usr/local/bin is on your $PATH.

Your Answer

Reminder: Answers generated by Artificial Intelligence tools are not allowed on Stack Overflow. Learn more

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.