Sublime is Simple and free to use, Light on memory, and can easily work with multiple projects. In this article, we will see how to use the terminal in a sublime text editor.
This will help you on Windows and Linux/Ubuntu as well.
There are super easy 5 steps to add terminal or command line access in the sublime.
-
- Step 1:Β Open Sublime Text
- Step 2: Install Pakage and Terminus
- Step 3: Update Default sublime Commands Section
- Step 4: Update Default sublime Keymap Section
- Step 5: Access terminal or command prompt
Lets start with the stepwise implementation..
Stepwise implementation:
Step 1:Β Open Sublime Text
Step 2: Install Pakage and Terminus
Open Command Palette using command Ctrl+shift+p
Type the below until the option appears and select it.
Package Control: Install Package
Note:Β Youβll need to install package control if you are using it for the first time.
Type βTerminusβΒ and select it. Wait for it to Complete installation and Restart sublime text.
Step 3: Update Default sublime Commands Section
Now go toΒ Preferences >Package Settings > Terminus > Command Palette
Now paste this code in the Default sublime Commands Section
[ { "caption": "Terminal (panel)", "command": "terminus_open", "args" : { "cmd": "bash", "cwd": "${file_path:${folder}}", "title": "Command Prompt", "panel_name": "Terminus" } }, ]
And save it.
Note:Β The above code is for Linux users for Windows users you have to enterΒ βcmd.exeβΒ in place ofΒ βbashβ
Step 4: Update Default sublime Keymap Section
Now go toΒ Preferences >Package Settings > Terminus > Key Bindings
Now paste this code in the Default sublime Keymap Section and save it:
[ { "keys": ["alt+1"], "command": "terminus_open", "args" : { "cmd": "bash", "cwd": "${file_path:${folder}}", "panel_name": "Terminus" } } ]
Note:Β The above code is for Linux users for Windows users you have to enterΒ βcmd.exeβΒ in place ofΒ βbashβ, also here we kept the shortcut key as βalt+1β you can use your own key.
Step 5: Access terminal or command prompt
So whenever you want to use terminal pressΒ alt+1Β and to close terminal type exit in the terminal and hit enter.
Isn’t it super easy. Do comment below giving your valuable feedback. I would love to hear from you.
You can watch this video below:
Powered by Embed YouTube Video
Happy Learning !!
Thank You !!
Very helpful your advies to sublime and terminus