Hacker News new | past | comments | ask | show | jobs | submit | tofflos's comments login

> I’ll preface this by saying that if Neovim isn’t your primary editor, you should first try an IDE specifically for Java."

Seconded.

As someone who has spent a lot of time configuring editors, but doesn't enjoy it quite as much as he used to, I gave Java on Neovim a shot this summer.

There are two main routes to go - both of which are described in the article. Either install it yourself, "You read the friendly manual", or use someone else's installer, "You use a distro".

My problem with someone else's installer is that I don't understand what it's doing, which in turn gives me the feeling that it's pulling in the kitchen sink, which is exactly the feeling I hoped to avoid by not using my regular IDE.

My problem with installing it myself is that I have to learn the entire ecosystem including, but not limited to, learning how to use Neovim for more than editing a simple text file, learning the Lua scripting language, learning where Neovim keeps its' configuration files and what to put in them, curating a set of plugins for highlighting, launching code, debugging, etc., figuring out how to configure those plugins for Neovim and finally how to make those plugins play nice together.

In the end it just wasn't for me but if Neovim is your primary editor it might be for you.

> Java has one LSP option for Neovim, and that’s JDTLS (Java Development Tools Language Server) by Eclipse.

Just wanted to mention that there is another LSP for Java, https://github.com/apache/netbeans/tree/master/java/java.lsp..., but I don't know if anyone has gotten it to work with Neovim.


I’ve tried out a few distros for vim and emacs over the years and usually drop them after a few hours of trying. But I gotta say I’m really enjoying LazyVim. It’s config layering system makes tweaking any specific plugin settings very easy, and it’s based on the “lazy.nvim” plugin manager that most plugins feature first in their README intros these days. That means there’s less a feeling of doing things “the normal way” vs “the weird distro specific way” that I experienced with DOOM EMacs and SpaceVim.

It’s definitely still a kitchen sink, lots of stuff that I wouldn’t configure on my own, but surprisingly discoverable via a popup that shows available keyboard shortcuts that appears after you type LEADER and wait a moment.

It’s also super fast to start up, putting most destros out there especially EMacs ones to shame.

The main downside is it encourages you to spread out your config in multiple Lua files, and overall learn and use more Lua stuff. But I think it’s worth the price.


Last time I tried and iirc, lazyvim would print out all sorts of various errors within seconds of using it for very basic things, which is enough for me to give up on most tools unless they are forced onto me. That said I have yet to find a proper code editor for my needs which is not exactly dev ; so far I settle with plain vim.

It works great for me with no random errors so far, with these dependency hashes: https://github.com/justjake/Dotfiles/blob/new/config/nvim/la...

Doesn't the idea of an "LSP for Neovim" mean the entire premise of LSP has failed? Wasn't the whole idea supposedly to put an end to editor-specific plugins in favor of one protocol spoken by all editors?

LSP exposes standard interfaces, but it still has to be bridged across the variety of languages editor plugins are written in. It’s much better than the previous state.

> LSP exposes standard interfaces, but it still has to be bridged

Why is the bridge not "specify where to find the LSP server"?


It is just that. (of course in practice you also need to get the LSP to exist on your system somewhere in the first place and have a command that runs it (rather annoying for java programs), but other than that it's literally just a program with JSON I/O)

I was in the same place you were a month ago but I decided to just bite the bullet and build my own Neovim configuration from scratch. Fortunately I don't use auto-complete and an LSP was only a recent addition to my configuration. Telescope was one of the few plug-ins I configured off the bat and when you start small learning the eco-system isn't that much of a hurdle.

The Nvim Kickstart Project is a great starting point for your configuration and has it's config file heavily commented to teach you how to setup your own configuration, I highly recommend it.


Is there a Java code assist utility for neovim that isn't a language server?

Off-topic but I love this naming convention from Red Hat which I hope gets more traction across the industry. It absolutely detest wading through vendor marketing material to figure out which open source product is being used under the hood. With names like "Red Hat Build of Keycloak" and "Microsoft Build of OpenJDK" it's crystal clear.

I believe it works out better for the vendors as well because there are so many obstacles with evaluating anything that requires a license in an enterprise setting. If the technical person downloads and evaluates the underlying open source version some manager will insist on purchasing a support contract before going to production.


Though Red Hat did a search and replace for RHSSO with "Red Hat Build of Keycloak" in their docs, and now they are extremely painful to read with Red Hat Build of Keycloak sometimes appearing three times in one sentence when "Keycloak" or some other shortened form would suffice.


> Like why didn't anyone catch the issue with the logs?

I see questions like these a lot and every time I feel that people immensely underestimate the effort required for curating data. In my experience data can only ever be as good as what it's being used for and in this story the logs haven't been used for this purpose before so they're not going to be any good.

It's some sort of data variation on the second law of thermodynamics - entropy is winning. Going in with the expectation that things should be better will only lead to frustration.


This is not a data curation issue though, it’s a basic o11y issue.


> o11y

Seems to be "observability", for anyone else seeing that for the first time.


It pops up every 8 months or so for me


This article is wrong on so many levels! Or, you know, the author is optimizing for something else than what I am optimizing for. ;-)

