This repository has been archived by the owner on Sep 8, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from praqma-training/wrapper_kata
add gradle-wrapper-basics kata
- Loading branch information
Showing
3 changed files
with
43 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Gradle Kata: Gradle Wrapper | ||
|
||
While you can use Gradle directly to run your build, the setup process is toilsome and having all your developers use the same version is a pain. The Gradle Wrapper script deals with these problems for you, and is the recommended way to use Gradle. | ||
|
||
## Setup | ||
|
||
Run `. setup.sh` | ||
|
||
Then enter the `exercises` directory. | ||
|
||
## The task | ||
The `exercises` directory is the root of your new project, where you want to use Gradle to build it. | ||
|
||
1. Run `gradlew wrapper` | ||
1. Examine the generated files. The following files and folders have been created: | ||
* .gradle/ | ||
* gradle/ | ||
* gradlew | ||
* gradlew.bat | ||
1. Run `gradlew --version` and verify that the version is the same as when running `gradle --version` | ||
1. Run `./gradlew wrapper --gradle-version 5.6.4` to update the version used by the gradle wrapper | ||
1. Run `gradlew --version` again | ||
1. Run `gradle --version` again | ||
|
||
## Useful commands | ||
* `gradle wrapper` | ||
* `gradle wrapper --gradle-version x.y.z` | ||
* `gradle --version` and `gradlew --version` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
echo "[KATA] Setting up the kata" | ||
echo "[KATA] ------" | ||
echo "[KATA] " | ||
|
||
echo "[KATA] Cleaning up old exercise" | ||
rm -rf exercise/ | ||
|
||
echo "[KATA] Initializing new exercise" | ||
mkdir exercise | ||
cd exercise | ||
|
||
echo "[KATA] Done!" |