Load jar package
file --- project structrue --- modules --- dependencies ---- + point number select a location idea of the software comes with added lib jar package, or downloaded to your designated location jar package
Switching the working environment:
Select the right maven --- profiles can configure their own working environment.
To convert ordinary file folder to source folders
The first:
file --- project structrue --- modules --- To change the selected folder, click above to source
The second:
Right-click to directly change the folder
![](file:///C:/Users/EDZ/AppData/Local/Temp/enhtmlclip/Image(4).png)
Click to source root
The jar packaging idea
maven project:
First, add the following code in the pom.xml file
<!--打包--> <build> <sourceDirectory>src/main/java</sourceDirectory> <testSourceDirectory>src/test/scala</testSourceDirectory> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>2.5.1</version> <configuration> <source>1.7</source> <target>1.7</target> <!--<encoding>${project.build.sourceEncoding}</encoding>--> </configuration> </plugin> <plugin> <groupId>net.alchim31.maven</groupId> <artifactId>scala-maven-plugin</artifactId> <version>3.2.0</version> <executions> <execution> <goals> <goal>compile</goal> <goal>testCompile</goal> </goals> <configuration> <args> <!--<arg>-make:transitive</arg>--> <arg>-dependencyfile</arg> <arg>${project.build.directory}/.scala_dependencies</arg> </args> </configuration> </execution> </executions> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>2.18.1</version> <configuration> <useFile>false</useFile> <disableXmlReport>true</disableXmlReport> <includes> <include>**/*Test.*</include> <include>**/*Suite.*</include> </includes> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <version>2.2</version> <executions> <execution> <phase>package</phase> <goals> <goal>shade</goal> </goals> <configuration> <filters> <filter> <artifact>*:*</artifact> <excludes> <!-- zip -d learn_spark.jar META-INF/*.RSA META-INF/*.DSA META-INF/*.SF --> <exclude>META-INF/*.SF</exclude> <exclude>META-INF/*.DSA</exclude> <exclude>META-INF/*.RSA</exclude> </excludes> </filter> </filters> <transformers> <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer"> <!-- <mainClass>com.dongfeng.query.QueryController</mainClass>--> <mainClass>FTPdownloads.TestFTP</mainClass> </transformer> </transformers> </configuration> </execution> </executions> </plugin> </plugins> </build>
Then click on the right side of the idea maven options ----- clean ---- install can be.
From the browser plug-in to download a good idea how to install
Settings button in the upper right corner of file ---- setting --- plugins ---- click, choose the third option is to find a local installation of plug-ins. Restart idea to