> "House, car, work scenario"

To provide some context know that I live in a place where I've never even seen a car key that is intended to be placed on a key chain and where all offices have access cards.

So my key chain has only the house key. My other keys, which I almost never use, hang in a key cabinet with labels. No unnecessary weight to carry around, no ordering and orientation problems, great for keeping track of which key goes where.

Hope that helps! :)


I used yq last week to scan through all the Java projects (i.e. Maven pom.xml-files) within our org to check which ones inherit from the corporate pom.

  yq eval --input-format xml --output-format csv '[file_index, file_name, .project.parent.groupId, .project.parent.artifactId, .project.parent.version]' **/pom.xml


Which yq? Last time I checked, there seemed to be a few tools with the same name.


The “go” yq

https://github.com/mikefarah/yq

| yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties processor


I believe that the popular working theory is that poor people have less options, i.e. distractions, which leads to more time spent training and better athletes. If the theory is correct then bringing people out of poverty would also decrease the number of candidates.


> I believe that the popular working theory is that poor people have less options, i.e. distractions, which leads to more time spent training and better athletes

That sounds backwards. Poor people have more distractions, they need to think about how to survive the current week/month with the little they have, and do everything they can do make sure to afford housing and food, leading to less time spent training.

At least that's my personal experience of being poor and not being able to focus because I didn't know if I'd afford the rent the next month.


> I believe that the popular working theory is that poor people have less options, i.e. distractions, which leads to more time spent training and better athletes.

As someone who grew up poor - this doesn’t make any sense. When you’re poor you can’t afford training, you can’t afford food and time to stay competitive.


I would have loved to see Java introduce something similar to the IntelliJ @Language-annotation in the standard library but maybe they'll figure out the sweet spot in a future String Templating JEP.

  @Language("application/sql")
  String query = "SELECT 1";

  @Language("application/graphql+json")
  String query = """
                 query HeroNameAndFriends {
                   hero {
                     name
                     friends {
                       name
                     }
                   }
                  }
                  """;


This is exactly how raw string literals together with StringSyntaxAttribute work in C#. It is very useful in e.g Regex syntax highlighting.


Check out https://eclipsestore.io (previously named Microstream) if you're into Java and interested in some of the ideas presented in this article. You use regular objects, such as Records, and regular code, such as java.util.stream, for processing, and the library does snapshotting to disk.

I haven't tried it out but just thinking of how many fewer organizational hoops I would have to jump through makes we want to try it out:

- No ordering a database from database operations.

- No ordering a port opening from network operations.

- No ordering of certificates.

- The above times 3 for development, test and production.

- Not having to run database containers during development.

I think the sweet spot for me would be in services that I don't expect to grow beyond a single node and there is an acceptance for a small amount of downtime during service windows.


Check out Spring Modulith at https://docs.spring.io/spring-modulith/docs/current-SNAPSHOT.... Their pitch is that the application framework organizes your code in such a way that it makes the architecture of your application easier to visualize and to reason about. I haven't tried it but have seen some talks on Youtube that makes we want to give it a shot in the future.


Could you expand a bit on the challenges with Skype/Zoom?


Piano tutors who want to give an engaging remote lesson will want the ability to show themselves playing as well as what notes they're playing. This requires expensive equipment and technical knowledge to set up using Skype/Zoom. I give a few typical setups on the landing page and compare it to Keyboard Connect, which requires just a MIDI controller and webcam.

This represents a challenge for tutors and could be discouraging for new pianists who just want to try lessons without committing to buying a digital/acoustic piano are supporting AV equipment.

Also, I'll add modules to Keyboard Connect that support tasks tutors/students would normally have to organize on their own (lesson planning, file sharing, practice tools)


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: