<!DOCTYPE configuration
PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-config.dtd">
<configuration>
<!--你要引入的外部properties文件-->
<properties resource="$(config.properties)"></properties>
<environments default="development">
<environment id="development">
<transactionManager type="JDBC"/>
<dataSource type="POOLED">
<property name="driver" value=""/>
<property name="url" value=""/>
<property name="username" value=""/>
<property name="password" value=""/>
</dataSource>
</environment>
</environments>
<mappers>
<!--你的映射文件-->
<mapper resource="$(mapper)"></mapper>
</mappers>
</configuration>
转载于:https://www.cnblogs.com/yxs98/p/mybatis_config.html