Effective Gradle Implementation

Build, automate, and deploy your application using Gradle
3.3 (10 ratings) Instead of using a simple lifetime average, Udemy calculates a
course's star rating by considering a number of different factors
such as the number of ratings, the age of ratings, and the
likelihood of fraudulent ratings.
179 students enrolled
$19
$85
78% off
Take This Course
  • Lectures 74
  • Length 3 hours
  • Skill Level All Levels
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion
Wishlisted Wishlist

How taking a course works

Discover

Find online courses made by experts from around the world.

Learn

Take your courses with you and learn anywhere, anytime.

Master

Learn and practice real-world skills and achieve your goals.

About This Course

Published 11/2014 English

Course Description

This course will show you how to use Gradle effectively and will help you overcome these issues with the build tool called Gradle. The authors, Ryan and Lee, will take the user from a point of having just a basic development background to being able to implement Gradle in a variety of languages, utilizing Gradle in some beneficial ways including continuous integration and artifact management.

You will learn to build and deploy your code effectively. Gradle is quickly becoming the de facto build tool for Java, Groovy, C++, and other platforms, and is rapidly replacing Maven and Ant systems. Learn how to integrate your IDE, leverage Ant or Maven build assets, deploy artifacts, and integrate with continuous integration servers. You can follow along with step-by-step instructions for the most common IDEs, programming languages, and artifact servers to implement.

You will leave the course feeling like you have a good handle on Gradle and confident to begin planning and building your implementation.

About the Author

Lee Fox is a technologist with a strong background in software development. He has served in architecture roles for companies like 3M, AT&T Wi-Fi Services, Borland, and Pervasive. His software development history has always focused on maintaining quality. He is an Agile pragmatist as he strives to help organizations become more effective in their technical and software development implementations while maintaining a high degree of quality. Lee received his Bachelor of Science in Computer Science from Southwest Texas State University. He is also a Certified ScrumMaster and Trained Innovation Games Facilitator. Lee is co-founder of Xan Endeavors.

Ryan is the Chief Systems and Software Architect and Director of Products at ReachForce, and was formerly Lead Architect. He maintains the grails-quartz plugin, GVPS Grails plugin, and Struts 1 plugins, and is co-chair of the Austin Groovy and Grails User Group in Austin, TX. Ryan is currently building a Grails infrastructure for ReachForce as well as teaching Grails to the developer team. Ryan is also the co-founder of Xan Endeavors, LLC, a collaboration of software development, consulting, coaching, and innovation games. In the past, Ryan has architected a Grails solution that allows rapid deployment of Developer Program portals for all kinds of companies, specializing in the mobile industry. He has also built Java- and Linux-based webcasting for events such as SXSW, built telecom software, and SaaS systems for the financial sector.

What are the requirements?

  • Basic Java development knowledge is a prerequisite.
  • This example-driven video tutorial shows you how to effectively implement Gradle in your projects through a variety of plugins and integration techniques.

What am I going to get from this course?

  • Create a build.gradle file and manage build dependencies
  • Integrate Gradle with popular IDEs such as IntelliJ, Eclipse, and Netbeans
  • Build Java, Scala, and Groovy applications with Gradle
  • Implement C/C++ and JavaScript applications with Gradle
  • Utilize Gradle within a Continuous Integration Loop
  • Integrate Gradle with Artifact Management
  • Incorporate external dependencies such as Maven and Ivy repositories

What is the target audience?

  • If you are a developer, devops engineer, build engineer, or IT administrator and wish to effectively implement Gradle in your projects, this course is for you. The course takes you through the installation process and how to set up your projects followed by dependency management, IDE integration, and plugin implementations. You also learn to deploy and publish your application.

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.

Curriculum

Section 1: Getting Started
Introduction
02:27
00:24

Even though we need to start somewhere, there are still some things that are required as prerequisites. In this section, we will look at the prerequisites you need to have in place before you install Gradle.

02:56

Installing software on various platforms can be annoying. Fortunately, there is a tool called GVM that will make installing Gradle and keeping track of versions much easier. In this section, we will take a look at installing and using GVM.

06:07

Sometimes, there is a need to manually install Gradle. In this section, we will show you how to install Gradle on Windows, OS X, and Linux.

05:26

Not every installation goes as smoothly as we would like. So, in this section, we will look at some common problems and solutions to help you past issues while installing Gradle.

05:05

Gradle has a lot of structure in its default binary installation. Getting to know that structure will help you better create the builds that best fit your environment. In this section, we will look at the binary installation structure for Gradle itself.

01:28

The default Gradle project has a good deal of structure. To ensure the structure helps you rather than hinders you, we will look at the default project structure in this section.

01:45

With today's technology, portability is a need that is almost always there, but sometimes overlooked. Gradle has a facility called Gradle wrapper to help with portability issues. In this section, we will look at the Gradle wrapper.

00:23

In this section we've learnt how to install Gradle and keep up with current versions of Gradle.

Section 2: Gradle Tasks
00:53

In this section we'll learn how to create Tasks in Gradle.

04:29

The heart and soul of a Gradle configuration is the build.gradle file. In this section, we will have a look at it.

03:04

With Gradle so tightly involved with its Groovy-based DSL, it makes sense to spend some time getting to know Groovy. In this section, we will get a quick taste of Groovy.

01:48

How to create a task on the fly that isn't predeclared in your build file.

02:43

Control flow of the execution of tasks in the case of errors. Also, control flow by making some tasks always run before or after others to avoid build code duplication.

01:46

If you are coming from an Ant environment, it'll be nice to know how to leverage your Ant builds to make the transition easier and more cost effective. In this section, we will look at using Ant tasks to do so.

04:04

We will see how to control the flow of certain tasks during the execution phase to create different types of artifacts. If certain dynamic tasks are available at runtime, we need to take certain actions.

Section 3: Java, Groovy, and WAR Plugins
00:24

In this section we're going to cover how to build and setup a basic and multimodule Java Project.

03:09

What kind of tasks do we need to know about to build a Java project? We will go over the tasks of the Java plugin and how to run it.

05:31

Learn how to hook into Maven and publish an artifact to your local repository.

05:02

Learn how test code is normally organized, what frameworks are supported, and how to write tests.

02:26

Walk through an example multimodule project and see how to access tasks from subprojects. Learn proper structure and how to use them to bring in a Maven or Ivy sub project.

04:31

Create a ZIP file with your application and related files for distribution.

01:24

Build a Groovy project and learn how to use the tasks. Learn how the srcDir property works in relation to Groovy files.

04:55

For an average Java developer, the endgame of a build environment is to turn out a WAR file. In this section, we will look at how we can create a WAR file using Gradle.

00:27

In this section we covered a bunch of things such as Java and Groovy plugin tasks, hooking into Maven, Testing, and WAR files.

Section 4: IDE Integration
00:15

In this section we'll cover IDE integration

03:15

IntelliJ IDEA is a very popular and very powerful IDE. In this section, we will look at integrating Gradle with IntelliJ IDEA and build a sample project in the IDE.

03:13

Eclipse is a very popular and free IDE that is chock-full of features. In this section, we will look at integrating Eclipse with Gradle and build a project.

03:07

NetBeans is a rather powerful IDE with a wide reach. In this section, we will look at the support for Gradle and build a sample project.

00:18

In this section we looked at three popular IDEs, IntelliJ Idea, Eclipse, and NetBeans.

Section 5: Dependency Management
01:56

In this section we'll be talking about Dependency Management.

01:05

Learn what the different dependency types are in Gradle and see examples of each in action.

02:35

See how to use a runtime, compile, test, and project dependency for your project.

04:19

Configure dependencies for Maven and Ivy repositories. See examples of long and short notation to resolve artifacts.

01:40

Publish Maven and Ivy artifacts like a pro on a local Maven repository or remote Ivy repository.

02:07

How do you keep test libraries out of your distributable artifacts? Use configurations like scopes and see examples in action.

00:27

·In this section we've covered the six types of dependencies, internal and external dependencies, Maven and Ivy repositories, and declaring dependencies.

Section 6: C++ Support
00:42

In this section we'll jump into building native binaries with our Gradle Scripts.

00:45

What does the CPP plugin support? In this section, we will look at the platform support and the language support offered by the plugin.

02:35

How do you install the CPP plugin? Here, we will show what plugins to use and give you an overview of their tasks.

02:02

How do you build a library? What tasks help you build a library? This section will show how to build a shared or static library.

01:44

This section will show how to build a native executable and show how to use the toolchain variable.

03:20

We dive deeper into the CPP plugin tasks to build and install executables.

02:11

Here, we show how to configure different compiler and linkers. Use the toolchain variable and binary types to build on multiple platforms.

02:21

Advances with external dependencies since 1.11 and what is still lacking.

02:01

