Skip to content

Commit

Permalink
packages/react-native-gradle-plugin/ -> packages/gradle-plugin/ (face…
Browse files Browse the repository at this point in the history
…book#44832)

Summary:
Pull Request resolved: facebook#44832

I'm renaming this folder as now we have 2 gradle plugins + we currently have
`package/react-native-gradle-plugin/react-native-gradle-plugin/` which is confusing so we can just call this folder `packages/gradle-plugin/`
to be consistent with the NPM package name

Changelog:
[Internal] [Changed] - packages/react-native-gradle-plugin/ -> packages/gradle-plugin/

Reviewed By: blakef

Differential Revision: D58284883

fbshipit-source-id: 5a7bb40a5d80f6fbab4ffb29e44107453f1013ec
  • Loading branch information
cortinico authored and facebook-github-bot committed Jun 21, 2024
1 parent 3429dc1 commit 15909fa
Show file tree
Hide file tree
Showing 91 changed files with 30 additions and 21 deletions.
11 changes: 7 additions & 4 deletions .circleci/configurations/jobs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,10 @@ jobs:
- packages/react-native/ReactAndroid/hermes-engine/.cxx/
- packages/react-native/ReactAndroid/hermes-engine/build/
- packages/react-native/ReactAndroid/src/main/jni/prebuilt/
- packages/react-native-gradle-plugin/.gradle/
- packages/react-native-gradle-plugin/build/
- packages/gradle-plugin/.gradle/
- packages/gradle-plugin/react-native-gradle-plugin/build/
- packages/gradle-plugin/settings-plugin/build/
- packages/gradle-plugin/shared/build/
- packages/react-native-codegen/lib/

# -------------------------
Expand Down Expand Up @@ -181,8 +183,9 @@ jobs:
platform: android

- store_test_results:
path: ~/react-native/packages/react-native-gradle-plugin/build/test-results

path: ~/react-native/packages/gradle-plugin/react-native-gradle-plugin/build/test-results
- store_test_results:
path: ~/react-native/packages/gradle-plugin/settings-plugin/build/test-results
- store_test_results:
path: ~/react-native/packages/react-native/ReactAndroid/build/test-results

Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -493,8 +493,8 @@ jobs:
name: build-android-results
compression-level: 1
path: |
packages/react-native-gradle-plugin/react-native-gradle-plugin/build/reports
packages/react-native-gradle-plugin/settings-plugin/build/reports
packages/gradle-plugin/settings-plugin/build/reports
packages/gradle-plugin/react-native-gradle-plugin/build/reports
packages/react-native/ReactAndroid/build/reports
- name: Upload RNTester APK
if: ${{ always() }}
Expand All @@ -503,6 +503,7 @@ jobs:
name: rntester-apk
path: packages/rn-tester/android/app/build/outputs/apk/
compression-level: 0

build_npm_package:
runs-on: 8-core-ubuntu
needs: [set_release_type, prepare_hermes_workspace, build_hermes_macos, build_hermesc_linux, build_hermesc_windows,build_android]
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -492,8 +492,8 @@ jobs:
name: build-android-results
compression-level: 1
path: |
packages/react-native-gradle-plugin/react-native-gradle-plugin/build/reports
packages/react-native-gradle-plugin/settings-plugin/build/reports
packages/gradle-plugin/react-native-gradle-plugin/build/reports
packages/gradle-plugin/settings-plugin/build/reports
packages/react-native/ReactAndroid/build/reports
- name: Upload RNTester APK
if: ${{ always() }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test-all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -565,8 +565,8 @@ jobs:
name: build-android-results
compression-level: 1
path: |
packages/react-native-gradle-plugin/react-native-gradle-plugin/build/reports
packages/react-native-gradle-plugin/settings-plugin/build/reports
packages/gradle-plugin/react-native-gradle-plugin/build/reports
packages/gradle-plugin/settings-plugin/build/reports
packages/react-native/ReactAndroid/build/reports
- name: Upload RNTester APK
if: ${{ always() }}
Expand Down
4 changes: 2 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ nexusPublishing {

tasks.register("clean", Delete::class.java) {
description = "Remove all the build files and intermediate build outputs"
dependsOn(gradle.includedBuild("react-native-gradle-plugin").task(":clean"))
dependsOn(gradle.includedBuild("gradle-plugin").task(":clean"))
subprojects.forEach {
if (it.project.plugins.hasPlugin("com.android.library") ||
it.project.plugins.hasPlugin("com.android.application")) {
Expand All @@ -86,7 +86,7 @@ tasks.register("clean", Delete::class.java) {

tasks.register("build") {
description = "Build and test all the React Native relevant projects."
dependsOn(gradle.includedBuild("react-native-gradle-plugin").task(":build"))
dependsOn(gradle.includedBuild("gradle-plugin").task(":build"))
}

tasks.register("publishAllToMavenTempLocal") {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
build/
app-plugin/build/
react-native-gradle-plugin/build/
settings-plugin/build/
shared/build/
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ yarn add @react-native/gradle-plugin
To run the tests in this package, run the following commands from the React Native root folder:

1. `yarn` to install the dependencies. You just need to run this once
2. `yarn jest packages/react-native-gradle-plugin`.
2. `./gradlew -p packages/gradle-plugin test`.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
@REM Copyright (c) Meta Platforms, Inc. and affiliates.
@REM
@REM This source code is licensed under the MIT license found in the
@REM LICENSE file in the root directory of this source tree.

@rem
@rem Copyright 2015 the original author or authors.
@rem
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
"repository": {
"type": "git",
"url": "git+https://github.com/facebook/react-native.git",
"directory": "packages/react-native-gradle-plugin"
"directory": "packages/gradle-plugin"
},
"homepage": "https://github.com/facebook/react-native/tree/HEAD/packages/react-native-gradle-plugin#readme",
"homepage": "https://github.com/facebook/react-native/tree/HEAD/packages/gradle-plugin#readme",
"keywords": [
"gradle",
"plugin",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ include(
":shared",
)

rootProject.name = "gradle-plugins-root"
rootProject.name = "gradle-plugin-root"
4 changes: 2 additions & 2 deletions packages/helloworld/android/settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@
*/

// Autolinking has now moved into the React Native Gradle Plugin
pluginManagement { includeBuild("../../react-native-gradle-plugin") }
pluginManagement { includeBuild("../../gradle-plugin") }
plugins { id("com.facebook.react.settings") }
extensions.configure(com.facebook.react.ReactSettingsExtension){ ex -> ex.autolinkLibrariesFromCommand() }

rootProject.name = 'HelloWorld'
include ':app'
includeBuild('../../react-native-gradle-plugin')
includeBuild('../../gradle-plugin')
includeBuild('../../react-native') {
dependencySubstitution {
substitute(module("com.facebook.react:react-android")).using(project(":packages:react-native:ReactAndroid"))
Expand Down
4 changes: 2 additions & 2 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pluginManagement {
google()
gradlePluginPortal()
}
includeBuild("packages/react-native-gradle-plugin/")
includeBuild("packages/gradle-plugin/")
}

include(
Expand All @@ -20,7 +20,7 @@ include(
":packages:react-native:ReactAndroid:external-artifacts",
":packages:rn-tester:android:app")

includeBuild("packages/react-native-gradle-plugin/")
includeBuild("packages/gradle-plugin/")

dependencyResolutionManagement {
versionCatalogs {
Expand Down

0 comments on commit 15909fa

Please sign in to comment.