Latest Socket ResearchMalicious Chrome Extension Performs Hidden Affiliate Hijacking.Details
Socket
Book a DemoInstallSign in
Socket

hiro-sdk-cli

Package Overview
Dependencies
Maintainers
3
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

hiro-sdk-cli

HIRO applications generator.

unpublished
Source
npmnpm
Version
1.2.4
Version published
Weekly downloads
0
Maintainers
3
Weekly downloads
 
Created
Source

HIRO SDK CLI

CLI utils for HIRO applications.

Project setup

Prerequisites

  • node 8+
  • npm 6+

Instalation

  • Run npm i -g hiro-sdk-cli

Commands

hiro-sdk init

Initializes new HIRO Application.

react-scripts v1.1.5 is used for development server / build scripts.

Usage:

  • hiro-sdk init my-app - initialize blank my-app application.
  • hiro-sdk init my-app -t react - initialize React my-app applicaiton.

Advanced usage:

  • hiro-sdk init my-app -l - initialize blank my-app application and link local hiro-sdk package
  • hiro-sdk init my-app -t react -l - initialize React my-app applicaiton and link local hiro-sdk package

hiro-sdk bundle

Bundles compiled application into a zip archive.

We need to build our app first. Run npm run build to create a production build.

As result, we expect a build folder in project root. It should have the following structure:

build
├── asset-manifest.json
├── icon.svg
├── index.html
└── static
    ├── css
    │   └── main.2c2ee846.css
    └── js
        └── main.fb659025.js

Important files

icon.svg is used by HIRO Desktop as the icon of the application.

asset-manifest.json contains paths mapping for your assets. main.js is required. Example asset-manifest.json contents:

{
  "main.css": "static/css/main.2c2ee846.css",
  "main.js": "static/js/main.fb659025.js"
}

HIRO Desktop loads main.js and all .css files found in manifest.

After we've made a production build, we need to bundle the app.
hiro-sdk bundle command creates a bundle.zip archive in the project root.

hiro-sdk publish

Publishes bundled application (bundle.zip) to the graph.

You can provide either host/token/parent combination to command or read those values from env files.

Using explicit arguments:

  • -h = Graph URL
  • -t = Graph token
  • -p = Desktop "ui" app ID on your installation

Using implicit arguments: just pass -e flag to read arguments from .env files

  • HIRO_GRAPH_URL = Graph URL
  • HIRO_GRAPH_TOKEN = Graph token
  • HIRO_DESKTOP_ID = Desktop "ui" app ID on your installation
# Explicit arguments
hiro-sdk publish -h https://acme.graphit.co -t vm8127v89126cn8712616c12c12 -p awv8a57wavmawvawawvaw

# Implicit arguments
hiro-sdk publish -e

As result, your application will be either created or updated, depending on name field in the manifest.yaml. NOTE, that you can only update applications uploaded by you.

Use hiro-sdk --help to get more info

FAQs

Package last updated on 25 Sep 2019

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