Use the multimodule project in concert with a native CPP project.

03:08

We will go over your options for publishing the native artifacts support and a plugin to help you do so.

02:35

Portability and internationalization can be challenging. In this section, we will address that through the use of variants like platforms and flavors.

Section 7: Building JavaScript (gradle-js-plugin)
01:30

In this section we'll talk about the Gradle JavaScript plugin

02:01

A build system that can entertain JavaScript files is a very awesome thing. In this section, we will look at enabling the GradleJS plugin and specifying our JavaScript files for a build.

01:44

Lots of web applications seem to have numerous JavaScript files that keep code scattered and unorganized. In this section, we will see how the Gradle JavaScript plugin helps to manage the chaos by combining the sources.

01:54

Discovering problems early can really help improve a project's development. In this section, we will look at how static code analysis using JSHint can accomplish that for JavaScript

02:18

Even JavaScript developers need to produce documentation. JSDoc offers a solution to help generate some of that documentation from source listings. In this section, we will look at integrating JSDoc with Gradle.

02:04

It's nice to have a way to manage configuration files and settings when doing JavaScript development. In this section, we will look at how to integrate Props2Js into our Gradle builds.

02:28

To help improve the quality of our JavaScript code, we need a script loader to help us out. This section will show how to integrate Gradle with RequireJS to achieve those aims.

01:00

If you are developing JavaScript, you are most likely going to be using a lot of CSS. In this section, we will lightly cover the Gradle CSS plugin to help you deal with CSS files in your build.

00:45

In this section we broadly covered the Gradle JavaScript plugin and lightly touched on the functionality in the CSS plugin.

Section 8: Building Scala
00:18

In this section we'll learn about the Scala Plugin Support.

04:09

When starting to learn about a new plugin, it's nice to go over the basics of that plugin. In this section, we will look at enabling the Scala plugin and go over some of the tasks it provides.

01:21

To best use the Scala plugin, we need to understand how it's laid out. In this section, we will explore the layout of a Scala project and how to specify sources.

04:00

The Scala plugin offers us several options for compiler support. To help alleviate confusion, this section will take a look at compiler setup and compilation with the Scala plugin.

01:16

Dependencies are a crucial item to understand and handle for any development. Scala is no different. In this section, we will look at dependencies with the Scala plugin.

01:06

Nothing will drive a developer crazier than a slow build. In this section, we will try to save some developer sanity by seeing how we can speed up a Scala build with Fast Compiler Support.

00:19

In this section we've covered usage and Tasks, Project Layout, Compiler Setup, Dependencies, and Fast Compiler Support.

Section 9: Continuous Integration Servers
04:01

Let's understand what is Continuous Integration.

06:34

Jenkins is a very powerful continuous integration server in wide use across the industry. In this section, we will look at integrating Jenkins and Gradle. Then we will configure a Jenkins Gradle build.

07:01

TeamCity is a very solid continuous integration server made by JetBrains. It's vastly popular for companies willing to invest money into this part of their infrastructure. In this section, we will look at the support TeamCity has for Gradle and run a Gradle build.

03:00

Bamboo is Atlassian's continuous integration server. In this section, we will look at Gradle integration with Bamboo and configure a Gradle build.

00:49

In this section we learnt about what Continuous Integration is, and covered three of the most popular CI servers.

Section 10: Repository Managers
00:46

In this section we'll learn what a Repository Manager is, and which of the Repository Managers are recommended.

05:30

Artifactory is a very popular repository manager. In this section, we will look at Artifactory integration with Gradle.

06:47

Bintray is becoming more and more popular with developers. In this section, we will look at integrating your Gradle builds with bintray.

03:11

Nexus is a great standard for repository managers. In this section, we will look at Gradle integration with Nexus.

00:19

In this section we've covered publishing your project to a repository manager service, whether its Artifactory, Bintray or Nexus.

Students Who Viewed This Course Also Viewed

  • Loading
  • Loading
  • Loading

Instructor Biography

Packt Publishing, Tech Knowledge in Motion

Over the past ten years Packt Publishing has developed an extensive catalogue of over 2000 books, e-books and video courses aimed at keeping IT professionals ahead of the technology curve. From new takes on established technologies through to the latest guides on emerging platforms, topics and trends – Packt's focus has always been on giving our customers the working knowledge they need to get the job done. Our Udemy courses continue this tradition, bringing you comprehensive yet concise video courses straight from the experts.

Ready to start learning?
Take This Course