How to Setup MavensMate in Sublime Text

Sublime Text is a sophisticated text editor for code, markup and prose.You’ll love the slick user interface, extraordinary features and amazing performance. Its very light weight and simple. If you are using eclipse for coding but after that reading post you would like to code with ST.

Take advantage of Sublime Text features like code assist, quick find, etc. when building your Force.com applications.

Download:
Sublime Text 2
Sublime Text 3

Setup :

A. Install the ST on you machine.

B. After installing open it.

C. Install Package Control :
1. Go on View > Show Console menu.
2. If you are using ST v3 then copy paste this script in console : (For more help go here)

import urllib.request,os,hashlib; h = 'eb2297e1a458f27d836c04bb0cbaf282' + 'd0e7a3098092775ccb37ca9d6b2e4b7d'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path(); urllib.request.install_opener( urllib.request.build_opener( urllib.request.ProxyHandler()) ); by = urllib.request.urlopen( 'http://packagecontrol.io/' + pf.replace(' ', '%20')).read(); dh = hashlib.sha256(by).hexdigest(); print('Error validating download (got %s instead of %s), please try manual install' % (dh, h)) if dh != h else open(os.path.join( ipp, pf), 'wb' ).write(by)

For ST v2

import urllib2,os,hashlib; h = 'eb2297e1a458f27d836c04bb0cbaf282' + 'd0e7a3098092775ccb37ca9d6b2e4b7d'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path(); os.makedirs( ipp ) if not os.path.exists(ipp) else None; urllib2.install_opener( urllib2.build_opener( urllib2.ProxyHandler()) ); by = urllib2.urlopen( 'http://packagecontrol.io/' + pf.replace(' ', '%20')).read(); dh = hashlib.sha256(by).hexdigest(); open( os.path.join( ipp, pf), 'wb' ).write(by) if dh == h else None; print('Error validating download (got %s instead of %s), please try manual install' % (dh, h) if dh != h else 'Please restart Sublime Text to finish installation')

D. Install MavensMate :
1. Go on Preferences > Package Control.
2. A window will opens, type install package and click on Package Control:Install Package

install package
3. After it a window will popup again. Type MavensMate and click on it. It will start downloading MavensMate. It takes few minutes.

Install Mavens Mate
4. After installing MavensMate, a new menu will appears.

Mavens Mate Menu

E. Install MavensMate Latest Api :
1. Go on MavensMate > MavensMate API (mm) > Install MavensMate API (mm) version….
2. Click on latest version and it will take time to install.

Mavens Mate API

F. Setup Directories :
1. Go on MavensMate > Settings > User.
2. Go on MavensMate > Settings > Default.
3. We have to setup dir in both files.
Find out “mm_workspace” : “”,
Put you dir here like if your dir is E:\ST then type it will be :
“mm_workspace” : “E:\/\/ST”,

Do same things for both files and save both files.

G. Now Restart you Machine.

H. Setup Salesforce Projects :
1. Open ST and Go on MavensMate > Project > New Project.
2. It will opens a tab in browser.

Mavens Mate Project
3. Fill Info of project here.
Note : In the password box , password must be password+Security Token
Like if password is test123 and security key is asdfghjkkblvls then put both together test123asdfghjkkblvls

NOTE : If you are getting Error 5: Access is denied error , please turn off your firewall or disable your antivirus. In my case i removed my McAfee.

All Setup ?

Cheers!!!

Advertisements

10 thoughts on “How to Setup MavensMate in Sublime Text

  1. Thanks for the walkthrough, very helpful as a new developer!

    Having trouble with the final steps surrounding creating a new Project? I’ve verified the correct login details but no matter what, I receive an error saying it’s “Unable to read project”. Any advice?

    Like

  2. Hi I have installed mm as you described the process. I have set the default browser to chrome. Now it says unable to read the project and u say ok, it opens a editor. Now in the editor, under mavensmate I could only find open project, new project, metadata shows classes and triggers but nothing opens. Please help

    Like

  3. Hi Visnu ,
    Thanks a lot for this post and it is very helpful.I am getting one exception in setup as below.

    Can you please help me .
    [
    “C:\\Users\\user\\Documents”
    ]
    “mm_workspace” : “D:\/\/sublimetext”,

    I paste like this in mavenmate but getting one exception unable to update maven mate.

    Please help me on this , many thanks in advance.

    Regards
    Sumi

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s