当前位置:网站首页>Installation and configuration of gradle environment
Installation and configuration of gradle environment
2022-06-26 00:42:00 【White as dust】
windows System
List of articles
1. Gradle brief introduction
Gradle It's from Apache Ant and Apache Maven Concept of project automation to build open source tools , It uses one based on Groovy Domain specific languages (DSL) To declare project settings , Abandoned based on XML All kinds of complicated configuration .
Gradle It's based on JVM Build tools for , It's a general and flexible build tool , Support maven, Ivy Warehouse , Support transitive dependency management , There's no need for a remote warehouse or pom.xml and ivy.xml The configuration file , be based on Groovy,build Script use Groovy To write .
oriented Java Application oriented . Currently, the supported languages are Java、Groovy、Kotlin and Scala.
image maven Same convention based building framework ( Convention over configuration ).
IDEA 2017.3 Above version support .
2. Gradle download
Official website download address :https://gradle.org/releases/
- binary-only: Binary source code
- Complete: Source code and documentation
3. Gradle install
decompression ZIP File to the directory where you want to install ,eg:F:\other\gradle.
4. To configure
Configure environment variables
- GRADLE_HOME: The installation directory .eg: F:\other\gradle\gradle-6.4.1
- GRADLE_USER_HOME( Don't configuration ): Custom warehouse ( It can be for Maven The warehouse directory of ).eg: D:\other\repository1
- environment variable Path:%GRADLE_HOME%\bin;

Test for successful installation : Enter the shortcut key WIN+ R, Input cmd, Enter the command line in the pop-up window : gradle -v
To configure Gradle Warehouse source ( Don't configuration ):
stay Gradle Install under directory init.d Under the folder , Create a new one init.gradle file , Fill in the following configuration .
allprojects {
repositories {
maven {
url 'file:///D:/other/repository1'}
mavenLocal()
maven {
name "Alibaba" ; url "https://maven.aliyun.com/repository/public" }
maven {
name "Bstek" ; url "http://nexus.bsdn.org/content/groups/public/" }
mavenCentral()
}
buildscript {
repositories {
maven {
name "Alibaba" ; url 'https://maven.aliyun.com/repository/public' }
maven {
name "Bstek" ; url 'http://nexus.bsdn.org/content/groups/public/' }
maven {
name "M2" ; url 'https://plugins.gradle.org/m2/' }
}
}
}
repositories It's about getting jar Order of packages . First, it's local Maven Warehouse path ; And then mavenLocal() Is to obtain Maven Path to local warehouse , It should be the same as the first one , But no conflict ; Article 3 and Article 4 are obtained from domestic and foreign network warehouses ; final mavenCentral() It's from Apache Provide central warehouse access to jar package .
5. IDEA To configure Gradle
Global configuration Gradle Warehouse :File --> New Projects Settings --> Settings for New Projects
Project configuration :File --> Settings --> Build,Execution,Deployment --> Build Tools --> Gradle
Warehouse path 、 Installation path configuration , It defaults to the configured in the environment variable .
Reference resources :
Official documents :https://docs.gradle.org/current/userguide/installation.html
Baidu Encyclopedia :https://baike.baidu.com/item/gradle/3066272
Blog :https://www.cnblogs.com/NyanKoSenSei/p/11458953.html
边栏推荐
- Qt之自定义带游标的QSlider
- Solution to SMT grape ball phenomenon
- 论文中英文大小写、数字与标点的正确撰写方式
- Core ideas of SQL optimization
- How to bypass SSL authentication
- 【超能云终端创领先机】如何在48小时内交付一座方舱医院?
- mtb13_ Perform extract_ blend_ Super{candidate (primaryalternate) \u unique (nullable filtering \foreign\index\granulati
- SQL按某字段去重 保留按某个字段排序最大值
- DPVS fullnat mode management
- 86. (cesium chapter) cesium overlay surface receiving shadow effect (gltf model)
猜你喜欢

渲云携手英特尔,共创云渲染“芯”时代

Explain from a process perspective what happens to the browser after entering a URL?

Openresty chapter 01 introduction and installation configuration

anchor free dection简介

小红书微服务框架及治理等云原生业务架构演进案例

Qt优秀开源项目之九:qTox

机器视觉:照亮“智”造新“视”界

使用VS2022編譯Telegram桌面端(tdesktop)

1-9Vmware中网络配置

1-11Vmware虚拟机常见的问题解决
随机推荐
Xiaohongshu microservice framework and governance and other cloud native business architecture evolution cases
1-9Vmware中网络配置
Multi-Instance Redo Apply
Compile the telegraph desktop side (tdesktop) using vs2022
Law and self-regulation in the meta universe
Performance leads the cloud native database market! Intel and Tencent jointly build cloud technology ecology
Apache foundation officially announced Apache inlong as a top-level project
防抖和节流
Comprehensive introduction to Simulink solver
86. (cesium chapter) cesium overlay surface receiving shadow effect (gltf model)
Maintenance and key points of SMT Mounter
Use Coe_ load_ sql_ profile. SQL fixed execution plan
Correct writing methods of case, number and punctuation in Chinese and English papers
Simulink求解器综合介绍
Ora-01153: incompatible media recovery activated
7. common instructions (Part 2): common operations of v-on, v-bind and V-model
mtb13_ Perform extract_ blend_ Super{candidate (primaryalternate) \u unique (nullable filtering \foreign\index\granulati
2021-04-28
QT excellent open source project 9: qtox
Wireshark's analysis of IMAP packet capturing