Skip to content

Commit

Permalink
Per build output, change "flavorDimension" to "dimension"
Browse files Browse the repository at this point in the history
This gets rid of the Gradle output "'flavorDimension' will be removed by Android Gradle Plugin 2.0, it has been replaced by 'dimension'."
  • Loading branch information
barbeau committed Aug 26, 2015
1 parent c3506d8 commit 4fd455e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions REBRANDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Here are the high-level steps to add a new brand, for a new brand name `newBrand
For Step 1, you new entry in `build.gradle` will look something like:

newBrandName {
flavorDimension "brand" // This line is always the same for all brands - it tells Gradle that this entry is for a brand
dimension "brand" // This line is always the same for all brands - it tells Gradle that this entry is for a brand
applicationId "com.newbrandname.android" // This is the unique identifier for the listing of this brand on Google Play (typically its your unique domain name in reverse) - you would find this app at https://play.google.com/store/apps/details?id=com.newbrandname.android
manifestPlaceholders = [databaseAuthority: applicationId.toString() + '.provider'] // This line is always the same for all brands - it tells Gradle how to set up the database authority field for the brand
...
Expand Down Expand Up @@ -85,7 +85,7 @@ Valid values are `0` and `1` - The way that estimated arrival information is sho
Here's an example of how configuration options are set up for the sample agency "Agency X" in `build.gradle`:

agencyX {
flavorDimension "brand" // This line is always the same for all brands - it tells Gradle that this entry is for a brand
dimension "brand" // This line is always the same for all brands - it tells Gradle that this entry is for a brand
applicationId "org.agencyx.android" // This is the unique identifier for the listing of this brand on Google Play (typically its your unique domain name in reverse) - you can find this app at https://play.google.com/store/apps/details?id=org.agencyx.android
manifestPlaceholders = [databaseAuthority: applicationId.toString() + '.provider'] // This line is always the same for all brands - it tells Gradle how to set up the database authority field for the brand
buildConfigField "int", "ARRIVAL_INFO_STYLE", "0" // Use the original OneBusAway presentation of arrival times (i.e., Style A)
Expand All @@ -98,7 +98,7 @@ So, Agency X has elected to stick with the normal OneBusAway arrival time presen
The Agency Y sample has chosen different options - they are using `ARRIVAL_INFO_STYLE_B`, and have their app fixed to the region info provided in their brand flavor dimension entry:

agencyY {
flavorDimension "brand" // Always the same for all brands
dimension "brand" // Always the same for all brands
applicationId "org.agencyy.android" // Unique listing of this brand on app store
manifestPlaceholders = [databaseAuthority: applicationId.toString() + '.provider'] // Always the same for all brands
buildConfigField "int", "ARRIVAL_INFO_STYLE", "1" // Use the York Region Transit presentation of arrival times (i.e., Style B)
Expand Down
10 changes: 5 additions & 5 deletions onebusaway-android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ android {
productFlavors {
google {
// Normal Google Play release - see src/google
flavorDimension "platform"
dimension "platform"
}

amazon {
Expand All @@ -68,7 +68,7 @@ android {
* GoogleMap class with the Amazon equivalents. Therefore, the files in
* src/amazon/java/org/onebusaway/android/map should not be manually changed.
*/
flavorDimension "platform"
dimension "platform"
}

oba {
Expand All @@ -79,7 +79,7 @@ android {
* original package name of the app before it was re-branded to OneBusAway:
* com.joulespersecond.seattlebusbot
*/
flavorDimension "brand"
dimension "brand"
applicationId "com.joulespersecond.seattlebusbot"
manifestPlaceholders = [databaseAuthority: "com.joulespersecond.oba"]
buildConfigField "int", "ARRIVAL_INFO_STYLE", "1" // Defined in BuildFlavorConstants
Expand Down Expand Up @@ -112,7 +112,7 @@ android {

agencyX {
// "Agency X" rebranding OneBusAway as another app - see src/agencyX/res for branded resources
flavorDimension "brand"
dimension "brand"
applicationId "org.agencyx.android" // Unique listing of this brand on app store
manifestPlaceholders = [databaseAuthority: applicationId.toString() + '.provider']
buildConfigField "int", "ARRIVAL_INFO_STYLE", "0" // Defined in BuildFlavorConstants
Expand All @@ -136,7 +136,7 @@ android {

agencyY {
// "Agency Y" rebranding OneBusAway as another app - see src/agencyY/res for branded resources
flavorDimension "brand"
dimension "brand"
applicationId "org.agencyy.android" // Unique listing of this brand on app store
manifestPlaceholders = [databaseAuthority: applicationId.toString() + '.provider']
buildConfigField "int", "ARRIVAL_INFO_STYLE", "1" // Defined in BuildFlavorConstants
Expand Down

0 comments on commit 4fd455e

Please sign in to comment.