Commit Graph

34 Commits

Author SHA1 Message Date
Tadeu Zagallo 270b1c718f Automatically save and convert JavaScript profile to chrome format
Summary: @​public

Migrate scripts to open source and add new route on the packager
to directly convert profiler outputs to a devtools compatible format.

Reviewed By: @jspahrsummers

Differential Revision: D2425740
2015-09-11 06:40:26 -07:00
Tadeu Zagallo 91e235465b Move systrace helper out of the packager
Summary: @​public

The profiler helper shouldn't live inside the packager itself, move
it to the packager.js file with other middlewares.

Reviewed By: @martinbigio

Differential Revision: D2424878
2015-09-09 11:25:24 -07:00
Martín Bigio 4b14a2f783 [react-packager] Add command line option to reset cache on OSS 2015-09-07 01:16:44 -08:00
Felix Oghină dbdf7f366f [reactnative] remove platform option from oss packager 2015-08-26 04:49:41 -08:00
Alex Kotliarskyi 37774b463d [ReactNative] Unbreak debugger 2015-08-21 11:20:17 -07:00
Harrison Harnisch ef7dc94907 UI CPU and memory utilization graphs in Chrome debugging mode
Summary:
Chrome debugging UI is currently only showing connection state and logs in the console, leaving room for plenty of interesting information.

I've pushed the UI (using the same convention set by FPS -- UI/JS) CPU and memory utilization data over the debug Websocket and tapped into the existing stream of JS calls that get ran in V8.

The number of JS calls in a time interval is counted for all sub calls in a batch
https://github.com/hharnisc/react-native/blob/master/packager/debugger.html#L150

The last 5 batches of JS calls are displayed in a list format.

<img width="951" alt="screen shot 2015-07-19 at 7 34 00 pm" src="https://cloud.githubusercontent.com/assets/1388079/8769257/edc42f70-2e4d-11e5-8813-e86ef530a446.png">

