Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Use module in multiple projects IntelliJ

I have several projects that need the same core database and utility classes so I have decided to make a "core" module to put these in. Is there any way to use this module in multiple projects or am I using modules for the wrong purpose?

like image 753
user2248702 Avatar asked Feb 28 '26 20:02

user2248702


1 Answers

Yeah! While I obviously can't provide a thorough critique of how you're using modules given what you've told us, the fact that you've encapsulated reusable functionality in this one is certainly a good sign!

Given that such is the purpose of modules, surely intelliJ would want to make it easy to share them across projects - and they did: In the File menu, there's an option to "Import Module". Click that and walk through the wizard, selecting the directory where your module is stored, and it'll appear in your Projects menu as normal.

like image 154
drew moore Avatar answered Mar 02 '26 14:03

drew moore



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!