# How to have input Java?

**URL:** <https://forum.sublimetext.com/t/how-to-have-input-java/47826>\
**Category:** Technical Support\
**Created:** [November 17, 2019, 8:49pm UTC](https://forum.sublimetext.com/t/how-to-have-input-java/47826 "2019-11-17T20:49:15Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![LouisLafontaine](https://forum.sublimetext.com/letter_avatar_proxy/v4/letter/l/e47c2d/32.png) [@LouisLafontaine](https://forum.sublimetext.com/u/LouisLafontaine)\
**Post date:** [November 17, 2020, 3:10pm UTC](https://forum.sublimetext.com/t/how-to-have-input-java/47826/7 "2020-11-17T15:10:06Z")

</div>

[SOLUTION]

I have recently found the solution suiting to my needs, so here’s a step by step :

1. Install [Package Control](https://packagecontrol.io) if you haven’t already
2. Install [Terminus](https://packagecontrol.io/packages/Terminus)  
2.1. To do so open the palette, press ctrl _+_ shift _+_ p (Win, Linux) or cmd _+_ shift _+_ p (Mac)  
2.2 Type in `Package Controll: InstalThis text will be hiddenl Package` then select with enter  
2.3 Type in Terminus then select with enter
3. In the top menu bar go to Tools \> Build Systems \> New Build System
4. It should have opened a new file untitled.sublime-build, erase all its content and paste :  
{  
“target”: “terminus\_exec”,  
“cancel”: “terminus\_cancel\_build”,  
“shell\_cmd”: “javac $file && java $file\_base\_name”  
}
5. Save this file under any name like : RunJava.sublime-build
6. Now to compile and execute you just have to go to the top menu bar again, go to Tools \> Build Systems, and select the build system RunJava. Then with cmd+B (mac) or crtl+B (win) it should open a console within Sublime Text 3 where the result of your code is displayed, and best of all, u can use input with this console !
7. Celebrate !

---

_[View the full topic](https://forum.sublimetext.com/t/how-to-have-input-java/47826)._
