Skip to content

Commit 87f42d0

Browse files
committed
added gradlew update script
1 parent cb99af6 commit 87f42d0

File tree

4 files changed

+31
-2
lines changed

4 files changed

+31
-2
lines changed

mode/gradlew.zip

51.9 KB
Binary file not shown.

scripts/gradlew-update.sh

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Needs gradle to be installed:
2+
# https://docs.gradle.org/current/userguide/installation.html
3+
4+
# Usage:
5+
# call with the version number of the gradle version to be used by gradlew, i.e.:
6+
# ./gradlew-update.sh 3.2.1:
7+
8+
version=$1
9+
10+
mkdir gradlew
11+
cd gradlew
12+
# Create a wrapper install as described here:
13+
# https://docs.gradle.org/current/userguide/gradle_wrapper.html#sec:wrapper_generation
14+
gradle wrapper --gradle-version $version
15+
cd ..
16+
17+
# Package and move to the mode folder
18+
zip -r gradlew.zip gradlew -x *.gradle*
19+
mv gradlew.zip ../mode
20+
21+
# Remove install
22+
rm -Rf gradlew
23+
24+
25+

scripts/info.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,8 @@ perm-parse.py: generates the array of permissions for a given SDK level, to be p
1111
Permissions.java
1212

1313
wear-update.sh: downloads the wearable aar file from a known maven repository, and
14-
extracts the classes jar and copies it inside core/library
14+
extracts the classes jar and copies it inside core/library
15+
16+
gradlew-update.sh: creates the gradle wrapper with the desired gradle version and packs
17+
it in the mode folder to be available when exporting projects using gradle as the build
18+
system

scripts/wear-update.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# call with the version number of the wearable package to copy from local SDK and extract, i.e.:
1616
# ./wear-update.sh 2.0.0-beta2:
1717

18-
version=2.0.0
18+
version=$1
1919

2020
cp $ANDROID_SDK/extras/google/m2repository/com/google/android/support/wearable/$version/wearable-$version.aar .
2121

0 commit comments

Comments
 (0)