Charts are created with [Chart.JS](https://github.com/nnnick/Chart.js) (MIT licensed).
Closes https://github.com/facebook/react-native/pull/2050
Github Author: Harrison Harnisch <hharnisc@gmail.com>
2015-08-21 02:11:45 -07:00
James Ide 01d07a3eb6 [io.js] Print a warning message if the user is not on io.js 2.x
Summary:
Detects if the user is on Node or io.js 1.x and prints a banner explaining how to upgrade. We probably should link to more detailed upgrade docs so this is just a start.

I also added a function to format banners that is kind of useful.

Addresses part of #1737

![packager-banner](https://cloud.githubusercontent.com/assets/379606/8447050/ad615402-1f67-11e5-8c02-ece5f7488135.png)

Closes https://github.com/facebook/react-native/pull/1824
Github Author: James Ide <ide@jameside.com>
2015-07-10 00:32:46 -08:00
Joe Wood 157a77e48d [Packager] Windows support for Packager - Blacklist changes
Summary:
Another Pull Request implementing the changes in issue #468 - Enabled Packager to run on Windows
This change relates to the blacklist fixes. It includes the path conversion for blacklist and changes to the default watched directory.  It has no impact on Mac OSX.
Closes https://github.com/facebook/react-native/pull/893
Github Author: Joe Wood <joewood>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-06-26 16:27:12 -08:00
Johannes Lumpe d70ff04746 [Packager] Allow user to specify a custom transformer file
Summary:
This is an edited re-submission of #1458 because I'm stupid.
Closes https://github.com/facebook/react-native/pull/1497
Github Author: Johannes Lumpe <johannes@johanneslumpe.de>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-06-26 16:00:37 -08:00
Philipp von Weitershausen fca872fac2 [React Native][Packager] allow --assetRoots to be relative paths 2015-06-22 12:58:04 -08:00
Jarek Potiuk 23ac061d83 Added support for React installed in the application via Cocoapods
Summary:
Similarly to npm-installed react, this change makes changes to the packager so that it understands that it's been installed via Cocoapods and determines the project and asset roots properly (from the main application directory).
Closes https://github.com/facebook/react-native/pull/1568
Github Author: Jarek Potiuk <jarek@potiuk.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-06-22 03:15:31 -08:00
Tadeu Zagallo 24026b6c25 [ReactNative] Revert packager ignoring node_modules 2015-06-11 10:45:32 -08:00
rickyc 91dcbe0905 Debugger won't start due to spaces in directory path
Summary:
Similar issue to #214. When I attempt to do command + D in the simulator, I get the following issue.

```
Launching Dev Tools...
Failed to run launchChromeDevTools.applescript { [Error: Command failed: /bin/sh -c /Users/ricky/Dropbox (Personal)/Sites/AwesomeProject/node_modules/react-native/packager/launchChromeDevTools.applescript http://localhost:8081/debugger-ui
/bin/sh: -c: line 0: syntax error near unexpected token `Personal'
/bin/sh: -c: line 0: `/Users/ricky/Dropbox (Personal)/Sites/AwesomeProject/node_modules/react-native/packager/launchChromeDevTools.applescript http://localhost:8081/debugger-ui'
]
  killed: false,
  code: 2,
  signal: null,
  cmd: '/bin/sh -c /Users/ricky/Dropbox (Personal)/Sites/AwesomeProject/node_modules/react-native/packager/launchChromeDevTools.applescript http://localhost:8081/debugger-ui' }

/bin/sh: -c: line 0: syntax error near unexpected token `Personal'
/bin/sh: -c: line 0: `/Users/ricky/Dropbox (Personal)/Sites/AwesomeProject/node_modules/react-native/packa
Closes https://github.com/facebook/react-native/pull/348
Github Author: rickyc <rickyc.us@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-06-02 15:13:55 -08:00
James Ide ea9ca4637c [Packager] Fix the --root, --assetRoots, and --platform options
Summary:
Looks like these options were handled as booleans when they should be handled as strings. Explicitly specify them as strings.

Closes https://github.com/facebook/react-native/pull/1377
Github Author: James Ide <ide@jameside.com>

Test Plan:
 `packager/packager.sh --root A --root B` works. Also tested `packager/packager.sh --root A,B`.
2015-05-26 14:19:22 -08:00
Amjad Masad 936f786765 [react-native] Make document.js into a polyfill. Fixes #1149
Summary:
@public
document shimming must run before anything else. However, we don't currently guarantee that. This moves the document shimming into `document.js` which is used as a polyfill.

Test Plan:
* start server
* go to playground app
* require `NativeModules` as the first thing
* open chrome debugger
* no error
2015-05-13 17:50:21 -08:00
Spencer Ahrens 876f1084af [ReactNative] temp disable flow check in packager for OSS 2015-04-27 19:13:33 -08:00
Amjad Masad 749c81842c [react-packager] Add jpe?g to asset extensions 2015-04-21 11:06:01 -08:00
Philipp von Weitershausen 241e263e5e [ReactNative] allow running JS app server for Android from fbobjc 2015-04-14 10:28:07 -08:00
Ben Alpert c24fc75a53 [react-native] Listen on all IPv6 interfaces 2015-04-08 14:23:52 -08:00
Spencer Ahrens 061de15c1c [ReactNative] Do flow check when running packager 2015-04-07 21:40:05 -08:00
Alex Kotliarskyi 5cbbc10e4f [ReactNative] Better error message for EADDRINUSE 2015-04-07 15:39:36 -08:00
Steve Lacy 461f169a9e Update deps order - core modules first
Summary:
**packager/packager.js**

- Update deps order - node core modules first

The core deps do not get installed, and do not need to be after the dep check.
Closes https://github.com/facebook/react-native/pull/224
Github Author: Steve Lacy <me@slacy.me>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-02 17:05:40 -08:00
Justin Carmony ceeb06eb1a Packager status page & build validating against it.
Summary:
Creating a packager status page so React can validate a proper packager instance is running on 8081.

See #257 for details on this bug.

The biggest thing in this PR is I have it perform an exit 2 in the build script if the check fails. This will cause the build to fail, they can click on the error and see a nice message. Not sure if there is a way to throw a warning instead.

Also, I broke the bash script into several lines, in the Xcode editor it looks fine but in the source code it looks less than ideal. We might want to break that out into it's own bash script that is called. Let me know if you want to do that.
Closes https://github.com/facebook/react-native/pull/308
Github Author: Justin Carmony <justin@justincarmony.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-03-31 23:01:04 -08:00
Amjad Masad a895e62e6d [react-packager] Fix assetRoots when starting in node_modules 2015-03-27 19:08:24 -08:00
James Ide ecfc78f47e [Assets] Allow scripts to override assetRoots
Summary:
The CLI parse was accepting a string but assetRoots should be an array, so split on commas. Tested by specifying a root directory that was at least two folders up (../../stuff).
Closes https://github.com/facebook/react-native/pull/189
Github Author: James Ide <ide@jameside.com>

Test Plan:
* export to open source
* started server passing --assetRoots array
2015-03-26 01:24:08 -08:00
Christopher Chedeau a2c32d4d29 [ReactNative] Expanded license on js packager files 2015-03-23 11:28:51 -08:00
Alex Kotliarskyi 098d7bfa45 [ReactNative] Print directories packager is serving files from 2015-03-22 22:37:55 -08:00
Alex Kotliarskyi 601b21fa79 [ReactNative] Adjust packager default root when running from within node_modules 2015-03-20 16:12:57 -08:00
Amjad Masad 98ed9422c2 [react-packager] Make sure projectRoots is converted to an array 2015-03-20 14:09:31 -08:00
Alex Kotliarskyi 72ad4e5be8 [ReactNative] Bring Chrome debugger to OSS. Part 2 2015-03-19 11:48:51 -08:00
Amjad Masad ace7e3613f [react-packager] Add assetRoots option 2015-03-18 18:26:35 -08:00
Amjad Masad a4d041ce62 [react-packager] Make dev a query param option 2015-03-04 21:24:08 -08:00
James Ide ee00675dab [react-packager] Add dev option to CLI | James Ide
Summary:
Exposes the dev option that is already there to the CLI so that you can turn off invariant checks, etc. I also made it omit the inlined source map when dev=false which made it a lot faster to run on a phone, both due to smaller download size and fewer bytes to copy from Obj-C to JS and evaluate.
Closes https://github.com/facebook/react-native/pull/112
Github Author: James Ide <ide@jameside.com>

Test Plan:
* ./runJestTests.sh
* test bundle creation with `bundle.sh`
* test `load_dependencies.js` script
* start the server and click around shell app
2015-03-02 21:11:07 -08:00
Spencer Ahrens 382e1553af [react-packager][streamline oss] Move open sourced JS source to react-native-github 2015-02-19 21:25:11 -08:00