Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

b2g-scripts

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

b2g-scripts

B2G/Gaia Helper Scripts

  • 0.4.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
9
increased by125%
Maintainers
1
Weekly downloads
 
Created
Source

B2G Scripts

Contains a single cli script - b2g-scripts with a growing number of subcommands.

In general it is assumed you have a working b2g emulator/desktop/phone with marionette turned on and listening on port 2828.

Commands like reload-app are not going to be useful if you're not in DEBUG mode (everything is in offline cache).

Install

# notice the -g option for global
npm install b2g-scripts -g

Recomended B2G Desktop settings

cd $GAIA_DIR
make DEBUG=1

Commands

Run b2g-scripts with no arguments to see the list of current commands. Each command has sub options as well and all respond to the --help option.

b2g-scripts watch --help

b2g-scripts watch

Watches a directory for web dev changes js/css/html/properties files. Executes a cli command. You can use this to chain other sub commands.

# I use this all the time to reload app when I am making rapid
# html/css changes
b2g-scripts watch "b2g-scripts reload-app"

b2g-scripts cmd

Runs any of the marionette commands with n number of arguments

b2g-scripts cmd goUrl http://google.com

b2g-scripts reload-app

Reloads currently running app.

WARNING this is bound to the current implementation of gaia and will break if that implementation changes.

b2g-scripts reload-app

b2g-scripts hosts

Output hostfile definition to add to /etc/hosts

b2g-scripts hosts --gaia $GAIA_DIR --ip 127.0.0.1

b2g-scripts server

Starts http server. Faster then HTTPD but designed for use with the emulator/phone.

b2g-scripts server --gaia $GAIA_DIR --port 8081

Keywords

FAQs

Package last updated on 01 Aug 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc