Socket
Socket
Sign inDemoInstall

electron-installer-windows

Package Overview
Dependencies
65
Maintainers
5
Versions
11
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.0.0 to 3.0.0

29

package.json
{
"name": "electron-installer-windows",
"description": "Create a Windows package for your Electron app.",
"version": "2.0.0",
"version": "3.0.0",
"license": "MIT",

@@ -33,24 +33,23 @@ "author": {

"debug": "^4.1.1",
"electron-installer-common": "^0.7.0",
"fs-extra": "^8.0.1",
"glob": "^7.1.4",
"lodash": "^4.17.11",
"electron-installer-common": "^0.10.0",
"fs-extra": "^8.1.0",
"lodash": "^4.17.15",
"parse-author": "^2.0.0",
"which": "^1.3.1",
"yargs": "^13.2.4"
"which": "^2.0.2",
"yargs": "^15.1.0"
},
"devDependencies": {
"chai": "^4.2.0",
"eslint": "^5.16.0",
"eslint-config-standard": "^12.0.0",
"eslint-plugin-import": "^2.17.3",
"eslint-plugin-node": "^9.1.0",
"eslint-plugin-promise": "^4.1.1",
"eslint-plugin-standard": "^4.0.0",
"eslint": "^6.8.0",
"eslint-config-standard": "^14.1.0",
"eslint-plugin-import": "^2.20.0",
"eslint-plugin-node": "^11.0.0",
"eslint-plugin-promise": "^4.2.1",
"eslint-plugin-standard": "^4.0.1",
"finalhandler": "^1.1.2",
"mocha": "^6.1.4",
"mocha": "^7.0.0",
"promise-retry": "^1.1.1",
"serve-static": "^1.14.1",
"tmp-promise": "^2.0.1"
"tmp-promise": "^2.0.2"
}
}

@@ -12,3 +12,3 @@ ![Electron Installer for Windows](resources/logo.png)

This tool requires Node 8 or greater.
This tool requires Node 10 or greater.

@@ -236,2 +236,3 @@ I'd recommend building your packages on your target platform, but if you have to run this on Mac OS X or Linux, you will need to install `mono` and `wine` through your package manager.

Name of the application (e.g., `Atom`), used in the [`title` field of the `nuspec` file](https://docs.nuget.org/create/nuspec-reference).
It is also used as the description when signing your msi installer.

@@ -248,10 +249,4 @@ #### options.exe

Short description of the application, used in the [`summary` field of the `nuspec` file](https://docs.nuget.org/create/nuspec-reference).
A description of the application, used in the [`description` field of the `nuspec` file](https://docs.microsoft.com/en-us/nuget/reference/nuspec#description).
#### options.productDescription
Type: `String`
Default: `package.productDescription || package.description`
Long description of the application, used in the [`description` field of the `nuspec` file](https://docs.nuget.org/create/nuspec-reference).
#### options.version

@@ -299,7 +294,7 @@ Type: `String`

#### options.iconUrl
#### options.iconNuget
Type: `String`
Default: `undefined`
URL for the image to use as the icon for the package in the *Manage NuGet Packages* dialog box, used in the [`iconUrl` field of the `spec` file](https://docs.nuget.org/create/nuspec-reference).
The path to an image file use as the icon for the NuGet package, used in the [`icon` field of the `spec` file](https://docs.microsoft.com/en-us/nuget/reference/nuspec#icon).

@@ -375,3 +370,3 @@ #### options.tags

### NuGet
Current version: 5.1.0
Current version: 5.4.0

@@ -378,0 +373,0 @@ To update [NuGet](https://github.com/nuget/home) to the latest version, head over to the [releases page](https://www.nuget.org/downloads).

@@ -8,4 +8,2 @@ 'use strict'

const path = require('path')
const { promisify } = require('util')
const glob = promisify(require('glob'))

@@ -54,2 +52,15 @@ const spawn = require('./spawn')

/**
* Transforms a version string from semver v2 into v1
*/
convertVersion () {
const [mainVersion, ...suffix] = this.options.version.split('-')
if (suffix.length > 0) {
this.options.version = [mainVersion, suffix.join('-').replace(/\./g, '')].join('-')
} else {
this.options.version = mainVersion
}
}
/**
* Copy the application into the package.

@@ -59,2 +70,6 @@ */

await super.copyApplication()
if (this.options.iconNuget) {
const iconNuget = path.join(this.stagingAppDir, this.options.iconNugetName)
await super.copyIcon(this.options.iconNuget, iconNuget)
}
return this.copySquirrelUpdater()

@@ -77,8 +92,5 @@ }

const args = [
'pack',
this.specPath,
'-BasePath',
this.stagingAppDir,
'-OutputDirectory',
path.join(this.stagingDir, 'nuget'),
'pack', this.specPath,
'-BasePath', this.stagingAppDir,
'-OutputDirectory', path.join(this.stagingDir, 'nuget'),
'-NoDefaultExcludes'

@@ -103,15 +115,2 @@ ]

/**
* Find the package just created.
*/
findPackage () {
const packagePattern = path.join(this.stagingDir, 'nuget', '*.nupkg')
this.options.logger(`Finding package with pattern ${packagePattern}`)
return common.wrapError('finding package with pattern', async () => {
const files = await glob(packagePattern)
return files[0]
})
}
/**
* Get the hash of default options for the installer. Some come from the info

@@ -136,3 +135,3 @@ * read from `package.json`, and some are hardcoded.

iconUrl: undefined,
iconNuget: undefined,

@@ -161,8 +160,12 @@ tags: [],

if (!this.options.description && !this.options.productDescription) {
throw new Error(`No Description or ProductDescription provided. Please set either a description in the app's package.json or provide it in the this.options.`)
this.convertVersion()
if (this.options.iconNuget) this.options.iconNugetName = path.basename(this.options.iconNuget)
if (!this.options.description) {
throw new Error("No Description provided. Please set a description in the app's package.json or provide it in the this.options.")
}
if (!this.options.authors) {
throw new Error(`No Authors provided. Please set an author in the app's package.json or provide it in the this.options.`)
throw new Error("No Authors provided. Please set an author in the app's package.json or provide it in the this.options.")
}

@@ -199,3 +202,4 @@

`/f "${path.resolve(this.options.certificateFile)}"`,
`/p "${this.options.certificatePassword}"`
`/p "${this.options.certificatePassword}"`,
`/d "${this.options.productName}"`
].join(' '))

@@ -209,3 +213,3 @@ }

return common.wrapError('releasifying package', async () => {
const pkg = await this.findPackage()
const pkg = path.join(this.stagingDir, 'nuget', `${this.options.name}.${this.options.version}.nupkg`)
args.unshift('--releasify', pkg)

@@ -212,0 +216,0 @@ return spawn(cmd, args, this.options.logger)

@@ -31,3 +31,6 @@ 'use strict'

}
return spawn(cmd, args, logger, updateExecutableMissingException)
return spawn(cmd, args, {
logger,
updateErrorCallback: updateExecutableMissingException
})
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc