From 57e48804332dce22a88e0114c3ef444e81d750cc Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 9 Aug 2018 11:43:13 -0700 Subject: [PATCH 01/58] Use the channel-qualified Atom title when packaging Windows releases --- script/lib/create-windows-installer.js | 7 +++++-- script/lib/generate-metadata.js | 10 ++++++++++ script/lib/package-application.js | 2 +- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/script/lib/create-windows-installer.js b/script/lib/create-windows-installer.js index f5e387e7f..c16df615b 100644 --- a/script/lib/create-windows-installer.js +++ b/script/lib/create-windows-installer.js @@ -10,6 +10,8 @@ const CONFIG = require('../config') module.exports = (packagedAppPath) => { const archSuffix = process.arch === 'ia32' ? '' : '-' + process.arch const options = { + exe: 'atom.exe', + title: CONFIG.appName, appDirectory: packagedAppPath, authors: 'GitHub Inc.', iconUrl: `https://raw.githubusercontent.com/atom/atom/master/resources/app-icons/${CONFIG.channel}/atom.ico`, @@ -28,14 +30,15 @@ module.exports = (packagedAppPath) => { fs.renameSync(releasesPath, `${releasesPath}-x64`) } - for (let nupkgPath of glob.sync(`${CONFIG.buildOutputPath}/atom-*.nupkg`)) { + let appName = CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}` + for (let nupkgPath of glob.sync(`${CONFIG.buildOutputPath}/${appName}-*.nupkg`)) { if (!nupkgPath.includes(CONFIG.computedAppVersion)) { console.log(`Deleting downloaded nupkg for previous version at ${nupkgPath} to prevent it from being stored as an artifact`) fs.unlinkSync(nupkgPath) } else { if (process.arch === 'x64') { // Use the original .nupkg filename to generate the `atom-x64` name by inserting `-x64` after `atom` - const newNupkgPath = nupkgPath.replace('atom-', 'atom-x64-') + const newNupkgPath = nupkgPath.replace(`${appName}-`, `${appName}-x64-`) fs.renameSync(nupkgPath, newNupkgPath) } } diff --git a/script/lib/generate-metadata.js b/script/lib/generate-metadata.js index ae61b6633..4baa8d9cf 100644 --- a/script/lib/generate-metadata.js +++ b/script/lib/generate-metadata.js @@ -9,6 +9,14 @@ const semver = require('semver') const CONFIG = require('../config') +let appName = CONFIG.appMetadata.name +let appProductName = CONFIG.appMetadata.productName + +if (process.platform === 'win32') { + appName = CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}` + appProductName = CONFIG.appName +} + module.exports = function () { console.log(`Generating metadata for ${path.join(CONFIG.intermediateAppPath, 'package.json')}`) CONFIG.appMetadata._atomPackages = buildBundledPackagesMetadata() @@ -16,6 +24,8 @@ module.exports = function () { CONFIG.appMetadata._atomKeymaps = buildPlatformKeymapsMetadata() CONFIG.appMetadata._deprecatedPackages = deprecatedPackagesMetadata CONFIG.appMetadata.version = CONFIG.computedAppVersion + CONFIG.appMetadata.name = appName + CONFIG.appMetadata.productName = appProductName checkDeprecatedPackagesMetadata() fs.writeFileSync(path.join(CONFIG.intermediateAppPath, 'package.json'), JSON.stringify(CONFIG.appMetadata)) } diff --git a/script/lib/package-application.js b/script/lib/package-application.js index 1b3c19b28..91b231ffd 100644 --- a/script/lib/package-application.js +++ b/script/lib/package-application.js @@ -34,7 +34,7 @@ module.exports = function () { 'version-string': { 'CompanyName': 'GitHub, Inc.', 'FileDescription': 'Atom', - 'ProductName': 'Atom' + 'ProductName': CONFIG.appName } }).then((packagedAppPath) => { let bundledResourcesPath From 29b04b8a61b036f5dd60f546ac3b7d2871013187 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 9 Aug 2018 11:44:21 -0700 Subject: [PATCH 02/58] Make the channel-qualified Atom title available through `atom.getAppName()` --- src/atom-environment.js | 8 ++++++++ src/main-process/atom-window.js | 3 ++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/atom-environment.js b/src/atom-environment.js index 915ff78f1..cb401592b 100644 --- a/src/atom-environment.js +++ b/src/atom-environment.js @@ -477,6 +477,14 @@ class AtomEnvironment { return this.firstLoad } + // Public: Get the full name of this Atom release (e.g. "Atom", "Atom Beta") + // + // Returns the app name {String}. + getAppName() { + if (this.appName == null) this.appName = this.getLoadSettings().appName + return this.appName + } + // Public: Get the version of the Atom application. // // Returns the version text {String}. diff --git a/src/main-process/atom-window.js b/src/main-process/atom-window.js index a56679143..56657ba55 100644 --- a/src/main-process/atom-window.js +++ b/src/main-process/atom-window.js @@ -32,7 +32,7 @@ class AtomWindow extends EventEmitter { const options = { show: false, - title: 'Atom', + title: app.getName(), tabbingIdentifier: 'atom', webPreferences: { // Prevent specs from throttling when the window is in the background: @@ -67,6 +67,7 @@ class AtomWindow extends EventEmitter { this.loadSettings = Object.assign({}, settings) this.loadSettings.appVersion = app.getVersion() + this.loadSettings.appName = app.getName() this.loadSettings.resourcePath = this.resourcePath this.loadSettings.atomHome = process.env.ATOM_HOME if (this.loadSettings.devMode == null) this.loadSettings.devMode = false From 783bce5275c9a83b0db7b1c4ad732a230dbd32a8 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 9 Aug 2018 11:45:02 -0700 Subject: [PATCH 03/58] Use the channel-qualified Atom title in the Windows app title bar --- src/workspace.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/workspace.js b/src/workspace.js index a3f85ddeb..27ca0f63e 100644 --- a/src/workspace.js +++ b/src/workspace.js @@ -560,7 +560,7 @@ module.exports = class Workspace extends Model { // open. updateWindowTitle () { let itemPath, itemTitle, projectPath, representedPath - const appName = 'Atom' + const appName = atom.getAppName() const left = this.project.getPaths() const projectPaths = left != null ? left : [] const item = this.getActivePaneItem() From 3be8db0c870251fecaac8e431fc65415d24539dc Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 9 Aug 2018 11:45:49 -0700 Subject: [PATCH 04/58] Update the channel-qualified Atom app shortcut for the Windows release --- src/main-process/squirrel-update.coffee | 163 ++++++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 src/main-process/squirrel-update.coffee diff --git a/src/main-process/squirrel-update.coffee b/src/main-process/squirrel-update.coffee new file mode 100644 index 000000000..77256feee --- /dev/null +++ b/src/main-process/squirrel-update.coffee @@ -0,0 +1,163 @@ +fs = require 'fs-plus' +path = require 'path' +{app} = require 'electron' +Spawner = require './spawner' +WinShell = require './win-shell' +WinPowerShell = require './win-powershell' + +appFolder = path.resolve(process.execPath, '..') +rootAtomFolder = path.resolve(appFolder, '..') +binFolder = path.join(rootAtomFolder, 'bin') +updateDotExe = path.join(rootAtomFolder, 'Update.exe') +exeName = path.basename(process.execPath) + +if process.env.SystemRoot + system32Path = path.join(process.env.SystemRoot, 'System32') + setxPath = path.join(system32Path, 'setx.exe') +else + setxPath = 'setx.exe' + +# Spawn setx.exe and callback when it completes +spawnSetx = (args, callback) -> + Spawner.spawn(setxPath, args, callback) + +# Spawn the Update.exe with the given arguments and invoke the callback when +# the command completes. +spawnUpdate = (args, callback) -> + Spawner.spawn(updateDotExe, args, callback) + +# Add atom and apm to the PATH +# +# This is done by adding .cmd shims to the root bin folder in the Atom +# install directory that point to the newly installed versions inside +# the versioned app directories. +addCommandsToPath = (callback) -> + installCommands = (callback) -> + atomCommandPath = path.join(binFolder, 'atom.cmd') + relativeAtomPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.cmd')) + atomCommand = "@echo off\r\n\"%~dp0\\#{relativeAtomPath}\" %*" + + atomShCommandPath = path.join(binFolder, 'atom') + relativeAtomShPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.sh')) + atomShCommand = "#!/bin/sh\r\n\"$(dirname \"$0\")/#{relativeAtomShPath.replace(/\\/g, '/')}\" \"$@\"\r\necho" + + apmCommandPath = path.join(binFolder, 'apm.cmd') + relativeApmPath = path.relative(binFolder, path.join(process.resourcesPath, 'app', 'apm', 'bin', 'apm.cmd')) + apmCommand = "@echo off\r\n\"%~dp0\\#{relativeApmPath}\" %*" + + apmShCommandPath = path.join(binFolder, 'apm') + relativeApmShPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'apm.sh')) + apmShCommand = "#!/bin/sh\r\n\"$(dirname \"$0\")/#{relativeApmShPath.replace(/\\/g, '/')}\" \"$@\"" + + fs.writeFile atomCommandPath, atomCommand, -> + fs.writeFile atomShCommandPath, atomShCommand, -> + fs.writeFile apmCommandPath, apmCommand, -> + fs.writeFile apmShCommandPath, apmShCommand, -> + callback() + + addBinToPath = (pathSegments, callback) -> + pathSegments.push(binFolder) + newPathEnv = pathSegments.join(';') + spawnSetx(['Path', newPathEnv], callback) + + installCommands (error) -> + return callback(error) if error? + + WinPowerShell.getPath (error, pathEnv) -> + return callback(error) if error? + + pathSegments = pathEnv.split(/;+/).filter (pathSegment) -> pathSegment + if pathSegments.indexOf(binFolder) is -1 + addBinToPath(pathSegments, callback) + else + callback() + +# Remove atom and apm from the PATH +removeCommandsFromPath = (callback) -> + WinPowerShell.getPath (error, pathEnv) -> + return callback(error) if error? + + pathSegments = pathEnv.split(/;+/).filter (pathSegment) -> + pathSegment and pathSegment isnt binFolder + newPathEnv = pathSegments.join(';') + + if pathEnv isnt newPathEnv + spawnSetx(['Path', newPathEnv], callback) + else + callback() + +# Create a desktop and start menu shortcut by using the command line API +# provided by Squirrel's Update.exe +createShortcuts = (locations, callback) -> + spawnUpdate(['--createShortcut', exeName, '-l', locations.join(',')], callback) + +# Update the desktop and start menu shortcuts by using the command line API +# provided by Squirrel's Update.exe +updateShortcuts = (callback) -> + if homeDirectory = fs.getHomeDirectory() + desktopShortcutPath = path.join(homeDirectory, 'Desktop', "#{app.getName()}.lnk") + # Check if the desktop shortcut has been previously deleted and + # and keep it deleted if it was + fs.exists desktopShortcutPath, (desktopShortcutExists) -> + locations = ['StartMenu'] + locations.push 'Desktop' if desktopShortcutExists + + createShortcuts locations, callback + else + createShortcuts ['Desktop', 'StartMenu'], callback + +# Remove the desktop and start menu shortcuts by using the command line API +# provided by Squirrel's Update.exe +removeShortcuts = (callback) -> + spawnUpdate(['--removeShortcut', exeName], callback) + +exports.spawn = spawnUpdate + +# Is the Update.exe installed with Atom? +exports.existsSync = -> + fs.existsSync(updateDotExe) + +# Restart Atom using the version pointed to by the atom.cmd shim +exports.restartAtom = (app) -> + if projectPath = global.atomApplication?.lastFocusedWindow?.projectPath + args = [projectPath] + app.once 'will-quit', -> Spawner.spawn(path.join(binFolder, 'atom.cmd'), args) + app.quit() + +updateContextMenus = (callback) -> + WinShell.fileContextMenu.update -> + WinShell.folderContextMenu.update -> + WinShell.folderBackgroundContextMenu.update -> + callback() + +# Handle squirrel events denoted by --squirrel-* command line arguments. +exports.handleStartupEvent = (app, squirrelCommand) -> + switch squirrelCommand + when '--squirrel-install' + createShortcuts ['Desktop', 'StartMenu'], -> + addCommandsToPath -> + WinShell.fileHandler.register -> + updateContextMenus -> + app.quit() + true + when '--squirrel-updated' + updateShortcuts -> + addCommandsToPath -> + WinShell.fileHandler.update -> + updateContextMenus -> + app.quit() + true + when '--squirrel-uninstall' + removeShortcuts -> + removeCommandsFromPath -> + WinShell.fileHandler.deregister -> + WinShell.fileContextMenu.deregister -> + WinShell.folderContextMenu.deregister -> + WinShell.folderBackgroundContextMenu.deregister -> + app.quit() + true + when '--squirrel-obsolete' + app.quit() + true + else + false From fe15f2dae517db209969afe5e6ddbc581cbb568b Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 9 Aug 2018 12:25:20 -0700 Subject: [PATCH 05/58] Set the productName similarly on all platforms --- script/lib/generate-metadata.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/script/lib/generate-metadata.js b/script/lib/generate-metadata.js index 4baa8d9cf..a23392be0 100644 --- a/script/lib/generate-metadata.js +++ b/script/lib/generate-metadata.js @@ -10,11 +10,10 @@ const semver = require('semver') const CONFIG = require('../config') let appName = CONFIG.appMetadata.name -let appProductName = CONFIG.appMetadata.productName - if (process.platform === 'win32') { + // Use the channel name in the app name on Windows so that the installer will + // place it in a different folder in AppData\Local appName = CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}` - appProductName = CONFIG.appName } module.exports = function () { @@ -25,7 +24,7 @@ module.exports = function () { CONFIG.appMetadata._deprecatedPackages = deprecatedPackagesMetadata CONFIG.appMetadata.version = CONFIG.computedAppVersion CONFIG.appMetadata.name = appName - CONFIG.appMetadata.productName = appProductName + CONFIG.appMetadata.productName = CONFIG.appName checkDeprecatedPackagesMetadata() fs.writeFileSync(path.join(CONFIG.intermediateAppPath, 'package.json'), JSON.stringify(CONFIG.appMetadata)) } From 43faf1ca36234b3d8eb8fe59bdf5e1bd0d3c5fed Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 9 Aug 2018 12:59:59 -0700 Subject: [PATCH 06/58] :shirt: More spaces for the space god --- src/atom-environment.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/atom-environment.js b/src/atom-environment.js index cb401592b..8715c9ba4 100644 --- a/src/atom-environment.js +++ b/src/atom-environment.js @@ -480,7 +480,7 @@ class AtomEnvironment { // Public: Get the full name of this Atom release (e.g. "Atom", "Atom Beta") // // Returns the app name {String}. - getAppName() { + getAppName () { if (this.appName == null) this.appName = this.getLoadSettings().appName return this.appName } From 83cfee6296bab1e4e1a43755ac39b57778b7ad7d Mon Sep 17 00:00:00 2001 From: David Wilson Date: Tue, 18 Sep 2018 13:11:37 -0700 Subject: [PATCH 07/58] Decaffeinate spect/squirrel-update-spec.coffee --- spec/squirrel-update-spec.coffee | 137 ---------------------------- spec/squirrel-update-spec.js | 148 +++++++++++++++++++++++++++++++ 2 files changed, 148 insertions(+), 137 deletions(-) delete mode 100644 spec/squirrel-update-spec.coffee create mode 100644 spec/squirrel-update-spec.js diff --git a/spec/squirrel-update-spec.coffee b/spec/squirrel-update-spec.coffee deleted file mode 100644 index fe0fa7479..000000000 --- a/spec/squirrel-update-spec.coffee +++ /dev/null @@ -1,137 +0,0 @@ -{EventEmitter} = require 'events' -fs = require 'fs-plus' -path = require 'path' -temp = require('temp').track() -SquirrelUpdate = require '../src/main-process/squirrel-update' -Spawner = require '../src/main-process/spawner' -WinShell = require '../src/main-process/win-shell' - -# Run passed callback as Spawner.spawn() would do -invokeCallback = (callback) -> - error = null - stdout = '' - callback?(error, stdout) - -describe "Windows Squirrel Update", -> - tempHomeDirectory = null - - beforeEach -> - # Prevent the actual home directory from being manipulated - tempHomeDirectory = temp.mkdirSync('atom-temp-home-') - spyOn(fs, 'getHomeDirectory').andReturn(tempHomeDirectory) - - # Prevent any spawned command from actually running and affecting the host - spyOn(Spawner, 'spawn').andCallFake (command, args, callback) -> - # do nothing on command, just run passed callback - invokeCallback callback - - # Prevent any actual change to Windows Shell - class FakeShellOption - isRegistered: (callback) -> callback true - register: (callback) -> callback null - deregister: (callback) -> callback null, true - update: (callback) -> callback null - WinShell.fileHandler = new FakeShellOption() - WinShell.fileContextMenu = new FakeShellOption() - WinShell.folderContextMenu = new FakeShellOption() - WinShell.folderBackgroundContextMenu = new FakeShellOption() - - afterEach -> - try - temp.cleanupSync() - - it "quits the app on all squirrel events", -> - app = quit: jasmine.createSpy('quit') - - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe true - - waitsFor -> - app.quit.callCount is 1 - - runs -> - app.quit.reset() - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated')).toBe true - - waitsFor -> - app.quit.callCount is 1 - - runs -> - app.quit.reset() - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-uninstall')).toBe true - - waitsFor -> - app.quit.callCount is 1 - - runs -> - app.quit.reset() - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-obsolete')).toBe true - - waitsFor -> - app.quit.callCount is 1 - - runs -> - expect(SquirrelUpdate.handleStartupEvent(app, '--not-squirrel')).toBe false - - describe "Desktop shortcut", -> - desktopShortcutPath = '/non/existing/path' - - beforeEach -> - desktopShortcutPath = path.join(tempHomeDirectory, 'Desktop', 'Atom.lnk') - - jasmine.unspy(Spawner, 'spawn') - spyOn(Spawner, 'spawn').andCallFake (command, args, callback) -> - if path.basename(command) is 'Update.exe' and args?[0] is '--createShortcut' and args?[3].match /Desktop/i - fs.writeFileSync(desktopShortcutPath, '') - else - # simply ignore other commands - - invokeCallback callback - - it "does not exist before install", -> - expect(fs.existsSync(desktopShortcutPath)).toBe false - - describe "on install", -> - beforeEach -> - app = quit: jasmine.createSpy('quit') - SquirrelUpdate.handleStartupEvent(app, '--squirrel-install') - waitsFor -> - app.quit.callCount is 1 - - it "creates desktop shortcut", -> - expect(fs.existsSync(desktopShortcutPath)).toBe true - - describe "when shortcut is deleted and then app is updated", -> - beforeEach -> - fs.removeSync(desktopShortcutPath) - expect(fs.existsSync(desktopShortcutPath)).toBe false - - app = quit: jasmine.createSpy('quit') - SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated') - waitsFor -> - app.quit.callCount is 1 - - it "does not recreate shortcut", -> - expect(fs.existsSync(desktopShortcutPath)).toBe false - - describe "when shortcut is kept and app is updated", -> - beforeEach -> - app = quit: jasmine.createSpy('quit') - SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated') - waitsFor -> - app.quit.callCount is 1 - - it "still has desktop shortcut", -> - expect(fs.existsSync(desktopShortcutPath)).toBe true - - describe ".restartAtom", -> - it "quits the app and spawns a new one", -> - app = new EventEmitter() - app.quit = jasmine.createSpy('quit') - - SquirrelUpdate.restartAtom(app) - expect(app.quit.callCount).toBe 1 - - expect(Spawner.spawn.callCount).toBe 0 - app.emit('will-quit') - expect(Spawner.spawn.callCount).toBe 1 - expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe 'atom.cmd' diff --git a/spec/squirrel-update-spec.js b/spec/squirrel-update-spec.js new file mode 100644 index 000000000..f7fad768a --- /dev/null +++ b/spec/squirrel-update-spec.js @@ -0,0 +1,148 @@ +const {EventEmitter} = require('events'); +const fs = require('fs-plus'); +const path = require('path'); +const temp = require('temp').track(); +const SquirrelUpdate = require('../src/main-process/squirrel-update'); +const Spawner = require('../src/main-process/spawner'); +const WinShell = require('../src/main-process/win-shell'); + +// Run passed callback as Spawner.spawn() would do +const invokeCallback = function(callback) { + const error = null; + const stdout = ''; + return (typeof callback === 'function' ? callback(error, stdout) : undefined); +}; + +describe("Windows Squirrel Update", function() { + let tempHomeDirectory = null; + + beforeEach(function() { + // Prevent the actual home directory from being manipulated + tempHomeDirectory = temp.mkdirSync('atom-temp-home-'); + spyOn(fs, 'getHomeDirectory').andReturn(tempHomeDirectory); + + // Prevent any spawned command from actually running and affecting the host + spyOn(Spawner, 'spawn').andCallFake((command, args, callback) => + // do nothing on command, just run passed callback + invokeCallback(callback) + ); + + // Prevent any actual change to Windows Shell + class FakeShellOption { + isRegistered(callback) { return callback(true); } + register(callback) { return callback(null); } + deregister(callback) { return callback(null, true); } + update(callback) { return callback(null); } + } + WinShell.fileHandler = new FakeShellOption(); + WinShell.fileContextMenu = new FakeShellOption(); + WinShell.folderContextMenu = new FakeShellOption(); + return WinShell.folderBackgroundContextMenu = new FakeShellOption(); + }); + + afterEach(function() { + try { + return temp.cleanupSync(); + } catch (error) {} + }); + + it("quits the app on all squirrel events", function() { + const app = {quit: jasmine.createSpy('quit')}; + + expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe(true); + + waitsFor(() => app.quit.callCount === 1); + + runs(function() { + app.quit.reset(); + return expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated')).toBe(true); + }); + + waitsFor(() => app.quit.callCount === 1); + + runs(function() { + app.quit.reset(); + return expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-uninstall')).toBe(true); + }); + + waitsFor(() => app.quit.callCount === 1); + + runs(function() { + app.quit.reset(); + return expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-obsolete')).toBe(true); + }); + + waitsFor(() => app.quit.callCount === 1); + + return runs(() => expect(SquirrelUpdate.handleStartupEvent(app, '--not-squirrel')).toBe(false)); + }); + + describe("Desktop shortcut", function() { + let desktopShortcutPath = '/non/existing/path'; + + beforeEach(function() { + desktopShortcutPath = path.join(tempHomeDirectory, 'Desktop', 'Atom.lnk'); + + jasmine.unspy(Spawner, 'spawn'); + return spyOn(Spawner, 'spawn').andCallFake(function(command, args, callback) { + if ((path.basename(command) === 'Update.exe') && ((args != null ? args[0] : undefined) === '--createShortcut') && (args != null ? args[3].match(/Desktop/i) : undefined)) { + fs.writeFileSync(desktopShortcutPath, ''); + } + else {} + // simply ignore other commands + + return invokeCallback(callback); + }); + }); + + it("does not exist before install", () => expect(fs.existsSync(desktopShortcutPath)).toBe(false)); + + return describe("on install", function() { + beforeEach(function() { + const app = {quit: jasmine.createSpy('quit')}; + SquirrelUpdate.handleStartupEvent(app, '--squirrel-install'); + return waitsFor(() => app.quit.callCount === 1); + }); + + it("creates desktop shortcut", () => expect(fs.existsSync(desktopShortcutPath)).toBe(true)); + + describe("when shortcut is deleted and then app is updated", function() { + beforeEach(function() { + fs.removeSync(desktopShortcutPath); + expect(fs.existsSync(desktopShortcutPath)).toBe(false); + + const app = {quit: jasmine.createSpy('quit')}; + SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); + return waitsFor(() => app.quit.callCount === 1); + }); + + return it("does not recreate shortcut", () => expect(fs.existsSync(desktopShortcutPath)).toBe(false)); + }); + + return describe("when shortcut is kept and app is updated", function() { + beforeEach(function() { + const app = {quit: jasmine.createSpy('quit')}; + SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); + return waitsFor(() => app.quit.callCount === 1); + }); + + return it("still has desktop shortcut", () => expect(fs.existsSync(desktopShortcutPath)).toBe(true)); + }); + }); + }); + + return describe(".restartAtom", () => + it("quits the app and spawns a new one", function() { + const app = new EventEmitter(); + app.quit = jasmine.createSpy('quit'); + + SquirrelUpdate.restartAtom(app); + expect(app.quit.callCount).toBe(1); + + expect(Spawner.spawn.callCount).toBe(0); + app.emit('will-quit'); + expect(Spawner.spawn.callCount).toBe(1); + return expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe('atom.cmd'); + }) + ); +}); From 41748876f1b998f48a05b9225dc981c2de69425f Mon Sep 17 00:00:00 2001 From: David Wilson Date: Tue, 18 Sep 2018 13:29:23 -0700 Subject: [PATCH 08/58] Pass the `app` object straight into SquirrelUpdate.updateShortcuts --- spec/squirrel-update-spec.js | 17 ++++++++++++++--- src/main-process/squirrel-update.js | 6 +++--- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/spec/squirrel-update-spec.js b/spec/squirrel-update-spec.js index f7fad768a..ad7d80884 100644 --- a/spec/squirrel-update-spec.js +++ b/spec/squirrel-update-spec.js @@ -13,6 +13,8 @@ const invokeCallback = function(callback) { return (typeof callback === 'function' ? callback(error, stdout) : undefined); }; +const AtomTestAppName = 'Atom Testing' + describe("Windows Squirrel Update", function() { let tempHomeDirectory = null; @@ -47,7 +49,10 @@ describe("Windows Squirrel Update", function() { }); it("quits the app on all squirrel events", function() { - const app = {quit: jasmine.createSpy('quit')}; + const app = { + quit: jasmine.createSpy('quit'), + getName: () => AtomTestAppName + }; expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe(true); @@ -111,7 +116,10 @@ describe("Windows Squirrel Update", function() { fs.removeSync(desktopShortcutPath); expect(fs.existsSync(desktopShortcutPath)).toBe(false); - const app = {quit: jasmine.createSpy('quit')}; + const app = { + quit: jasmine.createSpy('quit'), + getName: () => AtomTestAppName + }; SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); return waitsFor(() => app.quit.callCount === 1); }); @@ -121,7 +129,10 @@ describe("Windows Squirrel Update", function() { return describe("when shortcut is kept and app is updated", function() { beforeEach(function() { - const app = {quit: jasmine.createSpy('quit')}; + const app = { + quit: jasmine.createSpy('quit'), + getName: () => AtomTestAppName + }; SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); return waitsFor(() => app.quit.callCount === 1); }); diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index 0d8174f47..450b0203a 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -100,10 +100,10 @@ const createShortcuts = (locations, callback) => spawnUpdate(['--createShortcut' // Update the desktop and start menu shortcuts by using the command line API // provided by Squirrel's Update.exe -const updateShortcuts = (callback) => { +const updateShortcuts = (app, callback) => { const homeDirectory = fs.getHomeDirectory() if (homeDirectory) { - const desktopShortcutPath = path.join(homeDirectory, 'Desktop', 'Atom.lnk') + const desktopShortcutPath = path.join(homeDirectory, 'Desktop', `${app.getName()}.lnk`) // Check if the desktop shortcut has been previously deleted and // and keep it deleted if it was fs.exists(desktopShortcutPath, (desktopShortcutExists) => { @@ -157,7 +157,7 @@ exports.handleStartupEvent = (app, squirrelCommand) => { ) return true case '--squirrel-updated': - updateShortcuts(() => + updateShortcuts(app, () => addCommandsToPath(() => WinShell.fileHandler.update(() => updateContextMenus(() => app.quit()) From ab3c942b715c9ac8e522b3c3e728f7b3121e13d1 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Tue, 18 Sep 2018 13:30:28 -0700 Subject: [PATCH 09/58] Remove decaffeinated squirrel-update.coffee --- src/main-process/squirrel-update.coffee | 163 ------------------------ 1 file changed, 163 deletions(-) delete mode 100644 src/main-process/squirrel-update.coffee diff --git a/src/main-process/squirrel-update.coffee b/src/main-process/squirrel-update.coffee deleted file mode 100644 index 77256feee..000000000 --- a/src/main-process/squirrel-update.coffee +++ /dev/null @@ -1,163 +0,0 @@ -fs = require 'fs-plus' -path = require 'path' -{app} = require 'electron' -Spawner = require './spawner' -WinShell = require './win-shell' -WinPowerShell = require './win-powershell' - -appFolder = path.resolve(process.execPath, '..') -rootAtomFolder = path.resolve(appFolder, '..') -binFolder = path.join(rootAtomFolder, 'bin') -updateDotExe = path.join(rootAtomFolder, 'Update.exe') -exeName = path.basename(process.execPath) - -if process.env.SystemRoot - system32Path = path.join(process.env.SystemRoot, 'System32') - setxPath = path.join(system32Path, 'setx.exe') -else - setxPath = 'setx.exe' - -# Spawn setx.exe and callback when it completes -spawnSetx = (args, callback) -> - Spawner.spawn(setxPath, args, callback) - -# Spawn the Update.exe with the given arguments and invoke the callback when -# the command completes. -spawnUpdate = (args, callback) -> - Spawner.spawn(updateDotExe, args, callback) - -# Add atom and apm to the PATH -# -# This is done by adding .cmd shims to the root bin folder in the Atom -# install directory that point to the newly installed versions inside -# the versioned app directories. -addCommandsToPath = (callback) -> - installCommands = (callback) -> - atomCommandPath = path.join(binFolder, 'atom.cmd') - relativeAtomPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.cmd')) - atomCommand = "@echo off\r\n\"%~dp0\\#{relativeAtomPath}\" %*" - - atomShCommandPath = path.join(binFolder, 'atom') - relativeAtomShPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.sh')) - atomShCommand = "#!/bin/sh\r\n\"$(dirname \"$0\")/#{relativeAtomShPath.replace(/\\/g, '/')}\" \"$@\"\r\necho" - - apmCommandPath = path.join(binFolder, 'apm.cmd') - relativeApmPath = path.relative(binFolder, path.join(process.resourcesPath, 'app', 'apm', 'bin', 'apm.cmd')) - apmCommand = "@echo off\r\n\"%~dp0\\#{relativeApmPath}\" %*" - - apmShCommandPath = path.join(binFolder, 'apm') - relativeApmShPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'apm.sh')) - apmShCommand = "#!/bin/sh\r\n\"$(dirname \"$0\")/#{relativeApmShPath.replace(/\\/g, '/')}\" \"$@\"" - - fs.writeFile atomCommandPath, atomCommand, -> - fs.writeFile atomShCommandPath, atomShCommand, -> - fs.writeFile apmCommandPath, apmCommand, -> - fs.writeFile apmShCommandPath, apmShCommand, -> - callback() - - addBinToPath = (pathSegments, callback) -> - pathSegments.push(binFolder) - newPathEnv = pathSegments.join(';') - spawnSetx(['Path', newPathEnv], callback) - - installCommands (error) -> - return callback(error) if error? - - WinPowerShell.getPath (error, pathEnv) -> - return callback(error) if error? - - pathSegments = pathEnv.split(/;+/).filter (pathSegment) -> pathSegment - if pathSegments.indexOf(binFolder) is -1 - addBinToPath(pathSegments, callback) - else - callback() - -# Remove atom and apm from the PATH -removeCommandsFromPath = (callback) -> - WinPowerShell.getPath (error, pathEnv) -> - return callback(error) if error? - - pathSegments = pathEnv.split(/;+/).filter (pathSegment) -> - pathSegment and pathSegment isnt binFolder - newPathEnv = pathSegments.join(';') - - if pathEnv isnt newPathEnv - spawnSetx(['Path', newPathEnv], callback) - else - callback() - -# Create a desktop and start menu shortcut by using the command line API -# provided by Squirrel's Update.exe -createShortcuts = (locations, callback) -> - spawnUpdate(['--createShortcut', exeName, '-l', locations.join(',')], callback) - -# Update the desktop and start menu shortcuts by using the command line API -# provided by Squirrel's Update.exe -updateShortcuts = (callback) -> - if homeDirectory = fs.getHomeDirectory() - desktopShortcutPath = path.join(homeDirectory, 'Desktop', "#{app.getName()}.lnk") - # Check if the desktop shortcut has been previously deleted and - # and keep it deleted if it was - fs.exists desktopShortcutPath, (desktopShortcutExists) -> - locations = ['StartMenu'] - locations.push 'Desktop' if desktopShortcutExists - - createShortcuts locations, callback - else - createShortcuts ['Desktop', 'StartMenu'], callback - -# Remove the desktop and start menu shortcuts by using the command line API -# provided by Squirrel's Update.exe -removeShortcuts = (callback) -> - spawnUpdate(['--removeShortcut', exeName], callback) - -exports.spawn = spawnUpdate - -# Is the Update.exe installed with Atom? -exports.existsSync = -> - fs.existsSync(updateDotExe) - -# Restart Atom using the version pointed to by the atom.cmd shim -exports.restartAtom = (app) -> - if projectPath = global.atomApplication?.lastFocusedWindow?.projectPath - args = [projectPath] - app.once 'will-quit', -> Spawner.spawn(path.join(binFolder, 'atom.cmd'), args) - app.quit() - -updateContextMenus = (callback) -> - WinShell.fileContextMenu.update -> - WinShell.folderContextMenu.update -> - WinShell.folderBackgroundContextMenu.update -> - callback() - -# Handle squirrel events denoted by --squirrel-* command line arguments. -exports.handleStartupEvent = (app, squirrelCommand) -> - switch squirrelCommand - when '--squirrel-install' - createShortcuts ['Desktop', 'StartMenu'], -> - addCommandsToPath -> - WinShell.fileHandler.register -> - updateContextMenus -> - app.quit() - true - when '--squirrel-updated' - updateShortcuts -> - addCommandsToPath -> - WinShell.fileHandler.update -> - updateContextMenus -> - app.quit() - true - when '--squirrel-uninstall' - removeShortcuts -> - removeCommandsFromPath -> - WinShell.fileHandler.deregister -> - WinShell.fileContextMenu.deregister -> - WinShell.folderContextMenu.deregister -> - WinShell.folderBackgroundContextMenu.deregister -> - app.quit() - true - when '--squirrel-obsolete' - app.quit() - true - else - false From eb7f0aa452da27450f18538fc3f7dbf30133bb65 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 20 Sep 2018 12:05:01 -0700 Subject: [PATCH 10/58] Produce channel-specific Atom .exe and .cmd files on Windows --- script/config.js | 12 ++++ script/lib/create-windows-installer.js | 1 - script/lib/generate-startup-snapshot.js | 7 +-- script/lib/package-application.js | 2 + script/test | 2 +- spec/squirrel-update-spec.js | 43 ++++++-------- src/main-process/squirrel-update.js | 63 +++++++++----------- src/main-process/win-shell.js | 78 ++++++++++++++++++------- 8 files changed, 120 insertions(+), 88 deletions(-) diff --git a/script/config.js b/script/config.js index 16b7cadb5..88948a095 100644 --- a/script/config.js +++ b/script/config.js @@ -23,12 +23,14 @@ const apmMetadata = require(path.join(apmRootPath, 'package.json')) const computedAppVersion = computeAppVersion(process.env.ATOM_RELEASE_VERSION || appMetadata.version) const channel = getChannel(computedAppVersion) const appName = getAppName(channel) +const executableName = getExecutableName(channel, appName) module.exports = { appMetadata, apmMetadata, channel, appName, + executableName, computedAppVersion, repositoryRootPath, apmRootPath, @@ -62,6 +64,16 @@ function getAppName (channel) { : `Atom ${process.env.ATOM_CHANNEL_DISPLAY_NAME || channel.charAt(0).toUpperCase() + channel.slice(1)}` } +function getExecutableName (channel, appName) { + if (process.platform === 'darwin') { + return appName + } else if (process.platform === 'win32') { + return channel === 'stable' ? 'atom.exe' : `atom-${channel}.exe` + } else { + return 'atom' + } +} + function computeAppVersion (version) { if (version.match(/-dev$/)) { const result = spawnSync('git', ['rev-parse', '--short', 'HEAD'], {cwd: repositoryRootPath}) diff --git a/script/lib/create-windows-installer.js b/script/lib/create-windows-installer.js index c16df615b..23dd1f96f 100644 --- a/script/lib/create-windows-installer.js +++ b/script/lib/create-windows-installer.js @@ -10,7 +10,6 @@ const CONFIG = require('../config') module.exports = (packagedAppPath) => { const archSuffix = process.arch === 'ia32' ? '' : '-' + process.arch const options = { - exe: 'atom.exe', title: CONFIG.appName, appDirectory: packagedAppPath, authors: 'GitHub Inc.', diff --git a/script/lib/generate-startup-snapshot.js b/script/lib/generate-startup-snapshot.js index 4e4945e19..1a76b839d 100644 --- a/script/lib/generate-startup-snapshot.js +++ b/script/lib/generate-startup-snapshot.js @@ -84,12 +84,9 @@ module.exports = function (packagedAppPath) { const verifySnapshotScriptPath = path.join(CONFIG.repositoryRootPath, 'script', 'verify-snapshot-script') let nodeBundledInElectronPath if (process.platform === 'darwin') { - const executableName = CONFIG.appName - nodeBundledInElectronPath = path.join(packagedAppPath, 'Contents', 'MacOS', executableName) - } else if (process.platform === 'win32') { - nodeBundledInElectronPath = path.join(packagedAppPath, 'atom.exe') + nodeBundledInElectronPath = path.join(packagedAppPath, 'Contents', 'MacOS', CONFIG.executableName) } else { - nodeBundledInElectronPath = path.join(packagedAppPath, 'atom') + nodeBundledInElectronPath = path.join(packagedAppPath, CONFIG.executableName) } childProcess.execFileSync( nodeBundledInElectronPath, diff --git a/script/lib/package-application.js b/script/lib/package-application.js index 91b231ffd..7365bada8 100644 --- a/script/lib/package-application.js +++ b/script/lib/package-application.js @@ -115,6 +115,8 @@ function buildAsarUnpackGlobExpression () { function getAppName () { if (process.platform === 'darwin') { return CONFIG.appName + } else if (process.platform === 'win32') { + return CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}` } else { return 'atom' } diff --git a/script/test b/script/test index 64688daa1..ed57d1cf7 100755 --- a/script/test +++ b/script/test @@ -26,7 +26,7 @@ if (process.platform === 'darwin') { assert(executablePaths.length === 1, `More than one application to run tests against was found. ${executablePaths.join(',')}`) executablePath = executablePaths[0] } else if (process.platform === 'win32') { - const executablePaths = glob.sync(path.join(CONFIG.buildOutputPath, '**', 'atom.exe')) + const executablePaths = glob.sync(path.join(CONFIG.buildOutputPath, '**', CONFIG.executableName)) assert(executablePaths.length === 1, `More than one application to run tests against was found. ${executablePaths.join(',')}`) executablePath = executablePaths[0] } else { diff --git a/spec/squirrel-update-spec.js b/spec/squirrel-update-spec.js index ad7d80884..622315eb8 100644 --- a/spec/squirrel-update-spec.js +++ b/spec/squirrel-update-spec.js @@ -13,9 +13,17 @@ const invokeCallback = function(callback) { return (typeof callback === 'function' ? callback(error, stdout) : undefined); }; +const createFakeApp = function() { + return { + quit: jasmine.createSpy('quit'), + getName: () => AtomTestAppName, + getPath: () => 'atom-test.exe' + }; +} + const AtomTestAppName = 'Atom Testing' -describe("Windows Squirrel Update", function() { +fdescribe("Windows Squirrel Update", function() { let tempHomeDirectory = null; beforeEach(function() { @@ -30,16 +38,9 @@ describe("Windows Squirrel Update", function() { ); // Prevent any actual change to Windows Shell - class FakeShellOption { - isRegistered(callback) { return callback(true); } - register(callback) { return callback(null); } - deregister(callback) { return callback(null, true); } - update(callback) { return callback(null); } - } - WinShell.fileHandler = new FakeShellOption(); - WinShell.fileContextMenu = new FakeShellOption(); - WinShell.folderContextMenu = new FakeShellOption(); - return WinShell.folderBackgroundContextMenu = new FakeShellOption(); + spyOn(WinShell, 'registerShellIntegration').andCallFake((appName, callback) => callback()) + spyOn(WinShell, 'updateShellIntegration').andCallFake((appName, callback) => callback()) + spyOn(WinShell, 'deregisterShellIntegration').andCallFake((appName, callback) => callback()) }); afterEach(function() { @@ -49,10 +50,7 @@ describe("Windows Squirrel Update", function() { }); it("quits the app on all squirrel events", function() { - const app = { - quit: jasmine.createSpy('quit'), - getName: () => AtomTestAppName - }; + const app = createFakeApp() expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe(true); @@ -104,7 +102,7 @@ describe("Windows Squirrel Update", function() { return describe("on install", function() { beforeEach(function() { - const app = {quit: jasmine.createSpy('quit')}; + const app = createFakeApp() SquirrelUpdate.handleStartupEvent(app, '--squirrel-install'); return waitsFor(() => app.quit.callCount === 1); }); @@ -116,10 +114,7 @@ describe("Windows Squirrel Update", function() { fs.removeSync(desktopShortcutPath); expect(fs.existsSync(desktopShortcutPath)).toBe(false); - const app = { - quit: jasmine.createSpy('quit'), - getName: () => AtomTestAppName - }; + const app = createFakeApp() SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); return waitsFor(() => app.quit.callCount === 1); }); @@ -129,10 +124,7 @@ describe("Windows Squirrel Update", function() { return describe("when shortcut is kept and app is updated", function() { beforeEach(function() { - const app = { - quit: jasmine.createSpy('quit'), - getName: () => AtomTestAppName - }; + const app = createFakeApp() SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); return waitsFor(() => app.quit.callCount === 1); }); @@ -146,6 +138,7 @@ describe("Windows Squirrel Update", function() { it("quits the app and spawns a new one", function() { const app = new EventEmitter(); app.quit = jasmine.createSpy('quit'); + app.getPath = () => 'atom-test.exe' SquirrelUpdate.restartAtom(app); expect(app.quit.callCount).toBe(1); @@ -153,7 +146,7 @@ describe("Windows Squirrel Update", function() { expect(Spawner.spawn.callCount).toBe(0); app.emit('will-quit'); expect(Spawner.spawn.callCount).toBe(1); - return expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe('atom.cmd'); + return expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe('atom-test.cmd'); }) ); }); diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index 450b0203a..176568307 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -9,7 +9,6 @@ const appFolder = path.resolve(process.execPath, '..') const rootAtomFolder = path.resolve(appFolder, '..') const binFolder = path.join(rootAtomFolder, 'bin') const updateDotExe = path.join(rootAtomFolder, 'Update.exe') -const exeName = path.basename(process.execPath) if (process.env.SystemRoot) { const system32Path = path.join(process.env.SystemRoot, 'System32') @@ -30,9 +29,12 @@ const spawnUpdate = (args, callback) => Spawner.spawn(updateDotExe, args, callba // This is done by adding .cmd shims to the root bin folder in the Atom // install directory that point to the newly installed versions inside // the versioned app directories. -const addCommandsToPath = callback => { +const addCommandsToPath = (exeName, callback) => { + const atomCmdName = exeName.replace('.exe', '.cmd') + const apmCmdName = atomCmdName.replace('atom', 'apm') + const installCommands = callback => { - const atomCommandPath = path.join(binFolder, 'atom.cmd') + const atomCommandPath = path.join(binFolder, atomCmdName) const relativeAtomPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.cmd')) const atomCommand = `@echo off\r\n\"%~dp0\\${relativeAtomPath}\" %*` @@ -40,7 +42,7 @@ const addCommandsToPath = callback => { const relativeAtomShPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.sh')) const atomShCommand = `#!/bin/sh\r\n\"$(dirname \"$0\")/${relativeAtomShPath.replace(/\\/g, '/')}\" \"$@\"\r\necho` - const apmCommandPath = path.join(binFolder, 'apm.cmd') + const apmCommandPath = path.join(binFolder, apmCmdName) const relativeApmPath = path.relative(binFolder, path.join(process.resourcesPath, 'app', 'apm', 'bin', 'apm.cmd')) const apmCommand = `@echo off\r\n\"%~dp0\\${relativeApmPath}\" %*` @@ -94,32 +96,35 @@ const removeCommandsFromPath = callback => } }) +const getExeName = (app) => path.basename(app.getPath('exe')) + // Create a desktop and start menu shortcut by using the command line API // provided by Squirrel's Update.exe -const createShortcuts = (locations, callback) => spawnUpdate(['--createShortcut', exeName, '-l', locations.join(',')], callback) +const createShortcuts = (exeName, locations, callback) => + spawnUpdate(['--createShortcut', exeName, '-l', locations.join(',')], callback) // Update the desktop and start menu shortcuts by using the command line API // provided by Squirrel's Update.exe -const updateShortcuts = (app, callback) => { +const updateShortcuts = (appName, exeName, callback) => { const homeDirectory = fs.getHomeDirectory() if (homeDirectory) { - const desktopShortcutPath = path.join(homeDirectory, 'Desktop', `${app.getName()}.lnk`) + const desktopShortcutPath = path.join(homeDirectory, 'Desktop', `${appName}.lnk`) // Check if the desktop shortcut has been previously deleted and // and keep it deleted if it was fs.exists(desktopShortcutPath, (desktopShortcutExists) => { const locations = ['StartMenu'] if (desktopShortcutExists) { locations.push('Desktop') } - createShortcuts(locations, callback) + createShortcuts(exeName, locations, callback) }) } else { - createShortcuts(['Desktop', 'StartMenu'], callback) + createShortcuts(exeName, ['Desktop', 'StartMenu'], callback) } } // Remove the desktop and start menu shortcuts by using the command line API // provided by Squirrel's Update.exe -const removeShortcuts = callback => spawnUpdate(['--removeShortcut', exeName], callback) +const removeShortcuts = (exeName, callback) => spawnUpdate(['--removeShortcut', exeName], callback) exports.spawn = spawnUpdate @@ -129,52 +134,38 @@ exports.existsSync = () => fs.existsSync(updateDotExe) // Restart Atom using the version pointed to by the atom.cmd shim exports.restartAtom = (app) => { let args + const exeName = getExeName(app) + const atomCmdName = exeName.replace('.exe', '.cmd') if (global.atomApplication && global.atomApplication.lastFocusedWindow) { const {projectPath} = global.atomApplication.lastFocusedWindow if (projectPath) args = [projectPath] } - app.once('will-quit', () => Spawner.spawn(path.join(binFolder, 'atom.cmd'), args)) + app.once('will-quit', () => Spawner.spawn(path.join(binFolder, atomCmdName), args)) app.quit() } -const updateContextMenus = callback => - WinShell.fileContextMenu.update(() => - WinShell.folderContextMenu.update(() => - WinShell.folderBackgroundContextMenu.update(() => callback()) - ) - ) - // Handle squirrel events denoted by --squirrel-* command line arguments. exports.handleStartupEvent = (app, squirrelCommand) => { + const exeName = getExeName(app) switch (squirrelCommand) { case '--squirrel-install': - createShortcuts(['Desktop', 'StartMenu'], () => - addCommandsToPath(() => - WinShell.fileHandler.register(() => - updateContextMenus(() => app.quit()) - ) + createShortcuts(exeName, ['Desktop', 'StartMenu'], () => + addCommandsToPath(exeName, () => + WinShell.registerShellIntegration(app.getName(), () => app.quit()) ) ) return true case '--squirrel-updated': - updateShortcuts(app, () => - addCommandsToPath(() => - WinShell.fileHandler.update(() => - updateContextMenus(() => app.quit()) - ) + updateShortcuts(app.getName(), exeName, () => + addCommandsToPath(exeName, () => + WinShell.updateShellIntegration(app.getName(), () => app.quit()) ) ) return true case '--squirrel-uninstall': - removeShortcuts(() => + removeShortcuts(exeName, () => removeCommandsFromPath(() => - WinShell.fileHandler.deregister(() => - WinShell.fileContextMenu.deregister(() => - WinShell.folderContextMenu.deregister(() => - WinShell.folderBackgroundContextMenu.deregister(() => app.quit()) - ) - ) - ) + WinShell.deregisterShellIntegration(app.getName(), () => app.quit()) ) ) return true diff --git a/src/main-process/win-shell.js b/src/main-process/win-shell.js index dd694b9dd..835ae420f 100644 --- a/src/main-process/win-shell.js +++ b/src/main-process/win-shell.js @@ -4,8 +4,6 @@ const Path = require('path') let exeName = Path.basename(process.execPath) let appPath = `\"${process.execPath}\"` let fileIconPath = `\"${Path.join(process.execPath, '..', 'resources', 'cli', 'file.ico')}\"` -let isBeta = appPath.includes(' Beta') -let appName = exeName.replace('atom', isBeta ? 'Atom Beta' : 'Atom').replace('.exe', '') class ShellOption { constructor (key, parts) { @@ -52,24 +50,64 @@ class ShellOption { } } -exports.appName = appName - -exports.fileHandler = new ShellOption(`\\Software\\Classes\\Applications\\${exeName}`, - [ - {key: 'shell\\open\\command', name: '', value: `${appPath} \"%1\"`}, - {key: 'shell\\open', name: 'FriendlyAppName', value: `${appName}`}, - {key: 'DefaultIcon', name: '', value: `${fileIconPath}`} +function getShellOptions(appName) { + const contextParts = [ + {key: 'command', name: '', value: `${appPath} \"%1\"`}, + {name: '', value: `Open with ${appName}`}, + {name: 'Icon', value: `${appPath}`} ] -) -let contextParts = [ - {key: 'command', name: '', value: `${appPath} \"%1\"`}, - {name: '', value: `Open with ${appName}`}, - {name: 'Icon', value: `${appPath}`} -] + return { + fileHandler: new ShellOption(`\\Software\\Classes\\Applications\\${exeName}`, + [ + {key: 'shell\\open\\command', name: '', value: `${appPath} \"%1\"`}, + {key: 'shell\\open', name: 'FriendlyAppName', value: `${appName}`}, + {key: 'DefaultIcon', name: '', value: `${fileIconPath}`} + ] + ), + fileContextMenu: new ShellOption(`\\Software\\Classes\\*\\shell\\${appName}`, contextParts), + folderContextMenu: new ShellOption(`\\Software\\Classes\\Directory\\shell\\${appName}`, contextParts), + folderBackgroundContextMenu: new ShellOption(`\\Software\\Classes\\Directory\\background\\shell\\${appName}`, + JSON.parse(JSON.stringify(contextParts).replace('%1', '%V')) + ) + } +} -exports.fileContextMenu = new ShellOption(`\\Software\\Classes\\*\\shell\\${appName}`, contextParts) -exports.folderContextMenu = new ShellOption(`\\Software\\Classes\\Directory\\shell\\${appName}`, contextParts) -exports.folderBackgroundContextMenu = new ShellOption(`\\Software\\Classes\\Directory\\background\\shell\\${appName}`, - JSON.parse(JSON.stringify(contextParts).replace('%1', '%V')) -) +function registerShellIntegration(appName, callback) { + const shellOptions = getShellOptions(appName) + shellOptions.fileHandler.register(() => + shellOptions.fileContextMenu.update(() => + shellOptions.folderContextMenu.update(() => + shellOptions.folderBackgroundContextMenu.update(() => callback()) + ) + ) + ) +} + +function updateShellIntegration(appName, callback) { + const shellOptions = getShellOptions(appName) + shellOptions.fileHandler.update(() => + shellOptions.fileContextMenu.update(() => + shellOptions.folderContextMenu.update(() => + shellOptions.folderBackgroundContextMenu.update(() => callback()) + ) + ) + ) +} + +function deregisterShellIntegration(appName, callback) { + const shellOptions = getShellOptions(appName) + shellOptions.fileHandler.deregister(() => + shellOptions.fileContextMenu.deregister(() => + shellOptions.folderContextMenu.deregister(() => + shellOptions.folderBackgroundContextMenu.deregister(() => callback()) + ) + ) + ) +} + +module.exports = { + registerShellIntegration, + updateShellIntegration, + deregisterShellIntegration, +} From dca29bd99aa3ffc125c5e1cf2da48282f2a4f208 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 20 Sep 2018 12:41:55 -0700 Subject: [PATCH 11/58] :shirt: --- src/main-process/squirrel-update.js | 2 +- src/main-process/win-shell.js | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index 176568307..8bddd3d5b 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -134,7 +134,7 @@ exports.existsSync = () => fs.existsSync(updateDotExe) // Restart Atom using the version pointed to by the atom.cmd shim exports.restartAtom = (app) => { let args - const exeName = getExeName(app) + const exeName = getExeName(app) const atomCmdName = exeName.replace('.exe', '.cmd') if (global.atomApplication && global.atomApplication.lastFocusedWindow) { const {projectPath} = global.atomApplication.lastFocusedWindow diff --git a/src/main-process/win-shell.js b/src/main-process/win-shell.js index 835ae420f..9c3d2baad 100644 --- a/src/main-process/win-shell.js +++ b/src/main-process/win-shell.js @@ -50,7 +50,7 @@ class ShellOption { } } -function getShellOptions(appName) { +function getShellOptions (appName) { const contextParts = [ {key: 'command', name: '', value: `${appPath} \"%1\"`}, {name: '', value: `Open with ${appName}`}, @@ -73,7 +73,7 @@ function getShellOptions(appName) { } } -function registerShellIntegration(appName, callback) { +function registerShellIntegration (appName, callback) { const shellOptions = getShellOptions(appName) shellOptions.fileHandler.register(() => shellOptions.fileContextMenu.update(() => @@ -84,7 +84,7 @@ function registerShellIntegration(appName, callback) { ) } -function updateShellIntegration(appName, callback) { +function updateShellIntegration (appName, callback) { const shellOptions = getShellOptions(appName) shellOptions.fileHandler.update(() => shellOptions.fileContextMenu.update(() => @@ -95,7 +95,7 @@ function updateShellIntegration(appName, callback) { ) } -function deregisterShellIntegration(appName, callback) { +function deregisterShellIntegration (appName, callback) { const shellOptions = getShellOptions(appName) shellOptions.fileHandler.deregister(() => shellOptions.fileContextMenu.deregister(() => @@ -109,5 +109,5 @@ function deregisterShellIntegration(appName, callback) { module.exports = { registerShellIntegration, updateShellIntegration, - deregisterShellIntegration, + deregisterShellIntegration } From e82ee6ca377a9081f1a3ffa0f042d8a28a92c62d Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 20 Sep 2018 13:07:32 -0700 Subject: [PATCH 12/58] Remove focused test --- spec/squirrel-update-spec.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/squirrel-update-spec.js b/spec/squirrel-update-spec.js index 622315eb8..f7dcf1422 100644 --- a/spec/squirrel-update-spec.js +++ b/spec/squirrel-update-spec.js @@ -23,7 +23,7 @@ const createFakeApp = function() { const AtomTestAppName = 'Atom Testing' -fdescribe("Windows Squirrel Update", function() { +describe("Windows Squirrel Update", function() { let tempHomeDirectory = null; beforeEach(function() { From bddf799e264a5e12d820698e6288c53fa296c049 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Thu, 20 Sep 2018 13:15:50 -0700 Subject: [PATCH 13/58] Customize atom.cmd for channel-specific atom.exe --- resources/win/atom.cmd | 6 +++--- resources/win/atom.js | 4 ++-- script/lib/package-application.js | 12 +++++++++++- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/resources/win/atom.cmd b/resources/win/atom.cmd index 07b9933cb..2b770bba5 100644 --- a/resources/win/atom.cmd +++ b/resources/win/atom.cmd @@ -29,11 +29,11 @@ FOR %%a IN (%*) DO ( IF "%EXPECT_OUTPUT%"=="YES" ( IF "%WAIT%"=="YES" ( - powershell -noexit "Start-Process -FilePath \"%~dp0\..\..\atom.exe\" -ArgumentList \"--pid=$pid $env:PSARGS\" ; wait-event" + powershell -noexit "Start-Process -FilePath \"%~dp0\..\..\<%= atomExeName %>\" -ArgumentList \"--pid=$pid $env:PSARGS\" ; wait-event" exit 0 ) ELSE ( - "%~dp0\..\..\atom.exe" %* + "%~dp0\..\..\<%= atomExeName %>" %* ) ) ELSE ( - "%~dp0\..\app\apm\bin\node.exe" "%~dp0\atom.js" %* + "%~dp0\..\app\apm\bin\node.exe" "%~dp0\atom.js" "<%= atomExeName %>" %* ) diff --git a/resources/win/atom.js b/resources/win/atom.js index df059aa5b..99928d8e3 100644 --- a/resources/win/atom.js +++ b/resources/win/atom.js @@ -1,8 +1,8 @@ var path = require('path'); var spawn = require('child_process').spawn; -var atomCommandPath = path.resolve(__dirname, '..', '..', 'atom.exe'); -var arguments = process.argv.slice(2); +var atomCommandPath = path.resolve(__dirname, '..', '..', process.argv[2]); +var arguments = process.argv.slice(3); arguments.unshift('--executed-from', process.cwd()); var options = {detached: true, stdio: 'ignore'}; spawn(atomCommandPath, arguments, options); diff --git a/script/lib/package-application.js b/script/lib/package-application.js index 7365bada8..64daea86a 100644 --- a/script/lib/package-application.js +++ b/script/lib/package-application.js @@ -8,6 +8,7 @@ const includePathInPackagedApp = require('./include-path-in-packaged-app') const getLicenseText = require('./get-license-text') const path = require('path') const spawnSync = require('./spawn-sync') +const template = require('lodash.template') const CONFIG = require('../config') @@ -73,8 +74,11 @@ function copyNonASARResources (packagedAppPath, bundledResourcesPath) { } else if (process.platform === 'linux') { fs.copySync(path.join(CONFIG.repositoryRootPath, 'resources', 'app-icons', CONFIG.channel, 'png', '1024.png'), path.join(packagedAppPath, 'atom.png')) } else if (process.platform === 'win32') { - [ 'atom.cmd', 'atom.sh', 'atom.js', 'apm.cmd', 'apm.sh', 'file.ico', 'folder.ico' ] + [ 'atom.sh', 'atom.js', 'apm.cmd', 'apm.sh', 'file.ico', 'folder.ico' ] .forEach(file => fs.copySync(path.join('resources', 'win', file), path.join(bundledResourcesPath, 'cli', file))) + + // Customize atom.cmd for the channel-specific atom.exe name (e.g. atom-beta.exe) + generateAtomCmdForChannel(bundledResourcesPath) } console.log(`Writing LICENSE.md to ${bundledResourcesPath}`) @@ -180,3 +184,9 @@ function renamePackagedAppDir (packageOutputDirPath) { } return packagedAppPath } + +function generateAtomCmdForChannel (bundledResourcesPath) { + const atomCmdTemplate = fs.readFileSync(path.join(CONFIG.repositoryRootPath, 'resources', 'win', 'atom.cmd')) + const atomCmdContents = template(atomCmdTemplate)({ atomExeName: CONFIG.executableName }) + fs.writeFileSync(path.join(bundledResourcesPath, 'cli', 'atom.cmd'), atomCmdContents) +} From e213a69a1ffe5a7cae3cbe5fd06abd7d6b904bc5 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Sat, 1 Jun 2019 00:29:10 +0200 Subject: [PATCH 14/58] Re-apply prettier JS formatter --- script/config.js | 24 +++--- script/lib/create-windows-installer.js | 14 ++- script/lib/generate-metadata.js | 52 +++++++----- script/lib/generate-startup-snapshot.js | 12 ++- script/lib/package-application.js | 56 +++++++----- spec/squirrel-update-spec.js | 103 ++++++++++++++-------- src/atom-environment.js | 6 +- src/main-process/atom-window.js | 48 ++++++----- src/main-process/squirrel-update.js | 108 +++++++++++++++--------- src/main-process/win-shell.js | 66 +++++++++------ src/workspace.js | 12 +-- 11 files changed, 312 insertions(+), 189 deletions(-) diff --git a/script/config.js b/script/config.js index 20a36a3ca..5d0786983 100644 --- a/script/config.js +++ b/script/config.js @@ -19,12 +19,14 @@ const homeDirPath = process.env.HOME || process.env.USERPROFILE; const atomHomeDirPath = process.env.ATOM_HOME || path.join(homeDirPath, '.atom'); -const appMetadata = require(path.join(repositoryRootPath, 'package.json')) -const apmMetadata = require(path.join(apmRootPath, 'package.json')) -const computedAppVersion = computeAppVersion(process.env.ATOM_RELEASE_VERSION || appMetadata.version) -const channel = getChannel(computedAppVersion) -const appName = getAppName(channel) -const executableName = getExecutableName(channel, appName) +const appMetadata = require(path.join(repositoryRootPath, 'package.json')); +const apmMetadata = require(path.join(apmRootPath, 'package.json')); +const computedAppVersion = computeAppVersion( + process.env.ATOM_RELEASE_VERSION || appMetadata.version +); +const channel = getChannel(computedAppVersion); +const appName = getAppName(channel); +const executableName = getExecutableName(channel, appName); module.exports = { appMetadata, @@ -66,17 +68,17 @@ function getAppName(channel) { channel.charAt(0).toUpperCase() + channel.slice(1)}`; } -function getExecutableName (channel, appName) { +function getExecutableName(channel, appName) { if (process.platform === 'darwin') { - return appName + return appName; } else if (process.platform === 'win32') { - return channel === 'stable' ? 'atom.exe' : `atom-${channel}.exe` + return channel === 'stable' ? 'atom.exe' : `atom-${channel}.exe`; } else { - return 'atom' + return 'atom'; } } -function computeAppVersion (version) { +function computeAppVersion(version) { if (version.match(/-dev$/)) { const result = spawnSync('git', ['rev-parse', '--short', 'HEAD'], { cwd: repositoryRootPath diff --git a/script/lib/create-windows-installer.js b/script/lib/create-windows-installer.js index 1cdd7c0f4..bddbf12d4 100644 --- a/script/lib/create-windows-installer.js +++ b/script/lib/create-windows-installer.js @@ -46,8 +46,11 @@ module.exports = packagedAppPath => { fs.renameSync(releasesPath, `${releasesPath}-x64`); } - let appName = CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}` - for (let nupkgPath of glob.sync(`${CONFIG.buildOutputPath}/${appName}-*.nupkg`)) { + let appName = + CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}`; + for (let nupkgPath of glob.sync( + `${CONFIG.buildOutputPath}/${appName}-*.nupkg` + )) { if (!nupkgPath.includes(CONFIG.computedAppVersion)) { console.log( `Deleting downloaded nupkg for previous version at ${nupkgPath} to prevent it from being stored as an artifact` @@ -56,8 +59,11 @@ module.exports = packagedAppPath => { } else { if (process.arch === 'x64') { // Use the original .nupkg filename to generate the `atom-x64` name by inserting `-x64` after `atom` - const newNupkgPath = nupkgPath.replace(`${appName}-`, `${appName}-x64-`) - fs.renameSync(nupkgPath, newNupkgPath) + const newNupkgPath = nupkgPath.replace( + `${appName}-`, + `${appName}-x64-` + ); + fs.renameSync(nupkgPath, newNupkgPath); } } } diff --git a/script/lib/generate-metadata.js b/script/lib/generate-metadata.js index 165dfd623..c174a6e26 100644 --- a/script/lib/generate-metadata.js +++ b/script/lib/generate-metadata.js @@ -1,33 +1,41 @@ -'use strict' +'use strict'; -const CSON = require('season') -const deprecatedPackagesMetadata = require('../deprecated-packages') -const fs = require('fs-plus') -const normalizePackageData = require('normalize-package-data') -const path = require('path') -const semver = require('semver') +const CSON = require('season'); +const deprecatedPackagesMetadata = require('../deprecated-packages'); +const fs = require('fs-plus'); +const normalizePackageData = require('normalize-package-data'); +const path = require('path'); +const semver = require('semver'); -const CONFIG = require('../config') +const CONFIG = require('../config'); -let appName = CONFIG.appMetadata.name +let appName = CONFIG.appMetadata.name; if (process.platform === 'win32') { // Use the channel name in the app name on Windows so that the installer will // place it in a different folder in AppData\Local - appName = CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}` + appName = CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}`; } -module.exports = function () { - console.log(`Generating metadata for ${path.join(CONFIG.intermediateAppPath, 'package.json')}`) - CONFIG.appMetadata._atomPackages = buildBundledPackagesMetadata() - CONFIG.appMetadata._atomMenu = buildPlatformMenuMetadata() - CONFIG.appMetadata._atomKeymaps = buildPlatformKeymapsMetadata() - CONFIG.appMetadata._deprecatedPackages = deprecatedPackagesMetadata - CONFIG.appMetadata.version = CONFIG.computedAppVersion - CONFIG.appMetadata.name = appName - CONFIG.appMetadata.productName = CONFIG.appName - checkDeprecatedPackagesMetadata() - fs.writeFileSync(path.join(CONFIG.intermediateAppPath, 'package.json'), JSON.stringify(CONFIG.appMetadata)) -} +module.exports = function() { + console.log( + `Generating metadata for ${path.join( + CONFIG.intermediateAppPath, + 'package.json' + )}` + ); + CONFIG.appMetadata._atomPackages = buildBundledPackagesMetadata(); + CONFIG.appMetadata._atomMenu = buildPlatformMenuMetadata(); + CONFIG.appMetadata._atomKeymaps = buildPlatformKeymapsMetadata(); + CONFIG.appMetadata._deprecatedPackages = deprecatedPackagesMetadata; + CONFIG.appMetadata.version = CONFIG.computedAppVersion; + CONFIG.appMetadata.name = appName; + CONFIG.appMetadata.productName = CONFIG.appName; + checkDeprecatedPackagesMetadata(); + fs.writeFileSync( + path.join(CONFIG.intermediateAppPath, 'package.json'), + JSON.stringify(CONFIG.appMetadata) + ); +}; module.exports = function() { console.log( diff --git a/script/lib/generate-startup-snapshot.js b/script/lib/generate-startup-snapshot.js index 0888e51a4..69c182913 100644 --- a/script/lib/generate-startup-snapshot.js +++ b/script/lib/generate-startup-snapshot.js @@ -258,9 +258,17 @@ module.exports = function(packagedAppPath) { ); let nodeBundledInElectronPath; if (process.platform === 'darwin') { - nodeBundledInElectronPath = path.join(packagedAppPath, 'Contents', 'MacOS', CONFIG.executableName) + nodeBundledInElectronPath = path.join( + packagedAppPath, + 'Contents', + 'MacOS', + CONFIG.executableName + ); } else { - nodeBundledInElectronPath = path.join(packagedAppPath, CONFIG.executableName) + nodeBundledInElectronPath = path.join( + packagedAppPath, + CONFIG.executableName + ); } childProcess.execFileSync( nodeBundledInElectronPath, diff --git a/script/lib/package-application.js b/script/lib/package-application.js index 7ddb5754d..2de2af165 100644 --- a/script/lib/package-application.js +++ b/script/lib/package-application.js @@ -1,15 +1,15 @@ 'use strict'; -const assert = require('assert') -const childProcess = require('child_process') -const electronPackager = require('electron-packager') -const fs = require('fs-extra') -const hostArch = require('electron-packager/targets').hostArch -const includePathInPackagedApp = require('./include-path-in-packaged-app') -const getLicenseText = require('./get-license-text') -const path = require('path') -const spawnSync = require('./spawn-sync') -const template = require('lodash.template') +const assert = require('assert'); +const childProcess = require('child_process'); +const electronPackager = require('electron-packager'); +const fs = require('fs-extra'); +const hostArch = require('electron-packager/targets').hostArch; +const includePathInPackagedApp = require('./include-path-in-packaged-app'); +const getLicenseText = require('./get-license-text'); +const path = require('path'); +const spawnSync = require('./spawn-sync'); +const template = require('lodash.template'); const CONFIG = require('../config'); const HOST_ARCH = hostArch(); @@ -131,11 +131,22 @@ function copyNonASARResources(packagedAppPath, bundledResourcesPath) { path.join(packagedAppPath, 'atom.png') ); } else if (process.platform === 'win32') { - [ 'atom.sh', 'atom.js', 'apm.cmd', 'apm.sh', 'file.ico', 'folder.ico' ] - .forEach(file => fs.copySync(path.join('resources', 'win', file), path.join(bundledResourcesPath, 'cli', file))) + [ + 'atom.sh', + 'atom.js', + 'apm.cmd', + 'apm.sh', + 'file.ico', + 'folder.ico' + ].forEach(file => + fs.copySync( + path.join('resources', 'win', file), + path.join(bundledResourcesPath, 'cli', file) + ) + ); // Customize atom.cmd for the channel-specific atom.exe name (e.g. atom-beta.exe) - generateAtomCmdForChannel(bundledResourcesPath) + generateAtomCmdForChannel(bundledResourcesPath); } console.log(`Writing LICENSE.md to ${bundledResourcesPath}`); @@ -194,9 +205,9 @@ function buildAsarUnpackGlobExpression() { function getAppName() { if (process.platform === 'darwin') { - return CONFIG.appName + return CONFIG.appName; } else if (process.platform === 'win32') { - return CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}` + return CONFIG.channel === 'stable' ? 'atom' : `atom-${CONFIG.channel}`; } else { return 'atom'; } @@ -251,8 +262,15 @@ function renamePackagedAppDir(packageOutputDirPath) { return packagedAppPath; } -function generateAtomCmdForChannel (bundledResourcesPath) { - const atomCmdTemplate = fs.readFileSync(path.join(CONFIG.repositoryRootPath, 'resources', 'win', 'atom.cmd')) - const atomCmdContents = template(atomCmdTemplate)({ atomExeName: CONFIG.executableName }) - fs.writeFileSync(path.join(bundledResourcesPath, 'cli', 'atom.cmd'), atomCmdContents) +function generateAtomCmdForChannel(bundledResourcesPath) { + const atomCmdTemplate = fs.readFileSync( + path.join(CONFIG.repositoryRootPath, 'resources', 'win', 'atom.cmd') + ); + const atomCmdContents = template(atomCmdTemplate)({ + atomExeName: CONFIG.executableName + }); + fs.writeFileSync( + path.join(bundledResourcesPath, 'cli', 'atom.cmd'), + atomCmdContents + ); } diff --git a/spec/squirrel-update-spec.js b/spec/squirrel-update-spec.js index f7dcf1422..eff17811f 100644 --- a/spec/squirrel-update-spec.js +++ b/spec/squirrel-update-spec.js @@ -1,4 +1,4 @@ -const {EventEmitter} = require('events'); +const { EventEmitter } = require('events'); const fs = require('fs-plus'); const path = require('path'); const temp = require('temp').track(); @@ -10,7 +10,7 @@ const WinShell = require('../src/main-process/win-shell'); const invokeCallback = function(callback) { const error = null; const stdout = ''; - return (typeof callback === 'function' ? callback(error, stdout) : undefined); + return typeof callback === 'function' ? callback(error, stdout) : undefined; }; const createFakeApp = function() { @@ -19,11 +19,11 @@ const createFakeApp = function() { getName: () => AtomTestAppName, getPath: () => 'atom-test.exe' }; -} +}; -const AtomTestAppName = 'Atom Testing' +const AtomTestAppName = 'Atom Testing'; -describe("Windows Squirrel Update", function() { +describe('Windows Squirrel Update', function() { let tempHomeDirectory = null; beforeEach(function() { @@ -38,9 +38,15 @@ describe("Windows Squirrel Update", function() { ); // Prevent any actual change to Windows Shell - spyOn(WinShell, 'registerShellIntegration').andCallFake((appName, callback) => callback()) - spyOn(WinShell, 'updateShellIntegration').andCallFake((appName, callback) => callback()) - spyOn(WinShell, 'deregisterShellIntegration').andCallFake((appName, callback) => callback()) + spyOn(WinShell, 'registerShellIntegration').andCallFake( + (appName, callback) => callback() + ); + spyOn(WinShell, 'updateShellIntegration').andCallFake((appName, callback) => + callback() + ); + spyOn(WinShell, 'deregisterShellIntegration').andCallFake( + (appName, callback) => callback() + ); }); afterEach(function() { @@ -49,96 +55,120 @@ describe("Windows Squirrel Update", function() { } catch (error) {} }); - it("quits the app on all squirrel events", function() { - const app = createFakeApp() + it('quits the app on all squirrel events', function() { + const app = createFakeApp(); - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe(true); + expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe( + true + ); waitsFor(() => app.quit.callCount === 1); runs(function() { app.quit.reset(); - return expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated')).toBe(true); + return expect( + SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated') + ).toBe(true); }); waitsFor(() => app.quit.callCount === 1); runs(function() { app.quit.reset(); - return expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-uninstall')).toBe(true); + return expect( + SquirrelUpdate.handleStartupEvent(app, '--squirrel-uninstall') + ).toBe(true); }); waitsFor(() => app.quit.callCount === 1); runs(function() { app.quit.reset(); - return expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-obsolete')).toBe(true); + return expect( + SquirrelUpdate.handleStartupEvent(app, '--squirrel-obsolete') + ).toBe(true); }); waitsFor(() => app.quit.callCount === 1); - return runs(() => expect(SquirrelUpdate.handleStartupEvent(app, '--not-squirrel')).toBe(false)); + return runs(() => + expect(SquirrelUpdate.handleStartupEvent(app, '--not-squirrel')).toBe( + false + ) + ); }); - describe("Desktop shortcut", function() { + describe('Desktop shortcut', function() { let desktopShortcutPath = '/non/existing/path'; beforeEach(function() { desktopShortcutPath = path.join(tempHomeDirectory, 'Desktop', 'Atom.lnk'); jasmine.unspy(Spawner, 'spawn'); - return spyOn(Spawner, 'spawn').andCallFake(function(command, args, callback) { - if ((path.basename(command) === 'Update.exe') && ((args != null ? args[0] : undefined) === '--createShortcut') && (args != null ? args[3].match(/Desktop/i) : undefined)) { + return spyOn(Spawner, 'spawn').andCallFake(function( + command, + args, + callback + ) { + if ( + path.basename(command) === 'Update.exe' && + (args != null ? args[0] : undefined) === '--createShortcut' && + (args != null ? args[3].match(/Desktop/i) : undefined) + ) { fs.writeFileSync(desktopShortcutPath, ''); + } else { } - else {} - // simply ignore other commands + // simply ignore other commands return invokeCallback(callback); }); }); - it("does not exist before install", () => expect(fs.existsSync(desktopShortcutPath)).toBe(false)); + it('does not exist before install', () => + expect(fs.existsSync(desktopShortcutPath)).toBe(false)); - return describe("on install", function() { + return describe('on install', function() { beforeEach(function() { - const app = createFakeApp() + const app = createFakeApp(); SquirrelUpdate.handleStartupEvent(app, '--squirrel-install'); return waitsFor(() => app.quit.callCount === 1); }); - it("creates desktop shortcut", () => expect(fs.existsSync(desktopShortcutPath)).toBe(true)); + it('creates desktop shortcut', () => + expect(fs.existsSync(desktopShortcutPath)).toBe(true)); - describe("when shortcut is deleted and then app is updated", function() { + describe('when shortcut is deleted and then app is updated', function() { beforeEach(function() { fs.removeSync(desktopShortcutPath); expect(fs.existsSync(desktopShortcutPath)).toBe(false); - const app = createFakeApp() + const app = createFakeApp(); SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); return waitsFor(() => app.quit.callCount === 1); }); - return it("does not recreate shortcut", () => expect(fs.existsSync(desktopShortcutPath)).toBe(false)); + return it('does not recreate shortcut', () => + expect(fs.existsSync(desktopShortcutPath)).toBe(false)); }); - return describe("when shortcut is kept and app is updated", function() { + return describe('when shortcut is kept and app is updated', function() { beforeEach(function() { - const app = createFakeApp() + const app = createFakeApp(); SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); return waitsFor(() => app.quit.callCount === 1); }); - return it("still has desktop shortcut", () => expect(fs.existsSync(desktopShortcutPath)).toBe(true)); + return it('still has desktop shortcut', () => + expect(fs.existsSync(desktopShortcutPath)).toBe(true)); }); }); }); - return describe(".restartAtom", () => - it("quits the app and spawns a new one", function() { + return describe('.restartAtom', () => + it('quits the app and spawns a new one', function() { const app = new EventEmitter(); app.quit = jasmine.createSpy('quit'); - app.getPath = () => 'atom-test.exe' + app.getPath = () => 'atom-test.exe'; SquirrelUpdate.restartAtom(app); expect(app.quit.callCount).toBe(1); @@ -146,7 +176,8 @@ describe("Windows Squirrel Update", function() { expect(Spawner.spawn.callCount).toBe(0); app.emit('will-quit'); expect(Spawner.spawn.callCount).toBe(1); - return expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe('atom-test.cmd'); - }) - ); + return expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe( + 'atom-test.cmd' + ); + })); }); diff --git a/src/atom-environment.js b/src/atom-environment.js index f8257b1c9..45a551a5c 100644 --- a/src/atom-environment.js +++ b/src/atom-environment.js @@ -551,9 +551,9 @@ class AtomEnvironment { // Public: Get the full name of this Atom release (e.g. "Atom", "Atom Beta") // // Returns the app name {String}. - getAppName () { - if (this.appName == null) this.appName = this.getLoadSettings().appName - return this.appName + getAppName() { + if (this.appName == null) this.appName = this.getLoadSettings().appName; + return this.appName; } // Public: Get the version of the Atom application. diff --git a/src/main-process/atom-window.js b/src/main-process/atom-window.js index 330c56c62..b51280a32 100644 --- a/src/main-process/atom-window.js +++ b/src/main-process/atom-window.js @@ -63,31 +63,39 @@ module.exports = class AtomWindow extends EventEmitter { this.browserWindow = new BrowserWindowConstructor(options); Object.defineProperty(this.browserWindow, 'loadSettingsJSON', { - get: () => JSON.stringify(Object.assign({ - userSettings: !this.isSpec - ? this.atomApplication.configFile.get() - : null - }, this.loadSettings)) - }) + get: () => + JSON.stringify( + Object.assign( + { + userSettings: !this.isSpec + ? this.atomApplication.configFile.get() + : null + }, + this.loadSettings + ) + ) + }); - this.handleEvents() + this.handleEvents(); - this.loadSettings = Object.assign({}, settings) - this.loadSettings.appVersion = app.getVersion() - this.loadSettings.appName = app.getName() - this.loadSettings.resourcePath = this.resourcePath - this.loadSettings.atomHome = process.env.ATOM_HOME - if (this.loadSettings.devMode == null) this.loadSettings.devMode = false - if (this.loadSettings.safeMode == null) this.loadSettings.safeMode = false - if (this.loadSettings.clearWindowState == null) this.loadSettings.clearWindowState = false + this.loadSettings = Object.assign({}, settings); + this.loadSettings.appVersion = app.getVersion(); + this.loadSettings.appName = app.getName(); + this.loadSettings.resourcePath = this.resourcePath; + this.loadSettings.atomHome = process.env.ATOM_HOME; + if (this.loadSettings.devMode == null) this.loadSettings.devMode = false; + if (this.loadSettings.safeMode == null) this.loadSettings.safeMode = false; + if (this.loadSettings.clearWindowState == null) + this.loadSettings.clearWindowState = false; - this.addLocationsToOpen(locationsToOpen) + this.addLocationsToOpen(locationsToOpen); - this.loadSettings.hasOpenFiles = locationsToOpen - .some(location => location.pathToOpen && !location.isDirectory) - this.loadSettings.initialProjectRoots = this.projectRoots + this.loadSettings.hasOpenFiles = locationsToOpen.some( + location => location.pathToOpen && !location.isDirectory + ); + this.loadSettings.initialProjectRoots = this.projectRoots; - StartupTime.addMarker('main-process:atom-window:end') + StartupTime.addMarker('main-process:atom-window:end'); // Expose the startup markers to the renderer process, so we can have unified // measures about startup time between the main process and the renderer process. diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index bd7ba3421..f04bdf376 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -1,14 +1,14 @@ -let setxPath -const fs = require('fs-plus') -const path = require('path') -const Spawner = require('./spawner') -const WinShell = require('./win-shell') -const WinPowerShell = require('./win-powershell') +let setxPath; +const fs = require('fs-plus'); +const path = require('path'); +const Spawner = require('./spawner'); +const WinShell = require('./win-shell'); +const WinPowerShell = require('./win-powershell'); -const appFolder = path.resolve(process.execPath, '..') -const rootAtomFolder = path.resolve(appFolder, '..') -const binFolder = path.join(rootAtomFolder, 'bin') -const updateDotExe = path.join(rootAtomFolder, 'Update.exe') +const appFolder = path.resolve(process.execPath, '..'); +const rootAtomFolder = path.resolve(appFolder, '..'); +const binFolder = path.join(rootAtomFolder, 'bin'); +const updateDotExe = path.join(rootAtomFolder, 'Update.exe'); if (process.env.SystemRoot) { const system32Path = path.join(process.env.SystemRoot, 'System32'); @@ -31,25 +31,43 @@ const spawnUpdate = (args, callback) => // install directory that point to the newly installed versions inside // the versioned app directories. const addCommandsToPath = (exeName, callback) => { - const atomCmdName = exeName.replace('.exe', '.cmd') - const apmCmdName = atomCmdName.replace('atom', 'apm') + const atomCmdName = exeName.replace('.exe', '.cmd'); + const apmCmdName = atomCmdName.replace('atom', 'apm'); const installCommands = callback => { - const atomCommandPath = path.join(binFolder, atomCmdName) - const relativeAtomPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.cmd')) - const atomCommand = `@echo off\r\n"%~dp0\\${relativeAtomPath}" %*` + const atomCommandPath = path.join(binFolder, atomCmdName); + const relativeAtomPath = path.relative( + binFolder, + path.join(appFolder, 'resources', 'cli', 'atom.cmd') + ); + const atomCommand = `@echo off\r\n"%~dp0\\${relativeAtomPath}" %*`; - const atomShCommandPath = path.join(binFolder, 'atom') - const relativeAtomShPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.sh')) - const atomShCommand = `#!/bin/sh\r\n"$(dirname "$0")/${relativeAtomShPath.replace(/\\/g, '/')}" "$@"\r\necho` + const atomShCommandPath = path.join(binFolder, 'atom'); + const relativeAtomShPath = path.relative( + binFolder, + path.join(appFolder, 'resources', 'cli', 'atom.sh') + ); + const atomShCommand = `#!/bin/sh\r\n"$(dirname "$0")/${relativeAtomShPath.replace( + /\\/g, + '/' + )}" "$@"\r\necho`; - const apmCommandPath = path.join(binFolder, apmCmdName) - const relativeApmPath = path.relative(binFolder, path.join(process.resourcesPath, 'app', 'apm', 'bin', 'apm.cmd')) - const apmCommand = `@echo off\r\n"%~dp0\\${relativeApmPath}" %*` + const apmCommandPath = path.join(binFolder, apmCmdName); + const relativeApmPath = path.relative( + binFolder, + path.join(process.resourcesPath, 'app', 'apm', 'bin', 'apm.cmd') + ); + const apmCommand = `@echo off\r\n"%~dp0\\${relativeApmPath}" %*`; - const apmShCommandPath = path.join(binFolder, 'apm') - const relativeApmShPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'apm.sh')) - const apmShCommand = `#!/bin/sh\r\n"$(dirname "$0")/${relativeApmShPath.replace(/\\/g, '/')}" "$@"` + const apmShCommandPath = path.join(binFolder, 'apm'); + const relativeApmShPath = path.relative( + binFolder, + path.join(appFolder, 'resources', 'cli', 'apm.sh') + ); + const apmShCommand = `#!/bin/sh\r\n"$(dirname "$0")/${relativeApmShPath.replace( + /\\/g, + '/' + )}" "$@"`; fs.writeFile(atomCommandPath, atomCommand, () => fs.writeFile(atomShCommandPath, atomShCommand, () => @@ -103,19 +121,26 @@ const removeCommandsFromPath = callback => } }); -const getExeName = (app) => path.basename(app.getPath('exe')) +const getExeName = app => path.basename(app.getPath('exe')); // Create a desktop and start menu shortcut by using the command line API // provided by Squirrel's Update.exe const createShortcuts = (exeName, locations, callback) => - spawnUpdate(['--createShortcut', exeName, '-l', locations.join(',')], callback) + spawnUpdate( + ['--createShortcut', exeName, '-l', locations.join(',')], + callback + ); // Update the desktop and start menu shortcuts by using the command line API // provided by Squirrel's Update.exe const updateShortcuts = (appName, exeName, callback) => { - const homeDirectory = fs.getHomeDirectory() + const homeDirectory = fs.getHomeDirectory(); if (homeDirectory) { - const desktopShortcutPath = path.join(homeDirectory, 'Desktop', `${appName}.lnk`) + const desktopShortcutPath = path.join( + homeDirectory, + 'Desktop', + `${appName}.lnk` + ); // Check if the desktop shortcut has been previously deleted and // and keep it deleted if it was fs.exists(desktopShortcutPath, desktopShortcutExists => { @@ -124,16 +149,17 @@ const updateShortcuts = (appName, exeName, callback) => { locations.push('Desktop'); } - createShortcuts(exeName, locations, callback) - }) + createShortcuts(exeName, locations, callback); + }); } else { - createShortcuts(exeName, ['Desktop', 'StartMenu'], callback) + createShortcuts(exeName, ['Desktop', 'StartMenu'], callback); } }; // Remove the desktop and start menu shortcuts by using the command line API // provided by Squirrel's Update.exe -const removeShortcuts = (exeName, callback) => spawnUpdate(['--removeShortcut', exeName], callback) +const removeShortcuts = (exeName, callback) => + spawnUpdate(['--removeShortcut', exeName], callback); exports.spawn = spawnUpdate; @@ -141,21 +167,23 @@ exports.spawn = spawnUpdate; exports.existsSync = () => fs.existsSync(updateDotExe); // Restart Atom using the version pointed to by the atom.cmd shim -exports.restartAtom = (app) => { - let args - const exeName = getExeName(app) - const atomCmdName = exeName.replace('.exe', '.cmd') +exports.restartAtom = app => { + let args; + const exeName = getExeName(app); + const atomCmdName = exeName.replace('.exe', '.cmd'); if (global.atomApplication && global.atomApplication.lastFocusedWindow) { const { projectPath } = global.atomApplication.lastFocusedWindow; if (projectPath) args = [projectPath]; } - app.once('will-quit', () => Spawner.spawn(path.join(binFolder, atomCmdName), args)) - app.quit() -} + app.once('will-quit', () => + Spawner.spawn(path.join(binFolder, atomCmdName), args) + ); + app.quit(); +}; // Handle squirrel events denoted by --squirrel-* command line arguments. exports.handleStartupEvent = (app, squirrelCommand) => { - const exeName = getExeName(app) + const exeName = getExeName(app); switch (squirrelCommand) { case '--squirrel-install': createShortcuts(exeName, ['Desktop', 'StartMenu'], () => diff --git a/src/main-process/win-shell.js b/src/main-process/win-shell.js index eb20be5c9..b15d87a20 100644 --- a/src/main-process/win-shell.js +++ b/src/main-process/win-shell.js @@ -1,9 +1,15 @@ const Registry = require('winreg'); const Path = require('path'); -let exeName = Path.basename(process.execPath) -let appPath = `"${process.execPath}"` -let fileIconPath = `"${Path.join(process.execPath, '..', 'resources', 'cli', 'file.ico')}"` +let exeName = Path.basename(process.execPath); +let appPath = `"${process.execPath}"`; +let fileIconPath = `"${Path.join( + process.execPath, + '..', + 'resources', + 'cli', + 'file.ico' +)}"`; class ShellOption { constructor(key, parts) { @@ -65,64 +71,72 @@ class ShellOption { } } -function getShellOptions (appName) { +function getShellOptions(appName) { const contextParts = [ - {key: 'command', name: '', value: `${appPath} "%1"`}, - {name: '', value: `Open with ${appName}`}, - {name: 'Icon', value: `${appPath}`} - ] + { key: 'command', name: '', value: `${appPath} "%1"` }, + { name: '', value: `Open with ${appName}` }, + { name: 'Icon', value: `${appPath}` } + ]; return { - fileHandler: new ShellOption(`\\Software\\Classes\\Applications\\${exeName}`, + fileHandler: new ShellOption( + `\\Software\\Classes\\Applications\\${exeName}`, [ - {key: 'shell\\open\\command', name: '', value: `${appPath} "%1"`}, - {key: 'shell\\open', name: 'FriendlyAppName', value: `${appName}`}, - {key: 'DefaultIcon', name: '', value: `${fileIconPath}`} + { key: 'shell\\open\\command', name: '', value: `${appPath} "%1"` }, + { key: 'shell\\open', name: 'FriendlyAppName', value: `${appName}` }, + { key: 'DefaultIcon', name: '', value: `${fileIconPath}` } ] ), - fileContextMenu: new ShellOption(`\\Software\\Classes\\*\\shell\\${appName}`, contextParts), - folderContextMenu: new ShellOption(`\\Software\\Classes\\Directory\\shell\\${appName}`, contextParts), - folderBackgroundContextMenu: new ShellOption(`\\Software\\Classes\\Directory\\background\\shell\\${appName}`, + fileContextMenu: new ShellOption( + `\\Software\\Classes\\*\\shell\\${appName}`, + contextParts + ), + folderContextMenu: new ShellOption( + `\\Software\\Classes\\Directory\\shell\\${appName}`, + contextParts + ), + folderBackgroundContextMenu: new ShellOption( + `\\Software\\Classes\\Directory\\background\\shell\\${appName}`, JSON.parse(JSON.stringify(contextParts).replace('%1', '%V')) ) - } + }; } -function registerShellIntegration (appName, callback) { - const shellOptions = getShellOptions(appName) +function registerShellIntegration(appName, callback) { + const shellOptions = getShellOptions(appName); shellOptions.fileHandler.register(() => shellOptions.fileContextMenu.update(() => shellOptions.folderContextMenu.update(() => shellOptions.folderBackgroundContextMenu.update(() => callback()) ) ) - ) + ); } -function updateShellIntegration (appName, callback) { - const shellOptions = getShellOptions(appName) +function updateShellIntegration(appName, callback) { + const shellOptions = getShellOptions(appName); shellOptions.fileHandler.update(() => shellOptions.fileContextMenu.update(() => shellOptions.folderContextMenu.update(() => shellOptions.folderBackgroundContextMenu.update(() => callback()) ) ) - ) + ); } -function deregisterShellIntegration (appName, callback) { - const shellOptions = getShellOptions(appName) +function deregisterShellIntegration(appName, callback) { + const shellOptions = getShellOptions(appName); shellOptions.fileHandler.deregister(() => shellOptions.fileContextMenu.deregister(() => shellOptions.folderContextMenu.deregister(() => shellOptions.folderBackgroundContextMenu.deregister(() => callback()) ) ) - ) + ); } module.exports = { registerShellIntegration, updateShellIntegration, deregisterShellIntegration -} +}; diff --git a/src/workspace.js b/src/workspace.js index 15a69931a..b3c3e4b8d 100644 --- a/src/workspace.js +++ b/src/workspace.js @@ -678,12 +678,12 @@ module.exports = class Workspace extends Model { // Updates the application's title and proxy icon based on whichever file is // open. - updateWindowTitle () { - let itemPath, itemTitle, projectPath, representedPath - const appName = atom.getAppName() - const left = this.project.getPaths() - const projectPaths = left != null ? left : [] - const item = this.getActivePaneItem() + updateWindowTitle() { + let itemPath, itemTitle, projectPath, representedPath; + const appName = atom.getAppName(); + const left = this.project.getPaths(); + const projectPaths = left != null ? left : []; + const item = this.getActivePaneItem(); if (item) { itemPath = typeof item.getPath === 'function' ? item.getPath() : undefined; From c96b4a9774ecb63bb8d4b93eedf673d4ce97a4fa Mon Sep 17 00:00:00 2001 From: Tony Brix Date: Mon, 24 Jun 2019 14:47:40 -0500 Subject: [PATCH 15/58] fix comment docks --- src/workspace.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/workspace.js b/src/workspace.js index 1299187dd..9fd52faf7 100644 --- a/src/workspace.js +++ b/src/workspace.js @@ -76,7 +76,7 @@ const ALL_LOCATIONS = ['center', 'left', 'right', 'bottom']; // Returns a {String} containing a longer version of the title to display in // places like the window title or on tabs their short titles are ambiguous. // -// #### `onDidChangeTitle` +// #### `onDidChangeTitle(callback)` // // Called by the workspace so it can be notified when the item's title changes. // Must return a {Disposable}. From d90c34a7f5d65cdd4f9705fcdf502bd8519f1c86 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Mon, 24 Jun 2019 15:36:50 -0600 Subject: [PATCH 16/58] Post crash reports to https://atom.io/crash_reports if consented Co-Authored-By: Jason Rudolph --- src/crash-reporter-start.js | 12 ++++++++---- src/initialize-test-window.coffee | 3 --- src/main-process/start.js | 5 ++++- static/index.js | 13 ++++++++++++- 4 files changed, 24 insertions(+), 9 deletions(-) diff --git a/src/crash-reporter-start.js b/src/crash-reporter-start.js index 21e68fadc..6ab5a136d 100644 --- a/src/crash-reporter-start.js +++ b/src/crash-reporter-start.js @@ -1,10 +1,14 @@ -module.exports = function(extra) { +module.exports = function(params) { const { crashReporter } = require('electron'); + const { uploadToServer, appVersion } = params; + crashReporter.start({ productName: 'Atom', companyName: 'GitHub', - submitURL: 'https://crashreporter.atom.io', - uploadToServer: false, - extra: extra + submitURL: 'https://atom.io/crash_reports', + uploadToServer, + extra: { + appVersion + } }); }; diff --git a/src/initialize-test-window.coffee b/src/initialize-test-window.coffee index e80fc86a6..672923526 100644 --- a/src/initialize-test-window.coffee +++ b/src/initialize-test-window.coffee @@ -6,11 +6,8 @@ cloneObject = (object) -> clone module.exports = ({blobStore}) -> - startCrashReporter = require('./crash-reporter-start') {remote} = require 'electron' - startCrashReporter() # Before anything else - exitWithStatusCode = (status) -> remote.app.emit('will-quit') remote.process.exit(status) diff --git a/src/main-process/start.js b/src/main-process/start.js index cd312f392..7555395d5 100644 --- a/src/main-process/start.js +++ b/src/main-process/start.js @@ -87,7 +87,10 @@ module.exports = function start(resourcePath, devResourcePath, startTime) { app.on('open-file', addPathToOpen); app.on('open-url', addUrlToOpen); - app.on('will-finish-launching', startCrashReporter); + app.on('will-finish-launching', () => startCrashReporter({ + uploadToServer: config.get('core.telemetryConsent') === 'limited', + appVersion: app.getVersion() + })); if (args.userDataDir != null) { app.setPath('userData', args.userDataDir); diff --git a/static/index.js b/static/index.js index ffda2e79f..756383d08 100644 --- a/static/index.js +++ b/static/index.js @@ -143,7 +143,18 @@ const startCrashReporter = useSnapshot ? snapshotResult.customRequire('../src/crash-reporter-start.js') : require('../src/crash-reporter-start'); - startCrashReporter({ _version: getWindowLoadSettings().appVersion }); + + console.log(getWindowLoadSettings()) + const { userSettings, appVersion } = getWindowLoadSettings(); + const uploadToServer = + userSettings && + userSettings.core && + userSettings.core.telemetryConsent === 'limited'; + + startCrashReporter({ + uploadToServer, + appVersion + }); const CSON = useSnapshot ? snapshotResult.customRequire('../node_modules/season/lib/cson.js') From 0e46298648380dc849c09aa92199fc5a6fa9715f Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Mon, 24 Jun 2019 15:48:55 -0600 Subject: [PATCH 17/58] Remove redundant info when starting crash reporter Co-Authored-By: Jason Rudolph --- src/crash-reporter-start.js | 7 ++----- src/main-process/start.js | 3 +-- static/index.js | 4 ++-- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/crash-reporter-start.js b/src/crash-reporter-start.js index 6ab5a136d..9f636c976 100644 --- a/src/crash-reporter-start.js +++ b/src/crash-reporter-start.js @@ -1,14 +1,11 @@ module.exports = function(params) { const { crashReporter } = require('electron'); - const { uploadToServer, appVersion } = params; + const { uploadToServer } = params; crashReporter.start({ productName: 'Atom', companyName: 'GitHub', submitURL: 'https://atom.io/crash_reports', - uploadToServer, - extra: { - appVersion - } + uploadToServer }); }; diff --git a/src/main-process/start.js b/src/main-process/start.js index 7555395d5..583768d71 100644 --- a/src/main-process/start.js +++ b/src/main-process/start.js @@ -88,8 +88,7 @@ module.exports = function start(resourcePath, devResourcePath, startTime) { app.on('open-file', addPathToOpen); app.on('open-url', addUrlToOpen); app.on('will-finish-launching', () => startCrashReporter({ - uploadToServer: config.get('core.telemetryConsent') === 'limited', - appVersion: app.getVersion() + uploadToServer: config.get('core.telemetryConsent') === 'limited' })); if (args.userDataDir != null) { diff --git a/static/index.js b/static/index.js index 756383d08..b758a5f01 100644 --- a/static/index.js +++ b/static/index.js @@ -145,7 +145,7 @@ : require('../src/crash-reporter-start'); console.log(getWindowLoadSettings()) - const { userSettings, appVersion } = getWindowLoadSettings(); + const { userSettings } = getWindowLoadSettings(); const uploadToServer = userSettings && userSettings.core && @@ -153,7 +153,7 @@ startCrashReporter({ uploadToServer, - appVersion + process: 'renderer' }); const CSON = useSnapshot From 47d9bbf93884366c48508b6216531c02c0f07f8a Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Mon, 24 Jun 2019 15:54:56 -0600 Subject: [PATCH 18/58] Add platformRelease to data posted to Atom.io with crashes Co-Authored-By: Jason Rudolph --- src/crash-reporter-start.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/crash-reporter-start.js b/src/crash-reporter-start.js index 9f636c976..e253e266f 100644 --- a/src/crash-reporter-start.js +++ b/src/crash-reporter-start.js @@ -1,11 +1,13 @@ module.exports = function(params) { const { crashReporter } = require('electron'); + const platformRelease = require('os').release(); const { uploadToServer } = params; crashReporter.start({ productName: 'Atom', companyName: 'GitHub', submitURL: 'https://atom.io/crash_reports', - uploadToServer + uploadToServer, + extra: { platformRelease } }); }; From 6042f7c819aae4d66b486b9a0b21a801a4aec1b7 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Mon, 24 Jun 2019 16:22:44 -0600 Subject: [PATCH 19/58] Include architecture in data posted to Atom.io with crashes --- src/crash-reporter-start.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/crash-reporter-start.js b/src/crash-reporter-start.js index e253e266f..a7f22742b 100644 --- a/src/crash-reporter-start.js +++ b/src/crash-reporter-start.js @@ -1,6 +1,8 @@ module.exports = function(params) { const { crashReporter } = require('electron'); - const platformRelease = require('os').release(); + const os = require('os'); + const platformRelease = os.release(); + const arch = os.arch(); const { uploadToServer } = params; crashReporter.start({ @@ -8,6 +10,6 @@ module.exports = function(params) { companyName: 'GitHub', submitURL: 'https://atom.io/crash_reports', uploadToServer, - extra: { platformRelease } + extra: { platformRelease, arch } }); }; From 9793c74835db6997e15a71dae0cca83bf2b7d159 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Mon, 24 Jun 2019 16:44:01 -0600 Subject: [PATCH 20/58] Include the release channel in data posted to Atom.io with crashes --- src/atom-environment.js | 14 ++------------ src/crash-reporter-start.js | 4 ++-- src/get-release-channel.js | 14 ++++++++++++++ src/main-process/start.js | 10 +++++++--- static/index.js | 7 ++++--- 5 files changed, 29 insertions(+), 20 deletions(-) create mode 100644 src/get-release-channel.js diff --git a/src/atom-environment.js b/src/atom-environment.js index 36830ff76..3e6238982 100644 --- a/src/atom-environment.js +++ b/src/atom-environment.js @@ -45,6 +45,7 @@ const TextBuffer = require('text-buffer'); const TextEditorRegistry = require('./text-editor-registry'); const AutoUpdateManager = require('./auto-update-manager'); const StartupTime = require('./startup-time'); +const getReleaseChannel = require('./get-release-channel'); const stat = util.promisify(fs.stat); @@ -565,18 +566,7 @@ class AtomEnvironment { // name like 'beta' or 'nightly' if one is found in the Atom version or 'stable' // otherwise. getReleaseChannel() { - // This matches stable, dev (with or without commit hash) and any other - // release channel following the pattern '1.00.0-channel0' - const match = this.getVersion().match( - /\d+\.\d+\.\d+(-([a-z]+)(\d+|-\w{4,})?)?$/ - ); - if (!match) { - return 'unrecognized'; - } else if (match[2]) { - return match[2]; - } - - return 'stable'; + return getReleaseChannel(this.getVersion()); } // Public: Returns a {Boolean} that is `true` if the current version is an official release. diff --git a/src/crash-reporter-start.js b/src/crash-reporter-start.js index a7f22742b..5c44a34b5 100644 --- a/src/crash-reporter-start.js +++ b/src/crash-reporter-start.js @@ -3,13 +3,13 @@ module.exports = function(params) { const os = require('os'); const platformRelease = os.release(); const arch = os.arch(); - const { uploadToServer } = params; + const { uploadToServer, releaseChannel } = params; crashReporter.start({ productName: 'Atom', companyName: 'GitHub', submitURL: 'https://atom.io/crash_reports', uploadToServer, - extra: { platformRelease, arch } + extra: { platformRelease, arch, releaseChannel } }); }; diff --git a/src/get-release-channel.js b/src/get-release-channel.js new file mode 100644 index 000000000..8d3cd2e31 --- /dev/null +++ b/src/get-release-channel.js @@ -0,0 +1,14 @@ +module.exports = function(version) { + // This matches stable, dev (with or without commit hash) and any other + // release channel following the pattern '1.00.0-channel0' + const match = version.match( + /\d+\.\d+\.\d+(-([a-z]+)(\d+|-\w{4,})?)?$/ + ); + if (!match) { + return 'unrecognized'; + } else if (match[2]) { + return match[2]; + } + + return 'stable'; +} diff --git a/src/main-process/start.js b/src/main-process/start.js index 583768d71..6b7d44782 100644 --- a/src/main-process/start.js +++ b/src/main-process/start.js @@ -4,6 +4,7 @@ const path = require('path'); const temp = require('temp').track(); const parseCommandLine = require('./parse-command-line'); const startCrashReporter = require('../crash-reporter-start'); +const getReleaseChannel = require('../get-release-channel'); const atomPaths = require('../atom-paths'); const fs = require('fs'); const CSON = require('season'); @@ -87,9 +88,12 @@ module.exports = function start(resourcePath, devResourcePath, startTime) { app.on('open-file', addPathToOpen); app.on('open-url', addUrlToOpen); - app.on('will-finish-launching', () => startCrashReporter({ - uploadToServer: config.get('core.telemetryConsent') === 'limited' - })); + app.on('will-finish-launching', () => + startCrashReporter({ + uploadToServer: config.get('core.telemetryConsent') === 'limited', + releaseChannel: getReleaseChannel(app.getVersion()) + }) + ); if (args.userDataDir != null) { app.setPath('userData', args.userDataDir); diff --git a/static/index.js b/static/index.js index b758a5f01..75be58393 100644 --- a/static/index.js +++ b/static/index.js @@ -7,6 +7,7 @@ const path = require('path'); const Module = require('module'); const getWindowLoadSettings = require('../src/get-window-load-settings'); + const getReleaseChannel = require('../src/get-release-channel'); const StartupTime = require('../src/startup-time'); const entryPointDirPath = __dirname; let blobStore = null; @@ -144,16 +145,16 @@ ? snapshotResult.customRequire('../src/crash-reporter-start.js') : require('../src/crash-reporter-start'); - console.log(getWindowLoadSettings()) - const { userSettings } = getWindowLoadSettings(); + const { userSettings, appVersion } = getWindowLoadSettings(); const uploadToServer = userSettings && userSettings.core && userSettings.core.telemetryConsent === 'limited'; + const releaseChannel = getReleaseChannel(appVersion); startCrashReporter({ uploadToServer, - process: 'renderer' + releaseChannel }); const CSON = useSnapshot From a582a1a188b981f8d72d25d26827c837c0ad8be9 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Mon, 24 Jun 2019 17:01:25 -0600 Subject: [PATCH 21/58] Fix lint error --- src/get-release-channel.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/get-release-channel.js b/src/get-release-channel.js index 8d3cd2e31..e14ec68e2 100644 --- a/src/get-release-channel.js +++ b/src/get-release-channel.js @@ -1,9 +1,7 @@ module.exports = function(version) { // This matches stable, dev (with or without commit hash) and any other // release channel following the pattern '1.00.0-channel0' - const match = version.match( - /\d+\.\d+\.\d+(-([a-z]+)(\d+|-\w{4,})?)?$/ - ); + const match = version.match(/\d+\.\d+\.\d+(-([a-z]+)(\d+|-\w{4,})?)?$/); if (!match) { return 'unrecognized'; } else if (match[2]) { @@ -11,4 +9,4 @@ module.exports = function(version) { } return 'stable'; -} +}; From 466a1ff18a4880d0e869d3d63577f43848a40cb6 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 25 Jun 2019 15:47:33 +0200 Subject: [PATCH 22/58] Spawn updated Atom immediately instead of waiting for `will-quit` event Spawning the new version of Atom within a `will-quit` handler would cause Electron to quit before having a chance to actually run the executable. There may still be a possibility of raciness between closing the old version of Atom and opening the new one, causing resource contention between the two processes (e.g., IndexedDb) or failing to spawn the new process before the previous one quits. Addressing such raciness perfectly would require a much more complex solution and this approach is working for us consistently in our tests. Co-Authored-By: Nathan Sobo --- src/main-process/squirrel-update.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index 05b4ae9f3..c1624ba83 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -165,9 +165,7 @@ exports.restartAtom = app => { const { projectPath } = global.atomApplication.lastFocusedWindow; if (projectPath) args = [projectPath]; } - app.once('will-quit', () => - Spawner.spawn(path.join(binFolder, 'atom.cmd'), args) - ); + Spawner.spawn(path.join(binFolder, 'atom.cmd'), args); app.quit(); }; From 45ef67030322692fabf5350d0a641d27ba6fef9f Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 25 Jun 2019 16:40:25 +0200 Subject: [PATCH 23/58] Delete implementation-dependent test Co-Authored-By: Nathan Sobo --- spec/squirrel-update-spec.coffee | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/spec/squirrel-update-spec.coffee b/spec/squirrel-update-spec.coffee index fe0fa7479..d0156fb8f 100644 --- a/spec/squirrel-update-spec.coffee +++ b/spec/squirrel-update-spec.coffee @@ -122,16 +122,3 @@ describe "Windows Squirrel Update", -> it "still has desktop shortcut", -> expect(fs.existsSync(desktopShortcutPath)).toBe true - - describe ".restartAtom", -> - it "quits the app and spawns a new one", -> - app = new EventEmitter() - app.quit = jasmine.createSpy('quit') - - SquirrelUpdate.restartAtom(app) - expect(app.quit.callCount).toBe 1 - - expect(Spawner.spawn.callCount).toBe 0 - app.emit('will-quit') - expect(Spawner.spawn.callCount).toBe 1 - expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe 'atom.cmd' From 54a79eede36099be6f366045bb6eda31f87765fe Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 25 Jun 2019 16:57:44 +0200 Subject: [PATCH 24/58] Upgrade language-javascript to v0.130.2 Co-Authored-By: Nathan Sobo --- package-lock.json | 4 ++-- package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 63f01e405..5a227a2ea 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3933,8 +3933,8 @@ "integrity": "sha512-QXVHoj0eJDbl3pJK+Dm0+vnR1yRB80lSrvThwoVnnxsNphovsglXSGkhHoZ6RbEwkX9fEhtwOrhLUspT2NkG3A==" }, "language-javascript": { - "version": "https://www.atom.io/api/packages/language-javascript/versions/0.130.1/tarball", - "integrity": "sha512-KLz0V7EjpoYQxihWXYiNqFIdbZrOO4lMXg2K7ZA5y8/vb44reOQu1UnOwiC3f6kd1bPyJfv9zR2dUYoXVREy1Q==", + "version": "https://www.atom.io/api/packages/language-javascript/versions/0.130.2/tarball", + "integrity": "sha512-y9kBnaWOVNVMA7KIdHtPlny6lz4lFYXdqgaK3M98W/oWuiCvXZyrWG4VObCcYm1Wff0Gr1ZnXAp0aYmQJ5EKmg==", "requires": { "tree-sitter-javascript": "^0.15.0", "tree-sitter-jsdoc": "^0.15.0", diff --git a/package.json b/package.json index db056d36b..7001c8838 100644 --- a/package.json +++ b/package.json @@ -88,7 +88,7 @@ "language-html": "https://www.atom.io/api/packages/language-html/versions/0.52.3/tarball", "language-hyperlink": "https://www.atom.io/api/packages/language-hyperlink/versions/0.17.1/tarball", "language-java": "https://www.atom.io/api/packages/language-java/versions/0.31.3/tarball", - "language-javascript": "https://www.atom.io/api/packages/language-javascript/versions/0.130.1/tarball", + "language-javascript": "https://www.atom.io/api/packages/language-javascript/versions/0.130.2/tarball", "language-json": "https://www.atom.io/api/packages/language-json/versions/1.0.4/tarball", "language-less": "https://www.atom.io/api/packages/language-less/versions/0.34.3/tarball", "language-make": "https://www.atom.io/api/packages/language-make/versions/0.23.0/tarball", @@ -240,7 +240,7 @@ "language-html": "0.52.3", "language-hyperlink": "0.17.1", "language-java": "0.31.3", - "language-javascript": "0.130.1", + "language-javascript": "0.130.2", "language-json": "1.0.4", "language-less": "0.34.3", "language-make": "0.23.0", From 0ac07e7f32e5f855824b5cf85e86fe5f6c00862a Mon Sep 17 00:00:00 2001 From: Linus Eriksson Date: Tue, 25 Jun 2019 17:58:28 +0200 Subject: [PATCH 25/58] Specify exe in the metadata Because we changed it to be atom-beta.exe on beta for example this is required for electron-winstaller to find the executable --- script/lib/create-windows-installer.js | 1 + 1 file changed, 1 insertion(+) diff --git a/script/lib/create-windows-installer.js b/script/lib/create-windows-installer.js index 6c13e7425..6e100b48d 100644 --- a/script/lib/create-windows-installer.js +++ b/script/lib/create-windows-installer.js @@ -13,6 +13,7 @@ module.exports = packagedAppPath => { process.env.ATOM_UPDATE_URL_PREFIX || 'https://atom.io'; const options = { title: CONFIG.appName, + exe: CONFIG.executableName, appDirectory: packagedAppPath, authors: 'GitHub Inc.', iconUrl: `https://raw.githubusercontent.com/atom/atom/master/resources/app-icons/${ From 2d6cc4f17227ca22cfeeefdbd257813c8aff1435 Mon Sep 17 00:00:00 2001 From: Linus Eriksson Date: Tue, 25 Jun 2019 17:58:50 +0200 Subject: [PATCH 26/58] Use a different name depending on channel This makes Atom beta install in %LOCALAPPDATA%\atom-beta and stable in %LOCALAPPDATA%\atom so that installs are side by side --- script/config.js | 8 ++++++++ script/lib/create-windows-installer.js | 1 + 2 files changed, 9 insertions(+) diff --git a/script/config.js b/script/config.js index 5d0786983..73c9ffc92 100644 --- a/script/config.js +++ b/script/config.js @@ -27,11 +27,13 @@ const computedAppVersion = computeAppVersion( const channel = getChannel(computedAppVersion); const appName = getAppName(channel); const executableName = getExecutableName(channel, appName); +const channelName = getChannelName(channel); module.exports = { appMetadata, apmMetadata, channel, + channelName, appName, executableName, computedAppVersion, @@ -50,6 +52,12 @@ module.exports = { snapshotAuxiliaryData: {} }; +function getChannelName(channel) { + return channel === 'stable' + ? 'atom' + : `atom-${channel}`; +} + function getChannel(version) { const match = version.match(/\d+\.\d+\.\d+(-([a-z]+)(\d+|-\w{4,})?)?$/); if (!match) { diff --git a/script/lib/create-windows-installer.js b/script/lib/create-windows-installer.js index 6e100b48d..6f5d87c1d 100644 --- a/script/lib/create-windows-installer.js +++ b/script/lib/create-windows-installer.js @@ -12,6 +12,7 @@ module.exports = packagedAppPath => { const updateUrlPrefix = process.env.ATOM_UPDATE_URL_PREFIX || 'https://atom.io'; const options = { + name: CONFIG.channelName, title: CONFIG.appName, exe: CONFIG.executableName, appDirectory: packagedAppPath, From c919744f0e7faecec4f7f28b30b37bae0caaaf9a Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Tue, 25 Jun 2019 14:28:27 -0600 Subject: [PATCH 27/58] Rely on Azure Pipelines instead of Travis for Linux builds --- .travis.yml | 67 ---------------------- README.md | 2 +- docs/build-instructions/build-status.md | 8 +-- script/lib/include-path-in-packaged-app.js | 1 - 4 files changed, 5 insertions(+), 73 deletions(-) delete mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 2d4fd2d1c..000000000 --- a/.travis.yml +++ /dev/null @@ -1,67 +0,0 @@ -language: python - -python: - - '2.7.13' - -git: - depth: 10 - -branches: - only: - - master - - /^[0-9.]+-releases$/ - - /.*-test-travis$/ - -matrix: - include: - - os: linux - dist: trusty - env: NODE_VERSION=10.2.1 DISPLAY=:99.0 CC=clang CXX=clang++ npm_config_clang=1 ATOM_JASMINE_REPORTER=list - -before_install: - - '/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -ac -screen 0 1280x1024x16' - -install: - - git clone https://github.com/creationix/nvm.git /tmp/.nvm - - source /tmp/.nvm/nvm.sh - - nvm install $NODE_VERSION - - nvm use --delete-prefix $NODE_VERSION - - npm install --global npm@6.2.0 - - script/bootstrap - -script: > - script/lint && - script/build --no-bootstrap --create-debian-package --create-rpm-package --compress-artifacts && - script/test - -cache: - directories: - - electron - - node_modules - - apm/node_modules - - script/node_modules - - ~/.atom/compile-cache - - ~/.atom/snapshot-cache - -notifications: - email: - on_success: never - on_failure: change - -addons: - artifacts: - paths: - - out/atom-amd64.deb - - out/atom.x86_64.rpm - - out/atom-amd64.tar.gz - target_paths: travis-artifacts/$TRAVIS_BUILD_ID - apt: - packages: - - build-essential - - clang-3.3 - - fakeroot - - git - - libsecret-1-dev - - rpm - - libx11-dev - - libxkbfile-dev diff --git a/README.md b/README.md index f3ffb0ebb..23a37611b 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Atom -[![Build status](https://dev.azure.com/github/Atom/_apis/build/status/Atom%20Production%20Branches?branchName=master)](https://dev.azure.com/github/Atom/_build/latest?definitionId=32&branchName=master) [![Linux Build Status](https://travis-ci.org/atom/atom.svg?branch=master)](https://travis-ci.org/atom/atom) +[![Build status](https://dev.azure.com/github/Atom/_apis/build/status/Atom%20Production%20Branches?branchName=master)](https://dev.azure.com/github/Atom/_build/latest?definitionId=32&branchName=master) [![Dependency Status](https://david-dm.org/atom/atom.svg)](https://david-dm.org/atom/atom) [![Join the Atom Community on Slack](https://atom-slack.herokuapp.com/badge.svg)](https://atom-slack.herokuapp.com) diff --git a/docs/build-instructions/build-status.md b/docs/build-instructions/build-status.md index 2dc9d3b02..48c9c87e7 100644 --- a/docs/build-instructions/build-status.md +++ b/docs/build-instructions/build-status.md @@ -1,10 +1,10 @@ # Atom build status -| System | Travis | AppVeyor/Win | VSTS | Dependencies | +| System | Azure Pipelines | Travis | AppVeyor/Win | Dependencies | |--------|--------|--------------|------------|--------------| -| [Atom](https://github.com/atom/atom) | [![Travis Build Status](https://travis-ci.org/atom/atom.svg?branch=master)](https://travis-ci.org/atom/atom) | | [![Build status](https://github.visualstudio.com/Atom/_apis/build/status/Atom%20Production%20Branches?branch=master)](https://github.visualstudio.com/Atom/_build/latest?definitionId=32&branch=master) | [![Dependency Status](https://david-dm.org/atom/atom.svg)](https://david-dm.org/atom/atom) | -| [APM](https://github.com/atom/apm) | [![Travis Build Status](https://travis-ci.org/atom/apm.svg?branch=master)](https://travis-ci.org/atom/apm) | [![AppVeyor/Wi Build Status](https://ci.appveyor.com/api/projects/status/j6ixw374a397ugkb/branch/master?svg=true)](https://ci.appveyor.com/project/Atom/apm/branch/master) | | [![Dependency Status](https://david-dm.org/atom/apm.svg)](https://david-dm.org/atom/apm) | -| [Electron](https://github.com/electron/electron) | [![Travis Build Status](https://travis-ci.org/electron/electron.svg?branch=master)](https://travis-ci.org/electron/electron) | [![AppVeyor/Wi Build Status](https://ci.appveyor.com/api/projects/status/kvxe4byi7jcxbe26/branch/master?svg=true)](https://ci.appveyor.com/project/Atom/electron) | | [![Dependency Status](https://david-dm.org/electron/electron/dev-status.svg)](https://david-dm.org/electron/electron) +| [Atom](https://github.com/atom/atom) | [![Build status](https://github.visualstudio.com/Atom/_apis/build/status/Atom%20Production%20Branches?branch=master)](https://github.visualstudio.com/Atom/_build/latest?definitionId=32&branch=master) | | | [![Dependency Status](https://david-dm.org/atom/atom.svg)](https://david-dm.org/atom/atom) | +| [APM](https://github.com/atom/apm) | | [![Travis Build Status](https://travis-ci.org/atom/apm.svg?branch=master)](https://travis-ci.org/atom/apm) | [![AppVeyor/Wi Build Status](https://ci.appveyor.com/api/projects/status/j6ixw374a397ugkb/branch/master?svg=true)](https://ci.appveyor.com/project/Atom/apm/branch/master) | [![Dependency Status](https://david-dm.org/atom/apm.svg)](https://david-dm.org/atom/apm) | +| [Electron](https://github.com/electron/electron) | | [![Travis Build Status](https://travis-ci.org/electron/electron.svg?branch=master)](https://travis-ci.org/electron/electron) | [![AppVeyor/Wi Build Status](https://ci.appveyor.com/api/projects/status/kvxe4byi7jcxbe26/branch/master?svg=true)](https://ci.appveyor.com/project/Atom/electron) | [![Dependency Status](https://david-dm.org/electron/electron/dev-status.svg)](https://david-dm.org/electron/electron) ## Packages diff --git a/script/lib/include-path-in-packaged-app.js b/script/lib/include-path-in-packaged-app.js index f8caac357..3b6831f0d 100644 --- a/script/lib/include-path-in-packaged-app.js +++ b/script/lib/include-path-in-packaged-app.js @@ -15,7 +15,6 @@ const EXCLUDE_REGEXPS_SOURCES = [ escapeRegExp('.jshintrc'), escapeRegExp('.npmignore'), escapeRegExp('.pairs'), - escapeRegExp('.travis.yml'), escapeRegExp('.idea'), escapeRegExp('.editorconfig'), escapeRegExp('.lint'), From 914ff77f0d5f85883c45f20ea7a361529c6e780c Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Wed, 26 Jun 2019 10:04:03 +0200 Subject: [PATCH 28/58] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20spellchecker@3.6.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package-lock.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index 5a227a2ea..a0136c211 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6028,9 +6028,9 @@ } }, "spellchecker": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/spellchecker/-/spellchecker-3.6.0.tgz", - "integrity": "sha512-aGt8FEaFONTlo/IvDXbUvzN39NizCqkYS+MoQP8THy+Ocf1+OCfnG6QwrZwWxfrd8l06nxuc15icNiP8/ol/GA==", + "version": "3.6.1", + "resolved": "https://registry.npmjs.org/spellchecker/-/spellchecker-3.6.1.tgz", + "integrity": "sha512-i7qp5m/JpZqs+3LanJW6hhlXTX/m9+x8jvZvOuG/V3XlWHLsCsJQdOvGAXIU8ZHA1wuv1VRPJLpfVI8/e/ZBOg==", "requires": { "any-promise": "^1.3.0", "nan": "^2.14.0" From f6f90284f3fe7b209a6dd708851579b97e1938b2 Mon Sep 17 00:00:00 2001 From: Tony Brix Date: Wed, 26 Jun 2019 09:03:59 -0500 Subject: [PATCH 29/58] Update getInvisibles documentation fixes #16042 --- src/text-editor.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/text-editor.js b/src/text-editor.js index 46e692807..6f108d74a 100644 --- a/src/text-editor.js +++ b/src/text-editor.js @@ -4084,7 +4084,9 @@ module.exports = class TextEditor { } // Returns an {Object} representing the current invisible character - // substitutions for this editor. See {::setInvisibles}. + // substitutions for this editor, whose keys are names of invisible characters + // and whose values are 1-character {Strings}s that are displayed in place of + // those invisible characters getInvisibles() { if (!this.mini && this.showInvisibles && this.invisibles != null) { return this.invisibles; From 698b581106c7b83573f7cfe97d7b24432a234a61 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Wed, 26 Jun 2019 16:32:07 +0200 Subject: [PATCH 30/58] Run prettier --- script/config.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/script/config.js b/script/config.js index 73c9ffc92..f7deb6df0 100644 --- a/script/config.js +++ b/script/config.js @@ -53,9 +53,7 @@ module.exports = { }; function getChannelName(channel) { - return channel === 'stable' - ? 'atom' - : `atom-${channel}`; + return channel === 'stable' ? 'atom' : `atom-${channel}`; } function getChannel(version) { From cce8c1c87260de6e80eb4625bc0d312506b676f2 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Wed, 26 Jun 2019 17:04:06 +0200 Subject: [PATCH 31/58] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20fuzzy-finder@1.13.9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package-lock.json | 4 ++-- package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index a0136c211..0c3265d93 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3048,8 +3048,8 @@ "integrity": "sha1-gy9kifvodnaUWVmckUpnDsIpR+4=" }, "fuzzy-finder": { - "version": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.8/tarball", - "integrity": "sha512-uhBHzD0B42k4KQ+CktomP16nxH/0fxlM9of3r/1bEAAxK4i0+/4Z22Qmxv3qsawo+4DxFUc3P9KCTgjxZHTaBA==", + "version": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.9/tarball", + "integrity": "sha512-iN0jeWvQco7pHTzaGQkVZDEeKSc+bNo3m4udZXCx30SGD+4iMvW1jbs8ez2R//GJ9kbE3qinndooRFTt+MBiwg==", "requires": { "@atom/fuzzy-native": "^1.0.3", "async": "0.2.6", diff --git a/package.json b/package.json index 7001c8838..92b356d07 100644 --- a/package.json +++ b/package.json @@ -62,7 +62,7 @@ "fs-plus": "^3.1.1", "fstream": "0.1.24", "fuzzaldrin": "^2.1", - "fuzzy-finder": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.8/tarball", + "fuzzy-finder": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.9/tarball", "git-diff": "file:packages/git-diff", "git-utils": "5.6.1", "github": "https://www.atom.io/api/packages/github/versions/0.29.0/tarball", @@ -201,7 +201,7 @@ "encoding-selector": "0.23.9", "exception-reporting": "file:./packages/exception-reporting", "find-and-replace": "0.218.14", - "fuzzy-finder": "1.13.8", + "fuzzy-finder": "1.13.9", "github": "0.29.0", "git-diff": "file:./packages/git-diff", "go-to-line": "file:./packages/go-to-line", From b69fbe539b9d1ee8a5c79d622d2abba96b09de49 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Wed, 26 Jun 2019 11:11:20 -0600 Subject: [PATCH 32/58] :arrow_up: find-and-replace@0.218.15 --- package-lock.json | 18 ++---------------- package.json | 4 ++-- 2 files changed, 4 insertions(+), 18 deletions(-) diff --git a/package-lock.json b/package-lock.json index 0c3265d93..0ca0e3358 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1617,11 +1617,6 @@ "base16-tomorrow-light-theme": { "version": "file:packages/base16-tomorrow-light-theme" }, - "batch-processor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/batch-processor/-/batch-processor-1.0.0.tgz", - "integrity": "sha1-dclcMrdI4IUNEMKxaPa9vpiRrOg=" - }, "bcrypt-pbkdf": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", @@ -2533,14 +2528,6 @@ "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.133.tgz", "integrity": "sha512-lyoC8aoqbbDqsprb6aPdt9n3DpOZZzdz/T4IZKsR0/dkZIxnJVUjjcpOSwA66jPRIOyDAamCTAUqweU05kKNSg==" }, - "element-resize-detector": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/element-resize-detector/-/element-resize-detector-1.1.15.tgz", - "integrity": "sha512-16/5avDegXlUxytGgaumhjyQoM6hpp5j3+L79sYq5hlXfTNRy5WMMuTVWkZU3egp/CokCmTmvf18P3KeB57Iog==", - "requires": { - "batch-processor": "^1.0.0" - } - }, "emissary": { "version": "1.3.3", "resolved": "https://registry.npmjs.org/emissary/-/emissary-1.3.3.tgz", @@ -2841,11 +2828,10 @@ } }, "find-and-replace": { - "version": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.14/tarball", - "integrity": "sha512-ceaKDpLAyUmebe0q5aJ9vsiz3bZK8BAR9zDJwo3vl7Lb/GfK1QYrh8UllapOfltGdqCB59sKfAW/c3GBOzvrpA==", + "version": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.15/tarball", + "integrity": "sha512-6FWVuYR9V7O3qp93Vshq/J1MC+OpmRgbny25xzZAMJwVJTiR3mpi5OcnIok302y0Yxri69WLwkklVrytiX330w==", "requires": { "binary-search": "^1.3.3", - "element-resize-detector": "^1.1.10", "etch": "0.9.3", "fs-plus": "^3.0.0", "temp": "^0.8.3", diff --git a/package.json b/package.json index 92b356d07..5cc30e291 100644 --- a/package.json +++ b/package.json @@ -54,7 +54,7 @@ "etch": "^0.12.6", "event-kit": "^2.5.3", "exception-reporting": "file:packages/exception-reporting", - "find-and-replace": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.14/tarball", + "find-and-replace": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.15/tarball", "find-parent-dir": "^0.3.0", "first-mate": "7.4.0", "focus-trap": "2.4.5", @@ -200,7 +200,7 @@ "dev-live-reload": "file:./packages/dev-live-reload", "encoding-selector": "0.23.9", "exception-reporting": "file:./packages/exception-reporting", - "find-and-replace": "0.218.14", + "find-and-replace": "0.218.15", "fuzzy-finder": "1.13.9", "github": "0.29.0", "git-diff": "file:./packages/git-diff", From c9715548beea3c9997121e78b5322b589c325087 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Wed, 26 Jun 2019 15:10:16 -0600 Subject: [PATCH 33/58] :arrow_up: language-javascript@0.132.0 --- package-lock.json | 4 ++-- package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 0ca0e3358..17aaa542d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3919,8 +3919,8 @@ "integrity": "sha512-QXVHoj0eJDbl3pJK+Dm0+vnR1yRB80lSrvThwoVnnxsNphovsglXSGkhHoZ6RbEwkX9fEhtwOrhLUspT2NkG3A==" }, "language-javascript": { - "version": "https://www.atom.io/api/packages/language-javascript/versions/0.130.2/tarball", - "integrity": "sha512-y9kBnaWOVNVMA7KIdHtPlny6lz4lFYXdqgaK3M98W/oWuiCvXZyrWG4VObCcYm1Wff0Gr1ZnXAp0aYmQJ5EKmg==", + "version": "https://www.atom.io/api/packages/language-javascript/versions/0.132.0/tarball", + "integrity": "sha512-8Nh7VrvcFNGaATNTJak3iNx2TgWmw/bZ/6areyIPGXJVoKSn5XlmKmyN4QjMRJ6tfb4iLQyPMMq4sNEIDkIwdg==", "requires": { "tree-sitter-javascript": "^0.15.0", "tree-sitter-jsdoc": "^0.15.0", diff --git a/package.json b/package.json index 5cc30e291..6faad85d3 100644 --- a/package.json +++ b/package.json @@ -88,7 +88,7 @@ "language-html": "https://www.atom.io/api/packages/language-html/versions/0.52.3/tarball", "language-hyperlink": "https://www.atom.io/api/packages/language-hyperlink/versions/0.17.1/tarball", "language-java": "https://www.atom.io/api/packages/language-java/versions/0.31.3/tarball", - "language-javascript": "https://www.atom.io/api/packages/language-javascript/versions/0.130.2/tarball", + "language-javascript": "https://www.atom.io/api/packages/language-javascript/versions/0.132.0/tarball", "language-json": "https://www.atom.io/api/packages/language-json/versions/1.0.4/tarball", "language-less": "https://www.atom.io/api/packages/language-less/versions/0.34.3/tarball", "language-make": "https://www.atom.io/api/packages/language-make/versions/0.23.0/tarball", @@ -240,7 +240,7 @@ "language-html": "0.52.3", "language-hyperlink": "0.17.1", "language-java": "0.31.3", - "language-javascript": "0.130.2", + "language-javascript": "0.132.0", "language-json": "1.0.4", "language-less": "0.34.3", "language-make": "0.23.0", From 3a4fed4201247fb85ea30bad9d89394a8206df78 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Thu, 27 Jun 2019 11:43:36 +0200 Subject: [PATCH 34/58] Send OS version to the autoupdate endpoint --- src/main-process/auto-update-manager.js | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/main-process/auto-update-manager.js b/src/main-process/auto-update-manager.js index 4f9446d6c..a55df8bd9 100644 --- a/src/main-process/auto-update-manager.js +++ b/src/main-process/auto-update-manager.js @@ -1,4 +1,5 @@ const { EventEmitter } = require('events'); +const os = require('os'); const path = require('path'); const IdleState = 'idle'; @@ -34,14 +35,16 @@ module.exports = class AutoUpdateManager extends EventEmitter { initialize() { if (process.platform === 'win32') { const archSuffix = process.arch === 'ia32' ? '' : `-${process.arch}`; - this.feedUrl = `${ - this.updateUrlPrefix - }/api/updates${archSuffix}?version=${this.version}`; + this.feedUrl = + this.updateUrlPrefix + + `/api/updates${archSuffix}?version=${this.version}&os_version=${ + os.release + }`; autoUpdater = require('./auto-updater-win32'); } else { - this.feedUrl = `${this.updateUrlPrefix}/api/updates?version=${ - this.version - }`; + this.feedUrl = + this.updateUrlPrefix + + `/api/updates?version=${this.version}&os_version=${os.release}`; ({ autoUpdater } = require('electron')); } From 7593d49a892ef1a8d6493102266d6ee7c79aec68 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Fri, 28 Jun 2019 17:53:34 +0200 Subject: [PATCH 35/58] Debounce the resize event handler --- spec/window-event-handler-spec.js | 8 ++++++-- src/window-event-handler.js | 7 ++++++- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/spec/window-event-handler-spec.js b/spec/window-event-handler-spec.js index 62f0fe3b7..51a3ca47b 100644 --- a/spec/window-event-handler-spec.js +++ b/spec/window-event-handler-spec.js @@ -1,5 +1,6 @@ const KeymapManager = require('atom-keymap'); const WindowEventHandler = require('../src/window-event-handler'); +const { conditionPromise } = require('./async-spec-helpers'); describe('WindowEventHandler', () => { let windowEventHandler; @@ -50,10 +51,13 @@ describe('WindowEventHandler', () => { }); describe('resize event', () => - it('calls storeWindowDimensions', () => { + it('calls storeWindowDimensions', async () => { + jasmine.useRealClock(); + spyOn(atom, 'storeWindowDimensions'); window.dispatchEvent(new CustomEvent('resize')); - expect(atom.storeWindowDimensions).toHaveBeenCalled(); + + await conditionPromise(() => atom.storeWindowDimensions.callCount > 0); })); describe('window:close event', () => diff --git a/src/window-event-handler.js b/src/window-event-handler.js index 5f7ea9a4f..b796defb6 100644 --- a/src/window-event-handler.js +++ b/src/window-event-handler.js @@ -1,5 +1,6 @@ const { Disposable, CompositeDisposable } = require('event-kit'); const listen = require('./delegated-listener'); +const { debounce } = require('underscore-plus'); // Handles low-level events related to the `window`. module.exports = class WindowEventHandler { @@ -65,7 +66,11 @@ module.exports = class WindowEventHandler { ); this.addEventListener(this.window, 'focus', this.handleWindowFocus); this.addEventListener(this.window, 'blur', this.handleWindowBlur); - this.addEventListener(this.window, 'resize', this.handleWindowResize); + this.addEventListener( + this.window, + 'resize', + debounce(this.handleWindowResize, 500) + ); this.addEventListener(this.document, 'keyup', this.handleDocumentKeyEvent); this.addEventListener( From 3d2d439f933db5ffb1984b552a2c63c7f1e7ce5d Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 1 Jul 2019 12:49:06 +0200 Subject: [PATCH 36/58] Fix issue when ripgrep returns matches that are empty --- spec/workspace-spec.js | 28 ++++++++++++++++++++++++++++ src/ripgrep-directory-searcher.js | 2 +- 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/spec/workspace-spec.js b/spec/workspace-spec.js index 5af18e3cc..9ffdb05b2 100644 --- a/spec/workspace-spec.js +++ b/spec/workspace-spec.js @@ -2512,6 +2512,34 @@ describe('Workspace', () => { }); if (ripgrep) { + it('returns empty text matches', async () => { + const results = []; + await scan( + /^\s{0}/, + { + paths: [`oh-git`] + }, + result => results.push(result) + ); + + expect(results.length).toBe(1); + const { filePath, matches } = results[0]; + expect(filePath).toBe( + atom.project + .getDirectories()[0] + .resolve(path.join('a-dir', 'oh-git')) + ); + expect(matches).toHaveLength(1); + expect(matches[0]).toEqual({ + matchText: '', + lineText: 'bbb aaaa', + lineTextOffset: 0, + range: [[0, 0], [0, 0]], + leadingContextLines: [], + trailingContextLines: [] + }); + }); + describe('newlines on regexps', async () => { it('returns multiline results from regexps', async () => { const results = []; diff --git a/src/ripgrep-directory-searcher.js b/src/ripgrep-directory-searcher.js index f538f6d17..63ce5cc24 100644 --- a/src/ripgrep-directory-searcher.js +++ b/src/ripgrep-directory-searcher.js @@ -157,7 +157,7 @@ function processSubmatch(submatch, lineText, offsetRow) { } function getText(input) { - return input.text + return 'text' in input ? input.text : Buffer.from(input.bytes, 'base64').toString(); } From ef7b910ed0b30edd83d69396e7398124e99118f1 Mon Sep 17 00:00:00 2001 From: dwelle Date: Sun, 30 Jun 2019 17:12:57 +0200 Subject: [PATCH 37/58] Add ripgrep pcre2 support :shirt: fix lint Co-Authored-By: Rafael Oleza fix passing PCRE2 flag in specs :shirt: fix lint --- spec/workspace-spec.js | 24 ++++++++++++++++++++++++ src/ripgrep-directory-searcher.js | 4 ++++ src/workspace.js | 1 + 3 files changed, 29 insertions(+) diff --git a/spec/workspace-spec.js b/spec/workspace-spec.js index 5af18e3cc..f2b66a9a2 100644 --- a/spec/workspace-spec.js +++ b/spec/workspace-spec.js @@ -2652,6 +2652,30 @@ describe('Workspace', () => { }); }); }); + describe('pcre2 enabled', async () => { + it('supports lookbehind searches', async () => { + const results = []; + + await scan(/(? + results.push(result) + ); + + expect(results.length).toBe(1); + const { filePath, matches } = results[0]; + expect(filePath).toBe( + atom.project.getDirectories()[0].resolve('a') + ); + expect(matches).toHaveLength(1); + expect(matches[0]).toEqual({ + matchText: 'aa', + lineText: 'cc aa cc', + lineTextOffset: 0, + range: [[1, 3], [1, 5]], + leadingContextLines: [], + trailingContextLines: [] + }); + }); + }); } it('returns results on lines with unicode strings', async () => { diff --git a/src/ripgrep-directory-searcher.js b/src/ripgrep-directory-searcher.js index f538f6d17..6ac3a5741 100644 --- a/src/ripgrep-directory-searcher.js +++ b/src/ripgrep-directory-searcher.js @@ -269,6 +269,10 @@ module.exports = class RipgrepDirectorySearcher { args.push('--no-ignore-vcs'); } + if (options.PCRE2) { + args.push('--pcre2'); + } + args.push('.'); const child = spawn(this.rgPath, args, { diff --git a/src/workspace.js b/src/workspace.js index 9fd52faf7..66ba3052d 100644 --- a/src/workspace.js +++ b/src/workspace.js @@ -2104,6 +2104,7 @@ module.exports = class Workspace extends Model { follow: this.config.get('core.followSymlinks'), leadingContextLineCount: options.leadingContextLineCount || 0, trailingContextLineCount: options.trailingContextLineCount || 0, + PCRE2: options.PCRE2, didMatch: result => { if (!this.project.isPathModified(result.filePath)) { return iterator(result); From e2938867da7cfb96c671dc91c9a2838e5b60a225 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Tue, 2 Jul 2019 10:34:29 +0200 Subject: [PATCH 38/58] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20fuzzy-finder@1.14.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package-lock.json | 12 ++++++------ package.json | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 17aaa542d..ff2438a99 100644 --- a/package-lock.json +++ b/package-lock.json @@ -21,9 +21,9 @@ } }, "@atom/fuzzy-native": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@atom/fuzzy-native/-/fuzzy-native-1.0.3.tgz", - "integrity": "sha512-bpFKY270m+1JVZ5xEn1RIFo44ZwIYww0o/MZnev/SyMXZSuQEcJcgXbvz8mBAOK9Tpce4iDgRWcBLuBOoMbJSw==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@atom/fuzzy-native/-/fuzzy-native-1.1.0.tgz", + "integrity": "sha512-S+dZtzAtpMB6m5xEJ6aSp33JX2s539KCGBWn0oLHFX2vsnHtqFeWIKFspFuUZCHsmp+2DwRJuWTZhgc/zA+6ow==", "requires": { "nan": "^2.0.0" } @@ -3034,10 +3034,10 @@ "integrity": "sha1-gy9kifvodnaUWVmckUpnDsIpR+4=" }, "fuzzy-finder": { - "version": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.9/tarball", - "integrity": "sha512-iN0jeWvQco7pHTzaGQkVZDEeKSc+bNo3m4udZXCx30SGD+4iMvW1jbs8ez2R//GJ9kbE3qinndooRFTt+MBiwg==", + "version": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.14.0/tarball", + "integrity": "sha512-BZ/8e5wm5gr8T4BiYPH2cFA97RuYiv60JMnpn2IqYX1uWx9juL64fR6WEP2xi06VfwmBznfBxKkt6h/8fCkzpA==", "requires": { - "@atom/fuzzy-native": "^1.0.3", + "@atom/fuzzy-native": "^1.1.0", "async": "0.2.6", "atom-select-list": "^0.7.0", "fs-plus": "^3.0.0", diff --git a/package.json b/package.json index 6faad85d3..c11badbd1 100644 --- a/package.json +++ b/package.json @@ -62,7 +62,7 @@ "fs-plus": "^3.1.1", "fstream": "0.1.24", "fuzzaldrin": "^2.1", - "fuzzy-finder": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.9/tarball", + "fuzzy-finder": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.14.0/tarball", "git-diff": "file:packages/git-diff", "git-utils": "5.6.1", "github": "https://www.atom.io/api/packages/github/versions/0.29.0/tarball", @@ -201,7 +201,7 @@ "encoding-selector": "0.23.9", "exception-reporting": "file:./packages/exception-reporting", "find-and-replace": "0.218.15", - "fuzzy-finder": "1.13.9", + "fuzzy-finder": "1.14.0", "github": "0.29.0", "git-diff": "file:./packages/git-diff", "go-to-line": "file:./packages/go-to-line", From 3777fdf94b77fc3877d12da3678e36ee71c361f7 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 2 Jul 2019 12:17:43 +0200 Subject: [PATCH 39/58] Upgrade language-php@0.44.2 --- package-lock.json | 4 ++-- package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index ff2438a99..734131abe 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3955,8 +3955,8 @@ "integrity": "sha512-XXHULyFvbxAiRoj+MxIXoeO//in3bQctHZbaD72p3vFxm3klxe2ebx7b3cFmFYqf/g0eajmLrR3tR5m1Rmz1XQ==" }, "language-php": { - "version": "https://www.atom.io/api/packages/language-php/versions/0.44.1/tarball", - "integrity": "sha512-NJdhhvphaZYwuUpR2cPYdfTn/9AZee2IJ7YsiMJAjCNLHPpxnduRkmVPj6f6y2F82tNi8ckFJrS3hGU3dPchng==" + "version": "https://www.atom.io/api/packages/language-php/versions/0.44.2/tarball", + "integrity": "sha512-Kluwh/M4IyUqqVHFzMXKtdIHMqMsPAFrG6hZxIfcxlSgNoteuaWo+Tf43iYjpl9T006QDH5PljQvGKaoHfzd1Q==" }, "language-property-list": { "version": "https://www.atom.io/api/packages/language-property-list/versions/0.9.1/tarball", diff --git a/package.json b/package.json index c11badbd1..db1f244a4 100644 --- a/package.json +++ b/package.json @@ -95,7 +95,7 @@ "language-mustache": "https://www.atom.io/api/packages/language-mustache/versions/0.14.5/tarball", "language-objective-c": "https://www.atom.io/api/packages/language-objective-c/versions/0.16.0/tarball", "language-perl": "https://www.atom.io/api/packages/language-perl/versions/0.38.1/tarball", - "language-php": "https://www.atom.io/api/packages/language-php/versions/0.44.1/tarball", + "language-php": "https://www.atom.io/api/packages/language-php/versions/0.44.2/tarball", "language-property-list": "https://www.atom.io/api/packages/language-property-list/versions/0.9.1/tarball", "language-python": "https://www.atom.io/api/packages/language-python/versions/0.53.3/tarball", "language-ruby": "https://www.atom.io/api/packages/language-ruby/versions/0.72.17/tarball", @@ -247,7 +247,7 @@ "language-mustache": "0.14.5", "language-objective-c": "0.16.0", "language-perl": "0.38.1", - "language-php": "0.44.1", + "language-php": "0.44.2", "language-property-list": "0.9.1", "language-python": "0.53.3", "language-ruby": "0.72.17", From 2b552482dd3dfd87ce9da3c94f2923a6651d9515 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Wed, 3 Jul 2019 11:36:36 +0200 Subject: [PATCH 40/58] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20find-and-replace@0.2?= =?UTF-8?q?19.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package-lock.json | 4 ++-- package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 734131abe..dbfccf38a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2828,8 +2828,8 @@ } }, "find-and-replace": { - "version": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.15/tarball", - "integrity": "sha512-6FWVuYR9V7O3qp93Vshq/J1MC+OpmRgbny25xzZAMJwVJTiR3mpi5OcnIok302y0Yxri69WLwkklVrytiX330w==", + "version": "https://www.atom.io/api/packages/find-and-replace/versions/0.219.0/tarball", + "integrity": "sha512-ujsC2E6PMqiCVH/ifKVGcz6Itpp5/cGItkQqNdWArFrSxMgP97+iI6yCb/VO6XAFFaYUQLTXI3SNa5Ee30/DDQ==", "requires": { "binary-search": "^1.3.3", "etch": "0.9.3", diff --git a/package.json b/package.json index db1f244a4..0db649fab 100644 --- a/package.json +++ b/package.json @@ -54,7 +54,7 @@ "etch": "^0.12.6", "event-kit": "^2.5.3", "exception-reporting": "file:packages/exception-reporting", - "find-and-replace": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.15/tarball", + "find-and-replace": "https://www.atom.io/api/packages/find-and-replace/versions/0.219.0/tarball", "find-parent-dir": "^0.3.0", "first-mate": "7.4.0", "focus-trap": "2.4.5", @@ -200,7 +200,7 @@ "dev-live-reload": "file:./packages/dev-live-reload", "encoding-selector": "0.23.9", "exception-reporting": "file:./packages/exception-reporting", - "find-and-replace": "0.218.15", + "find-and-replace": "0.219.0", "fuzzy-finder": "1.14.0", "github": "0.29.0", "git-diff": "file:./packages/git-diff", From f7b7545fd0e997f76a09e685938385da665df1d1 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Thu, 4 Jul 2019 11:26:36 +0200 Subject: [PATCH 41/58] Create get-app-name module that returns correct application name Before, in order to retrieve the application name, Electron's `getName()` method was used (https://electronjs.org/docs/api/app#appgetname). Now, instead, we also use the Atom version in order to calculate the release channel and be able to have it on the app name (e.g `Atom Nightly`). --- spec/main-process/atom-window.test.js | 2 +- src/main-process/atom-window.js | 5 +++-- src/main-process/get-app-name.js | 15 +++++++++++++++ src/main-process/squirrel-update.js | 11 +++++++---- src/main-process/win-shell.js | 2 ++ 5 files changed, 28 insertions(+), 7 deletions(-) create mode 100644 src/main-process/get-app-name.js diff --git a/spec/main-process/atom-window.test.js b/spec/main-process/atom-window.test.js index 939c23fbf..d560fbf8d 100644 --- a/spec/main-process/atom-window.test.js +++ b/spec/main-process/atom-window.test.js @@ -97,7 +97,7 @@ describe('AtomWindow', function() { const { browserWindow } = w; assert.isFalse(browserWindow.isVisible()); - assert.strictEqual(browserWindow.getTitle(), 'Atom'); + assert.isTrue(browserWindow.getTitle().startsWith('Atom')); const settings = JSON.parse(browserWindow.loadSettingsJSON); assert.strictEqual(settings.userSettings, 'stub-config'); diff --git a/src/main-process/atom-window.js b/src/main-process/atom-window.js index b51280a32..bcf33ec18 100644 --- a/src/main-process/atom-window.js +++ b/src/main-process/atom-window.js @@ -1,4 +1,5 @@ const { BrowserWindow, app, dialog, ipcMain } = require('electron'); +const getAppName = require('./get-app-name'); const path = require('path'); const url = require('url'); const { EventEmitter } = require('events'); @@ -35,7 +36,7 @@ module.exports = class AtomWindow extends EventEmitter { const options = { show: false, - title: app.getName(), + title: getAppName(), tabbingIdentifier: 'atom', webPreferences: { // Prevent specs from throttling when the window is in the background: @@ -80,7 +81,7 @@ module.exports = class AtomWindow extends EventEmitter { this.loadSettings = Object.assign({}, settings); this.loadSettings.appVersion = app.getVersion(); - this.loadSettings.appName = app.getName(); + this.loadSettings.appName = getAppName(); this.loadSettings.resourcePath = this.resourcePath; this.loadSettings.atomHome = process.env.ATOM_HOME; if (this.loadSettings.devMode == null) this.loadSettings.devMode = false; diff --git a/src/main-process/get-app-name.js b/src/main-process/get-app-name.js new file mode 100644 index 000000000..2607f12b8 --- /dev/null +++ b/src/main-process/get-app-name.js @@ -0,0 +1,15 @@ +const { app } = require('electron'); +const getReleaseChannel = require('../get-release-channel'); + +module.exports = function getAppName() { + const releaseChannel = getReleaseChannel(app.getVersion()); + const appNameParts = [app.getName()]; + + if (releaseChannel !== 'stable') { + appNameParts.push( + releaseChannel.charAt(0).toUpperCase() + releaseChannel.slice(1) + ); + } + + return appNameParts.join(' '); +}; diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index f719fa28c..2ba81754d 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -1,5 +1,6 @@ let setxPath; const fs = require('fs-plus'); +const getAppName = require('./get-app-name'); const path = require('path'); const Spawner = require('./spawner'); const WinShell = require('./win-shell'); @@ -182,25 +183,27 @@ exports.restartAtom = app => { // Handle squirrel events denoted by --squirrel-* command line arguments. exports.handleStartupEvent = (app, squirrelCommand) => { const exeName = getExeName(app); + const appName = getAppName(); + switch (squirrelCommand) { case '--squirrel-install': createShortcuts(exeName, ['Desktop', 'StartMenu'], () => addCommandsToPath(exeName, () => - WinShell.registerShellIntegration(app.getName(), () => app.quit()) + WinShell.registerShellIntegration(appName, () => app.quit()) ) ); return true; case '--squirrel-updated': - updateShortcuts(app.getName(), exeName, () => + updateShortcuts(appName, exeName, () => addCommandsToPath(exeName, () => - WinShell.updateShellIntegration(app.getName(), () => app.quit()) + WinShell.updateShellIntegration(appName, () => app.quit()) ) ); return true; case '--squirrel-uninstall': removeShortcuts(exeName, () => removeCommandsFromPath(() => - WinShell.deregisterShellIntegration(app.getName(), () => app.quit()) + WinShell.deregisterShellIntegration(appName, () => app.quit()) ) ); return true; diff --git a/src/main-process/win-shell.js b/src/main-process/win-shell.js index b15d87a20..3ea9ec0fe 100644 --- a/src/main-process/win-shell.js +++ b/src/main-process/win-shell.js @@ -1,5 +1,6 @@ const Registry = require('winreg'); const Path = require('path'); +const getAppName = require('./get-app-name'); let exeName = Path.basename(process.execPath); let appPath = `"${process.execPath}"`; @@ -136,6 +137,7 @@ function deregisterShellIntegration(appName, callback) { } module.exports = { + appName: getAppName(), registerShellIntegration, updateShellIntegration, deregisterShellIntegration From cbe54954f44aef00eac477d210a7437624fbb627 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Thu, 4 Jul 2019 14:12:04 +0200 Subject: [PATCH 42/58] Revert breaking changes on the WinShell module In earlier commits from this PR, some breaking changes were done to the WinShell module, which cause some issues on the `settings` package (and potentially other packages). Since these breaking changes are not needed (and they don't provide even a better API), this PR reverts them to keep the previous contract. --- spec/squirrel-update-spec.coffee | 51 ++++---- spec/squirrel-update-spec.js | 183 ---------------------------- src/main-process/squirrel-update.js | 70 +++++++---- src/main-process/win-shell.js | 100 +++++---------- 4 files changed, 101 insertions(+), 303 deletions(-) delete mode 100644 spec/squirrel-update-spec.js diff --git a/spec/squirrel-update-spec.coffee b/spec/squirrel-update-spec.coffee index d0156fb8f..5879877c9 100644 --- a/spec/squirrel-update-spec.coffee +++ b/spec/squirrel-update-spec.coffee @@ -1,7 +1,15 @@ {EventEmitter} = require 'events' +electron = require 'electron' fs = require 'fs-plus' path = require 'path' temp = require('temp').track() + +electron.app = { + getName: -> 'Atom', + getVersion: -> '1.0.0', + getPath: -> '/tmp/atom.exe' +} + SquirrelUpdate = require '../src/main-process/squirrel-update' Spawner = require '../src/main-process/spawner' WinShell = require '../src/main-process/win-shell' @@ -35,42 +43,42 @@ describe "Windows Squirrel Update", -> WinShell.fileContextMenu = new FakeShellOption() WinShell.folderContextMenu = new FakeShellOption() WinShell.folderBackgroundContextMenu = new FakeShellOption() + electron.app.quit = jasmine.createSpy('quit') afterEach -> + electron.app.quit.reset() try temp.cleanupSync() it "quits the app on all squirrel events", -> - app = quit: jasmine.createSpy('quit') - - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe true + expect(SquirrelUpdate.handleStartupEvent('--squirrel-install')).toBe true waitsFor -> - app.quit.callCount is 1 + electron.app.quit.callCount is 1 runs -> - app.quit.reset() - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated')).toBe true + electron.app.quit.reset() + expect(SquirrelUpdate.handleStartupEvent('--squirrel-updated')).toBe true waitsFor -> - app.quit.callCount is 1 + electron.app.quit.callCount is 1 runs -> - app.quit.reset() - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-uninstall')).toBe true + electron.app.quit.reset() + expect(SquirrelUpdate.handleStartupEvent( '--squirrel-uninstall')).toBe true waitsFor -> - app.quit.callCount is 1 + electron.app.quit.callCount is 1 runs -> - app.quit.reset() - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-obsolete')).toBe true + electron.app.quit.reset() + expect(SquirrelUpdate.handleStartupEvent('--squirrel-obsolete')).toBe true waitsFor -> - app.quit.callCount is 1 + electron.app.quit.callCount is 1 runs -> - expect(SquirrelUpdate.handleStartupEvent(app, '--not-squirrel')).toBe false + expect(SquirrelUpdate.handleStartupEvent('--not-squirrel')).toBe false describe "Desktop shortcut", -> desktopShortcutPath = '/non/existing/path' @@ -92,10 +100,9 @@ describe "Windows Squirrel Update", -> describe "on install", -> beforeEach -> - app = quit: jasmine.createSpy('quit') - SquirrelUpdate.handleStartupEvent(app, '--squirrel-install') + SquirrelUpdate.handleStartupEvent('--squirrel-install') waitsFor -> - app.quit.callCount is 1 + electron.app.quit.callCount is 1 it "creates desktop shortcut", -> expect(fs.existsSync(desktopShortcutPath)).toBe true @@ -105,20 +112,18 @@ describe "Windows Squirrel Update", -> fs.removeSync(desktopShortcutPath) expect(fs.existsSync(desktopShortcutPath)).toBe false - app = quit: jasmine.createSpy('quit') - SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated') + SquirrelUpdate.handleStartupEvent('--squirrel-updated') waitsFor -> - app.quit.callCount is 1 + electron.app.quit.callCount is 1 it "does not recreate shortcut", -> expect(fs.existsSync(desktopShortcutPath)).toBe false describe "when shortcut is kept and app is updated", -> beforeEach -> - app = quit: jasmine.createSpy('quit') - SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated') + SquirrelUpdate.handleStartupEvent('--squirrel-updated') waitsFor -> - app.quit.callCount is 1 + electron.app.quit.callCount is 1 it "still has desktop shortcut", -> expect(fs.existsSync(desktopShortcutPath)).toBe true diff --git a/spec/squirrel-update-spec.js b/spec/squirrel-update-spec.js deleted file mode 100644 index eff17811f..000000000 --- a/spec/squirrel-update-spec.js +++ /dev/null @@ -1,183 +0,0 @@ -const { EventEmitter } = require('events'); -const fs = require('fs-plus'); -const path = require('path'); -const temp = require('temp').track(); -const SquirrelUpdate = require('../src/main-process/squirrel-update'); -const Spawner = require('../src/main-process/spawner'); -const WinShell = require('../src/main-process/win-shell'); - -// Run passed callback as Spawner.spawn() would do -const invokeCallback = function(callback) { - const error = null; - const stdout = ''; - return typeof callback === 'function' ? callback(error, stdout) : undefined; -}; - -const createFakeApp = function() { - return { - quit: jasmine.createSpy('quit'), - getName: () => AtomTestAppName, - getPath: () => 'atom-test.exe' - }; -}; - -const AtomTestAppName = 'Atom Testing'; - -describe('Windows Squirrel Update', function() { - let tempHomeDirectory = null; - - beforeEach(function() { - // Prevent the actual home directory from being manipulated - tempHomeDirectory = temp.mkdirSync('atom-temp-home-'); - spyOn(fs, 'getHomeDirectory').andReturn(tempHomeDirectory); - - // Prevent any spawned command from actually running and affecting the host - spyOn(Spawner, 'spawn').andCallFake((command, args, callback) => - // do nothing on command, just run passed callback - invokeCallback(callback) - ); - - // Prevent any actual change to Windows Shell - spyOn(WinShell, 'registerShellIntegration').andCallFake( - (appName, callback) => callback() - ); - spyOn(WinShell, 'updateShellIntegration').andCallFake((appName, callback) => - callback() - ); - spyOn(WinShell, 'deregisterShellIntegration').andCallFake( - (appName, callback) => callback() - ); - }); - - afterEach(function() { - try { - return temp.cleanupSync(); - } catch (error) {} - }); - - it('quits the app on all squirrel events', function() { - const app = createFakeApp(); - - expect(SquirrelUpdate.handleStartupEvent(app, '--squirrel-install')).toBe( - true - ); - - waitsFor(() => app.quit.callCount === 1); - - runs(function() { - app.quit.reset(); - return expect( - SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated') - ).toBe(true); - }); - - waitsFor(() => app.quit.callCount === 1); - - runs(function() { - app.quit.reset(); - return expect( - SquirrelUpdate.handleStartupEvent(app, '--squirrel-uninstall') - ).toBe(true); - }); - - waitsFor(() => app.quit.callCount === 1); - - runs(function() { - app.quit.reset(); - return expect( - SquirrelUpdate.handleStartupEvent(app, '--squirrel-obsolete') - ).toBe(true); - }); - - waitsFor(() => app.quit.callCount === 1); - - return runs(() => - expect(SquirrelUpdate.handleStartupEvent(app, '--not-squirrel')).toBe( - false - ) - ); - }); - - describe('Desktop shortcut', function() { - let desktopShortcutPath = '/non/existing/path'; - - beforeEach(function() { - desktopShortcutPath = path.join(tempHomeDirectory, 'Desktop', 'Atom.lnk'); - - jasmine.unspy(Spawner, 'spawn'); - return spyOn(Spawner, 'spawn').andCallFake(function( - command, - args, - callback - ) { - if ( - path.basename(command) === 'Update.exe' && - (args != null ? args[0] : undefined) === '--createShortcut' && - (args != null ? args[3].match(/Desktop/i) : undefined) - ) { - fs.writeFileSync(desktopShortcutPath, ''); - } else { - } - // simply ignore other commands - - return invokeCallback(callback); - }); - }); - - it('does not exist before install', () => - expect(fs.existsSync(desktopShortcutPath)).toBe(false)); - - return describe('on install', function() { - beforeEach(function() { - const app = createFakeApp(); - SquirrelUpdate.handleStartupEvent(app, '--squirrel-install'); - return waitsFor(() => app.quit.callCount === 1); - }); - - it('creates desktop shortcut', () => - expect(fs.existsSync(desktopShortcutPath)).toBe(true)); - - describe('when shortcut is deleted and then app is updated', function() { - beforeEach(function() { - fs.removeSync(desktopShortcutPath); - expect(fs.existsSync(desktopShortcutPath)).toBe(false); - - const app = createFakeApp(); - SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); - return waitsFor(() => app.quit.callCount === 1); - }); - - return it('does not recreate shortcut', () => - expect(fs.existsSync(desktopShortcutPath)).toBe(false)); - }); - - return describe('when shortcut is kept and app is updated', function() { - beforeEach(function() { - const app = createFakeApp(); - SquirrelUpdate.handleStartupEvent(app, '--squirrel-updated'); - return waitsFor(() => app.quit.callCount === 1); - }); - - return it('still has desktop shortcut', () => - expect(fs.existsSync(desktopShortcutPath)).toBe(true)); - }); - }); - }); - - return describe('.restartAtom', () => - it('quits the app and spawns a new one', function() { - const app = new EventEmitter(); - app.quit = jasmine.createSpy('quit'); - app.getPath = () => 'atom-test.exe'; - - SquirrelUpdate.restartAtom(app); - expect(app.quit.callCount).toBe(1); - - expect(Spawner.spawn.callCount).toBe(0); - app.emit('will-quit'); - expect(Spawner.spawn.callCount).toBe(1); - return expect(path.basename(Spawner.spawn.argsForCall[0][0])).toBe( - 'atom-test.cmd' - ); - })); -}); diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index 2ba81754d..8d9b769f2 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -1,4 +1,5 @@ let setxPath; +const { app } = require('electron'); const fs = require('fs-plus'); const getAppName = require('./get-app-name'); const path = require('path'); @@ -10,6 +11,7 @@ const appFolder = path.resolve(process.execPath, '..'); const rootAtomFolder = path.resolve(appFolder, '..'); const binFolder = path.join(rootAtomFolder, 'bin'); const updateDotExe = path.join(rootAtomFolder, 'Update.exe'); +const execName = path.basename(app.getPath('exe')); if (process.env.SystemRoot) { const system32Path = path.join(process.env.SystemRoot, 'System32'); @@ -31,8 +33,8 @@ const spawnUpdate = (args, callback) => // This is done by adding .cmd shims to the root bin folder in the Atom // install directory that point to the newly installed versions inside // the versioned app directories. -const addCommandsToPath = (exeName, callback) => { - const atomCmdName = exeName.replace('.exe', '.cmd'); +const addCommandsToPath = callback => { + const atomCmdName = execName.replace('.exe', '.cmd'); const apmCmdName = atomCmdName.replace('atom', 'apm'); const installCommands = callback => { @@ -122,25 +124,23 @@ const removeCommandsFromPath = callback => } }); -const getExeName = app => path.basename(app.getPath('exe')); - // Create a desktop and start menu shortcut by using the command line API // provided by Squirrel's Update.exe -const createShortcuts = (exeName, locations, callback) => +const createShortcuts = (locations, callback) => spawnUpdate( - ['--createShortcut', exeName, '-l', locations.join(',')], + ['--createShortcut', execName, '-l', locations.join(',')], callback ); // Update the desktop and start menu shortcuts by using the command line API // provided by Squirrel's Update.exe -const updateShortcuts = (appName, exeName, callback) => { +const updateShortcuts = callback => { const homeDirectory = fs.getHomeDirectory(); if (homeDirectory) { const desktopShortcutPath = path.join( homeDirectory, 'Desktop', - `${appName}.lnk` + `${getAppName()}.lnk` ); // Check if the desktop shortcut has been previously deleted and // and keep it deleted if it was @@ -150,17 +150,17 @@ const updateShortcuts = (appName, exeName, callback) => { locations.push('Desktop'); } - createShortcuts(exeName, locations, callback); + createShortcuts(locations, callback); }); } else { - createShortcuts(exeName, ['Desktop', 'StartMenu'], callback); + createShortcuts(['Desktop', 'StartMenu'], callback); } }; // Remove the desktop and start menu shortcuts by using the command line API // provided by Squirrel's Update.exe -const removeShortcuts = (exeName, callback) => - spawnUpdate(['--removeShortcut', exeName], callback); +const removeShortcuts = callback => + spawnUpdate(['--removeShortcut', execName], callback); exports.spawn = spawnUpdate; @@ -168,10 +168,10 @@ exports.spawn = spawnUpdate; exports.existsSync = () => fs.existsSync(updateDotExe); // Restart Atom using the version pointed to by the atom.cmd shim -exports.restartAtom = app => { +exports.restartAtom = () => { let args; - const exeName = getExeName(app); - const atomCmdName = exeName.replace('.exe', '.cmd'); + const atomCmdName = execName.replace('.exe', '.cmd'); + if (global.atomApplication && global.atomApplication.lastFocusedWindow) { const { projectPath } = global.atomApplication.lastFocusedWindow; if (projectPath) args = [projectPath]; @@ -180,30 +180,46 @@ exports.restartAtom = app => { app.quit(); }; -// Handle squirrel events denoted by --squirrel-* command line arguments. -exports.handleStartupEvent = (app, squirrelCommand) => { - const exeName = getExeName(app); - const appName = getAppName(); +const updateContextMenus = callback => + WinShell.fileContextMenu.update(() => + WinShell.folderContextMenu.update(() => + WinShell.folderBackgroundContextMenu.update(() => callback()) + ) + ); +// Handle squirrel events denoted by --squirrel-* command line arguments. +exports.handleStartupEvent = squirrelCommand => { switch (squirrelCommand) { case '--squirrel-install': - createShortcuts(exeName, ['Desktop', 'StartMenu'], () => - addCommandsToPath(exeName, () => - WinShell.registerShellIntegration(appName, () => app.quit()) + createShortcuts(['Desktop', 'StartMenu'], () => + addCommandsToPath(() => + WinShell.fileHandler.register(() => + updateContextMenus(() => app.quit()) + ) ) ); return true; case '--squirrel-updated': - updateShortcuts(appName, exeName, () => - addCommandsToPath(exeName, () => - WinShell.updateShellIntegration(appName, () => app.quit()) + updateShortcuts(() => + addCommandsToPath(() => + WinShell.fileHandler.update(() => + updateContextMenus(() => app.quit()) + ) ) ); return true; case '--squirrel-uninstall': - removeShortcuts(exeName, () => + removeShortcuts(() => removeCommandsFromPath(() => - WinShell.deregisterShellIntegration(appName, () => app.quit()) + WinShell.fileHandler.deregister(() => + WinShell.fileContextMenu.deregister(() => + WinShell.folderContextMenu.deregister(() => + WinShell.folderBackgroundContextMenu.deregister(() => + app.quit() + ) + ) + ) + ) ) ); return true; diff --git a/src/main-process/win-shell.js b/src/main-process/win-shell.js index 3ea9ec0fe..3e6a25a1e 100644 --- a/src/main-process/win-shell.js +++ b/src/main-process/win-shell.js @@ -2,9 +2,10 @@ const Registry = require('winreg'); const Path = require('path'); const getAppName = require('./get-app-name'); -let exeName = Path.basename(process.execPath); -let appPath = `"${process.execPath}"`; -let fileIconPath = `"${Path.join( +const appName = getAppName(); +const exeName = Path.basename(process.execPath); +const appPath = `"${process.execPath}"`; +const fileIconPath = `"${Path.join( process.execPath, '..', 'resources', @@ -72,73 +73,32 @@ class ShellOption { } } -function getShellOptions(appName) { - const contextParts = [ - { key: 'command', name: '', value: `${appPath} "%1"` }, - { name: '', value: `Open with ${appName}` }, - { name: 'Icon', value: `${appPath}` } - ]; +exports.appName = appName; - return { - fileHandler: new ShellOption( - `\\Software\\Classes\\Applications\\${exeName}`, - [ - { key: 'shell\\open\\command', name: '', value: `${appPath} "%1"` }, - { key: 'shell\\open', name: 'FriendlyAppName', value: `${appName}` }, - { key: 'DefaultIcon', name: '', value: `${fileIconPath}` } - ] - ), - fileContextMenu: new ShellOption( - `\\Software\\Classes\\*\\shell\\${appName}`, - contextParts - ), - folderContextMenu: new ShellOption( - `\\Software\\Classes\\Directory\\shell\\${appName}`, - contextParts - ), - folderBackgroundContextMenu: new ShellOption( - `\\Software\\Classes\\Directory\\background\\shell\\${appName}`, - JSON.parse(JSON.stringify(contextParts).replace('%1', '%V')) - ) - }; -} +exports.fileHandler = new ShellOption( + `\\Software\\Classes\\Applications\\${exeName}`, + [ + { key: 'shell\\open\\command', name: '', value: `${appPath} "%1"` }, + { key: 'shell\\open', name: 'FriendlyAppName', value: `${appName}` }, + { key: 'DefaultIcon', name: '', value: `${fileIconPath}` } + ] +); -function registerShellIntegration(appName, callback) { - const shellOptions = getShellOptions(appName); - shellOptions.fileHandler.register(() => - shellOptions.fileContextMenu.update(() => - shellOptions.folderContextMenu.update(() => - shellOptions.folderBackgroundContextMenu.update(() => callback()) - ) - ) - ); -} +let contextParts = [ + { key: 'command', name: '', value: `${appPath} "%1"` }, + { name: '', value: `Open with ${appName}` }, + { name: 'Icon', value: `${appPath}` } +]; -function updateShellIntegration(appName, callback) { - const shellOptions = getShellOptions(appName); - shellOptions.fileHandler.update(() => - shellOptions.fileContextMenu.update(() => - shellOptions.folderContextMenu.update(() => - shellOptions.folderBackgroundContextMenu.update(() => callback()) - ) - ) - ); -} - -function deregisterShellIntegration(appName, callback) { - const shellOptions = getShellOptions(appName); - shellOptions.fileHandler.deregister(() => - shellOptions.fileContextMenu.deregister(() => - shellOptions.folderContextMenu.deregister(() => - shellOptions.folderBackgroundContextMenu.deregister(() => callback()) - ) - ) - ); -} - -module.exports = { - appName: getAppName(), - registerShellIntegration, - updateShellIntegration, - deregisterShellIntegration -}; +exports.fileContextMenu = new ShellOption( + `\\Software\\Classes\\*\\shell\\${appName}`, + contextParts +); +exports.folderContextMenu = new ShellOption( + `\\Software\\Classes\\Directory\\shell\\${appName}`, + contextParts +); +exports.folderBackgroundContextMenu = new ShellOption( + `\\Software\\Classes\\Directory\\background\\shell\\${appName}`, + JSON.parse(JSON.stringify(contextParts).replace('%1', '%V')) +); From 0dfd8d409f66441b8b520feebef8e29753b3030c Mon Sep 17 00:00:00 2001 From: Linus Eriksson Date: Thu, 4 Jul 2019 14:58:03 +0200 Subject: [PATCH 43/58] Append the release channel to the AppUserModelId This allows each release channel to be pinned separately on Windows --- src/main-process/start.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main-process/start.js b/src/main-process/start.js index 6b7d44782..7f403fa70 100644 --- a/src/main-process/start.js +++ b/src/main-process/start.js @@ -74,7 +74,7 @@ module.exports = function start(resourcePath, devResourcePath, startTime) { } // NB: This prevents Win10 from showing dupe items in the taskbar - app.setAppUserModelId('com.squirrel.atom.' + process.arch); + app.setAppUserModelId('com.squirrel.atom.' + process.arch + getReleaseChannel(app.getVersion())); function addPathToOpen(event, pathToOpen) { event.preventDefault(); From fd6e9763a0c5a9c96635ba188ae68aa65d730109 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Thu, 4 Jul 2019 15:16:58 +0200 Subject: [PATCH 44/58] Fix squirrel-update specs --- spec/squirrel-update-spec.coffee | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spec/squirrel-update-spec.coffee b/spec/squirrel-update-spec.coffee index 5879877c9..5cea619ab 100644 --- a/spec/squirrel-update-spec.coffee +++ b/spec/squirrel-update-spec.coffee @@ -114,7 +114,7 @@ describe "Windows Squirrel Update", -> SquirrelUpdate.handleStartupEvent('--squirrel-updated') waitsFor -> - electron.app.quit.callCount is 1 + electron.app.quit.callCount is 2 it "does not recreate shortcut", -> expect(fs.existsSync(desktopShortcutPath)).toBe false @@ -123,7 +123,7 @@ describe "Windows Squirrel Update", -> beforeEach -> SquirrelUpdate.handleStartupEvent('--squirrel-updated') waitsFor -> - electron.app.quit.callCount is 1 + electron.app.quit.callCount is 2 it "still has desktop shortcut", -> expect(fs.existsSync(desktopShortcutPath)).toBe true From f0a4dcd46befa7cc3039f624deeebd63fec41688 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Thu, 4 Jul 2019 15:17:24 +0200 Subject: [PATCH 45/58] Make get-app-name module compatible with the renderer process This module is required both from the main process and the renderer process, since `win-shell.js` is also required from both processes (which is nuts). In order to make it work when used from the main process, `get-app-name` just falls back to use the `atom-environment` `getAppName()` method. --- src/{main-process => }/get-app-name.js | 6 +++++- src/main-process/atom-window.js | 2 +- src/main-process/squirrel-update.js | 2 +- src/main-process/win-shell.js | 2 +- 4 files changed, 8 insertions(+), 4 deletions(-) rename src/{main-process => }/get-app-name.js (73%) diff --git a/src/main-process/get-app-name.js b/src/get-app-name.js similarity index 73% rename from src/main-process/get-app-name.js rename to src/get-app-name.js index 2607f12b8..5ad814cef 100644 --- a/src/main-process/get-app-name.js +++ b/src/get-app-name.js @@ -1,7 +1,11 @@ const { app } = require('electron'); -const getReleaseChannel = require('../get-release-channel'); +const getReleaseChannel = require('./get-release-channel'); module.exports = function getAppName() { + if (process.type === 'renderer') { + return atom.getAppName(); + } + const releaseChannel = getReleaseChannel(app.getVersion()); const appNameParts = [app.getName()]; diff --git a/src/main-process/atom-window.js b/src/main-process/atom-window.js index bcf33ec18..f4c54315a 100644 --- a/src/main-process/atom-window.js +++ b/src/main-process/atom-window.js @@ -1,5 +1,5 @@ const { BrowserWindow, app, dialog, ipcMain } = require('electron'); -const getAppName = require('./get-app-name'); +const getAppName = require('../get-app-name'); const path = require('path'); const url = require('url'); const { EventEmitter } = require('events'); diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index 8d9b769f2..d46825912 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -1,7 +1,7 @@ let setxPath; const { app } = require('electron'); const fs = require('fs-plus'); -const getAppName = require('./get-app-name'); +const getAppName = require('../get-app-name'); const path = require('path'); const Spawner = require('./spawner'); const WinShell = require('./win-shell'); diff --git a/src/main-process/win-shell.js b/src/main-process/win-shell.js index 3e6a25a1e..366eb513c 100644 --- a/src/main-process/win-shell.js +++ b/src/main-process/win-shell.js @@ -1,6 +1,6 @@ const Registry = require('winreg'); const Path = require('path'); -const getAppName = require('./get-app-name'); +const getAppName = require('../get-app-name'); const appName = getAppName(); const exeName = Path.basename(process.execPath); From 00ff47375428a3954e5b6e8fc69e37564581619a Mon Sep 17 00:00:00 2001 From: Linus Eriksson Date: Thu, 4 Jul 2019 15:25:41 +0200 Subject: [PATCH 46/58] :shirt: --- src/main-process/start.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main-process/start.js b/src/main-process/start.js index 7f403fa70..690843be6 100644 --- a/src/main-process/start.js +++ b/src/main-process/start.js @@ -74,7 +74,9 @@ module.exports = function start(resourcePath, devResourcePath, startTime) { } // NB: This prevents Win10 from showing dupe items in the taskbar - app.setAppUserModelId('com.squirrel.atom.' + process.arch + getReleaseChannel(app.getVersion())); + app.setAppUserModelId( + 'com.squirrel.atom.' + process.arch + getReleaseChannel(app.getVersion()) + ); function addPathToOpen(event, pathToOpen) { event.preventDefault(); From 415861f1f92e570ae4fcd4b5b8d8d7ac8fcbdce3 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Thu, 4 Jul 2019 17:43:03 +0200 Subject: [PATCH 47/58] Fix creation of binary folders On cbe54954f44aef00eac477d210a7437624fbb627 I forgot to update the callers of handleStartupEvent() and restartAtom() which no longer expect an app object to be passed. --- src/main-process/auto-updater-win32.js | 2 +- src/main-process/start.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main-process/auto-updater-win32.js b/src/main-process/auto-updater-win32.js index f0e583a66..99015fd4c 100644 --- a/src/main-process/auto-updater-win32.js +++ b/src/main-process/auto-updater-win32.js @@ -8,7 +8,7 @@ class AutoUpdater extends EventEmitter { quitAndInstall() { if (SquirrelUpdate.existsSync()) { - SquirrelUpdate.restartAtom(require('electron').app); + SquirrelUpdate.restartAtom(); } else { require('electron').autoUpdater.quitAndInstall(); } diff --git a/src/main-process/start.js b/src/main-process/start.js index 690843be6..3926c51b6 100644 --- a/src/main-process/start.js +++ b/src/main-process/start.js @@ -125,7 +125,7 @@ function handleStartupEventWithSquirrel() { const SquirrelUpdate = require('./squirrel-update'); const squirrelCommand = process.argv[1]; - return SquirrelUpdate.handleStartupEvent(app, squirrelCommand); + return SquirrelUpdate.handleStartupEvent(squirrelCommand); } function getConfig() { From 3711c525a89787ce953e6c3c2c414e2fdf567433 Mon Sep 17 00:00:00 2001 From: Linus Eriksson Date: Fri, 5 Jul 2019 16:57:02 +0200 Subject: [PATCH 48/58] Rename the sh commands in the bin folder This fixes an issue where atom stable would not launch correctly from powershell if it was not the first entry in path because it tries to execute the shell script from another channel --- src/main-process/squirrel-update.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index d46825912..86f414824 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -36,6 +36,8 @@ const spawnUpdate = (args, callback) => const addCommandsToPath = callback => { const atomCmdName = execName.replace('.exe', '.cmd'); const apmCmdName = atomCmdName.replace('atom', 'apm'); + const atomShName = execName.replace('.exe', ''); + const apmShName = atomShName.replace('atom', 'apm'); const installCommands = callback => { const atomCommandPath = path.join(binFolder, atomCmdName); @@ -45,7 +47,7 @@ const addCommandsToPath = callback => { ); const atomCommand = `@echo off\r\n"%~dp0\\${relativeAtomPath}" %*`; - const atomShCommandPath = path.join(binFolder, 'atom'); + const atomShCommandPath = path.join(binFolder, atomShName); const relativeAtomShPath = path.relative( binFolder, path.join(appFolder, 'resources', 'cli', 'atom.sh') @@ -62,7 +64,7 @@ const addCommandsToPath = callback => { ); const apmCommand = `@echo off\r\n"%~dp0\\${relativeApmPath}" %*`; - const apmShCommandPath = path.join(binFolder, 'apm'); + const apmShCommandPath = path.join(binFolder, apmShName); const relativeApmShPath = path.relative( binFolder, path.join(appFolder, 'resources', 'cli', 'apm.sh') From 603800f20179b4338ca47741434029c9e67d2264 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 15 Jul 2019 16:50:52 +0200 Subject: [PATCH 49/58] Do not add the release channel on stable versions of Atom This is done to avoid changing the application user model id on Atom stable, which prevents pins from currently installed Atom stable versions to stop working. --- src/main-process/start.js | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/src/main-process/start.js b/src/main-process/start.js index 3926c51b6..82c0591a5 100644 --- a/src/main-process/start.js +++ b/src/main-process/start.js @@ -73,10 +73,17 @@ module.exports = function start(resourcePath, devResourcePath, startTime) { return; } - // NB: This prevents Win10 from showing dupe items in the taskbar - app.setAppUserModelId( - 'com.squirrel.atom.' + process.arch + getReleaseChannel(app.getVersion()) - ); + const releaseChannel = getReleaseChannel(app.getVersion()); + let appUserModelId = 'com.squirrel.atom.' + process.arch; + + // If the release channel is not stable, we append it to the app user model id. + // This allows having the different release channels as separate items in the taskbar. + if (releaseChannel !== 'stable') { + appUserModelId += `-${releaseChannel}`; + } + + // NB: This prevents Win10 from showing dupe items in the taskbar. + app.setAppUserModelId(appUserModelId); function addPathToOpen(event, pathToOpen) { event.preventDefault(); @@ -93,7 +100,7 @@ module.exports = function start(resourcePath, devResourcePath, startTime) { app.on('will-finish-launching', () => startCrashReporter({ uploadToServer: config.get('core.telemetryConsent') === 'limited', - releaseChannel: getReleaseChannel(app.getVersion()) + releaseChannel }) ); From 13805c2b2f7ef25663c254ea7b32e1a637ede92f Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Mon, 15 Jul 2019 17:18:27 -0600 Subject: [PATCH 50/58] :arrow_up: apm --- apm/package-lock.json | 104 +++++++++++++++++++++++++++--------------- apm/package.json | 2 +- 2 files changed, 68 insertions(+), 38 deletions(-) diff --git a/apm/package-lock.json b/apm/package-lock.json index c21d2488a..b429a305e 100644 --- a/apm/package-lock.json +++ b/apm/package-lock.json @@ -4,9 +4,9 @@ "lockfileVersion": 1, "dependencies": { "atom-package-manager": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/atom-package-manager/-/atom-package-manager-2.3.1.tgz", - "integrity": "sha512-CAys5szBJbqhkizMm32o0+uOTpT9rgPh9TdFX0R//usjOAgDr8iJ7oGNfULPvJzaKnBhrokuniKNumAxVyuauA==", + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/atom-package-manager/-/atom-package-manager-2.4.0.tgz", + "integrity": "sha512-hSA2YlxBgmuUk3EsmPKaNtp9zoSzsXeTBu/piHYh9+VRxulmYUSafIRaWS/gNEFDfa9UB4lu8Ej2/w3fEYruYg==", "requires": { "@atom/plist": "0.4.4", "asar-require": "0.3.0", @@ -50,9 +50,9 @@ "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==" }, "ajv": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.0.tgz", - "integrity": "sha512-nffhOpkymDECQyR0mnsUtoCE8RlX38G0rYP+wgLWFyZuUyuuojSSvi/+euOiQBIn63whYwYVIIH1TvE3tu4OEg==", + "version": "6.10.2", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.2.tgz", + "integrity": "sha512-TXtUUEYHuaTEbLZWIKUr5pmBuhDLy+8KYtPYdcV8qC+pOZL+NKqYwvWSRrVXHn+ZmRRAu8vJTAznH7Oag6RVRw==", "requires": { "fast-deep-equal": "^2.0.1", "fast-json-stable-stringify": "^2.0.0", @@ -98,6 +98,11 @@ "util-deprecate": "~1.0.1" } }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, "string_decoder": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", @@ -212,6 +217,13 @@ "safe-buffer": "~5.1.1", "string_decoder": "~1.1.1", "util-deprecate": "~1.0.1" + }, + "dependencies": { + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + } } }, "string_decoder": { @@ -220,6 +232,13 @@ "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "requires": { "safe-buffer": "~5.1.0" + }, + "dependencies": { + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + } } } } @@ -284,9 +303,9 @@ } }, "chownr": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.1.tgz", - "integrity": "sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g==" + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.2.tgz", + "integrity": "sha512-GkfeAQh+QNy3wquu9oIZr6SS5x7wGdSgNQvD10X3r+AZr1Oys22HW8kAmDMvNg2+Dm0TeGaEuO8gFwdBXxwO8A==" }, "chromium-pickle-js": { "version": "0.1.0", @@ -468,11 +487,12 @@ }, "dependencies": { "d": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/d/-/d-1.0.0.tgz", - "integrity": "sha1-dUu1v+VUUdpppYuU1F9MWwRi1Y8=", + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/d/-/d-1.0.1.tgz", + "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==", "requires": { - "es5-ext": "^0.10.9" + "es5-ext": "^0.10.50", + "type": "^1.0.1" } }, "es6-iterator": { @@ -701,9 +721,9 @@ } }, "graceful-fs": { - "version": "4.1.15", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.15.tgz", - "integrity": "sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA==" + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.0.tgz", + "integrity": "sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg==" }, "grim": { "version": "1.5.0", @@ -757,9 +777,9 @@ } }, "inherits": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", - "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, "ini": { "version": "1.3.5", @@ -834,9 +854,9 @@ } }, "keytar": { - "version": "4.9.0", - "resolved": "https://registry.npmjs.org/keytar/-/keytar-4.9.0.tgz", - "integrity": "sha512-5aKEpnxRWUIhSlRXckqTxomqokV1/tOBe3EdbCDyMjDaoa5AkVHVa1yK+fa2CgJR5MadbJndFWmcDMCq812F4A==", + "version": "4.11.0", + "resolved": "https://registry.npmjs.org/keytar/-/keytar-4.11.0.tgz", + "integrity": "sha512-cGn2xd4NY0yCBrU5zQ/lwIagP1UBOhUEemi6iSJU2gshN1RHkxHekSdLUji9IWNo5B1Va/iwXXWzGD2p8ziqfQ==", "requires": { "nan": "2.14.0", "prebuild-install": "5.3.0" @@ -970,9 +990,9 @@ "integrity": "sha1-yobR/ogoFpsBICCOPchCS524NCw=" }, "node-abi": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-2.8.0.tgz", - "integrity": "sha512-1/aa2clS0pue0HjckL62CsbhWWU35HARvBDXcJtYKbYR7LnIutmpxmXbuDMV9kEviD2lP/wACOgWmmwljghHyQ==", + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-2.9.0.tgz", + "integrity": "sha512-jmEOvv0eanWjhX8dX1pmjb7oJl1U1oR4FOh0b2GnvALwSYoOdU7sj+kLDSAyjo4pfC9aj/IxkloxdLJQhSSQBA==", "requires": { "semver": "^5.4.1" } @@ -3855,9 +3875,9 @@ } }, "process-nextick-args": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", - "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==" + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" }, "property-accessors": { "version": "1.1.3", @@ -3869,9 +3889,9 @@ } }, "psl": { - "version": "1.1.32", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.1.32.tgz", - "integrity": "sha512-MHACAkHpihU/REGGPLj4sEfc/XKW2bheigvHO1dUqjaKigMp1C8+WLQYRGgeKFMsw5PMfegZcaN8IDXK/cD0+g==" + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/psl/-/psl-1.2.0.tgz", + "integrity": "sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA==" }, "pump": { "version": "2.0.1", @@ -3985,9 +4005,9 @@ } }, "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", + "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==" }, "safer-buffer": { "version": "2.1.2", @@ -4174,6 +4194,11 @@ "util-deprecate": "~1.0.1" } }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, "string_decoder": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", @@ -4265,6 +4290,11 @@ "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=" }, + "type": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/type/-/type-1.0.1.tgz", + "integrity": "sha512-MAM5dBMJCJNKs9E7JXo4CXRAansRfG0nlJxW7Wf6GZzSOvH31zClSaHdIMWLehe/EGMBkqeC55rrkaOr5Oo7Nw==" + }, "underscore": { "version": "1.9.1", "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.9.1.tgz", @@ -4359,9 +4389,9 @@ "integrity": "sha1-1QH5ezvbQDr4757MIFcxh6rawOk=" }, "xtend": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.1.tgz", - "integrity": "sha1-pcbVMr5lbiPbgg77lDofBJmNY68=" + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==" }, "y18n": { "version": "3.2.1", diff --git a/apm/package.json b/apm/package.json index 8b8da2214..ff5c5f783 100644 --- a/apm/package.json +++ b/apm/package.json @@ -6,6 +6,6 @@ "url": "https://github.com/atom/atom.git" }, "dependencies": { - "atom-package-manager": "2.3.1" + "atom-package-manager": "2.4.0" } } From 27e9ab8d32b4e3a9a54cb0711f184e7973c83ec1 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Tue, 16 Jul 2019 18:32:24 +0200 Subject: [PATCH 51/58] Use the correct executable name on the code signing tool --- script/build | 2 +- script/lib/kill-running-atom-instances.js | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/script/build b/script/build index 9219edad2..90f55012d 100755 --- a/script/build +++ b/script/build @@ -107,7 +107,7 @@ if (!argv.generateApiDocs) { } if (argv.codeSign) { - const executablesToSign = [ path.join(packagedAppPath, 'Atom.exe') ] + const executablesToSign = [ path.join(packagedAppPath, CONFIG.executableName) ] if (argv.createWindowsInstaller) { executablesToSign.push(path.join(__dirname, 'node_modules', '@atom', 'electron-winstaller', 'vendor', 'Squirrel.exe')) } diff --git a/script/lib/kill-running-atom-instances.js b/script/lib/kill-running-atom-instances.js index a4c4850cc..6b35f4f0e 100644 --- a/script/lib/kill-running-atom-instances.js +++ b/script/lib/kill-running-atom-instances.js @@ -5,9 +5,7 @@ const CONFIG = require('../config.js'); module.exports = function() { if (process.platform === 'win32') { // Use START as a way to ignore error if Atom.exe isnt running - childProcess.execSync( - `START taskkill /F /IM ${CONFIG.appMetadata.productName}.exe` - ); + childProcess.execSync(`START taskkill /F /IM ${CONFIG.executableName}`); } else { childProcess.execSync(`pkill -9 ${CONFIG.appMetadata.productName} || true`); } From 3b64da30a4af0025c8b35a8e716fafa663a053b0 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Tue, 16 Jul 2019 14:30:45 -0600 Subject: [PATCH 52/58] :arrow_up: apm --- apm/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apm/package.json b/apm/package.json index ff5c5f783..c98126da8 100644 --- a/apm/package.json +++ b/apm/package.json @@ -6,6 +6,6 @@ "url": "https://github.com/atom/atom.git" }, "dependencies": { - "atom-package-manager": "2.4.0" + "atom-package-manager": "2.4.1" } } From 6fcfaffa041425933434e59058733484edab4c56 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Wed, 17 Jul 2019 11:40:37 +0200 Subject: [PATCH 53/58] Do not depend on CONFIG.executableName on the windows tests CONFIG.executableName depends on the ATOM_RELEASE_VERSION env variable to work correctly on nightly releases. Since this env variable is not being set for the testing steps, the nightly release builds contain a wrong executableName on the testing step, which causes a failure when trying to find the Atom executable. This commit fixes that by stop using the executableName from the test step, like it's done on other platforms. --- script/test | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/test b/script/test index e6e4737a1..cf178fafc 100755 --- a/script/test +++ b/script/test @@ -56,7 +56,7 @@ if (process.platform === 'darwin') { assert(executablePaths.length === 1, `More than one application to run tests against was found. ${executablePaths.join(',')}`) executablePath = executablePaths[0] } else if (process.platform === 'win32') { - const executablePaths = glob.sync(path.join(CONFIG.buildOutputPath, '**', CONFIG.executableName)) + const executablePaths = glob.sync(path.join(CONFIG.buildOutputPath, '**', 'atom*.exe')) assert(executablePaths.length === 1, `More than one application to run tests against was found. ${executablePaths.join(',')}`) executablePath = executablePaths[0] } else { From 535c0311d42f5cd5d23537b3534928e1229767f7 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Wed, 17 Jul 2019 15:33:13 +0200 Subject: [PATCH 54/58] Calculate correctly the nupkg filenames when uploading artifacts --- script/vsts/get-release-version.js | 17 +++++++++++++++++ script/vsts/platforms/windows.yml | 25 +++++++++++++------------ 2 files changed, 30 insertions(+), 12 deletions(-) diff --git a/script/vsts/get-release-version.js b/script/vsts/get-release-version.js index 1db97aa0e..159128eed 100644 --- a/script/vsts/get-release-version.js +++ b/script/vsts/get-release-version.js @@ -11,6 +11,17 @@ const argv = yargs .describe('nightly', 'Indicates that a nightly version should be produced') .wrap(yargs.terminalWidth()).argv; +function getAppName(version) { + const match = version.match(/\d+\.\d+\.\d+(-([a-z]+)(\d+|-\w{4,})?)?$/); + if (!match) { + throw new Error(`Found incorrectly formatted Atom version ${version}`); + } else if (match[2]) { + return `atom-${match[2]}`; + } + + return 'atom'; +} + async function getReleaseVersion() { let releaseVersion = process.env.ATOM_RELEASE_VERSION || appMetadata.version; if (argv.nightly) { @@ -67,6 +78,12 @@ async function getReleaseVersion() { buildBranch.startsWith('electron-') || (buildBranch === 'master' && !process.env.SYSTEM_PULLREQUEST_PULLREQUESTNUMBER)); + + console.log( + `##vso[task.setvariable variable=AppName;isOutput=true]${getAppName( + releaseVersion + )}` + ); console.log( `##vso[task.setvariable variable=IsReleaseBranch;isOutput=true]${isReleaseBranch}` ); diff --git a/script/vsts/platforms/windows.yml b/script/vsts/platforms/windows.yml index 6432cfa17..746d517a6 100644 --- a/script/vsts/platforms/windows.yml +++ b/script/vsts/platforms/windows.yml @@ -14,6 +14,7 @@ jobs: vmImage: vs2015-win2012r2 # needed for python 2.7 and gyp variables: + AppName: $[ dependencies.GetReleaseVersion.outputs['Version.AppName'] ] ReleaseVersion: $[ dependencies.GetReleaseVersion.outputs['Version.ReleaseVersion'] ] IsReleaseBranch: $[ dependencies.GetReleaseVersion.outputs['Version.IsReleaseBranch'] ] IsSignedZipBranch: $[ dependencies.GetReleaseVersion.outputs['Version.IsSignedZipBranch'] ] @@ -184,18 +185,18 @@ jobs: - task: PublishBuildArtifacts@1 inputs: - PathtoPublish: $(Build.SourcesDirectory)/out/atom-x64-$(ReleaseVersion)-full.nupkg - ArtifactName: atom-x64-$(ReleaseVersion)-full.nupkg + PathtoPublish: $(Build.SourcesDirectory)/out/$(AppName)-x64-$(ReleaseVersion)-full.nupkg + ArtifactName: $(AppName)-x64-$(ReleaseVersion)-full.nupkg ArtifactType: Container - displayName: Upload atom-x64-$(ReleaseVersion)-full.nupkg + displayName: Upload $(AppName)-x64-$(ReleaseVersion)-full.nupkg condition: and(succeeded(), eq(variables['IsReleaseBranch'], 'true'), eq(variables['buildArch'], 'x64')) - task: PublishBuildArtifacts@1 inputs: - PathtoPublish: $(Build.SourcesDirectory)/out/atom-x64-$(ReleaseVersion)-delta.nupkg - ArtifactName: atom-x64-$(ReleaseVersion)-delta.nupkg + PathtoPublish: $(Build.SourcesDirectory)/out/$(AppName)-x64-$(ReleaseVersion)-delta.nupkg + ArtifactName: $(AppName)-x64-$(ReleaseVersion)-delta.nupkg ArtifactType: Container - displayName: Upload atom-x64-$(ReleaseVersion)-delta.nupkg + displayName: Upload $(AppName)-x64-$(ReleaseVersion)-delta.nupkg condition: and(succeeded(), eq(variables['IsReleaseBranch'], 'true'), eq(variables['buildArch'], 'x64')) continueOnError: true # Nightly builds don't produce delta packages yet, so don't fail the build @@ -225,18 +226,18 @@ jobs: - task: PublishBuildArtifacts@1 inputs: - PathtoPublish: $(Build.SourcesDirectory)/out/atom-$(ReleaseVersion)-full.nupkg - ArtifactName: atom-$(ReleaseVersion)-full.nupkg + PathtoPublish: $(Build.SourcesDirectory)/out/$(AppName)-$(ReleaseVersion)-full.nupkg + ArtifactName: $(AppName)-$(ReleaseVersion)-full.nupkg ArtifactType: Container - displayName: Upload atom-$(ReleaseVersion)-full.nupkg + displayName: Upload $(AppName)-$(ReleaseVersion)-full.nupkg condition: and(succeeded(), eq(variables['IsReleaseBranch'], 'true'), eq(variables['buildArch'], 'x86')) - task: PublishBuildArtifacts@1 inputs: - PathtoPublish: $(Build.SourcesDirectory)/out/atom-$(ReleaseVersion)-delta.nupkg - ArtifactName: atom-$(ReleaseVersion)-delta.nupkg + PathtoPublish: $(Build.SourcesDirectory)/out/$(AppName)-$(ReleaseVersion)-delta.nupkg + ArtifactName: $(AppName)-$(ReleaseVersion)-delta.nupkg ArtifactType: Container - displayName: Upload atom-$(ReleaseVersion)-delta.nupkg + displayName: Upload $(AppName)-$(ReleaseVersion)-delta.nupkg condition: and(succeeded(), eq(variables['IsReleaseBranch'], 'true'), eq(variables['buildArch'], 'x86')) continueOnError: true # Nightly builds don't produce delta packages yet, so don't fail the build From 3df1f11d8db0b20cce6fa0e91901bc571ffbe573 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Thu, 18 Jul 2019 11:38:51 +0200 Subject: [PATCH 55/58] Upgrade apm@2.4.2 --- apm/package-lock.json | 6 +++--- apm/package.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apm/package-lock.json b/apm/package-lock.json index b429a305e..09cf9bfc9 100644 --- a/apm/package-lock.json +++ b/apm/package-lock.json @@ -4,9 +4,9 @@ "lockfileVersion": 1, "dependencies": { "atom-package-manager": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/atom-package-manager/-/atom-package-manager-2.4.0.tgz", - "integrity": "sha512-hSA2YlxBgmuUk3EsmPKaNtp9zoSzsXeTBu/piHYh9+VRxulmYUSafIRaWS/gNEFDfa9UB4lu8Ej2/w3fEYruYg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/atom-package-manager/-/atom-package-manager-2.4.2.tgz", + "integrity": "sha512-gX1c9fC4TL00ZfFkYKgFegabSGa7cGh0zzBQf4h8s99a/5pPUMvA0lnhC2/K1eM8XlYbnLwt03U/m6M3PFX/gA==", "requires": { "@atom/plist": "0.4.4", "asar-require": "0.3.0", diff --git a/apm/package.json b/apm/package.json index c98126da8..829f0f2a4 100644 --- a/apm/package.json +++ b/apm/package.json @@ -6,6 +6,6 @@ "url": "https://github.com/atom/atom.git" }, "dependencies": { - "atom-package-manager": "2.4.1" + "atom-package-manager": "2.4.2" } } From 476a649fa9c0ec1a239dc073d569987884839cfd Mon Sep 17 00:00:00 2001 From: Hubot Date: Thu, 18 Jul 2019 13:43:09 -0500 Subject: [PATCH 56/58] 1.41.0-dev --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 0db649fab..529f8fa75 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "atom", "productName": "Atom", - "version": "1.40.0-dev", + "version": "1.41.0-dev", "description": "A hackable text editor for the 21st Century.", "main": "./src/main-process/main.js", "repository": { From f31f3b6beafa475162749230a2f80e73412bc5db Mon Sep 17 00:00:00 2001 From: Ash Wilson Date: Thu, 18 Jul 2019 14:56:53 -0400 Subject: [PATCH 57/58] GitHub package prerelease --- package-lock.json | 697 +++++++++++++++++++++++++++------------------- package.json | 4 +- 2 files changed, 414 insertions(+), 287 deletions(-) diff --git a/package-lock.json b/package-lock.json index dbfccf38a..7941ad0e2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "atom", - "version": "1.40.0-dev", + "version": "1.41.0-dev", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -64,42 +64,42 @@ } }, "@babel/code-frame": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0.tgz", - "integrity": "sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.5.5.tgz", + "integrity": "sha512-27d4lZoomVyo51VegxI20xZPuSHusqbQag/ztrBC7wegWoQ1nLREPVSKSW8byhTlzTKyNE4ifaTA6lCp7JjpFw==", "requires": { "@babel/highlight": "^7.0.0" } }, "@babel/core": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.4.4.tgz", - "integrity": "sha512-lQgGX3FPRgbz2SKmhMtYgJvVzGZrmjaF4apZ2bLwofAKiSjxU0drPh4S/VasyYXwaTs+A1gvQ45BN8SQJzHsQQ==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.5.5.tgz", + "integrity": "sha512-i4qoSr2KTtce0DmkuuQBV4AuQgGPUcPXMr9L5MyYAtk06z068lQ10a4O009fe5OB/DfNV+h+qqT7ddNV8UnRjg==", "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/generator": "^7.4.4", - "@babel/helpers": "^7.4.4", - "@babel/parser": "^7.4.4", + "@babel/code-frame": "^7.5.5", + "@babel/generator": "^7.5.5", + "@babel/helpers": "^7.5.5", + "@babel/parser": "^7.5.5", "@babel/template": "^7.4.4", - "@babel/traverse": "^7.4.4", - "@babel/types": "^7.4.4", + "@babel/traverse": "^7.5.5", + "@babel/types": "^7.5.5", "convert-source-map": "^1.1.0", "debug": "^4.1.0", "json5": "^2.1.0", - "lodash": "^4.17.11", + "lodash": "^4.17.13", "resolve": "^1.3.2", "semver": "^5.4.1", "source-map": "^0.5.0" }, "dependencies": { "@babel/generator": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.4.4.tgz", - "integrity": "sha512-53UOLK6TVNqKxf7RUh8NE851EHRxOOeVXKbK2bivdb+iziMyk03Sr4eaE9OELCbyZAAafAKPDwF2TPUES5QbxQ==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.5.5.tgz", + "integrity": "sha512-ETI/4vyTSxTzGnU2c49XHv2zhExkv9JHLTwDAFz85kmcwuShvYG2H08FwgIguQf4JC75CBnXAUM5PqeF4fj0nQ==", "requires": { - "@babel/types": "^7.4.4", + "@babel/types": "^7.5.5", "jsesc": "^2.5.1", - "lodash": "^4.17.11", + "lodash": "^4.17.13", "source-map": "^0.5.0", "trim-right": "^1.0.1" } @@ -126,9 +126,9 @@ } }, "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" }, "minimist": { "version": "1.2.0", @@ -136,9 +136,9 @@ "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" }, "ms": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", - "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" }, "semver": { "version": "5.7.0", @@ -153,11 +153,11 @@ } }, "@babel/generator": { - "version": "7.4.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.4.0.tgz", - "integrity": "sha512-/v5I+a1jhGSKLgZDcmAUZ4K/VePi43eRkUs3yePW1HB1iANOD5tqJXwGSG4BZhSksP8J9ejSlwGeTiiOFZOrXQ==", + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.4.4.tgz", + "integrity": "sha512-53UOLK6TVNqKxf7RUh8NE851EHRxOOeVXKbK2bivdb+iziMyk03Sr4eaE9OELCbyZAAafAKPDwF2TPUES5QbxQ==", "requires": { - "@babel/types": "^7.4.0", + "@babel/types": "^7.4.4", "jsesc": "^2.5.1", "lodash": "^4.17.11", "source-map": "^0.5.0", @@ -170,9 +170,9 @@ "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==" }, "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" }, "source-map": { "version": "0.5.7", @@ -218,32 +218,32 @@ } }, "@babel/helper-create-class-features-plugin": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.4.4.tgz", - "integrity": "sha512-UbBHIa2qeAGgyiNR9RszVF7bUHEdgS4JAUNT8SiqrAN6YJVxlOxeLr5pBzb5kan302dejJ9nla4RyKcR1XT6XA==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.5.5.tgz", + "integrity": "sha512-ZsxkyYiRA7Bg+ZTRpPvB6AbOFKTFFK4LrvTet8lInm0V468MWCaSYJE+I7v2z2r8KNLtYiV+K5kTCnR7dvyZjg==", "requires": { "@babel/helper-function-name": "^7.1.0", - "@babel/helper-member-expression-to-functions": "^7.0.0", + "@babel/helper-member-expression-to-functions": "^7.5.5", "@babel/helper-optimise-call-expression": "^7.0.0", "@babel/helper-plugin-utils": "^7.0.0", - "@babel/helper-replace-supers": "^7.4.4", + "@babel/helper-replace-supers": "^7.5.5", "@babel/helper-split-export-declaration": "^7.4.4" } }, "@babel/helper-define-map": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/helper-define-map/-/helper-define-map-7.4.4.tgz", - "integrity": "sha512-IX3Ln8gLhZpSuqHJSnTNBWGDE9kdkTEWl21A/K7PQ00tseBwbqCHTvNLHSBd9M0R5rER4h5Rsvj9vw0R5SieBg==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/helper-define-map/-/helper-define-map-7.5.5.tgz", + "integrity": "sha512-fTfxx7i0B5NJqvUOBBGREnrqbTxRh7zinBANpZXAVDlsZxYdclDp467G1sQ8VZYMnAURY3RpBUAgOYT9GfzHBg==", "requires": { "@babel/helper-function-name": "^7.1.0", - "@babel/types": "^7.4.4", - "lodash": "^4.17.11" + "@babel/types": "^7.5.5", + "lodash": "^4.17.13" }, "dependencies": { "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" } } }, @@ -283,11 +283,11 @@ } }, "@babel/helper-member-expression-to-functions": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.0.0.tgz", - "integrity": "sha512-avo+lm/QmZlv27Zsi0xEor2fKcqWG56D5ae9dzklpIaY7cQMK5N8VSpaNVPPagiqmy7LrEjK1IWdGMOqPu5csg==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.5.5.tgz", + "integrity": "sha512-5qZ3D1uMclSNqYcXqiHoA0meVdv+xUEex9em2fqMnrk/scphGlGgg66zjMrPJESPwrFJ6sbfFQYUSa0Mz7FabA==", "requires": { - "@babel/types": "^7.0.0" + "@babel/types": "^7.5.5" } }, "@babel/helper-module-imports": { @@ -299,22 +299,22 @@ } }, "@babel/helper-module-transforms": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.4.4.tgz", - "integrity": "sha512-3Z1yp8TVQf+B4ynN7WoHPKS8EkdTbgAEy0nU0rs/1Kw4pDgmvYH3rz3aI11KgxKCba2cn7N+tqzV1mY2HMN96w==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.5.5.tgz", + "integrity": "sha512-jBeCvETKuJqeiaCdyaheF40aXnnU1+wkSiUs/IQg3tB85up1LyL8x77ClY8qJpuRJUcXQo+ZtdNESmZl4j56Pw==", "requires": { "@babel/helper-module-imports": "^7.0.0", "@babel/helper-simple-access": "^7.1.0", "@babel/helper-split-export-declaration": "^7.4.4", "@babel/template": "^7.4.4", - "@babel/types": "^7.4.4", - "lodash": "^4.17.11" + "@babel/types": "^7.5.5", + "lodash": "^4.17.13" }, "dependencies": { "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" } } }, @@ -332,17 +332,17 @@ "integrity": "sha512-CYAOUCARwExnEixLdB6sDm2dIJ/YgEAKDM1MOeMeZu9Ld/bDgVo8aiWrXwcY7OBh+1Ea2uUcVRcxKk0GJvW7QA==" }, "@babel/helper-regex": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.4.4.tgz", - "integrity": "sha512-Y5nuB/kESmR3tKjU8Nkn1wMGEx1tjJX076HBMeL3XLQCu6vA/YRzuTW0bbb+qRnXvQGn+d6Rx953yffl8vEy7Q==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.5.5.tgz", + "integrity": "sha512-CkCYQLkfkiugbRDO8eZn6lRuR8kzZoGXCg3149iTk5se7g6qykSpy3+hELSwquhu+TgHn8nkLiBwHvNX8Hofcw==", "requires": { - "lodash": "^4.17.11" + "lodash": "^4.17.13" }, "dependencies": { "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" } } }, @@ -359,14 +359,14 @@ } }, "@babel/helper-replace-supers": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.4.4.tgz", - "integrity": "sha512-04xGEnd+s01nY1l15EuMS1rfKktNF+1CkKmHoErDppjAAZL+IUBZpzT748x262HF7fibaQPhbvWUl5HeSt1EXg==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.5.5.tgz", + "integrity": "sha512-XvRFWrNnlsow2u7jXDuH4jDDctkxbS7gXssrP4q2nUD606ukXHRvydj346wmNg+zAgpFx4MWf4+usfC93bElJg==", "requires": { - "@babel/helper-member-expression-to-functions": "^7.0.0", + "@babel/helper-member-expression-to-functions": "^7.5.5", "@babel/helper-optimise-call-expression": "^7.0.0", - "@babel/traverse": "^7.4.4", - "@babel/types": "^7.4.4" + "@babel/traverse": "^7.5.5", + "@babel/types": "^7.5.5" } }, "@babel/helper-simple-access": { @@ -398,19 +398,19 @@ } }, "@babel/helpers": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.4.4.tgz", - "integrity": "sha512-igczbR/0SeuPR8RFfC7tGrbdTbFL3QTvH6D+Z6zNxnTe//GyqmtHmDkzrqDmyZ3eSwPqB/LhyKoU5DXsp+Vp2A==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.5.5.tgz", + "integrity": "sha512-nRq2BUhxZFnfEn/ciJuhklHvFOqjJUD5wpx+1bxUF2axL9C+v4DE/dmp5sT2dKnpOs4orZWzpAZqlCy8QqE/7g==", "requires": { "@babel/template": "^7.4.4", - "@babel/traverse": "^7.4.4", - "@babel/types": "^7.4.4" + "@babel/traverse": "^7.5.5", + "@babel/types": "^7.5.5" } }, "@babel/highlight": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.0.0.tgz", - "integrity": "sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.5.0.tgz", + "integrity": "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==", "requires": { "chalk": "^2.0.0", "esutils": "^2.0.2", @@ -464,9 +464,9 @@ } }, "@babel/parser": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.4.4.tgz", - "integrity": "sha512-5pCS4mOsL+ANsFZGdvNLybx4wtqAZJ0MJjMHxvzI3bvIsz6sQvzW8XX92EYIkiPtIvcfG3Aj+Ir5VNyjnZhP7w==" + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.5.5.tgz", + "integrity": "sha512-E5BN68cqR7dhKan1SfqgPGhQ178bkVKpXTPEXnFJBrEt8/DKRZlybmy+IgYLTeN7tp1R5Ccmbm2rBk17sHYU3g==" }, "@babel/plugin-proposal-async-generator-functions": { "version": "7.2.0", @@ -479,14 +479,23 @@ } }, "@babel/plugin-proposal-class-properties": { - "version": "7.4.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.4.0.tgz", - "integrity": "sha512-t2ECPNOXsIeK1JxJNKmgbzQtoG27KIlVE61vTqX0DKR9E9sZlVVxWUtEW9D5FlZ8b8j7SBNCHY47GgPKCKlpPg==", + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.4.4.tgz", + "integrity": "sha512-WjKTI8g8d5w1Bc9zgwSz2nfrsNQsXcCf9J9cdCvrJV6RF56yztwm4TmJC0MgJ9tvwO9gUA/mcYe89bLdGfiXFg==", "requires": { - "@babel/helper-create-class-features-plugin": "^7.4.0", + "@babel/helper-create-class-features-plugin": "^7.4.4", "@babel/helper-plugin-utils": "^7.0.0" } }, + "@babel/plugin-proposal-dynamic-import": { + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.5.0.tgz", + "integrity": "sha512-x/iMjggsKTFHYC6g11PL7Qy58IK8H5zqfm9e6hu4z1iH2IRyAp9u9dL80zA6R76yFovETFLKz2VJIC2iIPBuFw==", + "requires": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-syntax-dynamic-import": "^7.2.0" + } + }, "@babel/plugin-proposal-json-strings": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.2.0.tgz", @@ -532,6 +541,14 @@ "@babel/helper-plugin-utils": "^7.0.0" } }, + "@babel/plugin-syntax-dynamic-import": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.2.0.tgz", + "integrity": "sha512-mVxuJ0YroI/h/tbFTPGZR8cv6ai+STMKNBq0f8hFxsxWjl94qqhsb+wXbpNMDPU3cfR1TIsVFzU3nXyZMqyK4w==", + "requires": { + "@babel/helper-plugin-utils": "^7.0.0" + } + }, "@babel/plugin-syntax-json-strings": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.2.0.tgz", @@ -573,9 +590,9 @@ } }, "@babel/plugin-transform-async-to-generator": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.4.4.tgz", - "integrity": "sha512-YiqW2Li8TXmzgbXw+STsSqPBPFnGviiaSp6CYOq55X8GQ2SGVLrXB6pNid8HkqkZAzOH6knbai3snhP7v0fNwA==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.5.0.tgz", + "integrity": "sha512-mqvkzwIGkq0bEF1zLRRiTdjfomZJDV33AH3oQzHVGkI2VzEmXLpKKOBvEVaFZBJdN0XTyH38s9j/Kiqr68dggg==", "requires": { "@babel/helper-module-imports": "^7.0.0", "@babel/helper-plugin-utils": "^7.0.0", @@ -591,32 +608,32 @@ } }, "@babel/plugin-transform-block-scoping": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.4.4.tgz", - "integrity": "sha512-jkTUyWZcTrwxu5DD4rWz6rDB5Cjdmgz6z7M7RLXOJyCUkFBawssDGcGh8M/0FTSB87avyJI1HsTwUXp9nKA1PA==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.5.5.tgz", + "integrity": "sha512-82A3CLRRdYubkG85lKwhZB0WZoHxLGsJdux/cOVaJCJpvYFl1LVzAIFyRsa7CvXqW8rBM4Zf3Bfn8PHt5DP0Sg==", "requires": { "@babel/helper-plugin-utils": "^7.0.0", - "lodash": "^4.17.11" + "lodash": "^4.17.13" }, "dependencies": { "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" } } }, "@babel/plugin-transform-classes": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.4.4.tgz", - "integrity": "sha512-/e44eFLImEGIpL9qPxSRat13I5QNRgBLu2hOQJCF7VLy/otSM/sypV1+XaIw5+502RX/+6YaSAPmldk+nhHDPw==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.5.5.tgz", + "integrity": "sha512-U2htCNK/6e9K7jGyJ++1p5XRU+LJjrwtoiVn9SzRlDT2KubcZ11OOwy3s24TjHxPgxNwonCYP7U2K51uVYCMDg==", "requires": { "@babel/helper-annotate-as-pure": "^7.0.0", - "@babel/helper-define-map": "^7.4.4", + "@babel/helper-define-map": "^7.5.5", "@babel/helper-function-name": "^7.1.0", "@babel/helper-optimise-call-expression": "^7.0.0", "@babel/helper-plugin-utils": "^7.0.0", - "@babel/helper-replace-supers": "^7.4.4", + "@babel/helper-replace-supers": "^7.5.5", "@babel/helper-split-export-declaration": "^7.4.4", "globals": "^11.1.0" }, @@ -637,9 +654,9 @@ } }, "@babel/plugin-transform-destructuring": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.4.4.tgz", - "integrity": "sha512-/aOx+nW0w8eHiEHm+BTERB2oJn5D127iye/SUQl7NjHy0lf+j7h4MKMMSOwdazGq9OxgiNADncE+SRJkCxjZpQ==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.5.0.tgz", + "integrity": "sha512-YbYgbd3TryYYLGyC7ZR+Tq8H/+bCmwoaxHfJHupom5ECstzbRLTch6gOQbhEY9Z4hiCNHEURgq06ykFv9JZ/QQ==", "requires": { "@babel/helper-plugin-utils": "^7.0.0" } @@ -655,9 +672,9 @@ } }, "@babel/plugin-transform-duplicate-keys": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.2.0.tgz", - "integrity": "sha512-q+yuxW4DsTjNceUiTzK0L+AfQ0zD9rWaTLiUqHA8p0gxx7lu1EylenfzjeIWNkPy6e/0VG/Wjw9uf9LueQwLOw==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.5.0.tgz", + "integrity": "sha512-igcziksHizyQPlX9gfSjHkE2wmoCH3evvD2qR5w29/Dk0SMKE/eOI7f1HhBdNhR/zxJDqrgpoDTq5YSLH/XMsQ==", "requires": { "@babel/helper-plugin-utils": "^7.0.0" } @@ -705,31 +722,34 @@ } }, "@babel/plugin-transform-modules-amd": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.2.0.tgz", - "integrity": "sha512-mK2A8ucqz1qhrdqjS9VMIDfIvvT2thrEsIQzbaTdc5QFzhDjQv2CkJJ5f6BXIkgbmaoax3zBr2RyvV/8zeoUZw==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.5.0.tgz", + "integrity": "sha512-n20UsQMKnWrltocZZm24cRURxQnWIvsABPJlw/fvoy9c6AgHZzoelAIzajDHAQrDpuKFFPPcFGd7ChsYuIUMpg==", "requires": { "@babel/helper-module-transforms": "^7.1.0", - "@babel/helper-plugin-utils": "^7.0.0" + "@babel/helper-plugin-utils": "^7.0.0", + "babel-plugin-dynamic-import-node": "^2.3.0" } }, "@babel/plugin-transform-modules-commonjs": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.4.4.tgz", - "integrity": "sha512-4sfBOJt58sEo9a2BQXnZq+Q3ZTSAUXyK3E30o36BOGnJ+tvJ6YSxF0PG6kERvbeISgProodWuI9UVG3/FMY6iw==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.5.0.tgz", + "integrity": "sha512-xmHq0B+ytyrWJvQTc5OWAC4ii6Dhr0s22STOoydokG51JjWhyYo5mRPXoi+ZmtHQhZZwuXNN+GG5jy5UZZJxIQ==", "requires": { "@babel/helper-module-transforms": "^7.4.4", "@babel/helper-plugin-utils": "^7.0.0", - "@babel/helper-simple-access": "^7.1.0" + "@babel/helper-simple-access": "^7.1.0", + "babel-plugin-dynamic-import-node": "^2.3.0" } }, "@babel/plugin-transform-modules-systemjs": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.4.4.tgz", - "integrity": "sha512-MSiModfILQc3/oqnG7NrP1jHaSPryO6tA2kOMmAQApz5dayPxWiHqmq4sWH2xF5LcQK56LlbKByCd8Aah/OIkQ==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.5.0.tgz", + "integrity": "sha512-Q2m56tyoQWmuNGxEtUyeEkm6qJYFqs4c+XyXH5RAuYxObRNz9Zgj/1g2GMnjYp2EUyEy7YTrxliGCXzecl/vJg==", "requires": { "@babel/helper-hoist-variables": "^7.4.4", - "@babel/helper-plugin-utils": "^7.0.0" + "@babel/helper-plugin-utils": "^7.0.0", + "babel-plugin-dynamic-import-node": "^2.3.0" } }, "@babel/plugin-transform-modules-umd": { @@ -742,11 +762,11 @@ } }, "@babel/plugin-transform-named-capturing-groups-regex": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.4.4.tgz", - "integrity": "sha512-Ki+Y9nXBlKfhD+LXaRS7v95TtTGYRAf9Y1rTDiE75zf8YQz4GDaWRXosMfJBXxnk88mGFjWdCRIeqDbon7spYA==", + "version": "7.4.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.4.5.tgz", + "integrity": "sha512-z7+2IsWafTBbjNsOxU/Iv5CvTJlr5w4+HGu1HovKYTtgJ362f7kBcQglkfmlspKKZ3bgrbSGvLfNx++ZJgCWsg==", "requires": { - "regexp-tree": "^0.1.0" + "regexp-tree": "^0.1.6" } }, "@babel/plugin-transform-new-target": { @@ -758,12 +778,12 @@ } }, "@babel/plugin-transform-object-super": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.2.0.tgz", - "integrity": "sha512-VMyhPYZISFZAqAPVkiYb7dUe2AsVi2/wCT5+wZdsNO31FojQJa9ns40hzZ6U9f50Jlq4w6qwzdBB2uwqZ00ebg==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.5.5.tgz", + "integrity": "sha512-un1zJQAhSosGFBduPgN/YFNvWVpRuHKU7IHBglLoLZsGmruJPOo6pbInneflUdmq7YvSVqhpPs5zdBvLnteltQ==", "requires": { "@babel/helper-plugin-utils": "^7.0.0", - "@babel/helper-replace-supers": "^7.1.0" + "@babel/helper-replace-supers": "^7.5.5" } }, "@babel/plugin-transform-parameters": { @@ -812,20 +832,20 @@ } }, "@babel/plugin-transform-react-jsx-source": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.2.0.tgz", - "integrity": "sha512-A32OkKTp4i5U6aE88GwwcuV4HAprUgHcTq0sSafLxjr6AW0QahrCRCjxogkbbcdtpbXkuTOlgpjophCxb6sh5g==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.5.0.tgz", + "integrity": "sha512-58Q+Jsy4IDCZx7kqEZuSDdam/1oW8OdDX8f+Loo6xyxdfg1yF0GE2XNJQSTZCaMol93+FBzpWiPEwtbMloAcPg==", "requires": { "@babel/helper-plugin-utils": "^7.0.0", "@babel/plugin-syntax-jsx": "^7.2.0" } }, "@babel/plugin-transform-regenerator": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.4.4.tgz", - "integrity": "sha512-Zz3w+pX1SI0KMIiqshFZkwnVGUhDZzpX2vtPzfJBKQQq8WsP/Xy9DNdELWivxcKOCX/Pywge4SiEaPaLtoDT4g==", + "version": "7.4.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.4.5.tgz", + "integrity": "sha512-gBKRh5qAaCWntnd09S8QC7r3auLCqq5DI6O0DlfoyDjslSBVqBibrMdsqO+Uhmx3+BlOmE/Kw1HFxmGbv0N9dA==", "requires": { - "regenerator-transform": "^0.13.4" + "regenerator-transform": "^0.14.0" } }, "@babel/plugin-transform-reserved-words": { @@ -889,60 +909,71 @@ } }, "@babel/preset-env": { - "version": "7.4.3", - "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.4.3.tgz", - "integrity": "sha512-FYbZdV12yHdJU5Z70cEg0f6lvtpZ8jFSDakTm7WXeJbLXh4R0ztGEu/SW7G1nJ2ZvKwDhz8YrbA84eYyprmGqw==", + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.5.4.tgz", + "integrity": "sha512-hFnFnouyRNiH1rL8YkX1ANCNAUVC8Djwdqfev8i1415tnAG+7hlA5zhZ0Q/3Q5gkop4HioIPbCEWAalqcbxRoQ==", "requires": { "@babel/helper-module-imports": "^7.0.0", "@babel/helper-plugin-utils": "^7.0.0", "@babel/plugin-proposal-async-generator-functions": "^7.2.0", + "@babel/plugin-proposal-dynamic-import": "^7.5.0", "@babel/plugin-proposal-json-strings": "^7.2.0", - "@babel/plugin-proposal-object-rest-spread": "^7.4.3", + "@babel/plugin-proposal-object-rest-spread": "^7.5.4", "@babel/plugin-proposal-optional-catch-binding": "^7.2.0", - "@babel/plugin-proposal-unicode-property-regex": "^7.4.0", + "@babel/plugin-proposal-unicode-property-regex": "^7.4.4", "@babel/plugin-syntax-async-generators": "^7.2.0", + "@babel/plugin-syntax-dynamic-import": "^7.2.0", "@babel/plugin-syntax-json-strings": "^7.2.0", "@babel/plugin-syntax-object-rest-spread": "^7.2.0", "@babel/plugin-syntax-optional-catch-binding": "^7.2.0", "@babel/plugin-transform-arrow-functions": "^7.2.0", - "@babel/plugin-transform-async-to-generator": "^7.4.0", + "@babel/plugin-transform-async-to-generator": "^7.5.0", "@babel/plugin-transform-block-scoped-functions": "^7.2.0", - "@babel/plugin-transform-block-scoping": "^7.4.0", - "@babel/plugin-transform-classes": "^7.4.3", + "@babel/plugin-transform-block-scoping": "^7.4.4", + "@babel/plugin-transform-classes": "^7.4.4", "@babel/plugin-transform-computed-properties": "^7.2.0", - "@babel/plugin-transform-destructuring": "^7.4.3", - "@babel/plugin-transform-dotall-regex": "^7.4.3", - "@babel/plugin-transform-duplicate-keys": "^7.2.0", + "@babel/plugin-transform-destructuring": "^7.5.0", + "@babel/plugin-transform-dotall-regex": "^7.4.4", + "@babel/plugin-transform-duplicate-keys": "^7.5.0", "@babel/plugin-transform-exponentiation-operator": "^7.2.0", - "@babel/plugin-transform-for-of": "^7.4.3", - "@babel/plugin-transform-function-name": "^7.4.3", + "@babel/plugin-transform-for-of": "^7.4.4", + "@babel/plugin-transform-function-name": "^7.4.4", "@babel/plugin-transform-literals": "^7.2.0", "@babel/plugin-transform-member-expression-literals": "^7.2.0", - "@babel/plugin-transform-modules-amd": "^7.2.0", - "@babel/plugin-transform-modules-commonjs": "^7.4.3", - "@babel/plugin-transform-modules-systemjs": "^7.4.0", + "@babel/plugin-transform-modules-amd": "^7.5.0", + "@babel/plugin-transform-modules-commonjs": "^7.5.0", + "@babel/plugin-transform-modules-systemjs": "^7.5.0", "@babel/plugin-transform-modules-umd": "^7.2.0", - "@babel/plugin-transform-named-capturing-groups-regex": "^7.4.2", - "@babel/plugin-transform-new-target": "^7.4.0", + "@babel/plugin-transform-named-capturing-groups-regex": "^7.4.5", + "@babel/plugin-transform-new-target": "^7.4.4", "@babel/plugin-transform-object-super": "^7.2.0", - "@babel/plugin-transform-parameters": "^7.4.3", + "@babel/plugin-transform-parameters": "^7.4.4", "@babel/plugin-transform-property-literals": "^7.2.0", - "@babel/plugin-transform-regenerator": "^7.4.3", + "@babel/plugin-transform-regenerator": "^7.4.5", "@babel/plugin-transform-reserved-words": "^7.2.0", "@babel/plugin-transform-shorthand-properties": "^7.2.0", "@babel/plugin-transform-spread": "^7.2.0", "@babel/plugin-transform-sticky-regex": "^7.2.0", - "@babel/plugin-transform-template-literals": "^7.2.0", + "@babel/plugin-transform-template-literals": "^7.4.4", "@babel/plugin-transform-typeof-symbol": "^7.2.0", - "@babel/plugin-transform-unicode-regex": "^7.4.3", - "@babel/types": "^7.4.0", - "browserslist": "^4.5.2", - "core-js-compat": "^3.0.0", + "@babel/plugin-transform-unicode-regex": "^7.4.4", + "@babel/types": "^7.5.0", + "browserslist": "^4.6.0", + "core-js-compat": "^3.1.1", "invariant": "^2.2.2", "js-levenshtein": "^1.1.3", "semver": "^5.5.0" }, "dependencies": { + "@babel/plugin-proposal-object-rest-spread": { + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.5.5.tgz", + "integrity": "sha512-F2DxJJSQ7f64FyTVl5cw/9MWn6naXGdk3Q3UhDbFEEHv+EilCPoeRD3Zh/Utx1CJz4uyKlQ4uH+bJPbEhMV7Zw==", + "requires": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-syntax-object-rest-spread": "^7.2.0" + } + }, "semver": { "version": "5.7.0", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz", @@ -963,9 +994,9 @@ } }, "@babel/runtime": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.4.4.tgz", - "integrity": "sha512-w0+uT71b6Yi7i5SE0co4NioIpSYS6lLiXvCzWzGSKvpK5vdQtCbICHMj+gbAKAOtxiV6HsVh/MBdaF9EQ6faSg==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.5.5.tgz", + "integrity": "sha512-28QvEGyQyNkB0/m2B4FU7IEZGK2NUrcMtT6BZEFALTguLk+AUT6ofsHtPk5QyjAdUkpMJ+/Em+quwz4HOt30AQ==", "requires": { "regenerator-runtime": "^0.13.2" } @@ -981,29 +1012,29 @@ } }, "@babel/traverse": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.4.4.tgz", - "integrity": "sha512-Gw6qqkw/e6AGzlyj9KnkabJX7VcubqPtkUQVAwkc0wUMldr3A/hezNB3Rc5eIvId95iSGkGIOe5hh1kMKf951A==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.5.5.tgz", + "integrity": "sha512-MqB0782whsfffYfSjH4TM+LMjrJnhCNEDMDIjeTpl+ASaUvxcjoiVCo/sM1GhS1pHOXYfWVCYneLjMckuUxDaQ==", "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/generator": "^7.4.4", + "@babel/code-frame": "^7.5.5", + "@babel/generator": "^7.5.5", "@babel/helper-function-name": "^7.1.0", "@babel/helper-split-export-declaration": "^7.4.4", - "@babel/parser": "^7.4.4", - "@babel/types": "^7.4.4", + "@babel/parser": "^7.5.5", + "@babel/types": "^7.5.5", "debug": "^4.1.0", "globals": "^11.1.0", - "lodash": "^4.17.11" + "lodash": "^4.17.13" }, "dependencies": { "@babel/generator": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.4.4.tgz", - "integrity": "sha512-53UOLK6TVNqKxf7RUh8NE851EHRxOOeVXKbK2bivdb+iziMyk03Sr4eaE9OELCbyZAAafAKPDwF2TPUES5QbxQ==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.5.5.tgz", + "integrity": "sha512-ETI/4vyTSxTzGnU2c49XHv2zhExkv9JHLTwDAFz85kmcwuShvYG2H08FwgIguQf4JC75CBnXAUM5PqeF4fj0nQ==", "requires": { - "@babel/types": "^7.4.4", + "@babel/types": "^7.5.5", "jsesc": "^2.5.1", - "lodash": "^4.17.11", + "lodash": "^4.17.13", "source-map": "^0.5.0", "trim-right": "^1.0.1" } @@ -1027,14 +1058,14 @@ "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==" }, "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" }, "ms": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", - "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" }, "source-map": { "version": "0.5.7", @@ -1044,19 +1075,19 @@ } }, "@babel/types": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.4.4.tgz", - "integrity": "sha512-dOllgYdnEFOebhkKCjzSVFqw/PmmB8pH6RGOWkY4GsboQNd47b1fBThBSwlHAq9alF9vc1M3+6oqR47R50L0tQ==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.5.5.tgz", + "integrity": "sha512-s63F9nJioLqOlW3UkyMd+BYhXt44YuaFm/VV0VwuteqjYwRrObkU7ra9pY4wAJR3oXi8hJrMcrcJdO/HH33vtw==", "requires": { "esutils": "^2.0.2", - "lodash": "^4.17.11", + "lodash": "^4.17.13", "to-fast-properties": "^2.0.0" }, "dependencies": { "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==" }, "to-fast-properties": { "version": "2.0.0", @@ -1490,6 +1521,14 @@ "resolved": "https://registry.npmjs.org/babel-plugin-dead-code-elimination/-/babel-plugin-dead-code-elimination-1.0.2.tgz", "integrity": "sha1-X3xFEnTc18zNv7s+C4XdKBIfD2U=" }, + "babel-plugin-dynamic-import-node": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.0.tgz", + "integrity": "sha512-o6qFkpeQEBxcqt0XYlWzAVxNCSCZdUgcR8IRlhD/8DylxjjO4foPcvTW0GGKa/cVt3rvxZ7o5ippJ+/0nvLhlQ==", + "requires": { + "object.assign": "^4.1.0" + } + }, "babel-plugin-eval": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/babel-plugin-eval/-/babel-plugin-eval-1.0.1.tgz", @@ -1506,9 +1545,9 @@ "integrity": "sha1-jzQsOCduh6R9X6CovT1etsytj8w=" }, "babel-plugin-macros": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/babel-plugin-macros/-/babel-plugin-macros-2.5.1.tgz", - "integrity": "sha512-xN3KhAxPzsJ6OQTktCanNpIFnnMsCV+t8OloKxIL72D6+SUZYFn9qfklPgef5HyyDtzYZqqb+fs1S12+gQY82Q==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/babel-plugin-macros/-/babel-plugin-macros-2.6.1.tgz", + "integrity": "sha512-6W2nwiXme6j1n2erPOnmRiWfObUhWH7Qw1LMi9XZy8cj+KtESu3T6asZvtk5bMQQjX8te35o7CFueiSdL/2NmQ==", "requires": { "@babel/runtime": "^7.4.2", "cosmiconfig": "^5.2.0", @@ -1521,9 +1560,9 @@ "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==" }, "resolve": { - "version": "1.10.1", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.10.1.tgz", - "integrity": "sha512-KuIe4mf++td/eFb6wkaPbMDnP6kObCaEtIDuHOUED6MNUo4K670KZUHuuvYPZDxNF0WVLw49n06M2m2dXphEzA==", + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.11.1.tgz", + "integrity": "sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw==", "requires": { "path-parse": "^1.0.6" } @@ -1701,13 +1740,13 @@ "integrity": "sha1-eEp5eRWjjq0nutRWtVcstLuqeME=" }, "browserslist": { - "version": "4.5.6", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.5.6.tgz", - "integrity": "sha512-o/hPOtbU9oX507lIqon+UvPYqpx3mHc8cV3QemSBTXwkG8gSQSK6UKvXcE/DcleU3+A59XTUHyCvZ5qGy8xVAg==", + "version": "4.6.6", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.6.6.tgz", + "integrity": "sha512-D2Nk3W9JL9Fp/gIcWei8LrERCS+eXu9AM5cfXA8WEZ84lFks+ARnZ0q/R69m2SV3Wjma83QDDPxsNKXUwdIsyA==", "requires": { - "caniuse-lite": "^1.0.30000963", - "electron-to-chromium": "^1.3.127", - "node-releases": "^1.1.17" + "caniuse-lite": "^1.0.30000984", + "electron-to-chromium": "^1.3.191", + "node-releases": "^1.1.25" } }, "buffer-alloc": { @@ -1771,9 +1810,9 @@ "integrity": "sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8=" }, "caniuse-lite": { - "version": "1.0.30000967", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30000967.tgz", - "integrity": "sha512-rUBIbap+VJfxTzrM4akJ00lkvVb5/n5v3EGXfWzSH5zT8aJmGzjA8HWhJ4U6kCpzxozUSnB+yvAYDRPY6mRpgQ==" + "version": "1.0.30000984", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30000984.tgz", + "integrity": "sha512-n5tKOjMaZ1fksIpQbjERuqCyfgec/m9pferkFQbLmWtqLUdmt12hNhjSwsmPdqeiG2NkITOQhr1VYIwWSAceiA==" }, "caseless": { "version": "0.12.0", @@ -2095,32 +2134,26 @@ "integrity": "sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY=" }, "core-js-compat": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.0.1.tgz", - "integrity": "sha512-2pC3e+Ht/1/gD7Sim/sqzvRplMiRnFQVlPpDVaHtY9l7zZP7knamr3VRD6NyGfHd84MrDC0tAM9ulNxYMW0T3g==", + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.1.4.tgz", + "integrity": "sha512-Z5zbO9f1d0YrJdoaQhphVAnKPimX92D6z8lCGphH89MNRxlL1prI9ExJPqVwP0/kgkQCv8c4GJGT8X16yUncOg==", "requires": { - "browserslist": "^4.5.4", - "core-js": "3.0.1", - "core-js-pure": "3.0.1", - "semver": "^6.0.0" + "browserslist": "^4.6.2", + "core-js-pure": "3.1.4", + "semver": "^6.1.1" }, "dependencies": { - "core-js": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.0.1.tgz", - "integrity": "sha512-sco40rF+2KlE0ROMvydjkrVMMG1vYilP2ALoRXcYR4obqbYIuV3Bg+51GEDW+HF8n7NRA+iaA4qD0nD9lo9mew==" - }, "semver": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.0.0.tgz", - "integrity": "sha512-0UewU+9rFapKFnlbirLi3byoOuhrSsli/z/ihNnvM24vgF+8sNBiI1LZPBSH9wJKUwaUbw+s3hToDLCXkrghrQ==" + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.2.0.tgz", + "integrity": "sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A==" } } }, "core-js-pure": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/core-js-pure/-/core-js-pure-3.0.1.tgz", - "integrity": "sha512-mSxeQ6IghKW3MoyF4cz19GJ1cMm7761ON+WObSyLfTu/Jn3x7w4NwNFnrZxgl4MTSvYYepVLNuRtlB4loMwJ5g==" + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/core-js-pure/-/core-js-pure-3.1.4.tgz", + "integrity": "sha512-uJ4Z7iPNwiu1foygbcZYJsJs1jiXrTTCvxfLDXNhI/I+NHbSIEyr548y4fcsCEyWY0XgfAG/qqaunJ1SThHenA==" }, "core-util-is": { "version": "1.0.2", @@ -2128,13 +2161,13 @@ "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" }, "cosmiconfig": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-5.2.0.tgz", - "integrity": "sha512-nxt+Nfc3JAqf4WIWd0jXLjTJZmsPLrA9DDc4nRw2KFJQJK7DNooqSXrNI7tzLG50CF8axczly5UV929tBmh/7g==", + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-5.2.1.tgz", + "integrity": "sha512-H65gsXo1SKjf8zmrJ67eJk8aIRKV5ff2D4uKZIBZShbhGSpEmsQOPW/SKMKYhSTrqR7ufy6RP69rPogdaPh/kA==", "requires": { "import-fresh": "^2.0.0", "is-directory": "^0.3.1", - "js-yaml": "^3.13.0", + "js-yaml": "^3.13.1", "parse-json": "^4.0.0" }, "dependencies": { @@ -2294,6 +2327,14 @@ "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", "integrity": "sha1-xPp8lUBKF6nD6Mp+FTcxK3NjMKw=" }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "requires": { + "object-keys": "^1.0.12" + } + }, "defined": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.0.tgz", @@ -2524,9 +2565,9 @@ } }, "electron-to-chromium": { - "version": "1.3.133", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.133.tgz", - "integrity": "sha512-lyoC8aoqbbDqsprb6aPdt9n3DpOZZzdz/T4IZKsR0/dkZIxnJVUjjcpOSwA66jPRIOyDAamCTAUqweU05kKNSg==" + "version": "1.3.194", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.194.tgz", + "integrity": "sha512-w0LHR2YD9Ex1o+Sz4IN2hYzCB8vaFtMNW+yJcBf6SZlVqgFahkne/4rGVJdk4fPF98Gch9snY7PiabOh+vqHNg==" }, "emissary": { "version": "1.3.3", @@ -2731,6 +2772,11 @@ } } }, + "expand-template": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", + "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==" + }, "extend": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", @@ -2768,9 +2814,9 @@ }, "dependencies": { "core-js": { - "version": "2.6.5", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.5.tgz", - "integrity": "sha512-klh/kDpwX8hryYL14M9w/xei6vrv6sE8gTHDG7/T/+SEovB/G4ejwcfE/CBzO6Edsu+OETZMZ3wcX/EjUkrl5A==" + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.9.tgz", + "integrity": "sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A==" } } }, @@ -2965,9 +3011,9 @@ } }, "fs-minipass": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.5.tgz", - "integrity": "sha512-JhBl0skXjUPCFH7x6x61gQxrKyXsxB5gcgePLZCwfyCGGsTISMoIeObbrvVeP6Xmyaudw4TT43qV2Gz+iyd2oQ==", + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.6.tgz", + "integrity": "sha512-crhvyXcMejjv3Z5d2Fa9sf5xLYVCF5O1c71QxbVnbLsmYMBEvDAftewesN/HhY03YRoA7zOMxjNGrF5svGaaeQ==", "requires": { "minipass": "^2.2.1" } @@ -3023,6 +3069,11 @@ } } }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, "fuzzaldrin": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fuzzaldrin/-/fuzzaldrin-2.1.0.tgz", @@ -3165,32 +3216,34 @@ } }, "github": { - "version": "https://www.atom.io/api/packages/github/versions/0.29.0/tarball", - "integrity": "sha512-XlPinyfFjpsCEbEoZMspiJtrjwAVD/27kJJZWqRZhGxieAEO4wH6X/F5p5BoYbq3LfwMASIWEZXJ0pP5v1O/0Q==", + "version": "https://www.atom.io/api/packages/github/versions/0.30.0-0/tarball", + "integrity": "sha512-58jXqeyLYBBZR34SXRareYnwLCncVzT9LBhnPmUvcNRo39Mb8ez5M7YexUAFYPEf/YCes2oTK10K3Lhg2OVYZg==", "requires": { "@atom/babel-plugin-chai-assert-async": "1.0.0", "@atom/babel7-transpiler": "1.0.0-1", - "@babel/generator": "7.4.0", - "@babel/plugin-proposal-class-properties": "7.4.0", + "@babel/generator": "7.4.4", + "@babel/plugin-proposal-class-properties": "7.4.4", "@babel/plugin-proposal-object-rest-spread": "7.4.3", - "@babel/preset-env": "7.4.3", + "@babel/preset-env": "7.5.4", "@babel/preset-react": "7.0.0", "babel-plugin-relay": "3.0.0", "bintrees": "1.0.2", "bytes": "3.1.0", "classnames": "2.2.6", "compare-sets": "1.0.1", + "dompurify": "1.0.10", "dugite": "1.87.0", "event-kit": "2.5.3", "fs-extra": "4.0.3", - "graphql": "14.2.1", - "keytar": "4.4.1", + "graphql": "14.3.1", + "keytar": "4.10.0", "lodash.memoize": "4.1.2", + "marked": "0.6.2", "moment": "2.24.0", "node-emoji": "1.10.0", "prop-types": "15.7.2", - "react": "16.8.3", - "react-dom": "16.8.3", + "react": "16.8.6", + "react-dom": "16.8.6", "react-relay": "3.0.0", "react-select": "1.2.1", "react-tabs": "^3.0.0", @@ -3210,6 +3263,11 @@ "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz", "integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==" }, + "dompurify": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-1.0.10.tgz", + "integrity": "sha512-huhl3DSWX5LaA7jDtnj3XQdJgWW1wYouNW7N0drGzQa4vEUSVWyeFN+Atx6HP4r5cang6oQytMom6I4yhGJj5g==" + }, "fs-extra": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-4.0.3.tgz", @@ -3220,6 +3278,11 @@ "universalify": "^0.1.0" } }, + "marked": { + "version": "0.6.2", + "resolved": "https://registry.npmjs.org/marked/-/marked-0.6.2.tgz", + "integrity": "sha512-LqxwVH3P/rqKX4EKGz7+c2G9r98WeM/SW34ybhgNGhUQNKtf1GmmSkJ6cDGJ/t6tiyae49qRkpyTw2B9HOrgUA==" + }, "moment": { "version": "2.24.0", "resolved": "https://registry.npmjs.org/moment/-/moment-2.24.0.tgz", @@ -3278,9 +3341,9 @@ } }, "graphql": { - "version": "14.2.1", - "resolved": "https://registry.npmjs.org/graphql/-/graphql-14.2.1.tgz", - "integrity": "sha512-2PL1UbvKeSjy/lUeJqHk+eR9CvuErXoCNwJI4jm3oNFEeY+9ELqHNKO1ZuSxAkasPkpWbmT/iMRMFxd3cEL3tQ==", + "version": "14.3.1", + "resolved": "https://registry.npmjs.org/graphql/-/graphql-14.3.1.tgz", + "integrity": "sha512-FZm7kAa3FqKdXy8YSSpAoTtyDFMIYSpCDOr+3EqlI1bxmtHu+Vv/I2vrSeT1sBOEnEniX3uo4wFhFdS/8XN6gA==", "requires": { "iterall": "^1.2.2" } @@ -3325,6 +3388,11 @@ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=" }, + "has-symbols": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.0.tgz", + "integrity": "sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q=" + }, "has-unicode": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", @@ -3836,18 +3904,46 @@ } }, "keytar": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/keytar/-/keytar-4.4.1.tgz", - "integrity": "sha512-6xEe7ybXSR5EZC+z0GI2yqLYZjV1tyPQY2xSZ8rGsBxrrLEh8VR/Lfqv59uGX+I+W+OZxH0jCXN1dU1++ify4g==", + "version": "4.10.0", + "resolved": "https://registry.npmjs.org/keytar/-/keytar-4.10.0.tgz", + "integrity": "sha512-oL6dF4FMX8G80zL5e1CPIUEKwZCe9XZw6JZI5YesNstamzJbyZduj7NMUEX2l72BLyWQibyZOvipmof0QbsbRQ==", "requires": { - "nan": "2.12.1", - "prebuild-install": "5.2.4" + "nan": "2.14.0", + "prebuild-install": "5.3.0" }, "dependencies": { + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" + }, "nan": { - "version": "2.12.1", - "resolved": "https://registry.npmjs.org/nan/-/nan-2.12.1.tgz", - "integrity": "sha512-JY7V6lRkStKcKTvHO5NVSQRv+RV+FIL5pvDoLiAtSL9pKlC5x9PKQcZDsq7m4FO4d57mkhC6Z+QhAh3Jdk5JFw==" + "version": "2.14.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz", + "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==" + }, + "prebuild-install": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-5.3.0.tgz", + "integrity": "sha512-aaLVANlj4HgZweKttFNUVNRxDukytuIuxeK2boIMHjagNJCiVKWFsKF4tCE3ql3GbrD2tExPQ7/pwtEJcHNZeg==", + "requires": { + "detect-libc": "^1.0.3", + "expand-template": "^2.0.3", + "github-from-package": "0.0.0", + "minimist": "^1.2.0", + "mkdirp": "^0.5.1", + "napi-build-utils": "^1.0.1", + "node-abi": "^2.7.0", + "noop-logger": "^0.1.1", + "npmlog": "^4.0.1", + "os-homedir": "^1.0.1", + "pump": "^2.0.1", + "rc": "^1.2.7", + "simple-get": "^2.7.0", + "tar-fs": "^1.13.0", + "tunnel-agent": "^0.6.0", + "which-pm-runs": "^1.0.0" + } } } }, @@ -4755,6 +4851,21 @@ "resolved": "https://registry.npmjs.org/next-tick/-/next-tick-1.0.0.tgz", "integrity": "sha1-yobR/ogoFpsBICCOPchCS524NCw=" }, + "node-abi": { + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-2.9.0.tgz", + "integrity": "sha512-jmEOvv0eanWjhX8dX1pmjb7oJl1U1oR4FOh0b2GnvALwSYoOdU7sj+kLDSAyjo4pfC9aj/IxkloxdLJQhSSQBA==", + "requires": { + "semver": "^5.4.1" + }, + "dependencies": { + "semver": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz", + "integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==" + } + } + }, "node-emoji": { "version": "1.10.0", "resolved": "https://registry.npmjs.org/node-emoji/-/node-emoji-1.10.0.tgz", @@ -4773,9 +4884,9 @@ } }, "node-releases": { - "version": "1.1.18", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.18.tgz", - "integrity": "sha512-/mnVgm6u/8OwlIsoyRXtTI0RfQcxZoAZbdwyXap0EeWwcOpDDymyCHM2/aR9XKmHXrvizHoPAOs0pcbiJ6RUaA==", + "version": "1.1.25", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.25.tgz", + "integrity": "sha512-fI5BXuk83lKEoZDdH3gRhtsNgh05/wZacuXkgbiYkceE7+QIMXOg98n9ZV7mz27B+kFHnqHcUpscZZlGRSmTpQ==", "requires": { "semver": "^5.3.0" }, @@ -4892,6 +5003,22 @@ "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" + }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "requires": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + } + }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -5267,25 +5394,25 @@ } }, "react": { - "version": "16.8.3", - "resolved": "https://registry.npmjs.org/react/-/react-16.8.3.tgz", - "integrity": "sha512-3UoSIsEq8yTJuSu0luO1QQWYbgGEILm+eJl2QN/VLDi7hL+EN18M3q3oVZwmVzzBJ3DkM7RMdRwBmZZ+b4IzSA==", + "version": "16.8.6", + "resolved": "https://registry.npmjs.org/react/-/react-16.8.6.tgz", + "integrity": "sha512-pC0uMkhLaHm11ZSJULfOBqV4tIZkx87ZLvbbQYunNixAAvjnC+snJCg0XQXn9VIsttVsbZP/H/ewzgsd5fxKXw==", "requires": { "loose-envify": "^1.1.0", "object-assign": "^4.1.1", "prop-types": "^15.6.2", - "scheduler": "^0.13.3" + "scheduler": "^0.13.6" } }, "react-dom": { - "version": "16.8.3", - "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-16.8.3.tgz", - "integrity": "sha512-ttMem9yJL4/lpItZAQ2NTFAbV7frotHk5DZEHXUOws2rMmrsvh1Na7ThGT0dTzUIl6pqTOi5tYREfL8AEna3lA==", + "version": "16.8.6", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-16.8.6.tgz", + "integrity": "sha512-1nL7PIq9LTL3fthPqwkvr2zY7phIPjYrT0jp4HjyEQrEROnw4dG41VVwi/wfoCneoleqrNX7iAD+pXebJZwrwA==", "requires": { "loose-envify": "^1.1.0", "object-assign": "^4.1.1", "prop-types": "^15.6.2", - "scheduler": "^0.13.3" + "scheduler": "^0.13.6" } }, "react-input-autosize": { @@ -5375,9 +5502,9 @@ "integrity": "sha1-SoVuxLVuQHfFV1icroXnpMiGmhE=" }, "regenerate-unicode-properties": { - "version": "8.0.2", - "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-8.0.2.tgz", - "integrity": "sha512-SbA/iNrBUf6Pv2zU8Ekv1Qbhv92yxL4hiDa2siuxs4KKn4oOoMDHXjAf7+Nz9qinUQ46B1LcWEi/PhJfPWpZWQ==", + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-8.1.0.tgz", + "integrity": "sha512-LGZzkgtLY79GeXLm8Dp0BVLdQlWICzBnJz/ipWUgo59qBaZ+BHtq51P2q1uVZlppMuUAT37SDk39qUbjTWB7bA==", "requires": { "regenerate": "^1.4.0" } @@ -5401,17 +5528,17 @@ "integrity": "sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA==" }, "regenerator-transform": { - "version": "0.13.4", - "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.13.4.tgz", - "integrity": "sha512-T0QMBjK3J0MtxjPmdIMXm72Wvj2Abb0Bd4HADdfijwMdoIsyQZ6fWC7kDFhk2YinBBEMZDL7Y7wh0J1sGx3S4A==", + "version": "0.14.0", + "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.14.0.tgz", + "integrity": "sha512-rtOelq4Cawlbmq9xuMR5gdFmv7ku/sFoB7sRiywx7aq53bc52b4j6zvH7Te1Vt/X2YveDKnCGUbioieU7FEL3w==", "requires": { "private": "^0.1.6" } }, "regexp-tree": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/regexp-tree/-/regexp-tree-0.1.6.tgz", - "integrity": "sha512-LFrA98Dw/heXqDojz7qKFdygZmFoiVlvE1Zp7Cq2cvF+ZA+03Gmhy0k0PQlsC1jvHPiTUSs+pDHEuSWv6+6D7w==" + "version": "0.1.11", + "resolved": "https://registry.npmjs.org/regexp-tree/-/regexp-tree-0.1.11.tgz", + "integrity": "sha512-7/l/DgapVVDzZobwMCCgMlqiqyLFJ0cduo/j+3BcDJIB+yJdsYCfKuI3l/04NV+H/rfNRdPIDbXNZHM9XvQatg==" }, "regexpu": { "version": "1.3.0", @@ -6303,23 +6430,23 @@ } }, "tar": { - "version": "4.4.8", - "resolved": "https://registry.npmjs.org/tar/-/tar-4.4.8.tgz", - "integrity": "sha512-LzHF64s5chPQQS0IYBn9IN5h3i98c12bo4NCO7e0sGM2llXQ3p2FGC5sdENN4cTW48O915Sh+x+EXx7XW96xYQ==", + "version": "4.4.10", + "resolved": "https://registry.npmjs.org/tar/-/tar-4.4.10.tgz", + "integrity": "sha512-g2SVs5QIxvo6OLp0GudTqEf05maawKUxXru104iaayWA09551tFCTI8f1Asb4lPfkBr91k07iL4c11XO3/b0tA==", "requires": { "chownr": "^1.1.1", "fs-minipass": "^1.2.5", - "minipass": "^2.3.4", - "minizlib": "^1.1.1", + "minipass": "^2.3.5", + "minizlib": "^1.2.1", "mkdirp": "^0.5.0", "safe-buffer": "^5.1.2", - "yallist": "^3.0.2" + "yallist": "^3.0.3" }, "dependencies": { "chownr": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.1.tgz", - "integrity": "sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g==" + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.2.tgz", + "integrity": "sha512-GkfeAQh+QNy3wquu9oIZr6SS5x7wGdSgNQvD10X3r+AZr1Oys22HW8kAmDMvNg2+Dm0TeGaEuO8gFwdBXxwO8A==" } } }, @@ -6731,9 +6858,9 @@ } }, "ua-parser-js": { - "version": "0.7.19", - "resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-0.7.19.tgz", - "integrity": "sha512-T3PVJ6uz8i0HzPxOF9SWzWAlfN/DavlpQqepn22xgve/5QecC+XMCAtmUNnY7C9StehaV6exjUCI801lOI7QlQ==" + "version": "0.7.20", + "resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-0.7.20.tgz", + "integrity": "sha512-8OaIKfzL5cpx8eCMAhhvTlft8GYF8b2eQr6JkCyVdrgjcytyOmPCXrqXFcUnhonRpLlh5yxEZVohm6mzaowUOw==" }, "underscore": { "version": "1.8.3", diff --git a/package.json b/package.json index 529f8fa75..390aa5394 100644 --- a/package.json +++ b/package.json @@ -65,7 +65,7 @@ "fuzzy-finder": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.14.0/tarball", "git-diff": "file:packages/git-diff", "git-utils": "5.6.1", - "github": "https://www.atom.io/api/packages/github/versions/0.29.0/tarball", + "github": "https://www.atom.io/api/packages/github/versions/0.30.0-0/tarball", "glob": "^7.1.1", "go-to-line": "file:packages/go-to-line", "grammar-selector": "file:packages/grammar-selector", @@ -202,7 +202,7 @@ "exception-reporting": "file:./packages/exception-reporting", "find-and-replace": "0.219.0", "fuzzy-finder": "1.14.0", - "github": "0.29.0", + "github": "0.30.0-0", "git-diff": "file:./packages/git-diff", "go-to-line": "file:./packages/go-to-line", "grammar-selector": "file:./packages/grammar-selector", From 2f41ea979493c21d6577b85cff7b130420742c70 Mon Sep 17 00:00:00 2001 From: Ash Wilson Date: Thu, 18 Jul 2019 15:29:42 -0400 Subject: [PATCH 58/58] Minor version bump --- package-lock.json | 4 ++-- package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 7941ad0e2..63aa5613b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3216,8 +3216,8 @@ } }, "github": { - "version": "https://www.atom.io/api/packages/github/versions/0.30.0-0/tarball", - "integrity": "sha512-58jXqeyLYBBZR34SXRareYnwLCncVzT9LBhnPmUvcNRo39Mb8ez5M7YexUAFYPEf/YCes2oTK10K3Lhg2OVYZg==", + "version": "https://www.atom.io/api/packages/github/versions/0.30.0/tarball", + "integrity": "sha512-r2WbJS0YfUs2hmnLNcWQN4435A/1w5dvu8tVJLdPz1HZbDZOf4qA6AOA+z5vBPCi+JujXkEchZE69nE2S+ENhA==", "requires": { "@atom/babel-plugin-chai-assert-async": "1.0.0", "@atom/babel7-transpiler": "1.0.0-1", diff --git a/package.json b/package.json index 390aa5394..8d03a5482 100644 --- a/package.json +++ b/package.json @@ -65,7 +65,7 @@ "fuzzy-finder": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.14.0/tarball", "git-diff": "file:packages/git-diff", "git-utils": "5.6.1", - "github": "https://www.atom.io/api/packages/github/versions/0.30.0-0/tarball", + "github": "https://www.atom.io/api/packages/github/versions/0.30.0/tarball", "glob": "^7.1.1", "go-to-line": "file:packages/go-to-line", "grammar-selector": "file:packages/grammar-selector", @@ -202,7 +202,7 @@ "exception-reporting": "file:./packages/exception-reporting", "find-and-replace": "0.219.0", "fuzzy-finder": "1.14.0", - "github": "0.30.0-0", + "github": "0.30.0", "git-diff": "file:./packages/git-diff", "go-to-line": "file:./packages/go-to-line", "grammar-selector": "file:./packages/grammar-selector",