Skip to content

Commit e79af65

Browse files
authored
Merge branch 'main' into wmaj/nanospinner
2 parents d24109d + 5316cb7 commit e79af65

File tree

30 files changed

+161
-86
lines changed

30 files changed

+161
-86
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ Our release cycle is independent of `react-native`. We follow semver and here is
2323

2424
| `@react-native-community/cli` | `react-native` |
2525
| ------------------------------------------------------------------ | ------------------------- |
26-
| [^19.0.0](https://github.com/react-native-community/cli/tree/main) | ^0.80.0 |
26+
| [^20.0.0](https://github.com/react-native-community/cli/tree/main) | ^0.81.0 |
27+
| [^19.0.0](https://github.com/react-native-community/cli/tree/19.x) | ^0.80.0 |
2728
| [^18.0.0](https://github.com/react-native-community/cli/tree/18.x) | ^0.79.0 |
2829
| [^15.0.0](https://github.com/react-native-community/cli/tree/15.x) | ^0.76.0, ^0.77.0, ^0.78.0 |
2930
| [^14.0.0](https://github.com/react-native-community/cli/tree/14.x) | ^0.75.0 |

lerna.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "19.0.0",
2+
"version": "20.0.0",
33
"npmClient": "yarn",
44
"exact": true,
55
"$schema": "node_modules/lerna/schemas/lerna-schema.json"

packages/cli-clean/package.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
{
22
"name": "@react-native-community/cli-clean",
3-
"version": "19.0.0",
3+
"version": "20.0.0",
44
"license": "MIT",
55
"main": "build/index.js",
66
"publishConfig": {
77
"access": "public"
88
},
99
"types": "build/index.d.ts",
1010
"dependencies": {
11-
"@react-native-community/cli-tools": "19.0.0",
11+
"@react-native-community/cli-tools": "20.0.0",
1212
"chalk": "^4.1.2",
1313
"execa": "^5.0.0",
1414
"fast-glob": "^3.3.2"
@@ -19,13 +19,14 @@
1919
"!*.map"
2020
],
2121
"devDependencies": {
22-
"@react-native-community/cli-types": "19.0.0",
22+
"@react-native-community/cli-types": "20.0.0",
2323
"@types/prompts": "^2.4.4"
2424
},
2525
"homepage": "https://github.com/react-native-community/cli/tree/main/packages/cli-clean",
2626
"repository": {
2727
"type": "git",
2828
"url": "https://github.com/react-native-community/cli.git",
2929
"directory": "packages/cli-clean"
30-
}
30+
},
31+
"gitHead": "3614a01613030c0a328ad2e8bb5d897e5bae1456"
3132
}
Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
{
22
"name": "@react-native-community/cli-config-android",
3-
"version": "19.0.0",
3+
"version": "20.0.0",
44
"license": "MIT",
55
"main": "build/index.js",
66
"publishConfig": {
77
"access": "public"
88
},
99
"dependencies": {
10-
"@react-native-community/cli-tools": "19.0.0",
10+
"@react-native-community/cli-tools": "20.0.0",
1111
"chalk": "^4.1.2",
1212
"fast-glob": "^3.3.2",
1313
"fast-xml-parser": "^4.4.1"
@@ -19,12 +19,13 @@
1919
"native_modules.gradle"
2020
],
2121
"devDependencies": {
22-
"@react-native-community/cli-types": "19.0.0"
22+
"@react-native-community/cli-types": "20.0.0"
2323
},
2424
"homepage": "https://github.com/react-native-community/cli/tree/main/packages/cli-config-android",
2525
"repository": {
2626
"type": "git",
2727
"url": "https://github.com/react-native-community/cli.git",
2828
"directory": "packages/cli-config-android"
29-
}
29+
},
30+
"gitHead": "3614a01613030c0a328ad2e8bb5d897e5bae1456"
3031
}

packages/cli-config-android/src/config/findComponentDescriptors.ts

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,20 @@ import {extractComponentDescriptors} from './extractComponentDescriptors';
55
import {unixifyPaths} from '@react-native-community/cli-tools';
66

77
export function findComponentDescriptors(packageRoot: string) {
8-
const files = glob.sync('**/+(*.js|*.jsx|*.ts|*.tsx)', {
8+
let jsSrcsDir = null;
9+
try {
10+
const packageJson = fs.readFileSync(
11+
path.join(packageRoot, 'package.json'),
12+
'utf8',
13+
);
14+
jsSrcsDir = JSON.parse(packageJson).codegenConfig.jsSrcsDir;
15+
} catch (error) {
16+
// no jsSrcsDir, continue with default glob pattern
17+
}
18+
const globPattern = jsSrcsDir
19+
? `${jsSrcsDir}/**/+(*.js|*.jsx|*.ts|*.tsx)`
20+
: '**/+(*.js|*.jsx|*.ts|*.tsx)';
21+
const files = glob.sync(globPattern, {
922
cwd: unixifyPaths(packageRoot),
1023
onlyFiles: true,
1124
ignore: ['**/node_modules/**'],

packages/cli-config-android/src/config/findManifest.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,14 @@ export default function findManifest(folder: string) {
1414
let manifestPaths = glob.sync('**/AndroidManifest.xml', {
1515
cwd: unixifyPaths(folder),
1616
ignore: [
17-
'node_modules/**',
1817
'**/build/**',
1918
'**/debug/**',
2019
'Examples/**',
2120
'examples/**',
22-
'**/Pods/**',
2321
'**/sdks/hermes/android/**',
2422
'**/src/androidTest/**',
2523
'**/src/test/**',
24+
'**/.cxx/**',
2625
],
2726
});
2827
if (manifestPaths.length > 1) {

packages/cli-config-android/src/config/findPackageClassName.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ export function getMainActivityFiles(
2525

2626
return glob.sync(`**/+(${patternArray.join('|')})`, {
2727
cwd: unixifyPaths(folder),
28+
onlyFiles: true,
29+
ignore: ['**/.cxx/**'],
2830
});
2931
}
3032

packages/cli-config-apple/package.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
{
22
"name": "@react-native-community/cli-config-apple",
3-
"version": "19.0.0",
3+
"version": "20.0.0",
44
"license": "MIT",
55
"main": "build/index.js",
66
"publishConfig": {
77
"access": "public"
88
},
99
"dependencies": {
10-
"@react-native-community/cli-tools": "19.0.0",
10+
"@react-native-community/cli-tools": "20.0.0",
1111
"chalk": "^4.1.2",
1212
"execa": "^5.0.0",
1313
"fast-glob": "^3.3.2"
1414
},
1515
"devDependencies": {
16-
"@react-native-community/cli-types": "19.0.0-alpha.0",
16+
"@react-native-community/cli-types": "20.0.0",
1717
"nanospinner": "^1.0.0"
1818
},
1919
"files": [
@@ -26,5 +26,6 @@
2626
"type": "git",
2727
"url": "https://github.com/react-native-community/cli.git",
2828
"directory": "packages/cli-config-apple"
29-
}
29+
},
30+
"gitHead": "3614a01613030c0a328ad2e8bb5d897e5bae1456"
3031
}

packages/cli-config-apple/src/config/findAllPodfilePaths.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@ import glob from 'fast-glob';
99
import {unixifyPaths} from '@react-native-community/cli-tools';
1010

1111
// These folders will be excluded from search to speed it up
12-
const GLOB_EXCLUDE_PATTERN = ['**/@(Pods|node_modules|Carthage|vendor)/**'];
12+
const GLOB_EXCLUDE_PATTERN = [
13+
'**/@(Pods|node_modules|Carthage|vendor|android)/**',
14+
];
1315

1416
export default function findAllPodfilePaths(cwd: string) {
1517
return glob.sync('**/Podfile', {

packages/cli-config-apple/src/tools/installPods.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,15 @@ async function runPodInstall(loader: Spinner, options: RunPodInstallOptions) {
3535
env: {
3636
RCT_NEW_ARCH_ENABLED: options?.newArchEnabled ? '1' : '0',
3737
RCT_IGNORE_PODS_DEPRECATION: '1', // From React Native 0.79 onwards, users shouldn't install CocoaPods manually.
38+
...(process.env.USE_THIRD_PARTY_JSC && {
39+
USE_THIRD_PARTY_JSC: process.env.USE_THIRD_PARTY_JSC,
40+
}), // This is used to install the third party JSC.
41+
...(process.env.RCT_USE_RN_DEP && {
42+
RCT_USE_RN_DEP: process.env.RCT_USE_RN_DEP,
43+
}), // prebuilt RN dep available from 0.80 onwards
44+
...(process.env.RCT_USE_PREBUILT_RNCORE && {
45+
RCT_USE_PREBUILT_RNCORE: process.env.RCT_USE_PREBUILT_RNCORE,
46+
}), // whole RN core prebuilt from 0.81 onwards
3847
},
3948
});
4049
} catch (error) {

0 commit comments

Comments
 (0)