Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Pedestrian Xing
Jul 19, 2007

Can't remember who recommended Key Promoter X but it's helped a ton in switching to IntelliJ.

Adbot
ADBOT LOVES YOU

geeves
Sep 16, 2004

Wheany posted:

Intellij pro tip: double tap the shift key, start typing.

If you have a smaller screen and want to save screen space, turn off tabs

Then use CMD-E for most recent files, CMD+O (Classes) and CMD+SHIFT+O (all files) I forget what double-SHIFT opens files or classes.


The big thing about intellij is making sure to exclude what needs and can be excluded. Otherwise you will be in indexing hell every build. It has gotten better about auto-ignoring build, target and node_modules but sometimes doesn't.

The other thing is when importing a project from existing sources, making sure to select build.gradle or pom.xml and let intellij roll with everything else and setup your default environment.

crazysim
May 23, 2004
I AM SOOOOO GAY
I just want to give a shout out to the Help Menu -> Productivity Guide in IntelliJ IDEs. It tracks how often you use some of the productivity features of the IDE and what you haven't used.

Volguus
Mar 3, 2009
I just to give a shout to all of these fantastic people who give great advice on how to use IntelliJ. Ironically, the exact same advice, the exact same words, apply to Eclipse. But no, eclipse is slow and bloated...

carry on then
Jul 10, 2010

by VideoGames

