zoukankan      html  css  js  c++  java
  • 创建一个Maven项目

    创建我的第一个Maven项目

    一、new project(选择Maven),点击next

    二、GroupId(公司域名),ArtifactId(项目名),点击next

    三、项目名,项目所在位置,点击finish

    四、pom.xml中配置依赖(mybatis,mysql),Maven不会自动把.xml文件打包,所以用build配置

    <?xml version="1.0" encoding="UTF-8"?>
    <project xmlns="http://maven.apache.org/POM/4.0.0"
             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
             xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
        <modelVersion>4.0.0</modelVersion>

        <groupId>com.ychs</groupId>
        <artifactId>homework</artifactId>
        <version>1.0-SNAPSHOT</version>

        <dependencies>
            <!--mybatis-->
            <dependency>
                <groupId>org.mybatis</groupId>
                <artifactId>mybatis</artifactId>
                <version>3.5.0</version>
            </dependency>
            <!--mysql-->
            <dependency>
                <groupId>mysql</groupId>
                <artifactId>mysql-connector-java</artifactId>
                <version>5.1.49</version>
            </dependency>
        </dependencies>

        <build>
            <resources>
                <resource>
                    <directory>src/main/java</directory>
                    <includes>
                        <include>**/*.xml</include>
                    </includes>
                </resource>
            </resources>
        </build>

    </project>



    软件下载提取码:qwer
  • 相关阅读:
    【POJ 2044】 Weather Forecast
    【POJ 1703】 Find them,Catch them
    【SCOI 2005】 骑士精神
    字长与指针
    XModem协议
    SecureCRT乱码问题解决方法
    usb设备驱动程序
    如何检测 51单片机IO口的下降沿
    matlab神经网络工具箱创建神经网络
    九针串口接线问题, 232, 485
  • 原文地址:https://www.cnblogs.com/ty0910/p/14774228.html
Copyright © 2011-2022 走看看