[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

How to include a folder from another project in intellij idea

Posted on 2016-11-01
2
Medium Priority
?
97 Views
Last Modified: 2016-11-20
HI,
I have two projects A and B... The project A uses B as dependency..
While working on Project A i have to make change simulataneously in A and B.
This will cause me to open the project B in another instance of intellij Idea and build it and then use this latest build of B in A. Which is quite troublesome..
If i could include the source of B directly in A and make changes there only things will be very easy..
How do i do that..
Also i saw that intellij i cannot open two projects in the same instance...

To give the exact case of my scenario :
I have a project A which is a web application...
And it uses an npm module called B in its javascript files which is another project.
eg... in a new.js i include B like :
require(B)
B is listed as a dependency in package.json...
Now i have to make changes in A and B simulatenously and test my changes...
what i have done currently is manually copy the files i need in B directly in a folder in A and then work.. And when i am finished... copy them back to project B...
I tried creating an alias of files in B. So as i dont have to copy them back and forth.. But intellij doesnt seem to work with aliases...

Thanks
0
Comment
Question by:Rohit Bajaj
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 28

Accepted Solution

by:
dpearson earned 2000 total points (awarded by participants)
ID: 41869258
I think A and B should both be modules within a single project.

Then you go to "Project structure, Modules" and select A, then in the Dependencies tab for A, add "Module B" (click the "+" at the side and choose Module Dependency...).

Now when you edit B, it will be compiled into A as needed.

You can still have a separate run target for just B if you wish too, for when you want to run B separately from A.

Give that a try and see if that solves your problem,

Doug
0
 
LVL 28

Expert Comment

by:dpearson
ID: 41894653
Only solution submitted.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…
The viewer will learn how to use and create new code templates in NetBeans IDE 8.0 for Windows.
Suggested Courses

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question