在Intellij的项目中包含外部文件(而不是库) [英] Include external files (not libraries) in a project in Intellij
本文介绍了在Intellij的项目中包含外部文件(而不是库)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在目录'P'中有一个'P'项目。我希望在'P'中使用css文件,但css文件不在目录'P'中。它高于'P'一级。我是否仍然可以在'P'中包含/使用css文件而无需更改目录结构或制作css文件的副本?
I have a project ‘P’ in directory ‘P’. I want the use a css file in ‘P’ but the css file is not in directory ‘P’. It is at one level above ‘P’. Could I still include/use the css file in ‘P’ without changing the directory structure or making a copy of the css file?
推荐答案
是的,您可以在根项目目录之外添加目录:
Yes, you can add directories outside of the root project directory:
项目结构→模块→来源→添加内容根
Project Structure → Modules → Sources → Add content root
然后在添加目录后,您可以在项目根目录下看到它。
Then after adding a directory, you can see it under your project root.
这篇关于在Intellij的项目中包含外部文件(而不是库)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文