Skip to content

Commit

Permalink
Rename BraintreeApi module to Braintree
Browse files Browse the repository at this point in the history
  • Loading branch information
lkorth committed Feb 1, 2016
1 parent 74b3249 commit 242c986
Show file tree
Hide file tree
Showing 155 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion BraintreeApi/build.gradle → Braintree/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ task runAllTests {
}

gradle.taskGraph.whenReady { taskGraph ->
def RUN_ALL_TESTS = taskGraph.hasTask(':BraintreeApi:runAllTests')
def RUN_ALL_TESTS = taskGraph.hasTask(':Braintree:runAllTests')
android.buildTypes.debug.buildConfigField('boolean', 'RUN_ALL_TESTS', '' + RUN_ALL_TESTS)
}

Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ Please note: It is not currently possible to run tests outside of Braintree.

There are several components that comprise this SDK:

* [BraintreeApi](BraintreeApi) provides the networking, communication and modeling layer for Braintree.
* [Braintree](Braintree) provides the networking, communication and modeling layer for Braintree.
* [BraintreeDataCollector](BraintreeDataCollector) collects and provides data for fraud detection.
* [Core](Core) provides shared code across all the modules in the SDK.
* [Drop-In](Drop-In) uses `BraintreeApi` to create a full checkout experience inside an `Activity`.
* [Drop-In](Drop-In) uses `Braintree` to create a full checkout experience inside an `Activity`.
* [Demo](Demo) is the reference integration of [Drop-In](Drop-In).
* [PayPalOneTouch](PayPalOneTouch) provides support for PayPal app and browser switch.
* [PayPalDataCollector](PayPalDataCollector) collects and provides data for PayPal fraud detection.
Expand Down
2 changes: 1 addition & 1 deletion Drop-In/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ android {

dependencies {
compile 'com.braintreepayments:card-form:2.1.1'
compile project(':BraintreeApi')
compile project(':Braintree')
compile 'com.google.android.gms:play-services-wallet:[8.4.0,9.0.0)'

androidTestCompile project(path: ':TestUtils', configuration: 'instrumentationTestDebug')
Expand Down
20 changes: 10 additions & 10 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
require 'rake'

PAYPAL_ONE_TOUCH_BUILD_GRADLE = "PayPalOneTouch/build.gradle"
BRAINTREE_API_BUILD_GRADLE = "BraintreeApi/build.gradle"
BRAINTREE_API_BUILD_GRADLE = "Braintree/build.gradle"
DROP_IN_BUILD_GRADLE = "Drop-In/build.gradle"

task :default => :tests
Expand Down Expand Up @@ -46,17 +46,17 @@ task :publish_snapshot => :tests do
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile project(':Core')", "compile 'com.braintreepayments.api:core:#{get_current_version}'")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile project(':BraintreeDataCollector')", "compile 'com.braintreepayments.api:data-collector:#{get_current_version}'")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile project(':PayPalOneTouch')", "compile 'com.paypal.android.sdk:paypal-one-touch:#{get_current_version}'")
sh "./gradlew clean :BraintreeApi:uploadArchives"
sh "./gradlew clean :Braintree:uploadArchives"

replace_string(DROP_IN_BUILD_GRADLE, "compile project(':BraintreeApi')", "compile 'com.braintreepayments.api:braintree:#{get_current_version}'")
replace_string(DROP_IN_BUILD_GRADLE, "compile project(':Braintree')", "compile 'com.braintreepayments.api:braintree:#{get_current_version}'")
sh "./gradlew clean :Drop-In:uploadArchives"

replace_string(PAYPAL_ONE_TOUCH_BUILD_GRADLE, "compile 'com.braintreepayments.api:core:#{get_current_version}'", "compile project(':Core')")
replace_string(PAYPAL_ONE_TOUCH_BUILD_GRADLE, "compile 'com.paypal.android.sdk:data-collector:#{get_current_version}'", "compile project(':PayPalDataCollector')")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile 'com.braintreepayments.api:core:#{get_current_version}'", "compile project(':Core')")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile 'com.braintreepayments.api:data-collector:#{get_current_version}'", "compile project(':BraintreeDataCollector')")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile 'com.paypal.android.sdk:paypal-one-touch:#{get_current_version}'", "compile project(:PayPalOneTouch')")
replace_string(DROP_IN_BUILD_GRADLE, "compile 'com.braintreepayments.api:braintree:#{get_current_version}'", "compile project(':BraintreeApi')")
replace_string(DROP_IN_BUILD_GRADLE, "compile 'com.braintreepayments.api:braintree:#{get_current_version}'", "compile project(':Braintree')")
end

desc "Interactive release to publish new version"
Expand Down Expand Up @@ -138,12 +138,12 @@ task :release_braintree_api, :version do |t, args|
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile project(':Core')", "compile 'com.braintreepayments.api:core:#{version}'")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile project(':BraintreeDataCollector')", "compile 'com.braintreepayments.api:data-collector:#{version}'")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile project(':PayPalOneTouch')", "compile 'com.paypal.android.sdk:paypal-one-touch:#{version}'")
sh "./gradlew clean :BraintreeApi:uploadArchives"
puts "BraintreeApi was uploaded, releasing..."
sh "./gradlew :BraintreeApi:closeRepository"
sh "./gradlew clean :Braintree:uploadArchives"
puts "Braintree was uploaded, releasing..."
sh "./gradlew :Braintree:closeRepository"
puts "Sleeping for one minute to allow closing to finish"
sleep 60
sh "./gradlew :BraintreeApi:promoteRepository"
sh "./gradlew :Braintree:promoteRepository"
puts "Sleeping for ten minutes to allow promotion to finish"
sleep 600
end
Expand All @@ -152,7 +152,7 @@ task :release_drop_in, :version do |t, args|
version = args[:version]
abort("A version must be provided") unless version != nil