(and can't post for 10 years!)

Volguus posted:

I just to give a shout to all of these fantastic people who give great advice on how to use IntelliJ. Ironically, the exact same advice, the exact same words, apply to Eclipse. But no, eclipse is slow and bloated...

Agreed, Eclipse is offers nothing IntelliJ doesn’t and is slower and larger to boot

Volguus
Mar 3, 2009

carry on then posted:

Agreed, Eclipse is offers nothing IntelliJ doesn’t and is slower and larger to boot

Eclipse offers everything intellij does and more, faster and slimmer and it doesn't ask for $$$ for nothing.

carry on then
Jul 10, 2010

by VideoGames

(and can't post for 10 years!)

Volguus posted:

Eclipse offers everything intellij does and more, faster and slimmer and it doesn't ask for $$$ for nothing.

Prove it

RandomBlue
Dec 30, 2012

hay guys!


Biscuit Hider
People just pay money to Jetbrains for fun. I mean, that's why I do it.

M31
Jun 12, 2012
The Eclipse interface sucks and it has terrible support for JavaScript. I'm more interested in VS Code to be honest.

hooah
Feb 6, 2006
WTF?
The only thing Eclipse does faster in my experience is run jUnit tests. I don't know why they're so much faster in Eclipse, but holy poo poo I wish IntelliJ could do that.

John F Bennett
Jan 30, 2013

I always wear my wedding ring. It's my trademark.

Programmers sure like to bicker about their ide's. What's next, tabs vs spaces, vim vs emacs?

Wheany
Mar 17, 2006

Spinyahahahahahahahahahahahaha!

Doctor Rope

John F Bennett posted:

Programmers sure like to bicker about their ide's. What's next, tabs vs spaces, vim vs emacs?

Vim and emacs are both good text editors, and can be used to write source code in a pinch. Just like a rock can be used as a hammer.

Ola
Jul 19, 2004

Which shoes are best for coding? Find Nike gives a different level of damping to Adidas, so when I return from getting coffee my heels are in less distracting pain and I'm less likely to write bugs. Not sure how people can write good code in Adidas to be honest.

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...
Slippers, if anything must be worn. There are slippers that look like business casual loafers so that no one will notice.

Sagacity
May 2, 2003
Hopefully my epitaph will be funnier than my custom title.
Crocs if you're working on a Ruby on Rails project

Trabandiumium
Feb 20, 2010

wooden moccasins with splinters so you can learn to feel again

Ither
Jan 30, 2010

Barefoot is the best. Be free.

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...

Ither posted:

Barefoot is the best. Be free.

Excuse me I believe you mean GNU-barefoot

TheresaJayne
Jul 1, 2011

Wheany posted:

That would be a reason to migrate to maven, not to keep using ant.

Better to go to gradle it supports ant scripts instantly and you can then slowly migrate over time to full gradle

PS Vim over emacs every time, and PC not mac

ChickenWing
Jul 22, 2010

:v:

lol if you don't code in Birks

carry on then
Jul 10, 2010

by VideoGames

(and can't post for 10 years!)

ChickenWing posted:

lol if you don't code in Birks

That a functional JVM language or more conventional?

ChickenWing
Jul 22, 2010

:v:

carry on then posted:

That a functional JVM language or more conventional?

very functional, and I'm a fan of the style

geeves
Sep 16, 2004

To the surprise of no one, Oracle took a left turn at the last minute and added to their ToS that OracleJDK 11 can't be used for commercial purposes without a license.

https://blog.joda.org/2018/09/do-not-fall-into-oracles-java-11-trap.html

So those of you moving to Java 11, use OpenJDK or Zulu.

Zaphod42
Sep 13, 2012

If there's anything more important than my ego around, I want it caught and shot now.

geeves posted:

If you have a smaller screen and want to save screen space, turn off tabs

Then use CMD-E for most recent files, CMD+O (Classes) and CMD+SHIFT+O (all files) I forget what double-SHIFT opens files or classes.


The big thing about intellij is making sure to exclude what needs and can be excluded. Otherwise you will be in indexing hell every build. It has gotten better about auto-ignoring build, target and node_modules but sometimes doesn't.

The other thing is when importing a project from existing sources, making sure to select build.gradle or pom.xml and let intellij roll with everything else and setup your default environment.

CTRL+O and CTRL+SHIFT+O are basically the only chords I use in intellij

for awhile I used... what is is, CTRL+B for go to definition? CTRL+D? But I end up just right clicking and using the gui more often.

baka kaba
Jul 19, 2003

PLEASE ASK ME, THE SELF-PROFESSED NO #1 PAUL CATTERMOLE FAN IN THE SOMETHING AWFUL S-CLUB 7 MEGATHREAD, TO NAME A SINGLE SONG BY HIS EXCELLENT NU-METAL SIDE PROJECT, SKUA, AND IF I CAN'T PLEASE TELL ME TO
EAT SHIT

Turn off tabs anyway because that one dude is right, you don't need 'em

Volguus
Mar 3, 2009

baka kaba posted:

Turn off tabs anyway because that one dude is right, you don't need 'em

Been using QT Creator lately and that IDE does not have tabs. You have a dropdown to switch between opened documents (and a list view if you want, and ctrl+tab if you're so inclined). I miss tabs. Tabs are good. I can live without them, but I'd rather have them. It is among my few complaints about an otherwise pretty great IDE.

baka kaba
Jul 19, 2003

PLEASE ASK ME, THE SELF-PROFESSED NO #1 PAUL CATTERMOLE FAN IN THE SOMETHING AWFUL S-CLUB 7 MEGATHREAD, TO NAME A SINGLE SONG BY HIS EXCELLENT NU-METAL SIDE PROJECT, SKUA, AND IF I CAN'T PLEASE TELL ME TO
EAT SHIT

I like the way IntelliJ handles it - ctrl+tab is basically your tab history (like ctrl+e except it switches as soon as you release ctrl, so one press will toggle back to the last tab), there's back navigation, and there's a bunch of fast search options if you need to go to something you haven't touched in a while. No need to janitor a tab bar or keep track of where the last things you were working on are located on the bar, it was honestly refreshing when I took the plunge

I guess that doesn't work if you want a specific consistent setup with certain tabs in place, so they're always there no matter how long it's been since you used them, but you can probably do something with favourites or whatever. Pin them to the switcher popup, something like that

Whatever works for you, y'know, but I'd definitely encourage people to try ditching them for a while at least!

Ola
Jul 19, 2004

Thanks for prodding me to look up tab switching in Intellij, alt-arrrows moves between open tabs, going to use that a lot. One particular touchpad gesture is also very useful, three finger side swipe to swap between current window and most recently used one, which is very useful for quickly *ahem* researching things on stack overflow for instance.

e: Related thing, touchpad scroll hasn't worked for a while. Suddenly it worked, now it's not working anymore. That is, works fine elsewhere but not in Intellij. And ideas? I'm on Windows 10 btw.

Ola fucked around with this message at 15:28 on Sep 27, 2018

a witch
Jan 12, 2017

I don't even look at tabs anymore. Cmd+Shift+N is 99% of my navigation in Intellij.

creatine
Jan 27, 2012




Does anyone have a book to recommend for someone new to java but novice/intermediate to programming? I have a 6 hour flight tomorrow so figured I could learn some java since I will be using it in my master's program next year

Ola
Jul 19, 2004

creatine posted:

Does anyone have a book to recommend for someone new to java but novice/intermediate to programming? I have a 6 hour flight tomorrow so figured I could learn some java since I will be using it in my master's program next year

I like this series, although I haven't read the Java one: https://www.amazon.com/Head-First-Java-Brain-Friendly-Guide-ebook-dp-B009KCUX3S/dp/B009KCUX3S/ref=mt_kindle?_encoding=UTF8

Very clear, simple, hand hold-y pedagogical stuff. Get it on Kindle, so you can have it on the desktop Kindle app along with a Java IDE on a fully charged laptop. https://www.jetbrains.com/idea/ Make sure everything runs and you can do "hello world" before you fly, it should be a productive couple of hours.

oh no computer
May 27, 2003

I have Core Java by Cay Horstmann which is written for people already familiar with programming, though not necessarily OOP so it does go over those concepts again. It also has lots of notes throughout as to how Java differs from C++ if that's helpful.

There are two volumes (Fundamentals and Advanced Features) and they are quite big but most of it is code examples that can be skimmed. He also has a version which apparently combines the two volumes into a condensed version called Core Java for the Impatient, though I don't know if that's any good.

Keetron
Sep 26, 2008

Check out my enormous testicles in my TFLC log!

Ola posted:

I like this series, although I haven't read the Java one: https://www.amazon.com/Head-First-Java-Brain-Friendly-Guide-ebook-dp-B009KCUX3S/dp/B009KCUX3S/ref=mt_kindle?_encoding=UTF8

Very clear, simple, hand hold-y pedagogical stuff. Get it on Kindle, so you can have it on the desktop Kindle app along with a Java IDE on a fully charged laptop. https://www.jetbrains.com/idea/ Make sure everything runs and you can do "hello world" before you fly, it should be a productive couple of hours.

I used this book (among some other sources) to teach myself java and now I am employed as a java developer.
It is good for people like me with a short attention span and not that experienced as a programmer.

oh no computer
May 27, 2003

FYI if you do go for that Heads First book note it's currently in a humble bundle with a bunch of their other books in the $15 tier: https://www.humblebundle.com/books/head-first-books?hmb_source=navbar&hmb_medium=product_tile&hmb_campaign=tile_index_2

geeves
Sep 16, 2004

olives black posted:

Anyone have any experience with Baeldung courses? Wondering if this is worth the cash, or if I should go with something cheaper like Pluralsight/Udemy/etc.

I know I already wrote a reply to this a couple weeks ago, but someone took the course and they weren't too pleased

https://rieckpil.de/review-baeldungs-rest-with-spring-masterclass/

crazysim
May 23, 2004
I AM SOOOOO GAY

Ola posted:

I like this series, although I haven't read the Java one: https://www.amazon.com/Head-First-Java-Brain-Friendly-Guide-ebook-dp-B009KCUX3S/dp/B009KCUX3S/ref=mt_kindle?_encoding=UTF8

Very clear, simple, hand hold-y pedagogical stuff. Get it on Kindle, so you can have it on the desktop Kindle app along with a Java IDE on a fully charged laptop. https://www.jetbrains.com/idea/ Make sure everything runs and you can do "hello world" before you fly, it should be a productive couple of hours.

It's old Java, like Java 5.0. Some of the refactoring is also a bit questionable. However, like another poster here, I got started with that book and I had a short attention span. It is an amazing start.

I actually bought that humble bundle to check out some of their newer books to see if they've kept the "moxie" (not quality) which can maybe help my distracted friends to start programming.

On that note, the books from Humble bundle come in mobi, epub, and pdf format. I personally think the Head First series is best enjoyed as PDF format as it's a very graphical teaching approach.

Ola
Jul 19, 2004

youtube commenter posted:

FYI if you do go for that Heads First book note it's currently in a humble bundle with a bunch of their other books in the $15 tier: https://www.humblebundle.com/books/head-first-books?hmb_source=navbar&hmb_medium=product_tile&hmb_campaign=tile_index_2

Thanks, just bought the $15 bundle even if I might only need a few. It's cheaper than most of the individual titles on Amazon.

Pedestrian Xing
Jul 19, 2007

I have a friend who has done a Java bootcamp and wants to learn more OO stuff. What's a good mid-beginner Java book/course?

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer
We have a library that we use for a lot of stuff, and at the moment it involves a painful amount of nearly identical boilerplate be written for each new job we write. It can be as much as 200 lines for a reasonably complex job.

Unfortunately it can't be abstracted away via interfaces or abstract classes because we can have a variable number of fields internal to the class (each of either a type Foo<T> or String) and we have to write this boilerplate code for each field. It's the exact same code with the field name swapped out basically which got me thinking that maybe there was a way to do add code generation for these things with an annotation.

For example, right now we do something like
Java code:
Foo<T> stuff = null;
Foo<T> junk = null;

String pile = null;

//just gonna list names since implementation ain't important

public void setStuff;
public Foo<T> getStuff;
public Bar<Foo<T>> getSpecialStuff;

//repeat for junk

public String getPile;
public void setPile;
public void doStuffWithPile;

public Collection<Foo<T>> getAllFoos;
public Collection<String> getAllStrings;
All of these functions will be 100% identical except for the field being operated on. I'd love to be able to write this:

Java code:
@foo
Foo<T> stuff;
@foo
Foo<T> junk;
@fooString
String pile;
and just have all the repetitive stuff generated behind the scenes.

I've been googling documentation on annotations and I'm not clear if this is possible. None of these functions have to be used internal to the class, which just works with raw fields. These functions can be called by the superclass at runtime or by other classes. Can anyone point me toward some useful docs or shoot this idea down before I waste too much time? Thanks!

Adbot
ADBOT LOVES YOU

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...
Would Autovalue be helpful?

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply