Website | Source

Introduction into C++ Builds with Gradle

Shadow plugin: "Shadow is a Gradle plugin for combining a project's dependency classes and resources into a single output Jar. The combined Jar is often referred to a fat-jar or uber-jar. ... Shadowing a project output has 2 major use cases: (1) Creating an executable JAR distribution, and Bundling and relocating common dependencies in libraries to avoid classpath conflicts."

Reading

Notes

Gradle uses a 1:1 relationship of a build script to a Project instance. Most "magic" comes from the use of plugins (listed below). Thus, the world's simplest Gradle build:

// build.gradle.kts
println("Hello Gradle")

... when run with gradle -b build.gradle.kts:

~/Projects/Exploration.git/Gradle % gradle -b build.gradle.kts 

> Configure project :
Hello Gradle

> Task :help

Welcome to Gradle 8.10.

To run a build, run gradle <task> ...

To see a list of available tasks, run gradle tasks

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

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

For more detail on using Gradle, see https://docs.gradle.org/8.10/userguide/command_line_interface.html

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

Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.10/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

BUILD SUCCESSFUL in 843ms
1 actionable task: 1 executed

Awesome Gradle

Plugins

Notice: in the following descriptions, "Official plugin" means that it's provided as a builtin plugin by Gradle.

Language

Code quality

Code generation

Java application development

Web application development

Android application development

iOS and Mac application development

Editor and IDE integration

Templating

Database

Dependency management

Debugging

Testing

Building

Packaging

Releasing

Notification

Cloud services

SCM

CI

VM and container

Boilerplates

Resources

General Resources

Official Documentation


Tags: tool   jvm   android   build  

Last modified 07 October 2024