Граф коммитов

12 Коммитов

Автор SHA1 Сообщение Дата
Andres Suarez 8bd3edec88 Update copyright headers from Facebook to Meta
Reviewed By: aaronabramov

Differential Revision: D33367752

fbshipit-source-id: 4ce94d184485e5ee0a62cf67ad2d3ba16e285c8f
2021-12-30 15:11:21 -08:00
enniel b399c2e3d1 CLI: export packager environment variables (#32666)
Summary:
Custom metro port not working without exporting variables from `.packager.env`

## Changelog

[General] [Fixed] - Fix support for custom port

Pull Request resolved: https://github.com/facebook/react-native/pull/32666

Test Plan: run `react-native run-android --port=8082` and `react-native run-ios --port=8082`

Reviewed By: yungsters

Differential Revision: D32694233

Pulled By: cortinico

fbshipit-source-id: 42e803d56b83608024b901d2a3024733ed7099b7
2021-11-29 08:31:27 -08:00
Moti Zilberman 6df04ae666 Optionally capture packager logs during RNTester Xcode build
Summary:
Changelog: [Internal]

* Sets a default custom reporter in `scripts/packager.sh` that redirects Metro's logs to a JSON file when the `RCT_PACKAGER_LOG_PATH` environment variable is set. Otherwise we use Metro's `TerminalReporter`, [like the CLI does by default](0993f62786/packages/cli-plugin-metro/src/commands/start/runServer.ts (L124)).
* Modifies `scripts/launchPackager.command` to write logs to `$RCT_PACKAGER_LOGS_DIR` (and in particular use the JSON reporter) if this environment var is set.
* Uses [`open -n`](https://ss64.com/osx/open.html#:~:text=Open%20a%20new%20instance%20of%20the%20application) to execute `launchPackager.command` from Xcode, so that environment variables are reliably passed to the script even if a Terminal process is already running.

Reviewed By: yungsters

Differential Revision: D32295290

fbshipit-source-id: 4d783e1f94d122d3a35c104b2b02dbfaf8e1a1a3
2021-11-11 00:01:40 -08:00
Christoph Nakazawa 88d0ac17e8 Metro Bundler -> Metro
Summary: This bothers me, we renamed the project to drop the "Metro" a while ago.

Reviewed By: rubennorte

Differential Revision: D16831281

fbshipit-source-id: bb6de412eccda61b617580f3660e3e635f2d2815
2019-08-16 10:37:10 -07:00
Guillaume Hain 8d2e8fdca4 macOS : request interactive input when killing the packager (#19663)
Summary:
Do not request interactive input when running on a CI

When I'm running the build on my CI server, many Terminal windows are remaining on the server because of the `read` command.

This PR prevent this behaviour when the `CI` environment variable is defined so that it doesn't alter the behaviour on local machines.
Pull Request resolved: https://github.com/facebook/react-native/pull/19663

Differential Revision: D14206458

Pulled By: cpojer

fbshipit-source-id: 476067ebebb07c6e708469fa8829a06e05c58200
2019-02-24 22:48:17 -08:00
Héctor Ramos 0407d8c8fd Update RNTester snapshots
Summary:
The iOS snapshots have been out of date for months, but the failure was not caught in open source's  `test_objc` job because `xcpretty` was swallowing the non-zero error code.

To fix this, I enabled recording mode in RNTesterSnapshotTests.m temporarily, and re-ran the tests in order to update the snapshots. I've also switched the test device used by Circle CI to iPhone 6s to be consistent with the snapshot tests that run internally at Facebook.

Integration tests are not fully fixed yet, but I can confirm the following tests are fixed by this diff:

```
-[RNTesterIntegrationTests testImageSnapshotTest]
-[RNTesterIntegrationTests testSimpleSnapshotTest]
-[RNTesterSnapshotTests testARTExample]
-[RNTesterSnapshotTests testLayoutExample]
-[RNTesterSnapshotTests testSliderExample]
-[RNTesterSnapshotTests testSwitchExample]
-[RNTesterSnapshotTests testTabBarExample]
-[RNTesterSnapshotTests testTextExample]
-[RNTesterSnapshotTests testViewExample]
```

I've also fixed a few shellcheck warnings in related scripts.

Reviewed By: fkgozali

Differential Revision: D13506865

fbshipit-source-id: dab985130c2ff3cb9dea19d1f87c8ee65d8c141e
2018-12-18 16:20:10 -08:00
Héctor Ramos 1151c096da Update copyright headers to yearless format
Summary: This change drops the year from the copyright headers and the LICENSE file.

Reviewed By: yungsters

Differential Revision: D9727774

fbshipit-source-id: df4fc1e4390733fe774b1a160dd41b4a3d83302a
2018-09-11 15:33:07 -07:00
Héctor Ramos fe4f03517c Add missing copyright headers (#21000)
Summary:
One of our automated project tools noted that these were all missing their copyright headers.
Pull Request resolved: https://github.com/facebook/react-native/pull/21000

Differential Revision: D9721495

Pulled By: hramos

fbshipit-source-id: 6ccf0f37165a0fe16cf06bd996d615f2286101dc
2018-09-07 13:17:38 -07:00
Maël Nison e183844df5 Uniformizes how THIS_DIR is computed in xplat/js
Summary: This form of THIS_DIR resolves symlinks, which is better.

Reviewed By: davidaurelio

Differential Revision: D8661886

fbshipit-source-id: 90bf329e765d9623d103b03c5dd3b71fae9d9854
2018-07-19 05:16:22 -07:00
Sophie Alpert 1490ab12ef Update license headers for MIT license
Summary:
Includes React Native and its dependencies Fresco, Metro, and Yoga. Excludes samples/examples/docs.

find: ^(?:( *)|( *(?:[\*~#]|::))( )? *)?Copyright (?:\(c\) )?(\d{4})\b.+Facebook[\s\S]+?BSD[\s\S]+?(?:this source tree|the same directory)\.$
replace: $1$2$3Copyright (c) $4-present, Facebook, Inc.\n$2\n$1$2$3This source code is licensed under the MIT license found in the\n$1$2$3LICENSE file in the root directory of this source tree.

Reviewed By: TheSavior, yungsters

Differential Revision: D7007050

fbshipit-source-id: 37dd6bf0ffec0923bfc99c260bb330683f35553e
2018-02-16 18:31:53 -08:00
Edward Coleridge Smith 654d7595fe Update terminal title to 'Metro Bundler'
Summary:
I noticed in v0.50.0 all mentions of 'packager' were updated to 'Metro Bundler':

12eb04b236

It seems like command which launches the bundler still sets the terminal title to 'React Packager'. This PR simply updates the title from 'React Packager' to 'Metro Bundler'.

Run `scripts/launchPackager.command`/`scripts/launchPackager.bat` and check title:

<img width="907" alt="screen shot 2018-01-05 at 14 02 53" src="https://user-images.githubusercontent.com/754498/34612337-3e93e8ca-f221-11e7-98f9-c5190674868e.png">

[GENERAL] [ENHANCEMENT] [./scripts]
Closes https://github.com/facebook/react-native/pull/17457

Differential Revision: D6673843

Pulled By: shergin

fbshipit-source-id: 65a072c3b79593391f257191b1372e7e9c8799f1
2018-01-07 22:22:45 -08:00
David Aurelio a710f9a81e Move packager launcher scripts outside of `packager/`
Summary: in order to prepare open sourcing React Native Packager, we have to move scripts specific to React Native to a directory that will continue to exist.

Reviewed By: javache

Differential Revision: D5112193

fbshipit-source-id: eac77d0d981aecef7ee52365a6856340420a5638
2017-05-23 16:17:09 -07:00