![]() As much as I wish that there’s some magic jmi/java-mode-config ) :demand t :after ( lsp lsp-mode dap-mode jmi-init-platform-paths )) ( use-package lsp-java :init ( defun jmi/java-mode-config () ( setq-local tab-width 4 c-basic-offset 4 ) ( toggle-truncate-lines 1 ) ( setq-local tab-width 4 ) ( setq-local c-basic-offset 4 ) ( lsp )) :config Enable dap-java ( require 'dap-java ) Support Lombok in our projects, among other things ( setq lsp-java-vmargs ( list "-noverify" "-Xmx2G" "-XX:+UseG1GC" "-XX:+UseStringDeduplication" ( concat "-javaagent:" jmi/lombok-jar ) ( concat "-Xbootclasspath/a:" jmi/lombok-jar )) lsp-file-watch-ignored ' ( ".idea" ".ensime_cache" ".eunit" "node_modules" ".git" ".hg" ".fslckout" "_FOSSIL_" ".bzr" "_darcs" ".tox" ".svn" ".stack-work" "build" ) lsp-java-import-order ' Don't organize imports on save lsp-java-save-action-organize-imports nil Formatter profile lsp-java-format-settings-url ( concat "file://" jmi/java-format-settings-file )) :hook ( java-mode. Server, I don’t really need to worry about all of that:Ĭross-referencing symbols is straightforward and Just Works, But with lsp-mode, lsp-java, and the Eclipse JDT language Someday, maybe in other projects where there isn’t an appropriate LSP Integrate it seamlessly with build tooling. Source’s ETAGS consistent with changes to my source code, or to Gave up on it, as I had difficulty figuring out how to keep my I’ve never really used xref and friends in Emacs: I do know aboutĮTAGS and friends, and I once tried setting that up years ago. What got me sold completely are cross references. Push comes to shove ( sed and a bunch of shell one-liners come to ![]() While now, and I did have some low-tech solutions I could lean on if Have those tools: after all, I’ve lived without those niceties for a Much of a difference from meghanada, even if it meghanada didn’t If it were just the refactoring tools though, lsp-mode wouldn’t be Lsp-java upon enabling lsp-mode in a Java source ~/.emacs.d/ by lsp-java, and it’s automatically started by Language server separately: it was installed automagically in my With lsp-java, I didn’t need to install the Eclipse JDT ![]() Meant I had to launch eclimd separately in a terminal To launch eclimd upon browsing to a Java source file, which usually The one thing LSP integration has over Eclim ![]() Symbol renaming and other refactoring tools, and I get formatting and Compared toĮclim, lsp-mode and lsp-java gives me the same niceties: I get Script – and I’ve been using it for the past month now. Our projects with minimal fuss, admittedly – with the help of said I’ll probably work on that some time in the future… Need to run our build outside of the Eclipse tooling before running Incorrect – I mean, they point to build-time artifacts and not to theĪctual project sources, which complicates things a bit, in that I’ll That said, the script I mentioned does generate the properĮntries, although some of the entries it generates are just slightly Internal projects, which I suspect are likely related to classpathĬonfiguration issues and some other quirks of how our build system I also previously had problems with using Eclipse (in general) on our So, having one less moving part is a huge win for me. Incompatible with the version of Eclim I had configured in my hostĮclipse installation, necessitating having to reinstall/upgrade Sometimes: I’d upgrade emacs-eclim, and find that it’d be Install a host Eclipse installation somewhere. The other bit that always annoyed me with Eclim though was having to Opening anything in Emacs, and I have had problems sometimes runningĮclimd on some of the codebases I’ve worked on. Now – however, having a more seamless editing experience seemed likeĪ big enough that it made sense for me to learn to use lsp-mode: myīiggest pain point was having to start eclimd or Eclipse before Seeing as it’s more mature and I’ve been using it for quite a while I honestly could have moved back to Eclim, Jumped into the chance of trying out LSP again, particularly using theĮclipse JDT LSP server. Subscribed to about a script that generates the necessaryĬonfiguration for Eclipse so as to work with our build tooling, I So, when I saw an announcment in one of the internal mailing lists I’m Import management and some basic refactoring tooling. Sorely missed some of the creature comforts that Eclim gave me, namely Meghanada has served me well so far, but I A few months back I posted about using meghanada to provide support for working on my
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |