Skip to content
This repository has been archived by the owner on Apr 26, 2020. It is now read-only.

Commit

Permalink
Removed travis_fold, extracted dependency updates, made tool a module
Browse files Browse the repository at this point in the history
  • Loading branch information
DreierF committed Apr 3, 2017
1 parent 7b31697 commit 5aa864b
Show file tree
Hide file tree
Showing 12 changed files with 93 additions and 50 deletions.
7 changes: 7 additions & 0 deletions .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,12 @@ before_install:
- wget https://raw.githubusercontent.com/JakeWharton/pidcat/master/pidcat.py
install:
- git fetch --unshallow --tags
- chmod +x travis_fold
before_script:
- echo no | android create avd -f -n test -t "android-"$EMULATOR_API_LEVEL --abi $ANDROID_ABI -s WVGA800 -c 128M
- emulator -avd test -no-audio -no-window &
- ./gradlew clean
script:
- ./travis_fold assembleRelease ./gradlew assembleRegularRelease -PdisablePreDex
- ./gradlew assembleRegularRelease -PdisablePreDex
- android-wait-for-emulator
- adb shell settings put global window_animation_scale 0
- adb shell settings put global transition_animation_scale 0
Expand All @@ -55,7 +54,7 @@ after_success:
- |
if [[ "$TRAVIS_TAG" ]]; then
./gradlew publishRegularRelease
./gradlew -PFirebaseServiceAccountFilePath=$PWD/app/src/release/google-services.json :app:firebaseUploadRegularReleaseProguardMapping
./gradlew -PFirebaseServiceAccountFilePath=$PWD/app/src/release/google-services.json :app:firebaseUploadRegularReleaseProguardMapping --debug
./dropbox_uploader.sh upload app/build/outputs/apk/app-regular-release.apk /Release/$TRAVIS_TAG/MyTargets.apk
./dropbox_uploader.sh upload app/build/outputs/mapping/regular/release/mapping.txt /Release/$TRAVIS_TAG/mapping.txt
fi
Expand Down
14 changes: 7 additions & 7 deletions app/app.iml
Original file line number Diff line number Diff line change
Expand Up @@ -80,20 +80,20 @@
<sourceFolder url="file://$MODULE_DIR$/src/regularDebug/java" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/regularDebug/rs" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/regularDebug/shaders" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/androidTest/regular/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/androidTest/regular/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/androidTest/regular/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/androidTest/regular/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/androidTest/regular/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/androidTest/regular/debug" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/resValues/androidTest/regular/debug" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/rs" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/testRegularDebug/shaders" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/regular/res" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/regular/resources" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/regular/assets" type="java-resource" />
Expand Down
14 changes: 1 addition & 13 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -89,16 +89,4 @@ allprojects {

apply from: "tools/script-crowdin.gradle"
apply from: "tools/script-git-version.gradle"

dependencyUpdates.resolutionStrategy = {
componentSelection { rules ->
rules.all { selection ->
boolean rejected = ['alpha', 'preview', 'beta', 'rc', 'cr', 'm'].any { qualifier ->
selection.candidate.version ==~ /(?i).*[.-]${qualifier}[.\d-]*/
}
if (rejected) {
selection.reject('Release candidate')
}
}
}
}
apply from: "tools/script-dependency-updates.gradle"
1 change: 1 addition & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@
include ':app'
include ':wearable'
include ':shared'
include ':tools'
2 changes: 1 addition & 1 deletion shared/shared.iml
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" exported="" name="icepick-3.2.0" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="byte-buddy-agent-1.6.11" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="byte-buddy-1.6.11" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="runner-0.5" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="byte-buddy-1.6.11" level="project" />
<orderEntry type="library" exported="" name="data.priority-map-0.0.2" level="project" />
<orderEntry type="library" exported="" name="slingshot-0.10.3" level="project" />
<orderEntry type="library" exported="" name="support-core-ui-25.3.1" level="project" />
Expand Down
27 changes: 27 additions & 0 deletions tools/script-dependency-updates.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
/*
* Copyright (C) 2017 Florian Dreier
*
* This file is part of MyTargets.
*
* MyTargets is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2
* as published by the Free Software Foundation.
*
* MyTargets is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*/

dependencyUpdates.resolutionStrategy = {
componentSelection { rules ->
rules.all { selection ->
boolean rejected = ['alpha', 'preview', 'beta', 'rc', 'cr', 'm'].any { qualifier ->
selection.candidate.version ==~ /(?i).*[.-]${qualifier}[.\d-]*/
}
if (rejected) {
selection.reject('Release candidate')
}
}
}
}
38 changes: 20 additions & 18 deletions tools/script-git-version.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,25 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*/

buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'org.ajoberstar:grgit:1.9.0'
}
}

import org.ajoberstar.grgit.Grgit
import org.ajoberstar.grgit.Grgit

ext {
git = Grgit.open()
gitVersionCode = git.tag.list().size()
gitVersionName = git.describe()
.replace("v", "")
.replace("_b", "-Beta")
.replace("_rc", "-RC")
}
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'org.ajoberstar:grgit:1.9.0'
}
}

ext {
git = Grgit.open()
gitVersionCode = git.tag.list().size()
gitVersionName = git.describe()
.replace("v", "")
.replace("_b", "-Beta")
.replace("_rc", "-RC")

print("Code $gitVersionCode")
}
25 changes: 25 additions & 0 deletions tools/tools.iml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?>
<module external.linked.project.id=":tools" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$/.." external.system.id="GRADLE" type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="android-gradle" name="Android-Gradle">
<configuration>
<option name="GRADLE_PROJECT_PATH" value=":tools" />
</configuration>
</facet>
<facet type="java-gradle" name="Java-Gradle">
<configuration>
<option name="BUILD_FOLDER_PATH" value="$MODULE_DIR$/build" />
<option name="BUILDABLE" value="false" />
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<excludeFolder url="file://$MODULE_DIR$/.gradle" />
<excludeFolder url="file://$MODULE_DIR$/build" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
7 changes: 0 additions & 7 deletions travis_fold

This file was deleted.

2 changes: 1 addition & 1 deletion wearable/wearable.iml
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,8 @@
<orderEntry type="module" module-name="shared" exported="" />
<orderEntry type="library" exported="" name="icepick-3.2.0" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="byte-buddy-agent-1.6.11" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="byte-buddy-1.6.11" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="runner-0.5" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="byte-buddy-1.6.11" level="project" />
<orderEntry type="library" exported="" name="data.priority-map-0.0.2" level="project" />
<orderEntry type="library" exported="" name="slingshot-0.10.3" level="project" />
<orderEntry type="library" exported="" name="auto-common-0.3" level="project" />
Expand Down

0 comments on commit 5aa864b

Please sign in to comment.