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

openfin-cli

Package Overview
Dependencies
Maintainers
18
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

openfin-cli - npm Package Compare versions

Comparing version 3.0.1 to 3.0.2-beta.1

6

cli.js

@@ -14,3 +14,4 @@ #!/usr/bin/env node

runtime: { alias: 'r', type: 'string' },
platform: { alias: 't', type: 'boolean' }
platform: { alias: 't', type: 'boolean' },
save: { alias: 's', type: 'string' }
}

@@ -23,3 +24,3 @@ };

'Options:',
'-c --config <config file>',
'-c --config <path to config file>',
'-u --url <application url>',

@@ -29,2 +30,3 @@ '-l --launch launch this configuration',

'-r --runtime-version runtime version',
'-s --save the manifest to the current directory <manifest name>',
'--version current version of the tool',

@@ -31,0 +33,0 @@ 'Example',

@@ -17,2 +17,3 @@ 'use strict';

const isPlatform = flags.t || flags.platform;
const manifestName = flags.s || flags.save
let manifestUrl = flags.c || flags.config || null;

@@ -30,3 +31,3 @@ let buildConfig;

buildConfig = true;
const manifestInfo = await writeManifest(url, devtoolsPort, runtime, isPlatform);
const manifestInfo = await writeManifest(url, devtoolsPort, runtime, isPlatform, manifestName);
manifestUrl = manifestInfo.filepath;

@@ -85,3 +86,3 @@ configObj = manifestInfo.manifest;

function writeManifest(url, devtoolsPort, runtime, isPlatform) {
function writeManifest(url, devtoolsPort, runtime, isPlatform, manifestName) {
return new Promise((resolve, reject) => {

@@ -159,9 +160,11 @@ const uuid = `app-${getUuid()}`;

const manifestJson = JSON.stringify(manifest, null, 4);
let filepath;
if (manifestName) {
filepath = path.join(process.cwd(), manifestName);
} else {
filepath = path.join(os.tmpdir(), `${uuid}.json`);
}
const manifestJson = JSON.stringify(manifest);
const filepath = path.join(os.tmpdir(), `${uuid}.json`);
fs.writeFile(filepath, manifestJson, (error) => {

@@ -168,0 +171,0 @@ if (error) {

{
"name": "openfin-cli",
"version": "3.0.1",
"version": "3.0.2-beta.1",
"description": "OpenFin Runtime cli tool",

@@ -5,0 +5,0 @@ "homepage": "http://www.openfin.co",

@@ -42,2 +42,15 @@ # OpenFin Runtime cli tool

```
#### Launch application and save manifest to the working directory
```sh
$ openfin --launch --url http://www.openfin.co --save myconfig.json
```
Shorthand
```sh
$ openfin -l -u http://www.openfin.co -s myconfig.json
```
#### Launching a given config file

@@ -58,3 +71,3 @@

```
$ openfin -launch -platform -url https://openfin.co,http://cdn.openfin.co/demos/hyperblotter/index.html,https://google.com
$ openfin --launch --platform --url https://openfin.co,http://cdn.openfin.co/demos/hyperblotter/index.html,https://google.com
```

@@ -61,0 +74,0 @@

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