How to link/use a file outside the project directory?

I create a web app in Idea and I want to use an existing xml file (named icon-config.xml) outside the project directory in this app. That means I want to see that file in the project structure in Idea and I want Idea to copy that file to WEB-INF when it builds the app or when I Ctrl+Shift+F9 that file. How can I do that?

Note: there are other existing files in the same directory with icon-config.xml and I don't want to bring them into this application.

People who use Eclipse here use the FileSync plugin to do that. I think this plugin is powerful. I can link a whole directory (Idea can do that in Project Structure | Facets | choose Web facet | Web Resource Directories by creating an item like this: Web Resource Directory: C:\some\directory\outside\the\project, Path Relative to Deployment Root: /WEB-INF) or a single file.

Regards.

Please sign in to leave a comment.