Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialmarcus walta
1,108 Pointsi keep getting an error with subl . it says 'subl' is not a recognized as an internal or external command, operable prog
i keep getting an error with subl . it says 'subl' is not a recognized as an internal or external command, operable program or batch file.
I am on windows... Thoughts on how to fix this?
1 Answer
Bob Sutherton
20,160 PointsIt's been a while since I did this but I'll try to walk you through it. I'm assuming you're using Windows 10. Basically we tell Windows where to find the program. Here's how.
Step one: First, find out the path to that subl.exe thing. For me it looks like this:
C:/Program Files/Sublime Text 3
Step two: In the Cortana "Ask me anything" bar, search for environment variables. It's in the control panel somewhere. Then open that up.
There are two sets of environment variables. The first is for the user and the second is for the system. I actually have this added for both boxes, so I'm not sure which one is better but I'm guessing it doesn't matter a whole lot unless someone else is going to use your computer and need access to the subl
command while logged in as a different user.
Click on new. A window will pop up asking for a variable name and a variable value. I just have the variable name as SUBLIME in all caps. I don't know how much the variable name really matters. For the variable value, add the path from step one.
Click ok. Hopefully, it's working now!
Note: Add the path to the folder only, as I did in step one. This won't work.
C:/Program Files/Sublime Text 3/subl.exe