Skip to content

Commit

Permalink
[native] Don't always download Folly during Android build
Browse files Browse the repository at this point in the history
Summary:
From the [documentation](https://github.com/michel-kraemer/gradle-download-task#download-task) for the `Download` task:

> By default, the plugin always performs a download even if the destination file already exists. If you want to prevent files from being downloaded again, use the `overwrite` flag

I had copied [this configuration](karol-bisztyga/rnfbjni@704994b) from @karol-bisztyga's test repo, but React Native sets `overwrite(false)`. I don't think we need to download it every time.

Test Plan: Compile Android and make sure `downloadFolly` doesn't get re-run

Reviewers: karol-bisztyga, atul

Reviewed By: atul

Subscribers: KatPo, palys-swm, Adrian, karol-bisztyga

Differential Revision: https://phabricator.ashoat.com/D1230
  • Loading branch information
Ashoat committed May 24, 2021
1 parent d97bd43 commit 3e9b1b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion native/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ task createNativeDepsDirectories {
task downloadFolly(dependsOn: createNativeDepsDirectories, type: Download) {
src("https://github.com/facebook/folly/archive/v${FOLLY_VERSION}.tar.gz")
onlyIfNewer(true)
overwrite(true)
overwrite(false)
dest(new File(downloadsDir, "folly-${FOLLY_VERSION}.tar.gz"))
}

Expand Down

0 comments on commit 3e9b1b3

Please sign in to comment.