replace_string(DROP_IN_BUILD_GRADLE, "compile project(':BraintreeApi')", "compile 'com.braintreepayments.api:braintree:#{version}'")
replace_string(DROP_IN_BUILD_GRADLE, "compile project(':Braintree')", "compile 'com.braintreepayments.api:braintree:#{version}'")
sh "./gradlew clean :Drop-In:uploadArchives"
puts "Drop-In was uploaded, releasing..."
sh "./gradlew :Drop-In:closeRepository"
Expand All @@ -174,7 +174,7 @@ task :post_release, :version do |t, args|
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile 'com.braintreepayments.api:core:#{version}'", "compile project(':Core')")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile 'com.braintreepayments.api:data-collector:#{version}'", "compile project(':BraintreeDataCollector')")
replace_string(BRAINTREE_API_BUILD_GRADLE, "compile 'com.paypal.android.sdk:paypal-one-touch:#{version}'", "compile project(':PayPalOneTouch')")
replace_string(DROP_IN_BUILD_GRADLE, "compile 'com.braintreepayments.api:braintree:#{version}'", "compile project(':BraintreeApi')")
replace_string(DROP_IN_BUILD_GRADLE, "compile 'com.braintreepayments.api:braintree:#{version}'", "compile project(':Braintree')")
update_version("#{version}-SNAPSHOT")
sh "git commit -am 'Prepare for development'"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
import static android.support.test.InstrumentationRegistry.getTargetContext;

/**
* Provides managed access to shared preferences used by BraintreeApi, et al.
* Provides managed access to shared preferences used by Braintree, et al.
*/
public class SharedPreferencesHelper {

/**
* @return Shared Preferences used in BraintreeApi
* @return Shared Preferences used in Braintree
*/
public static SharedPreferences getSharedPreferences() {
return getTargetContext().getSharedPreferences("BraintreeApi", Context.MODE_PRIVATE);
Expand Down
2 changes: 1 addition & 1 deletion settings.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ':BraintreeApi'
include ':Braintree'
include ':PayPalDataCollector'
include ':BraintreeDataCollector'
include ':Drop-In'
Expand Down

0 comments on commit 242c986

Please sign in to comment.