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

crx

Package Overview
Dependencies
Maintainers
1
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

crx

Build Google Chrome extensions with node.js

  • 0.1.4
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
11K
decreased by-50.77%
Maintainers
1
Weekly downloads
 
Created
Source

crx

crx is a node.js command line app for packing Google Chrome extensions.

Requirements

  • node.js, tested with 0.4.12
  • openssl
  • ssh-keygen
  • zip

Install

$ npm install crx

API

crx pack [directory] [-f file] [-p private-key]

Pack the specified directory into a .crx package, and output it to stdout. If no directory is specified, the current working directory is used.

Use the -f option to output to a file instead of stdout; if no file is specified, the package is given the same name as the directory basename.

Use the -p option to specify an external private key. If this is not used, key.pem is used from within the directory. If this option is not used and no key.pem file exists, one will be generated automatically.

crx keygen [directory]

Generate a 1,024-bit RSA private key within the directory. This is called automatically if a key is not specified, and key.pem does not exist.

crx -h

Show information about using this utility, generated by commander.

Examples

Given the following directory structure:

└─┬ myFirstExtension
  ├── manifest.json
  └── icon.png

run this:

cd myFirstExtension
crx pack -f

to generate this:

├─┬ myFirstExtension
│ ├── manifest.json
│ ├── icon.png
│ └── key.pem
└── myFirstExtension.crx

You can also name the output file like this:

cd myFirstExtension
crx pack -f myFirstExtension.crx

to get the same results, or also pipe to the file manually like this.

cd myFirstExtension
crx pack > ../myFirstExtension.crx

As you can see a key is generated for you at key.pem if none exists. You can also specify an external key. So if you have this:

├─┬ myFirstExtension
│ ├── manifest.json
│ └── icon.png
└── myPrivateKey.pem

you can run this:

crx pack myFirstExtension -p myPrivateKey.pem -f

to sign your package without keeping the key in the directory.

Copyright (c) 2011 Jed Schmidt. See LICENSE.txt for details.

Send any questions or comments here.

FAQs

Package last updated on 31 Dec 2011

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