binwrap

WebJar for binwrap

License

License

MIT
GroupId

GroupId

org.webjars.npm
ArtifactId

ArtifactId

binwrap
Last Version

Last Version

0.1.4
Release Date

Release Date

Type

Type

jar
Description

Description

binwrap
WebJar for binwrap
Project URL

Project URL

https://www.webjars.org
Source Code Management

Source Code Management

https://github.com/avh4/binwrap

Download binwrap

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.npm/binwrap/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>binwrap</artifactId>
    <version>0.1.4</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/binwrap/
implementation 'org.webjars.npm:binwrap:0.1.4'
// https://jarcasting.com/artifacts/org.webjars.npm/binwrap/
implementation ("org.webjars.npm:binwrap:0.1.4")
'org.webjars.npm:binwrap:jar:0.1.4'
<dependency org="org.webjars.npm" name="binwrap" rev="0.1.4">
  <artifact name="binwrap" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='binwrap', version='0.1.4')
)
libraryDependencies += "org.webjars.npm" % "binwrap" % "0.1.4"
[org.webjars.npm/binwrap "0.1.4"]

Dependencies

compile (4)

Group / Artifact Type Version
org.webjars.npm : request jar [2.81.0,3)
org.webjars.npm : request-promise jar [4.2.0,5)
org.webjars.npm : tar jar [2.2.1,3)
org.webjars.npm : unzip jar [0.1.11,0.2)

Project Modules

There are no modules declared in this project.

Build Status npm

This package helps with distributing binaries via npm.

Usage

First, create your compiled binaries and make them available via HTTPS.

Now create your npm installer: Make a package.json that looks like this:

{
  "name": "myApp",
  "version": "1.0.0",
  "description": "Install myApp",
  "preferGlobal": true,
  "main": "index.js",
  "scripts": {
    "install": "binwrap-install",
    "prepare": "binwrap-prepare",
    "test": "binwrap-test",
    "prepublish": "npm test"
  },
  "license": "BSD-3-Clause",
  "files": [
    "index.js",
    "bin"
  ],
  "bin": {
    "myapp-cli": "bin/myapp-cli"
  },
  "dependencies": {
    "binwrap": "^0.2.2"
  }
}

Then create your index.js file like this:

var binwrap = require("binwrap");
var path = require("path");

var packageInfo = require(path.join(__dirname, "package.json"));
var version = packageInfo.version;
var root = "https://dl.bintray.com/me/myApp/" + version;

module.exports = binwrap({
  dirname: __dirname,
  binaries: [
    "myapp-cli"
  ],
  urls: {
    "darwin-x64": root + "/mac-x64.tgz",
    "linux-x64": root + "/linux-x64.tgz",
    "win32-x64": root + "/win-i386.zip",
    "win32-ia32": root + "/win-i386.zip"
  }
});

Then run npm test to verify that your packages are published correctly.

Finally, run npm publish when you are ready to publish your installer.

Versions

Version
0.1.4