|
Volguus posted:If i don't use groovy for my dev work to install that huge runtime just to use one tool (gradle) ... meh. Then again, the day I find that maven cannot do X (that I need) I will switch to gradle. Hasn't happened yet. We use gradle here at work and I have neither groovy nor gradle installed. Gradle wrapper bro.
|
# ? Aug 16, 2018 21:47 |
|
|
# ? Jun 11, 2024 02:55 |
|
poemdexter posted:We use gradle here at work and I have neither groovy nor gradle installed. Gradle wrapper bro.
|
# ? Aug 17, 2018 00:16 |
|
Keetron posted:Why would anyone use Apache Ant over Maven? If you already have ant build files? I can't think of another reason poemdexter posted:We use gradle here at work and I have neither groovy nor gradle installed. Gradle wrapper bro. I really hate gradle. I've wasted way way way too much time with gradle for how little I've actually used it. BabyFur Denny posted:Why would anyone use Maven over Gradle? In my experience: maven works, gradle doesn't. Now maybe I'm more familiar with editing maven files, yeah, but what am I supposed to learn gradle or something? Pah!
|
# ? Aug 17, 2018 00:44 |
|
Can anyone recommend a good, concise tutorial for Spring? I haven't used it in ages and am supposed to convert a web app to it, so a practical run through of the framework would be great. I think the only non-basic thing Iwould need to do is configure it so that it uses certain classes depending on which profile is used.
|
# ? Aug 17, 2018 18:38 |
|
Everything is locked down here. We can only install things approved through some group of people and then use the installer provided on our machine. Also they use artifactory internally which is fine except they don't allow outside repos meaning you have to have every dependency requested and then someone manually installs it into artifactory. Bonus: they never add the source or javadoc jars for the library. I honestly have no idea how they got the gradle wrapper placed into the project in the first place since that requires a real gradle install first. I've also wasted way too much time in maven when gradle just works. Heaven forbid you have to deal with any sort of automated pipeline using the maven release plugin.
|
# ? Aug 17, 2018 18:58 |
|
poemdexter posted:Everything is locked down here. I stopped listening after this. I mean, how can you work at all?
|
# ? Aug 17, 2018 19:45 |
|
poemdexter posted:Everything is locked down here. We can only install things approved through some group of people and then use the installer provided on our machine. Also they use artifactory internally which is fine except they don't allow outside repos meaning you have to have every dependency requested and then someone manually installs it into artifactory. Bonus: they never add the source or javadoc jars for the library. My was about the fact that you said poemdexter posted:We use gradle here at work and I have neither groovy nor gradle installed. Gradle wrapper bro. About poemdexter posted:Bonus: they never add the source or javadoc jars for the library.
|
# ? Aug 17, 2018 19:49 |
|
carry on then posted:What's your thought on using Kotlinscript as the Gradle DSL? It seems a lot better than the Groovy DSL, code completion actually works reliably in IntelliJ. It still hasn't hit 1.0 yet, though it's close (they're up to release candidates). Unfortunately, it doesn't matter for me as my current company is using Play Framework so I'm cursed with using sbt. And we're using the Java API for Play.
|
# ? Aug 17, 2018 19:58 |
|
Keetron posted:I stopped listening after this. I mean, how can you work at all? Very slowly. Considering I completely burnt out at the last place I worked, I'm ok with forced slowness. My team is working on making it better but it's an uphill struggle. We'll get there.
|
# ? Aug 17, 2018 20:44 |
|
BabyFur Denny posted:Why would anyone use Maven over Gradle? I can't get Scala to compile with Gradle. Keep running into dumb errors. Maven was quick and easy for it. On the other hand, Gradle is much better than Maven especially when you can run a bunch of tasks in parallel. Once I got the hang of how to structure everything, I knocked off 70% of average build time for our team. Not a fan of Groovy, but we've been re-writing them in Kotlin. Cached builds are a huge time saver. Especially when you have to do multiple builds in a row because you're a fuckup. geeves fucked around with this message at 04:15 on Aug 18, 2018 |
# ? Aug 18, 2018 04:13 |
|
For testing, I'm trying to set up a data structure that will correspond people to accounts. A person can have multiple accounts, but an account belongs to only one person. I need to be able to query both ways. What would be a good data structure for this? I tried a BidiMap<String, List<String>> from Apache Commons, but I couldn't retrieve the person via one of their accounts, even if the target person had only one account and I did peopleToAccounts.getKey(Arrays.asList("dude's only account")).
|
# ? Aug 29, 2018 02:18 |
|
BidiMap's docs say it requires a 1:1 relationship (since it's basically a reversible map where either side can be the key and the other the value). So you'd have to look up a person by passing their entire account list as stored - not sure why it didn't work for your single account version though! Maybe the implementation you used doesn't lookup by hashcode etc? Not sure if there's a ready-made collection for it, but I think you basically want to keep a pair of maps - one mapping each person to their collection of accounts (you could use a MultiValuedMap if you want), and then a reverse lookup with a basic map that links each account to its owner, 1:1. Just need to make sure you keep them both synchronised (and synchronized ) This is assuming you want fast lookups both ways, and you can't just store one of those maps and iterate over it to find the opposite thing when you need that baka kaba fucked around with this message at 03:21 on Aug 29, 2018 |
# ? Aug 29, 2018 03:09 |
|
hooah posted:For testing, I'm trying to set up a data structure that will correspond people to accounts. A person can have multiple accounts, but an account belongs to only one person. I need to be able to query both ways. What would be a good data structure for this? I tried a BidiMap<String, List<String>> from Apache Commons, but I couldn't retrieve the person via one of their accounts, even if the target person had only one account and I did peopleToAccounts.getKey(Arrays.asList("dude's only account")). Generally, you should use a Multimap instead of doing it yourself with a map of lists. If you're using Guava, the operation you want is built-in: https://google.github.io/guava/releases/19.0/api/docs/com/google/common/collect/ImmutableMultimap.html#inverse() Not sure if there's an equivalent in apache commons.
|
# ? Aug 29, 2018 03:09 |
|
yeah that would be great if you can use it. MultiValuedMap is apparently the Commons equivalent but... I haven't used it but it looks weird. Seems like you can check if a value exists somewhere, but that's about it e- maybe it's not that weird, the Guava one looks the same - it just has a convenience function to generate a mirrored copy from an immutable multimap. I thought it was a live inverse view on a mutable one for a minute baka kaba fucked around with this message at 03:27 on Aug 29, 2018 |
# ? Aug 29, 2018 03:22 |
|
Cool, I didn't know about multimaps, and I haven't had a chance/reason to explore Guava. Thanks.
|
# ? Aug 29, 2018 14:36 |
|
I'm looking to run javadoc on this file: https://github.com/ankidroid/Anki-Android/blob/master/api/src/main/java/com/ichi2/anki/FlashCardsContract.java I haven't used java in five years or more so I'm not sure whether I can run something like javadoc.exe myFile.java and have it spit out an myFile.html. The windows examples link on the Javadoc FAQ is a 404. I'm not even sure how to tell if I have the java sdk installed on my machine. java.exe, javaw.exe, and javaws.exe are available in my command prompt, but javac isn't. Any directions to give? (A generous person could also feel free to generate the doc and pastebin it or something if it's a one-step procedure).
|
# ? Sep 1, 2018 17:18 |
|
If you haven't installed the JDK, it's not installed. The compiler et al aren't put into your PATH by default though, although JAVA_HOME might be (which should point to whichever JDK you're using). That said, if you're using Android Studio, that basically comes with its own JDK. You might want to post in the Android thread too.
|
# ? Sep 1, 2018 17:51 |
|
Newf posted:I'm not even sure how to tell if I have the java sdk installed on my machine. java.exe, javaw.exe, and javaws.exe are available in my command prompt, but javac isn't. Sounds like you have the JRE installed but not the JDK.
|
# ? Sep 1, 2018 17:57 |
|
I figured it out. Noticing the long-unclicked Eclipse icon on my taskbar, I guessed that some version of the java sdk must exist on the machine. I had earlier tried using windows explorer and the start menu to find javac.exe, but they failed. Of course, it was in the first place I looked (program files (x86)/java/sdk/bin). Eclipse's export javadoc worked out for me. Such pangs of nostalgia at running Eclipse...
|
# ? Sep 1, 2018 18:08 |
|
Newf posted:I figured it out. Noticing the long-unclicked Eclipse icon on my taskbar, I guessed that some version of the java sdk must exist on the machine. I had earlier tried using windows explorer and the start menu to find javac.exe, but they failed. Of course, it was in the first place I looked (program files (x86)/java/sdk/bin). Eclipse's export javadoc worked out for me. If i remember correctly eclipse can run on the JRE, it doesn't need the SDK, since it has its own compiler.
|
# ? Sep 2, 2018 03:15 |
|
So I’m moving into a new position at work where I’m going to be writing mostly Java (coming from a position where I’ve been writing Go almost exclusively for about two years and then perl before that). I haven’t written a line of Java since college when Java 5 was the new hotness. Should I just pick up a copy of Effective Java and go from there? I’m also not super familiar with the intricacies of maven or the tooling around Java in general (not what they were teaching back in Algorithms & Data Structures a decade ago), is there a decent reference/primer for that kind of stuff?
|
# ? Sep 2, 2018 15:51 |
|
You might want to look at the Not sure where to suggest looking for build systems tutorials. Take a look at IntelliJ as your IDE rather than Eclipse.
|
# ? Sep 3, 2018 11:52 |
|
Volmarias posted:Take a look at IntelliJ as your IDE rather than Eclipse. And then go back to Eclipse like any normal human being.
|
# ? Sep 3, 2018 17:59 |
|
Intellij is the best Java IDE.
|
# ? Sep 3, 2018 18:28 |
|
I've had to go back to using Eclipse at work the last few weeks after months of IntelliJ, and it just doesn't compare. It's crashed/frozen a few times, so the loooong startup time is really noticeable. The whole "perspective" thing is kind of annoying, especially when debugging and fixing code. It's pretty ugly.
|
# ? Sep 3, 2018 19:16 |
|
Lamont Cranston posted:So I’m moving into a new position at work where I’m going to be writing mostly Java (coming from a position where I’ve been writing Go almost exclusively for about two years and then perl before that). I haven’t written a line of Java since college when Java 5 was the new hotness. Should I just pick up a copy of Effective Java and go from there? I’m also not super familiar with the intricacies of maven or the tooling around Java in general (not what they were teaching back in Algorithms & Data Structures a decade ago), is there a decent reference/primer for that kind of stuff? As for books, I would recommend this one: https://www.manning.com/books/modern-java-in-action It should be coming out in the next few days hopefully, but if you buy it now you can already read the work in progress version (which should be 99% finished anyway) so you wouldn't have to wait. Disclaimer: I did some technical review work on the previous edition of this book. hooah posted:I've had to go back to using Eclipse at work the last few weeks after months of IntelliJ, and it just doesn't compare. It's crashed/frozen a few times, so the loooong startup time is really noticeable. The whole "perspective" thing is kind of annoying, especially when debugging and fixing code. It's pretty ugly. Honestly, if there is one thing I wish they could go back and revisit a decision that was made early on in Eclipse's life, it's perspectives. It probably seemed a good idea at the time, but it just hinders instead of helps most of the time as far as I am concerned. I feel the way it's done in Idea works a lot smoother, esp. with debug. ivantod fucked around with this message at 19:42 on Sep 3, 2018 |
# ? Sep 3, 2018 19:39 |
|
Awesome, thanks for the help.Volmarias posted:Take a look at IntelliJ as your IDE rather than Eclipse. We actually all use IntelliJ at work, so that's no problem (even with vim mode on I'm still absurdly slow in it so far but hopefully that will improve)
|
# ? Sep 4, 2018 03:55 |
|
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.
|
# ? Sep 19, 2018 02:57 |
|
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'd start with reading his blog which is pretty good, especially for the little day-to-day things that aren't so day-to-day. I would say if you like the blog his courses probably would be a good investment, it's better than most of the trash on Udemy. If you want to see the beginnings of a spring boot API, check out https://github.com/pram/spring-react-boilerplate
|
# ? Sep 19, 2018 22:23 |
|
geeves posted:I'd start with reading his blog which is pretty good, especially for the little day-to-day things that aren't so day-to-day. I would say if you like the blog his courses probably would be a good investment, it's better than most of the trash on Udemy. Will do, thanks!
|
# ? Sep 20, 2018 01:06 |
|
Man I feel like I'm totally missing something. I've been forced to use IntelliJ at work and I'm having the complete opposite thoughts, it seems so clunky and crappy compared to eclipse (well, compared to STS which is what I have been using specifically). I don't get it!
|
# ? Sep 20, 2018 19:38 |
|
The one thing that I struggled with in Intellij was Ctrl-Y is delete line, not redo. Lost a few chunks of code before I learned.
|
# ? Sep 20, 2018 19:51 |
|
FateFree posted:Man I feel like I'm totally missing something. I've been forced to use IntelliJ at work and I'm having the complete opposite thoughts, it seems so clunky and crappy compared to eclipse (well, compared to STS which is what I have been using specifically). I don't get it! In my experience it's more responsive than Eclipse and it has a working dark theme which helps with eye strain. Last I tried none of the dark theme options for Eclipse worked well in windows, they all had issues of some kind. Ola posted:The one thing that I struggled with in Intellij was Ctrl-Y is delete line, not redo. Lost a few chunks of code before I learned. If you change the keymap to Visual Studio then ctrl+z & ctrl+y function as you'd expect, or you could just remap that command yourself.
|
# ? Sep 20, 2018 20:10 |
|
I never knew ctrl-Y was a thing, ctrl-shft-z felt very natural.
|
# ? Sep 21, 2018 12:41 |
|
Yeah I figured it was best to just get used to a new convention because sooner or later I'd install a new IDE or use a new laptop and would rather do as little custom config as possible. Just started using CLion as well, I really like the Jetbrains stuff.
|
# ? Sep 21, 2018 12:54 |
|
Zaphod42 posted:If you already have ant build files? That would be a reason to migrate to maven, not to keep using ant.
|
# ? Sep 21, 2018 12:57 |
|
Kuule hain nussivan posted:Can anyone recommend a good, concise tutorial for Spring? I haven't used it in ages and am supposed to convert a web app to it, so a practical run through of the framework would be great. I think the only non-basic thing Iwould need to do is configure it so that it uses certain classes depending on which profile is used. Wheany posted:If you need a quick course on Spring Boot, check out this playlist on youtube, it's an excellent starting point because the instructor explains a lot of the magic that Spring does behind the scenes.
|
# ? Sep 21, 2018 12:58 |
FateFree posted:Man I feel like I'm totally missing something. I've been forced to use IntelliJ at work and I'm having the complete opposite thoughts, it seems so clunky and crappy compared to eclipse (well, compared to STS which is what I have been using specifically). I don't get it! It takes a while, but over time you'll find that a) it's way more performant than eclipse, and b) has a ton more built in features. There's the odd QOL feature from STS that I found myself missing after I switched, but I honestly can't remember any of them anymore (been using intellij for about a year and a half ish) I've been you. Give it a while. Keep looking up shortcuts, eventually you'll become a powerful intellij keyboard warrior. If it helps, I'm p sure there's a built in way to set yourself up with eclipse keybinds
|
|
# ? Sep 21, 2018 13:29 |
|
Intellij pro tip: double tap the shift key, start typing.
|
# ? Sep 21, 2018 13:37 |
|
|
# ? Jun 11, 2024 02:55 |
ironically I almost never use that, it always seems much slower than the specific searches
|
|
# ? Sep 21, 2018 13:44 |