Skip to content

Commit 9193c4f

Browse files
fkgozalifacebook-github-bot
authored andcommitted
rn_codegen: renamed src_prefix to codegen_src_prefix (#36866)
Summary: Pull Request resolved: #36866 For consistency with internal build rules, rename this kwarg. This will make it easier to keep both internal and external usages consistent. Changelog: [General][Changed] react-native-codegen: Buck-only: renamed src_prefix kwarg Reviewed By: sammy-SC Differential Revision: D44857745 fbshipit-source-id: 475658281a6c2846be42e130f81e23dfcae5856b
1 parent 71506ce commit 9193c4f

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

BUCK

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -769,23 +769,23 @@ rn_codegen(
769769
name = "FBReactNativeSpec",
770770
android_package_name = "com.facebook.fbreact.specs",
771771
codegen_modules = True,
772+
codegen_src_prefix = "packages/react-native/Libraries/",
772773
ios_assume_nonnull = False,
773774
library_labels = [
774775
"pfh:ReactNative_CommonInfrastructurePlaceholder",
775776
],
776777
native_module_spec_name = "FBReactNativeSpec",
777-
src_prefix = "packages/react-native/Libraries/",
778778
)
779779

780780
# TODO: Merge this into FBReactNativeSpec
781781
rn_codegen(
782782
name = "FBReactNativeComponentSpec",
783783
codegen_components = True,
784+
codegen_src_prefix = "packages/react-native/Libraries/",
784785
ios_assume_nonnull = False,
785786
library_labels = [
786787
"pfh:ReactNative_CommonInfrastructurePlaceholder",
787788
],
788-
src_prefix = "packages/react-native/Libraries/",
789789
)
790790

791791
rn_apple_library(

tools/build_defs/oss/rn_codegen_defs.bzl

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def rn_codegen(
3131
codegen_components = False,
3232
codegen_modules = False,
3333
library_labels = [],
34-
src_prefix = "",
34+
codegen_src_prefix = "",
3535
external_spec_target = None):
3636
if codegen_modules:
3737
error_header = "rn_codegen(name=\"{}\")".format(name)
@@ -43,11 +43,11 @@ def rn_codegen(
4343

4444
spec_srcs = native.glob(
4545
[
46-
src_prefix + "**/Native*.js",
47-
src_prefix + "**/Native*.ts",
46+
codegen_src_prefix + "**/Native*.js",
47+
codegen_src_prefix + "**/Native*.ts",
4848
],
4949
exclude = [
50-
src_prefix + "**/nativeImageSource.js",
50+
codegen_src_prefix + "**/nativeImageSource.js",
5151
"**/__*__/**",
5252
],
5353
)
@@ -82,8 +82,8 @@ def rn_codegen(
8282
name = "codegen_rn_components_schema_{}".format(component_spec_name),
8383
srcs = native.glob(
8484
[
85-
src_prefix + "**/*NativeComponent.js",
86-
src_prefix + "**/*NativeComponent.ts",
85+
codegen_src_prefix + "**/*NativeComponent.js",
86+
codegen_src_prefix + "**/*NativeComponent.ts",
8787
],
8888
exclude = [
8989
"**/__*__/**",

0 commit comments

Comments
 (0)