[JAVA] Installieren Sie gradle auf dem Mac

Ein persönliches Memorandum zur Installation von gradle auf Ihrem Mac. Ich denke, es ist schwer, das Glas jedes Mal zu vergessen und zu installieren.

Änderungen übernehmen

$ brew update

Ich erhalte eine Fehlermeldung, daher enttappe ich sie wie geschrieben

$ brew untap homebrew/homebrew-dupes
$ brew untap homebrew/homebrew-x11

Gradle installieren

$ brew install gradle

Übrigens Wartung

$ brew cleanup

Wechseln Sie in das gewünschte Verzeichnis

Wechseln Sie in das Verzeichnis mit build.gradle usw.

Erstverarbeitung

$ gradle

Ich verstehe das

Welcome to Gradle 5.4!

Here are the highlights of this release:
 - Run builds with JDK12
 - New API for Incremental Tasks
 - Updates to native projects, including Swift 5 support

For more details see https://docs.gradle.org/5.4/release-notes.html

Starting a Gradle Daemon (subsequent builds will be faster)

> Task :help

Welcome to Gradle 5.4.

To run a build, run gradle  ...

To see a list of available tasks, run gradle tasks

To see a list of command-line options, run gradle --help

To see more detail about a task, run gradle help --task 

For troubleshooting, visit https://help.gradle.org

BUILD SUCCESSFUL in 12s
1 actionable task: 1 executed

Aufgabe bestätigen (muss nicht)

$ gradle tasks
> Task :tasks

------------------------------------------------------------
Tasks runnable from root project
------------------------------------------------------------

Build tasks
-----------
assemble - Assembles the outputs of this project.
build - Assembles and tests this project.
buildDependents - Assembles and tests this project and all projects that depend on it.
buildNeeded - Assembles and tests this project and all projects it depends on.
classes - Assembles main classes.
clean - Deletes the build directory.
jar - Assembles a jar archive containing the main classes.
testClasses - Assembles test classes.

Build Setup tasks
-----------------
init - Initializes a new Gradle build.
wrapper - Generates Gradle wrapper files.

Documentation tasks
-------------------
javadoc - Generates Javadoc API documentation for the main source code.

Help tasks
----------
buildEnvironment - Displays all buildscript dependencies declared in root project 'ArtNet for Java'.
components - Displays the components produced by root project 'ArtNet for Java'. [incubating]
dependencies - Displays all dependencies declared in root project 'ArtNet for Java'.
dependencyInsight - Displays the insight into a specific dependency in root project 'ArtNet for Java'.
dependentComponents - Displays the dependent components of components in root project 'ArtNet for Java'. [incubating]
help - Displays a help message.
model - Displays the configuration model of root project 'ArtNet for Java'. [incubating]
projects - Displays the sub-projects of root project 'ArtNet for Java'.
properties - Displays the properties of root project 'ArtNet for Java'.
tasks - Displays the tasks runnable from root project 'ArtNet for Java'.

Verification tasks
------------------
check - Runs all checks.
test - Runs the unit tests.

Rules
-----
Pattern: clean: Cleans the output files of a task.
Pattern: build: Assembles the artifacts of a configuration.
Pattern: upload: Assembles and uploads the artifacts belonging to a configuration.

To see all tasks and more detail, run gradle tasks --all

To see more detail about a task, run gradle help --task 

BUILD SUCCESSFUL in 2s
1 actionable task: 1 executed

bauen

$ gradle build
BUILD SUCCESSFUL in 21s
4 actionable tasks: 4 executed

Bei Erfolg wird eine JAR-Datei im Verzeichnis build / libs generiert. Glück.

Recommended Posts

Installieren Sie gradle auf dem Mac
Installieren Sie Java auf dem Mac
Installieren Sie openjdk11 auf einem Mac
Installieren Sie OpenJDK 8 auf einem Mac
Installieren Sie Tomcat + Eclipse auf einem Mac
Installieren Sie die Java-Entwicklungsumgebung auf dem Mac
Wenn der Gradle-Build beim Importieren auf einem Mac beendet wird
So installieren Sie Eclipse (Photon) auf Ihrem Mac
Rails können nicht auf dem Mac installiert werden
Installieren Sie Corretto 8 unter Windows
Führen Sie STS4 auf dem Mac aus
Installieren Sie OpenJDK unter macOS
Installieren Sie Java und Android-SDK auf dem Mac mit Homebrew
Installieren Sie Golang unter CentOS 8
Installieren Sie pyqt5 auf Ubuntu
Installieren Sie Neo4j 4.1.3 unter centOS
Installieren Sie Docker auf Manjaro
Installieren Sie Vertica 10.0 unter CentOS 6.10
Installieren Sie Ruby unter Ubuntu 20.04
Installieren Sie Gradle auf ubuntu16.04
Mac Rails Installationsfehler
Installieren Sie PostgreSQL 12 auf Centos8
Installieren Sie lombok auf SpringToolSuite4
Installieren Sie SonarQube auf einem Mac und fordern Sie die Quellanalyse heraus
Installieren Sie Python 3 unter CentOS 7
Installieren Sie kuromoji unter CentOS7
Installieren Sie PostGIS 2.5.5 unter CentOS7
Installieren Sie jpndistrict unter CentOS 7
Installieren Sie Redmine 4.1.1 unter CentOS 7
Smokeping Installation unter CentOS7
Installieren Sie PostgreSQL 13 unter CentOS 7.5
[Ruby] puma kann nicht auf einem Mac installiert werden [Rails usw.]
Installieren Sie Java und Maven mit Brew auf einem neuen Mac
Installieren Sie Eclipse auf einem Mac und übersetzen Sie es ins Japanische
Bis zum Erstellen von Spring-Boot mit Eclipse auf einem Mac (Gradle-Version)
So installieren Sie Gradle und Kotlin mit SDKMAN (Mac)
Installiere ag (den silbernen Sucher) [unter CentOS / Ubuntu / Mac]
Installieren Sie Docker auf Raspberry Pi
Installieren Sie Docker unter Windows 10 PRO
Installieren Sie OpenJDK7 (JAVA) unter Ubuntu 14.04
Installieren Sie Docker unter Ubuntu Server 20.04
Installieren Sie rbenv unter Amazon Linux
Installieren Sie den zabbix agent (5.0) unter Ubuntu 18.04
Installieren von MAV Proxy unter Ubuntu 18.04
Installieren Sie Tomcat auf Sakuras VPS
Installieren Sie OpenFOAM v2006 unter CentOS
Installieren Sie Java unter WSL Ubuntu 18.04
Installieren Sie Jenkins auf Dockers CentOS
Installieren Sie Ubuntu Desktop 20.10 auf RaspberryPi4
Installieren Sie Apache unter CentOS auf VirtualBox
Installieren Sie Rails unter macOS Catalina