• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

Recommended text editor for writing Java

 
Ranch Hand
Posts: 42
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I just finished my first java command line program. I have come to appreciate the limitations of wordpad and notepad when editing Java code. I would like some recommendations for a text editor that will produce clean code, with line numbers . Auto formatting would be a plus but is not necessary.  I am NOT looking for an IDE. I have used Netbeans and am not yet ready to resume that path.
 
Sheriff
Posts: 67752
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Perhaps you should check out Sublime Text.
 
Bartender
Posts: 1868
81
Android IntelliJ IDE MySQL Database Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Maybe try Visual Studio Code, which you can read about here https://en.wikipedia.org/wiki/Visual_Studio_Code.
Visual Studio Code is not an IDE, it's only a source code editor according to Wikipedia.
It's free, cross platform and can support a variety of different programming languages.

In looking at this once more I came across this posting VS Code versus Atom versus VIM versus  Sublime.
So it is in the same realm as Sublime which was mentioned by Bear previously.
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would say the best IDE would be IntelliJ. There is a community edition available for free and a Ultimate edition that is paid but free to students.

Best text editor? There are plenty of good text editors. My favorite would be Atom.io or Sublime.
 
Greenhorn
Posts: 1
Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

ras oscar wrote:.. I am NOT looking for an IDE ...



Out of curiosity, why? Is there something you dislike about IDEs?
 
Marshal
Posts: 80088
412
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the Ranch , Anthony Voelker and Jericho Brown.

We have an FAQ about editors. You do need an editor which helps with indentation; you will find things so much easier with such formatting aids. Are you using Windows®? If so, I think the best is NotePad++, though I rarely use Windows® and there might be something newer.
 
Bartender
Posts: 2911
150
Google Web Toolkit Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:think the best is NotePad++, though I rarely use Windows® and there might be something newer.


I still use windows. Yes NotePad++ is still the best.
 
Anthony Voelker
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

salvin francis wrote:

Campbell Ritchie wrote:think the best is NotePad++, though I rarely use Windows® and there might be something newer.


I still use windows. Yes NotePad++ is still the best.



better than Atom.io or Sublime....doubful but a text editor is a text editor. They all do similar things just depends what you get comfortable with. Personally, I would rather write code in IntelliJ or Eclipse, but that's just because I am more comfortable with working in those environments.
 
Campbell Ritchie
Marshal
Posts: 80088
412
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
OP specifically asked for a text editor not an IDE.
 
ras oscar
Ranch Hand
Posts: 42
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Jericho Brown wrote:

ras oscar wrote:.. I am NOT looking for an IDE ...



Out of curiosity, why? Is there something you dislike about IDEs?



I have been trying to learn java on my own for a couple years. Worked with the Netbeans interface and continually got lost in my own code. Finally decided to go back to basics and do a few exercises from the command prompt. For me at my present greenhorn status, NetBeans simply removes me too much from the plumbing of java. I speculate I will return to Netbeans eventually, but I want to learn Java first.
 
Ranch Hand
Posts: 67
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

The Big Three are IntelliJ Netbeans and Eclipse


...and IntelliJ is the best.


*ducks*
-
 
Greenhorn
Posts: 19
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Honesty I won't do java development without Eclipse. I find it invaluable in so many ways I can't list them here. It would be hard for me to create and manage a Maven project without Eclipse.
 
Bartender
Posts: 15737
368
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Really? I found that Eclipse has such poor Maven support. Maybe it's gotten better. However, I wonder why you would have issues with managing Maven projects without Eclipse. I think Maven is quite intuitive once you've taken the time to go through the POM reference.
 
Sheriff
Posts: 7126
185
Eclipse IDE Postgres Database VI Editor Chrome Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Stephan van Hulst wrote:I found that Eclipse has such poor Maven support.


Even with the M2E plugin?
 
Saloon Keeper
Posts: 28401
210
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Knute Snortum wrote:

Stephan van Hulst wrote:I found that Eclipse has such poor Maven support.


Even with the M2E plugin?


I'm puzzled about this assertion as well. I work with M2E all the time and it suits me. It even can look into the Maven cache for source code.
 
Marshal
Posts: 5735
347
IntelliJ IDE Python TypeScript Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Conversely, I distrust any IDE to perform Maven and Git tasks reliably. As such I do all my Maven executions from the terminal.
 
Tim Holloway
Saloon Keeper
Posts: 28401
210
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Tim Cooke wrote:Conversely, I distrust any IDE to perform Maven and Git tasks reliably. As such I do all my Maven executions from the terminal.



I have that opinion of the J2EE version of Eclipse and its built-in Tomcat execution. But that's the fault of its WTP plugin. The sysdeo/mongrel plugin can run Tomcat properly.

The m2e plugin doesn't "perform maven tasks". It runs maven itself. It provides a profile template in the Run menu that facilitates Maven command-line options, such as selecting a goal, but Maven is a Java application and the plugin runs it as a Java application. It's quite straightforward. It doesn't screw around with Maven's run environment like the J2EE WTP plugin does with Tomcat.

The same, incidentally, is also true with Ant. git isn't a Java app, and I have found it a bit confusing at times, but then I find often git more than a bit confusing IDE or not.

Maven, in turn loves Eclipse. You can make a Maven project into an eclipse project just by running the command "mvn eclipse:eclipse" and then instructing Eclipse to add it to a workspace. If you're an IntelliJ fan, there's a goal for that as well.
 
Stephan van Hulst
Bartender
Posts: 15737
368
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Knute Snortum wrote:Even with the M2E plugin?


It's been a few years since I last worked with Eclipse, but I always found the M2E plugin crashed a lot and generally provided terrible support. It might have gotten better.

NetBeans' native support for Maven is excellent, but I make sure that I know how to perform everything from the command line as well. Same for tools such as Git.
 
Tim Holloway
Saloon Keeper
Posts: 28401
210
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I never had problems with it myself. But then my favorite way of crashing Eclipse has always involved editing XML files.

If the Maven plugin only ran Maven, that would be good. But it also permits keeping multiple run profiles with differing goals, POM profiles, command-line options, etc. So you can quickly yank them off a menu and run them over and over again.

Plus it's good about incorporating dependencies into the project (both source and class) without requiring manual addition.

I'll admit that sometimes it seems to be mysterious about what it takes to make the light bulb go on, but mostly I think that has to do with the fact that Eclipse project facets are pretty gnarly to begin with.
 
And when my army is complete, I will rule the world! But, for now, I'm going to be happy with this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic