`
kanpiaoxue
  • 浏览: 1781627 次
  • 性别: Icon_minigender_1
  • 来自: 北京
文章分类
社区版块
存档分类
最新评论

Java version automatically change to java 1.5 after maven update

 
阅读更多

 

Java version automatically change to java 1.5 after maven update

参考地址:https://stackoverflow.com/questions/28509928/java-version-automatically-change-to-java-1-5-after-maven-update/28510029

 

Open your pom.xml file and add the following lines on it:

<properties>
    <maven.compiler.source>1.8</maven.compiler.source> 
    <maven.compiler.target>1.8</maven.compiler.target>
</properties>

 

Where 1.8 is the java version of your current JDK/JRE. Another way of doing this is adding a <build> with the maven-compile-plugin as

<build>
 <plugins>
  <plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-compiler-plugin</artifactId>
    <version>3.2</version>
   <!-- or whatever current version -->
  <configuration>
     <source>1.8</source>
     <target>1.8</target>
  </configuration>
 </plugin>
 </plugins>
</build>

 

 

分享到:
评论

相关推荐

    Maven-The Complete Reference.pdf

    Maven's key feature is its ability to handle dependencies automatically, which simplifies the build process and ensures consistency across different environments. **1.2 Convention Over Configuration...

    java反编译工具jad 1.5.8g(可以反编译jdk1.5,1.6)

    java反编译工具jad 1.5.8g支持 jdk1.5,jdk1.6。 说明很多 记住一个万能的命令基本就够用了。 jad -sjava -r -8 -o **\*.class &lt;br&gt;--------------- This is README file for Jad - the fast Java ...

    Java Language Conversion Assistant

    Java Language Conversion Assistant is a tool that automatically converts existing Java-language code into Visual C#® Quick Info File Name:VS7.1-KB819018-X86.exe Download Size:10092 KB Date Published:...

    maven3安装教程

    3. 如果你希望 Eclipse 自动更新 Maven 项目,勾选“Automatically detect updates to projects”选项。 4. 点击“Apply”然后“OK”完成配置。 ### 五、创建 Maven 项目 1. 在 Eclipse 中,选择 “File” -&gt; ...

    maven相关书籍及安装步骤

    6. **勾选 `Import Maven projects automatically`**:这样 IDEA 会在启动时自动导入 Maven 项目。 7. **应用并关闭设置**:点击 `Apply` 和 `OK` 保存配置。 8. **创建或导入 Maven 项目**:在 IDEA 中新建项目时...

    javacv-platform-1.3.3-src

    To learn how to use the API, since documentation currently lacks, please refer to the Sample Usage section below as well as the sample programs, including two for Android (FacePreview.java and Record...

    maven课堂笔记2.pdf

    3. **配置Maven自动导入jar包**:确保"Import Maven projects automatically"选项被勾选,这样Maven会在项目创建或更改时自动同步依赖。 4. **配置Maven默认支持的JDK版本**:在IDEA的Project Structure中设定项目...

    java7帮助文档

    The ability to use a try-with-resources statement to automatically close resources of type Connection, ResultSet, and Statement; see Closing Connections in Processing SQL Statements. RowSet 1.1: The ...

    项目管理Maven安装1

    6. 如果需要,还可以配置`Importing`选项,比如勾选`Import Maven projects automatically`,使得IDEA自动识别并导入Maven项目的结构。 ### 7. 安装疑难解答 在安装过程中遇到任何问题,可以通过搜索引擎(如百度...

    配置好的maven 3.6.3配置文件以及环境变量设置教程

    在IT行业中,构建和管理Java项目时,Maven是一个不可或缺的工具。本教程将详细介绍如何配置Maven 3.6.3,特别是针对中国开发者优化的阿里云镜像源,以及如何在JetBrains的IntelliJ IDEA中设置相关环境变量。 首先,...

    Android代码-gradle-maven-publish-plugin

    Gradle plugin that creates an uploadArchives task to automatically upload all of your Java, Kotlin or Android libraries to any Maven instance. This plugin is based on Chris Banes initial ...

    Java邮件开发Fundamentals of the JavaMail API

    included with the 1.2.1 version of the Java 2 Platform, Enterprise Edition (J2EE), so it is still commonly used. The version of the JavaMail API you want to use affects what you download and install...

    eclipse4.5 mars 64位 自带Maven插件

    Eclipse 4.5 Mars是Eclipse IDE的一个重要版本,专为Java开发人员设计,同时在该版本中集成了对Maven的支持。Maven是一个流行的项目管理和综合工具,主要用于Java项目构建、依赖管理和项目信息管理。它通过使用一个...

    Natural.Language.Processing.with.Java.178439179

    Natural Language Processing with Java will explore how to automatically organize text using approaches such as full-text search, proper name recognition, clustering, tagging, information extraction, ...

    Absolute Java(PEARSON,6ed,2015)

    Absolute Java provides a comprehensive reference to programming in the Java language. Accessible to both beginner and intermediate programmers, the text focuses around specifically using the Java ...

    Android代码-MiniJava

    A modified version of the project three starter is available at src/java/. The clojure code automatically loads class files from classes/ folder. FOR THE TA: To run the tests $ java -jar minijava-...

    基于Google.App.Engine(GAE)的Java和GWT应用开发.pdf

    Google Application Engine is a cloud computing technology that lets you run web applications that are easy to build and maintain as well as being scaled and load-balanced automatically. To build ...

    培训班的java文档

    Java编程语言是软件开发领域广泛使用的高级编程语言,以其跨平台、面向对象和强大的功能而闻名。本培训文档旨在提供全面的Java基础知识,帮助初学者迅速掌握这门强大的语言,并结合Eclipse集成开发环境(IDE)进行...

Global site tag (gtag.js) - Google Analytics