From 8e2e2620d36cd78ba887a79b8a209570a35df1c3 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 21 May 2019 17:26:00 +0200 Subject: [PATCH 01/29] Revert "Revert "Merge pull request #18916 from atom/electron-3.1"" This reverts commit 3da827b8b06128b2fbe94d5ee16d762871a7aa31. --- package.json | 2 +- script/lib/check-chromedriver-version.js | 12 ++++----- script/lib/generate-startup-snapshot.js | 34 +++++++++++++++++------- script/package-lock.json | 15 ++++++----- script/package.json | 4 +-- spec/theme-manager-spec.js | 4 +-- src/text-editor-component.js | 2 +- 7 files changed, 44 insertions(+), 29 deletions(-) diff --git a/package.json b/package.json index 5eb80f5c6..1ceefbc28 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "url": "https://github.com/atom/atom/issues" }, "license": "MIT", - "electronVersion": "2.0.18", + "electronVersion": "3.1.9", "dependencies": { "@atom/nsfw": "1.0.22", "@atom/source-map-support": "^0.3.4", diff --git a/script/lib/check-chromedriver-version.js b/script/lib/check-chromedriver-version.js index 1659f093c..f5cada045 100644 --- a/script/lib/check-chromedriver-version.js +++ b/script/lib/check-chromedriver-version.js @@ -5,17 +5,17 @@ const CONFIG = require('../config') const semver = require('semver') module.exports = function () { - // Chromedriver should be specified as ~x.y where x and y match Electron major/minor + // Chromedriver should be specified as ^n.x where n matches the Electron major version const chromedriverVer = buildMetadata.dependencies['electron-chromedriver'] const mksnapshotVer = buildMetadata.dependencies['electron-mksnapshot'] - // Always use tilde on electron-chromedriver so that it can pick up the best patch version - if (!chromedriverVer.startsWith('~')) { - throw new Error(`electron-chromedriver version in script/package.json should start with a tilde to match latest patch version.`) + // Always use caret on electron-chromedriver so that it can pick up the best minor/patch versions + if (!chromedriverVer.startsWith('^')) { + throw new Error(`electron-chromedriver version in script/package.json should start with a caret to match latest patch version.`) } - if (!mksnapshotVer.startsWith('~')) { - throw new Error(`electron-mksnapshot version in script/package.json should start with a tilde to match latest patch version.`) + if (!mksnapshotVer.startsWith('^')) { + throw new Error(`electron-mksnapshot version in script/package.json should start with a caret to match latest patch version.`) } const electronVer = CONFIG.appMetadata.electronVersion diff --git a/script/lib/generate-startup-snapshot.js b/script/lib/generate-startup-snapshot.js index c8cf02022..da87b3253 100644 --- a/script/lib/generate-startup-snapshot.js +++ b/script/lib/generate-startup-snapshot.js @@ -104,22 +104,36 @@ module.exports = function (packagedAppPath) { {env: Object.assign({}, process.env, {ELECTRON_RUN_AS_NODE: 1})} ) - const generatedStartupBlobPath = path.join(CONFIG.buildOutputPath, 'snapshot_blob.bin') - console.log(`Generating startup blob at "${generatedStartupBlobPath}"`) - childProcess.execFileSync( - path.join(CONFIG.repositoryRootPath, 'script', 'node_modules', 'electron-mksnapshot', 'bin', 'mksnapshot'), - ['--no-use_ic', snapshotScriptPath, '--startup_blob', generatedStartupBlobPath] + console.log('Generating startup blob with mksnapshot') + childProcess.spawnSync( + process.execPath, [ + path.join(CONFIG.repositoryRootPath, 'script', 'node_modules', 'electron-mksnapshot', 'mksnapshot.js'), + snapshotScriptPath, + '--output_dir', + CONFIG.buildOutputPath + ] ) let startupBlobDestinationPath if (process.platform === 'darwin') { - startupBlobDestinationPath = `${packagedAppPath}/Contents/Frameworks/Electron Framework.framework/Resources/snapshot_blob.bin` + startupBlobDestinationPath = `${packagedAppPath}/Contents/Frameworks/Electron Framework.framework/Resources` } else { - startupBlobDestinationPath = path.join(packagedAppPath, 'snapshot_blob.bin') + startupBlobDestinationPath = packagedAppPath } - console.log(`Moving generated startup blob into "${startupBlobDestinationPath}"`) - fs.unlinkSync(startupBlobDestinationPath) - fs.renameSync(generatedStartupBlobPath, startupBlobDestinationPath) + const snapshotBinaries = ['v8_context_snapshot.bin', 'snapshot_blob.bin'] + for (let snapshotBinary of snapshotBinaries) { + const destinationPath = path.join(startupBlobDestinationPath, snapshotBinary) + console.log(`Moving generated startup blob into "${destinationPath}"`) + try { + fs.unlinkSync(destinationPath) + } catch (err) { + // Doesn't matter if the file doesn't exist already + if (!err.code || err.code !== 'ENOENT') { + throw err + } + } + fs.renameSync(path.join(CONFIG.buildOutputPath, snapshotBinary), destinationPath) + } }) } diff --git a/script/package-lock.json b/script/package-lock.json index 4c8ad5fe2..8eddc0bdf 100644 --- a/script/package-lock.json +++ b/script/package-lock.json @@ -1912,9 +1912,9 @@ } }, "electron-chromedriver": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/electron-chromedriver/-/electron-chromedriver-2.0.0.tgz", - "integrity": "sha512-kERk/Wzhc9RzW9jUKXA5kJc4m8BlL6c9p5QH+CrIlst0saeqZL1Up7vzD4ZOnuBDpAVBBYJ4jhkAKIssf8ZlXg==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/electron-chromedriver/-/electron-chromedriver-3.0.0.tgz", + "integrity": "sha512-xWivZRiPTtDFJt+qXv7Ax/Dmhxj0iqESOxoLZ2szu3fv6k1vYDUDJUMHfdfVAke9D2gBRIgChuGb5j3YEt6hxQ==", "requires": { "electron-download": "^4.1.0", "extract-zip": "^1.6.5" @@ -2009,12 +2009,13 @@ } }, "electron-mksnapshot": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/electron-mksnapshot/-/electron-mksnapshot-2.0.0.tgz", - "integrity": "sha512-OoZwZJNKgHP+DwhCGVTJEuDSeb478hOzAbHeg7dKGCHDbKKmUWmjGc+pEjxGutpqQ3Mn8hCdLzdx2c/lAJcTLA==", + "version": "3.0.10", + "resolved": "https://registry.npmjs.org/electron-mksnapshot/-/electron-mksnapshot-3.0.10.tgz", + "integrity": "sha512-Toy6sAC3t9tgvq1kUYsx+4TRNPDj7Bzoo+1gx5FD8Q0YCS+tq+ter62Ot6dBXCKG9SwoaGBz84b++MgO0VobYw==", "requires": { "electron-download": "^4.1.0", - "extract-zip": "^1.6.5" + "extract-zip": "^1.6.5", + "temp": "^0.8.3" } }, "electron-osx-sign": { diff --git a/script/package.json b/script/package.json index 1076c63a9..933573368 100644 --- a/script/package.json +++ b/script/package.json @@ -10,9 +10,9 @@ "coffeelint": "1.15.7", "colors": "1.1.2", "donna": "1.0.16", - "electron-chromedriver": "~2.0", + "electron-chromedriver": "^3.0.0", "electron-link": "0.4.0", - "electron-mksnapshot": "~2.0", + "electron-mksnapshot": "^3.0.10", "electron-packager": "12.2.0", "electron-winstaller": "2.6.4", "eslint": "^5.16.0", diff --git a/spec/theme-manager-spec.js b/spec/theme-manager-spec.js index 2e4f74b50..a146d1486 100644 --- a/spec/theme-manager-spec.js +++ b/spec/theme-manager-spec.js @@ -319,9 +319,9 @@ h2 { it('returns a disposable allowing styles applied by the given path to be removed', function () { const cssPath = require.resolve('./fixtures/css.css') - expect(getComputedStyle(document.body).fontWeight).not.toBe('bold') + expect(getComputedStyle(document.body).fontWeight).not.toBe('700') const disposable = atom.themes.requireStylesheet(cssPath) - expect(getComputedStyle(document.body).fontWeight).toBe('bold') + expect(getComputedStyle(document.body).fontWeight).toBe('700') let styleElementRemovedHandler atom.styles.onDidRemoveStyleElement( diff --git a/src/text-editor-component.js b/src/text-editor-component.js index 7db399713..30af9fd38 100644 --- a/src/text-editor-component.js +++ b/src/text-editor-component.js @@ -4449,7 +4449,7 @@ class NodePool { if (element) { element.className = className || '' - element.styleMap.forEach((value, key) => { + element.attributeStyleMap.forEach((value, key) => { if (!style || style[key] == null) element.style[key] = '' }) if (style) Object.assign(element.style, style) From 4a1ff9982607b3c673dc1f01aee42b0810981ced Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 21 May 2019 20:12:25 +0200 Subject: [PATCH 02/29] :arrow_up: nsfw@1.0.23 --- package-lock.json | 19 ++++++++++++++++--- package.json | 2 +- script/package-lock.json | 4 +--- 3 files changed, 18 insertions(+), 7 deletions(-) diff --git a/package-lock.json b/package-lock.json index 9d60f3149..644d6f9e9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -456,11 +456,24 @@ } }, "@atom/nsfw": { - "version": "1.0.22", - "resolved": "https://registry.npmjs.org/@atom/nsfw/-/nsfw-1.0.22.tgz", - "integrity": "sha512-D1yp+X31Jed/2xkGXTurC9CGZO4d2WzEr5Rxi1elzv7bipqtIcM7HmxV0gK+WceeEj2+V1lrIINhU6mbXsJ69w==", + "version": "1.0.23", + "resolved": "https://registry.npmjs.org/@atom/nsfw/-/nsfw-1.0.23.tgz", + "integrity": "sha512-mo6G3eYzQzmdUWjCHO/2a4dWPPYYOZjAXjA4QtLGVXlnTMn08gC7JUEuztjAld1Qk+MYyV613O3ACj8xZ4KEog==", "requires": { + "fs-extra": "^7.0.0", "nan": "^2.10.0" + }, + "dependencies": { + "fs-extra": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-7.0.1.tgz", + "integrity": "sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==", + "requires": { + "graceful-fs": "^4.1.2", + "jsonfile": "^4.0.0", + "universalify": "^0.1.0" + } + } } }, "@atom/source-map-support": { diff --git a/package.json b/package.json index 1ceefbc28..59255e908 100644 --- a/package.json +++ b/package.json @@ -14,7 +14,7 @@ "license": "MIT", "electronVersion": "3.1.9", "dependencies": { - "@atom/nsfw": "1.0.22", + "@atom/nsfw": "1.0.23", "@atom/source-map-support": "^0.3.4", "@atom/watcher": "1.3.1", "about": "file:packages/about", diff --git a/script/package-lock.json b/script/package-lock.json index 8eddc0bdf..042db4275 100644 --- a/script/package-lock.json +++ b/script/package-lock.json @@ -901,7 +901,6 @@ "version": "0.4.2", "resolved": "https://registry.npmjs.org/boom/-/boom-0.4.2.tgz", "integrity": "sha1-emNune1O/O+xnO9JR6PGffrukRs=", - "optional": true, "requires": { "hoek": "0.9.x" } @@ -3992,8 +3991,7 @@ "hoek": { "version": "0.9.1", "resolved": "https://registry.npmjs.org/hoek/-/hoek-0.9.1.tgz", - "integrity": "sha1-PTIkYrrfB3Fup+uFuviAec3c5QU=", - "optional": true + "integrity": "sha1-PTIkYrrfB3Fup+uFuviAec3c5QU=" }, "home-or-tmp": { "version": "1.0.0", From b473adf994bcb34f6045ed20b0976a0e0070b27c Mon Sep 17 00:00:00 2001 From: Jason Rudolph Date: Fri, 24 May 2019 09:50:54 -0400 Subject: [PATCH 03/29] :arrow_up: language-python@0.53.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 30bde3375..1f7d0ad8a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4470,8 +4470,8 @@ "integrity": "sha512-HD6HI41u57i0/Tu9catiriURhJsef0RDrzJDkGDtdFkE9F9KPxC9Fayq2JBLJrhIyADRVXFxwxsfwQ2Jmh6hxg==" }, "language-python": { - "version": "https://www.atom.io/api/packages/language-python/versions/0.53.1/tarball", - "integrity": "sha512-yu2DU+Lqy0dzyMwzBIa6Oz6yvQiOeqwwnXl8Gbw4CasnTiAnEW9fk0wFOsUZOs1veqkZqP6Mdd5Zu7n5p1gLcw==", + "version": "https://www.atom.io/api/packages/language-python/versions/0.53.2/tarball", + "integrity": "sha512-ACNHWQWlRUfWrOb5MTvjP2wMTFdAq8Wnd3tWXYEd/TcfECtmCGy+6h33dt9X6SmAZz6OGKQ7V8lnVbOlh3X+Fw==", "requires": { "atom-grammar-test": "^0.6.4", "tree-sitter-python": "^0.14.0" diff --git a/package.json b/package.json index 724648a82..9eb0fad7a 100644 --- a/package.json +++ b/package.json @@ -97,7 +97,7 @@ "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-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.1/tarball", + "language-python": "https://www.atom.io/api/packages/language-python/versions/0.53.2/tarball", "language-ruby": "https://www.atom.io/api/packages/language-ruby/versions/0.72.16/tarball", "language-ruby-on-rails": "https://www.atom.io/api/packages/language-ruby-on-rails/versions/0.25.3/tarball", "language-rust-bundled": "file:packages/language-rust-bundled", @@ -249,7 +249,7 @@ "language-perl": "0.38.1", "language-php": "0.44.1", "language-property-list": "0.9.1", - "language-python": "0.53.1", + "language-python": "0.53.2", "language-ruby": "0.72.16", "language-ruby-on-rails": "0.25.3", "language-rust-bundled": "file:./packages/language-rust-bundled", From 17aa985f4e3f8694d3391bf0a14bdaa828754968 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Fri, 24 May 2019 18:55:18 +0200 Subject: [PATCH 04/29] Fix handling of binary files when using ripgrep scanner --- spec/fixtures/dir/file-detected-as-binary | 3 +++ spec/workspace-spec.js | 27 ++++++++++++++++++++++ src/ripgrep-directory-searcher.js | 28 ++++++++++++++++------- 3 files changed, 50 insertions(+), 8 deletions(-) create mode 100644 spec/fixtures/dir/file-detected-as-binary diff --git a/spec/fixtures/dir/file-detected-as-binary b/spec/fixtures/dir/file-detected-as-binary new file mode 100644 index 000000000..b1eaaa651 --- /dev/null +++ b/spec/fixtures/dir/file-detected-as-binary @@ -0,0 +1,3 @@ +asciiProperty=Foo +utf8Property=Fòò +latin1Property=Fòò diff --git a/spec/workspace-spec.js b/spec/workspace-spec.js index 4dd8fef54..06207861f 100644 --- a/spec/workspace-spec.js +++ b/spec/workspace-spec.js @@ -2669,6 +2669,33 @@ describe('Workspace', () => { }) }) + it('returns results on files detected as binary', async () => { + const results = [] + + await scan( + /asciiProperty=Foo/, + { + trailingContextLineCount: 2 + }, + result => results.push(result) + ) + expect(results.length).toBe(1) + const { filePath, matches } = results[0] + expect(filePath).toBe(atom.project.getDirectories()[0].resolve('file-detected-as-binary')) + expect(matches).toHaveLength(1) + expect(matches[0]).toEqual({ + matchText: 'asciiProperty=Foo', + lineText: 'asciiProperty=Foo', + lineTextOffset: 0, + range: [[0, 0], [0, 17]], + leadingContextLines: [], + trailingContextLines: [ + 'utf8Property=Fòò', + 'latin1Property=F��' + ] + }) + }) + describe('when the core.excludeVcsIgnoredPaths config is truthy', () => { let projectPath let ignoredPath diff --git a/src/ripgrep-directory-searcher.js b/src/ripgrep-directory-searcher.js index fd33d5a3a..4f162a9e9 100644 --- a/src/ripgrep-directory-searcher.js +++ b/src/ripgrep-directory-searcher.js @@ -50,7 +50,7 @@ function updateLeadingContext (message, pendingLeadingContext, options) { } if (options.leadingContextLineCount) { - pendingLeadingContext.push(cleanResultLine(message.data.lines.text)) + pendingLeadingContext.push(cleanResultLine(message.data.lines)) if (pendingLeadingContext.length > options.leadingContextLineCount) { pendingLeadingContext.shift() @@ -65,7 +65,7 @@ function updateTrailingContexts (message, pendingTrailingContexts, options) { if (options.trailingContextLineCount) { for (const trailingContextLines of pendingTrailingContexts) { - trailingContextLines.push(cleanResultLine(message.data.lines.text)) + trailingContextLines.push(cleanResultLine(message.data.lines)) if (trailingContextLines.length === options.trailingContextLineCount) { pendingTrailingContexts.delete(trailingContextLines) @@ -75,6 +75,8 @@ function updateTrailingContexts (message, pendingTrailingContexts, options) { } function cleanResultLine (resultLine) { + resultLine = getText(resultLine) + return resultLine[resultLine.length - 1] === '\n' ? resultLine.slice(0, -1) : resultLine } @@ -93,12 +95,14 @@ function getPositionFromColumn (lines, column) { } function processUnicodeMatch (match) { - if (match.lines.text.length === Buffer.byteLength(match.lines.text)) { + const text = getText(match.lines) + + if (text.length === Buffer.byteLength(text)) { // fast codepath for lines that only contain characters of 1 byte length. return } - let remainingBuffer = Buffer.from(match.lines.text) + let remainingBuffer = Buffer.from(text) let currentLength = 0 let previousPosition = 0 @@ -146,10 +150,18 @@ function processSubmatch (submatch, lineText, offsetRow) { return { range: [start, end], - lineText: cleanResultLine(lineParts.join('\n')) + lineText: cleanResultLine({ text: lineParts.join('\n') }) } } +function getText (input) { + if (input.text) { + return input.text + } + + return Buffer.from(input.bytes, 'base64').toString() +} + module.exports = class RipgrepDirectorySearcher { canSearchDirectory () { return true @@ -280,7 +292,7 @@ module.exports = class RipgrepDirectorySearcher { if (message.type === 'begin') { pendingEvent = { - filePath: message.data.path.text, + filePath: getText(message.data.path), matches: [] } pendingLeadingContext = [] @@ -294,12 +306,12 @@ module.exports = class RipgrepDirectorySearcher { for (const submatch of message.data.submatches) { const { lineText, range } = processSubmatch( submatch, - message.data.lines.text, + getText(message.data.lines), message.data.line_number - 1 ) pendingEvent.matches.push({ - matchText: submatch.match.text, + matchText: getText(submatch.match), lineText, lineTextOffset: 0, range, From f40880b0432f572ef811eca4137b38428f5c93fb Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Fri, 24 May 2019 11:29:43 -0600 Subject: [PATCH 05/29] Revert inadvertent changes to package-lock.json These were introduced for unknown reasons in fd82a58f1d6e851000e73e434de21b967920b194 Co-Authored-By: Jason Rudolph --- package-lock.json | 40 +++++++++++++++++++--------------------- 1 file changed, 19 insertions(+), 21 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1f7d0ad8a..51e2b02d8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1529,11 +1529,11 @@ "dependencies": { "etch": { "version": "0.9.0", - "resolved": false + "bundled": true }, "semver": { "version": "5.5.1", - "resolved": false + "bundled": true } } }, @@ -1819,11 +1819,11 @@ "dependencies": { "underscore": { "version": "1.9.1", - "resolved": false + "bundled": true }, "underscore-plus": { "version": "1.7.0", - "resolved": false, + "bundled": true, "requires": { "underscore": "^1.9.1" } @@ -2115,7 +2115,6 @@ "version": "2.10.1", "resolved": "https://registry.npmjs.org/boom/-/boom-2.10.1.tgz", "integrity": "sha1-OciRjO/1eZ+D+UkqhI9iWt0Mdm8=", - "optional": true, "requires": { "hoek": "2.x.x" } @@ -2675,7 +2674,7 @@ "dependencies": { "grim": { "version": "2.0.2", - "resolved": false, + "bundled": true, "requires": { "event-kit": "^2.0.0" } @@ -2828,22 +2827,22 @@ "dependencies": { "etch": { "version": "0.9.0", - "resolved": false + "bundled": true }, "grim": { "version": "2.0.2", - "resolved": false, + "bundled": true, "requires": { "event-kit": "^2.0.0" } }, "underscore": { "version": "1.9.1", - "resolved": false + "bundled": true }, "underscore-plus": { "version": "1.7.0", - "resolved": false, + "bundled": true, "requires": { "underscore": "^1.9.1" } @@ -3180,11 +3179,11 @@ "dependencies": { "underscore": { "version": "1.9.1", - "resolved": false + "bundled": true }, "underscore-plus": { "version": "1.7.0", - "resolved": false, + "bundled": true, "requires": { "underscore": "^1.9.1" } @@ -3656,11 +3655,11 @@ "dependencies": { "rimraf": { "version": "2.2.8", - "resolved": false + "bundled": true }, "temp": { "version": "0.8.3", - "resolved": false, + "bundled": true, "requires": { "os-tmpdir": "^1.0.0", "rimraf": "~2.2.6" @@ -3863,8 +3862,7 @@ "hoek": { "version": "2.16.3", "resolved": "https://registry.npmjs.org/hoek/-/hoek-2.16.3.tgz", - "integrity": "sha1-ILt0A9POo5jpHcRxCo/xuCdKJe0=", - "optional": true + "integrity": "sha1-ILt0A9POo5jpHcRxCo/xuCdKJe0=" }, "home-or-tmp": { "version": "1.0.0", @@ -4133,7 +4131,7 @@ "resolved": "https://registry.npmjs.org/jasmine-focused/-/jasmine-focused-1.0.7.tgz", "integrity": "sha1-uDx1fIAOaOHW78GjoaE/85/23NI=", "requires": { - "jasmine-node": "jasmine-node@git+https://github.com/kevinsawicki/jasmine-node.git#81af4f953a2b7dfb5bde8331c05362a4b464c5ef", + "jasmine-node": "git+https://github.com/kevinsawicki/jasmine-node.git#81af4f953a2b7dfb5bde8331c05362a4b464c5ef", "underscore-plus": "1.x", "walkdir": "0.0.7" } @@ -4716,11 +4714,11 @@ "dependencies": { "underscore": { "version": "1.9.1", - "resolved": false + "bundled": true }, "underscore-plus": { "version": "1.7.0", - "resolved": false, + "bundled": true, "requires": { "underscore": "^1.9.1" } @@ -4743,11 +4741,11 @@ "dependencies": { "underscore": { "version": "1.9.1", - "resolved": false + "bundled": true }, "underscore-plus": { "version": "1.7.0", - "resolved": false, + "bundled": true, "requires": { "underscore": "^1.9.1" } From ab90d08292acf8fe095fea6e921b9806996692a5 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Fri, 24 May 2019 19:39:07 +0200 Subject: [PATCH 06/29] Fix unrelated test --- spec/workspace-spec.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spec/workspace-spec.js b/spec/workspace-spec.js index 06207861f..1b84553b1 100644 --- a/spec/workspace-spec.js +++ b/spec/workspace-spec.js @@ -2424,7 +2424,7 @@ describe('Workspace', () => { results.sort((a, b) => a.filePath.localeCompare(b.filePath)) - expect(results).toHaveLength(3) + expect(results.length).toBeGreaterThan(0) expect(results[0].filePath).toBe( atom.project.getDirectories()[0].resolve('a') ) @@ -2804,7 +2804,7 @@ describe('Workspace', () => { await scan(/a|Elephant/, {}, result => results.push(result)) - expect(results).toHaveLength(3) + expect(results.length).toBeGreaterThan(0) const resultForA = _.find( results, ({ filePath }) => path.basename(filePath) === 'a' From 7ec394fa2e3142be756cfd13cadb264d13ef8b72 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Fri, 24 May 2019 12:42:54 -0600 Subject: [PATCH 07/29] :arrow_up: atom-keymap@8.2.13-0 to include atom/keyboard-layout#51 --- package-lock.json | 23 +++++++++++++++-------- package.json | 2 +- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/package-lock.json b/package-lock.json index 51e2b02d8..3f7a8283c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1709,16 +1709,16 @@ } }, "atom-keymap": { - "version": "8.2.13", - "resolved": "https://registry.npmjs.org/atom-keymap/-/atom-keymap-8.2.13.tgz", - "integrity": "sha512-RNf+5KbAiXpNV2KZT0+XYpTRFE8rhq7NrBryghJAOlwayY3g3z6Kp9tMfaPJ05BkPo9mChcaFO6SKUL8LTQcBg==", + "version": "8.2.13-0", + "resolved": "https://registry.npmjs.org/atom-keymap/-/atom-keymap-8.2.13-0.tgz", + "integrity": "sha512-VnMMDwaKTk3IPIb6bJUJDbM5wHsgL/IXbE/Qmrc4sMgdMf45jU6ZDPimHB8Ll6tmSQibh9LPv4zZ/hYgUuzSCQ==", "requires": { "clear-cut": "^2", "emissary": "^1.1.0", "event-kit": "^1.0.0", "fs-plus": "^3.0.0", "grim": "^1.2.1", - "keyboard-layout": "2.0.14", + "keyboard-layout": "2.0.15-0", "pathwatcher": "^8.0.0", "property-accessors": "^1", "season": "^6.0.2" @@ -4332,12 +4332,19 @@ } }, "keyboard-layout": { - "version": "2.0.14", - "resolved": "https://registry.npmjs.org/keyboard-layout/-/keyboard-layout-2.0.14.tgz", - "integrity": "sha512-QuCfpEC8oai6F8oaNQdxi5+1QIpaQu9HSVI9yzkC2HbIXeBnahzHFDRVGUtwwAWiNnzjNBjUI/djsrMGUTgK1w==", + "version": "2.0.15-0", + "resolved": "https://registry.npmjs.org/keyboard-layout/-/keyboard-layout-2.0.15-0.tgz", + "integrity": "sha512-FmNwOaqs0nxkLgSFEAzIczV3gpBedFJ4xl/djzpsxbT36v/cafixtvs2e0g9PNMUxyHTyC48qXMMTftuTT78tg==", "requires": { "event-kit": "^2.0.0", - "nan": "^2.10.0" + "nan": "^2.13.2" + }, + "dependencies": { + "nan": { + "version": "2.14.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz", + "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==" + } } }, "keytar": { diff --git a/package.json b/package.json index 9eb0fad7a..409671d0a 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,7 @@ "async": "0.2.6", "atom-dark-syntax": "file:packages/atom-dark-syntax", "atom-dark-ui": "file:packages/atom-dark-ui", - "atom-keymap": "8.2.13", + "atom-keymap": "8.2.13-0", "atom-light-syntax": "file:packages/atom-light-syntax", "atom-light-ui": "file:packages/atom-light-ui", "atom-select-list": "^0.7.2", From fc3aa8a7f0391c2654482b80577739c8ed77cc78 Mon Sep 17 00:00:00 2001 From: Nathan Sobo Date: Fri, 24 May 2019 16:15:25 -0600 Subject: [PATCH 08/29] :arrow_up: atom-keymap@8.2.14 --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3f7a8283c..081923db1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1709,16 +1709,16 @@ } }, "atom-keymap": { - "version": "8.2.13-0", - "resolved": "https://registry.npmjs.org/atom-keymap/-/atom-keymap-8.2.13-0.tgz", - "integrity": "sha512-VnMMDwaKTk3IPIb6bJUJDbM5wHsgL/IXbE/Qmrc4sMgdMf45jU6ZDPimHB8Ll6tmSQibh9LPv4zZ/hYgUuzSCQ==", + "version": "8.2.14", + "resolved": "https://registry.npmjs.org/atom-keymap/-/atom-keymap-8.2.14.tgz", + "integrity": "sha512-9ofjA8IG/RNJcqvMvYglc0l7DljavIUQvGs5xdEtd5dEYX4rCQo9coeBfGaC0YM7FB0SBHPZy39QYFROkOzTOw==", "requires": { "clear-cut": "^2", "emissary": "^1.1.0", "event-kit": "^1.0.0", "fs-plus": "^3.0.0", "grim": "^1.2.1", - "keyboard-layout": "2.0.15-0", + "keyboard-layout": "2.0.16", "pathwatcher": "^8.0.0", "property-accessors": "^1", "season": "^6.0.2" @@ -4332,9 +4332,9 @@ } }, "keyboard-layout": { - "version": "2.0.15-0", - "resolved": "https://registry.npmjs.org/keyboard-layout/-/keyboard-layout-2.0.15-0.tgz", - "integrity": "sha512-FmNwOaqs0nxkLgSFEAzIczV3gpBedFJ4xl/djzpsxbT36v/cafixtvs2e0g9PNMUxyHTyC48qXMMTftuTT78tg==", + "version": "2.0.16", + "resolved": "https://registry.npmjs.org/keyboard-layout/-/keyboard-layout-2.0.16.tgz", + "integrity": "sha512-eGrxmlV6jbm/mbPEOpYGuH53XEC7wIUj9ZxKcT2z9QHJ/RwrT9iVkvxka9zRxqHZHwQzcffgsa5OxoVAKnhK9w==", "requires": { "event-kit": "^2.0.0", "nan": "^2.13.2" diff --git a/package.json b/package.json index 409671d0a..a33e0d583 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,7 @@ "async": "0.2.6", "atom-dark-syntax": "file:packages/atom-dark-syntax", "atom-dark-ui": "file:packages/atom-dark-ui", - "atom-keymap": "8.2.13-0", + "atom-keymap": "8.2.14", "atom-light-syntax": "file:packages/atom-light-syntax", "atom-light-ui": "file:packages/atom-light-ui", "atom-select-list": "^0.7.2", From 14daa4bdc13ab563fb5c21762db8bea52dd27a76 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 27 May 2019 10:46:06 +0200 Subject: [PATCH 09/29] Use ternary instead of conditional --- src/ripgrep-directory-searcher.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/ripgrep-directory-searcher.js b/src/ripgrep-directory-searcher.js index 4f162a9e9..ffb0f8614 100644 --- a/src/ripgrep-directory-searcher.js +++ b/src/ripgrep-directory-searcher.js @@ -155,11 +155,7 @@ function processSubmatch (submatch, lineText, offsetRow) { } function getText (input) { - if (input.text) { - return input.text - } - - return Buffer.from(input.bytes, 'base64').toString() + return input.text ? input.text : Buffer.from(input.bytes, 'base64').toString() } module.exports = class RipgrepDirectorySearcher { From dc2df49b6096fc303ab0214ad22c3be7a10130a4 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 27 May 2019 10:55:53 +0200 Subject: [PATCH 10/29] Enable no-useless-escape eslint rule --- .eslintrc.json | 2 -- script/lib/test-sign-on-mac.js | 2 +- spec/style-manager-spec.js | 2 +- src/buffered-process.js | 6 +++--- src/main-process/squirrel-update.js | 8 ++++---- src/main-process/win-shell.js | 8 ++++---- 6 files changed, 13 insertions(+), 15 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 8a461266e..65916feea 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -24,8 +24,6 @@ }, "rules": { "standard/no-callback-literal": ["off"], - "no-mixed-operators": ["off"], - "no-useless-escape": ["off"], "no-return-await": ["off"], "node/no-deprecated-api": ["off"], "prefer-promise-reject-errors": ["off"], diff --git a/script/lib/test-sign-on-mac.js b/script/lib/test-sign-on-mac.js index 1cd0efadd..eb64b8c0d 100644 --- a/script/lib/test-sign-on-mac.js +++ b/script/lib/test-sign-on-mac.js @@ -6,7 +6,7 @@ module.exports = function (packagedAppPath) { 'find-certificate', '-c', 'Mac Developer' ]) - const certMatch = (result.stdout || '').toString().match(/\"(Mac Developer.*\))\"/) + const certMatch = (result.stdout || '').toString().match(/"(Mac Developer.*\))"/) if (!certMatch || !certMatch[1]) { console.error('A "Mac Developer" certificate must be configured to perform test signing') } else { diff --git a/spec/style-manager-spec.js b/spec/style-manager-spec.js index b27ea97ad..88560e989 100644 --- a/spec/style-manager-spec.js +++ b/spec/style-manager-spec.js @@ -57,7 +57,7 @@ describe('StyleManager', () => { atom-text-editor::shadow .class-1, atom-text-editor::shadow .class-2 { color: red } atom-text-editor::shadow > .class-3 { color: yellow } atom-text-editor .class-4 { color: blue } - atom-text-editor[data-grammar*=\"js\"]::shadow .class-6 { color: green; } + atom-text-editor[data-grammar*="js"]::shadow .class-6 { color: green; } atom-text-editor[mini].is-focused::shadow .class-7 { color: green; } `) expect( diff --git a/src/buffered-process.js b/src/buffered-process.js index c82c78fac..21872d7d4 100644 --- a/src/buffered-process.js +++ b/src/buffered-process.js @@ -88,18 +88,18 @@ class BufferedProcess { return arg } else { // Escape double quotes by putting a backslash in front of them - return `\"${arg.toString().replace(/"/g, '\\"')}\"` + return `"${arg.toString().replace(/"/g, '\\"')}"` } }) } // The command itself is quoted if it contains spaces, &, ^, | or # chars - cmdArgs.unshift(/\s|&|\^|\(|\)|\||#/.test(command) ? `\"${command}\"` : command) + cmdArgs.unshift(/\s|&|\^|\(|\)|\||#/.test(command) ? `"${command}"` : command) const cmdOptions = _.clone(options) cmdOptions.windowsVerbatimArguments = true - this.spawn(this.getCmdPath(), ['/s', '/d', '/c', `\"${cmdArgs.join(' ')}\"`], cmdOptions) + this.spawn(this.getCmdPath(), ['/s', '/d', '/c', `"${cmdArgs.join(' ')}"`], cmdOptions) } /* diff --git a/src/main-process/squirrel-update.js b/src/main-process/squirrel-update.js index 0d8174f47..deb25e4eb 100644 --- a/src/main-process/squirrel-update.js +++ b/src/main-process/squirrel-update.js @@ -34,19 +34,19 @@ const addCommandsToPath = callback => { const installCommands = callback => { const atomCommandPath = path.join(binFolder, 'atom.cmd') const relativeAtomPath = path.relative(binFolder, path.join(appFolder, 'resources', 'cli', 'atom.cmd')) - const atomCommand = `@echo off\r\n\"%~dp0\\${relativeAtomPath}\" %*` + 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 atomShCommand = `#!/bin/sh\r\n"$(dirname "$0")/${relativeAtomShPath.replace(/\\/g, '/')}" "$@"\r\necho` const apmCommandPath = path.join(binFolder, 'apm.cmd') const relativeApmPath = path.relative(binFolder, path.join(process.resourcesPath, 'app', 'apm', 'bin', 'apm.cmd')) - const apmCommand = `@echo off\r\n\"%~dp0\\${relativeApmPath}\" %*` + 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 apmShCommand = `#!/bin/sh\r\n"$(dirname "$0")/${relativeApmShPath.replace(/\\/g, '/')}" "$@"` fs.writeFile(atomCommandPath, atomCommand, () => fs.writeFile(atomShCommandPath, atomShCommand, () => diff --git a/src/main-process/win-shell.js b/src/main-process/win-shell.js index dd694b9dd..f27c2d6c0 100644 --- a/src/main-process/win-shell.js +++ b/src/main-process/win-shell.js @@ -2,8 +2,8 @@ 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 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', '') @@ -56,14 +56,14 @@ exports.appName = appName exports.fileHandler = new ShellOption(`\\Software\\Classes\\Applications\\${exeName}`, [ - {key: 'shell\\open\\command', name: '', value: `${appPath} \"%1\"`}, + {key: 'shell\\open\\command', name: '', value: `${appPath} "%1"`}, {key: 'shell\\open', name: 'FriendlyAppName', value: `${appName}`}, {key: 'DefaultIcon', name: '', value: `${fileIconPath}`} ] ) let contextParts = [ - {key: 'command', name: '', value: `${appPath} \"%1\"`}, + {key: 'command', name: '', value: `${appPath} "%1"`}, {name: '', value: `Open with ${appName}`}, {name: 'Icon', value: `${appPath}`} ] From 69fc4ad69a1fb495de95d7363651a6c098bfc8bf Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 27 May 2019 11:00:42 +0200 Subject: [PATCH 11/29] Enable no-return-await eslint rule --- .eslintrc.json | 1 - src/git-repository-provider.js | 4 ++-- src/main-process/atom-application.js | 2 +- src/pane.js | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 65916feea..4dcbf7651 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -24,7 +24,6 @@ }, "rules": { "standard/no-callback-literal": ["off"], - "no-return-await": ["off"], "node/no-deprecated-api": ["off"], "prefer-promise-reject-errors": ["off"], "no-unused-expressions": ["off"], diff --git a/src/git-repository-provider.js b/src/git-repository-provider.js index 9785a88ee..827523b71 100644 --- a/src/git-repository-provider.js +++ b/src/git-repository-provider.js @@ -87,7 +87,7 @@ async function findGitDirectory (directory) { } else if (directory.isRoot()) { return null } else { - return await findGitDirectory(directory.getParent()) + return findGitDirectory(directory.getParent()) } } @@ -117,7 +117,7 @@ async function isValidGitDirectory (directory) { return ( (await directory.getSubdirectory('objects').exists()) && (await directory.getFile('HEAD').exists()) && - (await directory.getSubdirectory('refs').exists()) + directory.getSubdirectory('refs').exists() ) } diff --git a/src/main-process/atom-application.js b/src/main-process/atom-application.js index e74a3d463..e66509e5e 100644 --- a/src/main-process/atom-application.js +++ b/src/main-process/atom-application.js @@ -1230,7 +1230,7 @@ class AtomApplication extends EventEmitter { } else if (state.version === undefined) { // Atom <= 1.36.0 // Schema: [{initialPaths: ['', ...]}, ...] - return await Promise.all( + return Promise.all( state.map(async windowState => { // Classify each window's initialPaths as directories or non-directories const classifiedPaths = await Promise.all( diff --git a/src/pane.js b/src/pane.js index 943a12589..ac36f39f7 100644 --- a/src/pane.js +++ b/src/pane.js @@ -949,7 +949,7 @@ class Pane { } }) - return await saveDialogPromise + return saveDialogPromise } // Public: Save all items. From 2139b4b936fee941ac4a0c97b4a371ab119244b8 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 27 May 2019 11:11:49 +0200 Subject: [PATCH 12/29] Enable prefer-promise-reject-errors eslint rule --- .eslintrc.json | 1 - spec/command-registry-spec.js | 2 +- src/default-directory-searcher.js | 2 +- src/path-watcher.js | 2 +- 4 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 4dcbf7651..97e7c65c3 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -25,7 +25,6 @@ "rules": { "standard/no-callback-literal": ["off"], "node/no-deprecated-api": ["off"], - "prefer-promise-reject-errors": ["off"], "no-unused-expressions": ["off"], "symbol-description": ["off"], "no-use-before-define": ["off"], diff --git a/spec/command-registry-spec.js b/spec/command-registry-spec.js index 597a72c35..86a5f7101 100644 --- a/spec/command-registry-spec.js +++ b/spec/command-registry-spec.js @@ -414,7 +414,7 @@ describe('CommandRegistry', () => { () => new Promise((resolve, reject) => { setTimeout(() => { - reject(3) + reject(3) // eslint-disable-line prefer-promise-reject-errors }, 1) }) ) diff --git a/src/default-directory-searcher.js b/src/default-directory-searcher.js index 2f0889b0a..5dca54a55 100644 --- a/src/default-directory-searcher.js +++ b/src/default-directory-searcher.js @@ -98,7 +98,7 @@ module.exports = class DefaultDirectorySearcher { if (isCancelled) { resolve() } else { - reject() + reject() // eslint-disable-line prefer-promise-reject-errors } }) }) diff --git a/src/path-watcher.js b/src/path-watcher.js index 6693489ef..0cde2f535 100644 --- a/src/path-watcher.js +++ b/src/path-watcher.js @@ -55,7 +55,7 @@ class NativeWatcher { } doStart () { - return Promise.reject('doStart() not overridden') + return Promise.reject(new Error('doStart() not overridden')) } // Private: Return true if the underlying watcher is actively listening for filesystem events. From 9abdb2f93a1526da1c6edb9018d2be346182e3be Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 27 May 2019 11:15:37 +0200 Subject: [PATCH 13/29] Enable no-unused-expressions eslint rule --- .eslintrc.json | 1 - spec/atom-environment-spec.js | 8 ++++---- src/compile-cache.js | 2 +- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 97e7c65c3..b1862f3b4 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -25,7 +25,6 @@ "rules": { "standard/no-callback-literal": ["off"], "node/no-deprecated-api": ["off"], - "no-unused-expressions": ["off"], "symbol-description": ["off"], "no-use-before-define": ["off"], "prettier/prettier": ["off"] // disable prettier rules for now. diff --git a/spec/atom-environment-spec.js b/spec/atom-environment-spec.js index 9a34bb009..989c23b95 100644 --- a/spec/atom-environment-spec.js +++ b/spec/atom-environment-spec.js @@ -66,7 +66,7 @@ describe('AtomEnvironment', () => { it('will open the dev tools when an error is triggered', async () => { try { - a + 1 // eslint-disable-line no-undef + a + 1 // eslint-disable-line no-undef, no-unused-expressions } catch (e) { window.onerror(e.toString(), 'abc', 2, 3, e) } @@ -87,7 +87,7 @@ describe('AtomEnvironment', () => { let error = null atom.onWillThrowError(willThrowSpy) try { - a + 1 // eslint-disable-line no-undef + a + 1 // eslint-disable-line no-undef, no-unused-expressions } catch (e) { error = e window.onerror(e.toString(), 'abc', 2, 3, e) @@ -108,7 +108,7 @@ describe('AtomEnvironment', () => { atom.onWillThrowError(willThrowSpy) try { - a + 1 // eslint-disable-line no-undef + a + 1 // eslint-disable-line no-undef, no-unused-expressions } catch (e) { window.onerror(e.toString(), 'abc', 2, 3, e) } @@ -127,7 +127,7 @@ describe('AtomEnvironment', () => { let error = null atom.onDidThrowError(didThrowSpy) try { - a + 1 // eslint-disable-line no-undef + a + 1 // eslint-disable-line no-undef, no-unused-expressions } catch (e) { error = e window.onerror(e.toString(), 'abc', 2, 3, e) diff --git a/src/compile-cache.js b/src/compile-cache.js index f2f5aade3..bf9a0771c 100644 --- a/src/compile-cache.js +++ b/src/compile-cache.js @@ -221,7 +221,7 @@ exports.install = function (resourcesPath, nodeRequire) { Error.prototype.getRawStack = function () { // Access this.stack to ensure prepareStackTrace has been run on this error // because it assigns this.rawStack as a side-effect - this.stack + this.stack // eslint-disable-line no-unused-expressions return this.rawStack } From a14b3a5dddbf00d1ede4d44c415a2a5a06012bf4 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 27 May 2019 11:17:29 +0200 Subject: [PATCH 14/29] Enable symbol-description eslint rule --- .eslintrc.json | 1 - spec/atom-environment-spec.js | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index b1862f3b4..a40e0e994 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -25,7 +25,6 @@ "rules": { "standard/no-callback-literal": ["off"], "node/no-deprecated-api": ["off"], - "symbol-description": ["off"], "no-use-before-define": ["off"], "prettier/prettier": ["off"] // disable prettier rules for now. }, diff --git a/spec/atom-environment-spec.js b/spec/atom-environment-spec.js index 989c23b95..5ca2a8761 100644 --- a/spec/atom-environment-spec.js +++ b/spec/atom-environment-spec.js @@ -545,7 +545,7 @@ describe('AtomEnvironment', () => { spyOn(atom, 'confirm').andReturn(1) spyOn(atom.project, 'addPath') spyOn(atom.workspace, 'open') - const state = Symbol() + const state = Symbol('state') atom.attemptRestoreProjectStateForPaths( state, [__dirname], @@ -560,7 +560,7 @@ describe('AtomEnvironment', () => { spyOn(atom, 'confirm').andCallFake((options, callback) => callback(1)) spyOn(atom.project, 'addPath') spyOn(atom.workspace, 'open') - const state = Symbol() + const state = Symbol('state') atom.attemptRestoreProjectStateForPaths( state, @@ -579,7 +579,7 @@ describe('AtomEnvironment', () => { jasmine.useRealClock() spyOn(atom, 'confirm').andCallFake((options, callback) => callback(0)) spyOn(atom, 'open') - const state = Symbol() + const state = Symbol('state') atom.attemptRestoreProjectStateForPaths( state, From 34dcd205e114c45f6f8ac74f1cc6138242efeed2 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Mon, 27 May 2019 11:24:12 +0200 Subject: [PATCH 15/29] Enable no-use-before-define eslint rule The changed codepath seems to be an unintentional mistake which was added in https://github.com/atom/atom/commit/5c1a49fccf291b229cee1c76faf52e590249784d I cannot see any reason to set a default argument to itself: this is going to cause a ReferenceError when calling that function without that argument and I guess if that was the intended behaviour the author would have added an explicit check at the beginning of the function (or at least a comment). --- .eslintrc.json | 1 - src/tree-sitter-language-mode.js | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index a40e0e994..3050b2b9e 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -25,7 +25,6 @@ "rules": { "standard/no-callback-literal": ["off"], "node/no-deprecated-api": ["off"], - "no-use-before-define": ["off"], "prettier/prettier": ["off"] // disable prettier rules for now. }, "overrides": [ diff --git a/src/tree-sitter-language-mode.js b/src/tree-sitter-language-mode.js index f0645c580..d282e083c 100644 --- a/src/tree-sitter-language-mode.js +++ b/src/tree-sitter-language-mode.js @@ -197,7 +197,7 @@ class TreeSitterLanguageMode { ) } - indentLevelForLine (line, tabLength = tabLength) { + indentLevelForLine (line, tabLength) { let indentLength = 0 for (let i = 0, {length} = line; i < length; i++) { const char = line[i] From 95fe9527d9580445ae74b3a40f71ca9dfe944962 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Mon, 27 May 2019 12:32:54 +0200 Subject: [PATCH 16/29] Don't create a promise when preloading package settings in snapshot Promise creation is forbidden within `mksnapshot` (see https://github.com/electron/libchromiumcontent/pull/363, https://github.com/nodejs/node/pull/13242 and https://github.com/electron/electron/issues/18420). Since preloading a package's settings is a synchronous action anyway, we just avoid instantiating a new Promise when calling `loadSettings`. --- src/package.js | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/src/package.js b/src/package.js index 56764a86a..37afb30b5 100644 --- a/src/package.js +++ b/src/package.js @@ -648,16 +648,15 @@ class Package { }) } - return new Promise(resolve => { - if (this.preloadedPackage && this.packageManager.packagesCache[this.name]) { - for (let settingsPath in this.packageManager.packagesCache[this.name].settings) { - const properties = this.packageManager.packagesCache[this.name].settings[settingsPath] - const settingsFile = new SettingsFile(`core:${settingsPath}`, properties || {}) - this.settings.push(settingsFile) - if (this.settingsActivated) settingsFile.activate(this.config) - } - return resolve() - } else { + if (this.preloadedPackage && this.packageManager.packagesCache[this.name]) { + for (let settingsPath in this.packageManager.packagesCache[this.name].settings) { + const properties = this.packageManager.packagesCache[this.name].settings[settingsPath] + const settingsFile = new SettingsFile(`core:${settingsPath}`, properties || {}) + this.settings.push(settingsFile) + if (this.settingsActivated) settingsFile.activate(this.config) + } + } else { + return new Promise(resolve => { const settingsDirPath = path.join(this.path, 'settings') fs.exists(settingsDirPath, (settingsDirExists) => { if (!settingsDirExists) return resolve() @@ -666,8 +665,8 @@ class Package { async.each(settingsPaths, loadSettingsFile, () => resolve()) }) }) - } - }) + }) + } } serialize () { From 1e87055f6d2294b8732fab14da615fd632bce0f0 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 28 May 2019 11:47:49 +0200 Subject: [PATCH 17/29] Require policykit in debian distribution This is used by fs-admin to invoke `pkexec` and escalate privileges to write into restricted locations. Co-Authored-By: Rafael Oleza --- resources/linux/debian/control.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/linux/debian/control.in b/resources/linux/debian/control.in index 43ccef9af..4e33e5823 100644 --- a/resources/linux/debian/control.in +++ b/resources/linux/debian/control.in @@ -1,6 +1,6 @@ Package: <%= appFileName %> Version: <%= version %> -Depends: git, libgconf-2-4 (>= 3.2.5) | libgconf2-4, libgtk-3-0 (>= 3.9.10), libgcrypt11 | libgcrypt20, libnotify4, libxtst6, libnss3 (>= 2:3.22), python, gvfs-bin, xdg-utils, libx11-xcb1, libxss1, libasound2 (>= 1.0.16), libxkbfile1, libcurl3 | libcurl4 +Depends: git, libgconf-2-4 (>= 3.2.5) | libgconf2-4, libgtk-3-0 (>= 3.9.10), libgcrypt11 | libgcrypt20, libnotify4, libxtst6, libnss3 (>= 2:3.22), python, gvfs-bin, xdg-utils, libx11-xcb1, libxss1, libasound2 (>= 1.0.16), libxkbfile1, libcurl3 | libcurl4, policykit-1 Recommends: lsb-release Suggests: libsecret-1-0, gir1.2-gnomekeyring-1.0 Section: devel From 50f73a57b7378e37b2debaccad090c52f449cc90 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 28 May 2019 11:52:47 +0200 Subject: [PATCH 18/29] Add policy to prevent asking password more than once on Debian This is a polkit policy that is read when fs-admin invokes `dd` via `pkexec` after trying to write into a restricted location. By specifying `auth_admin_keep`, we are telling the polkit daemon to not prompt users for a password again if they have already escalated privileges recently. Co-Authored-By: Rafael Oleza --- resources/linux/atom.policy | 18 ++++++++++++++++++ script/lib/create-debian-package.js | 6 ++++++ 2 files changed, 24 insertions(+) create mode 100644 resources/linux/atom.policy diff --git a/resources/linux/atom.policy b/resources/linux/atom.policy new file mode 100644 index 000000000..0dd19d216 --- /dev/null +++ b/resources/linux/atom.policy @@ -0,0 +1,18 @@ + + + + Atom + + Admin privileges required + Please enter your password to save this file + /bin/dd + true + + auth_admin_keep + auth_admin_keep + auth_admin_keep + + + diff --git a/script/lib/create-debian-package.js b/script/lib/create-debian-package.js index 1aa179b70..cf5aaecf8 100644 --- a/script/lib/create-debian-package.js +++ b/script/lib/create-debian-package.js @@ -113,6 +113,12 @@ module.exports = function (packagedAppPath) { path.join(debianPackageLintianOverridesDirPath, atomExecutableName) ) + console.log(`Copying polkit configuration into "${debianPackageShareDirPath}"`) + fs.copySync( + path.join(CONFIG.repositoryRootPath, 'resources', 'linux', 'atom.policy'), + path.join(debianPackageShareDirPath, 'polkit-1', 'actions', 'atom.policy') + ) + console.log(`Generating .deb file from ${debianPackageDirPath}`) spawnSync('fakeroot', ['dpkg-deb', '-b', debianPackageDirPath], {stdio: 'inherit'}) From 949e53e7f660a581e2b820215caaa856be44eb1c Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 28 May 2019 11:52:47 +0200 Subject: [PATCH 19/29] Require policykit in RPM distribution Co-Authored-By: Rafael Oleza --- resources/linux/redhat/atom.spec.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/linux/redhat/atom.spec.in b/resources/linux/redhat/atom.spec.in index 471d4b82a..f28520f4e 100644 --- a/resources/linux/redhat/atom.spec.in +++ b/resources/linux/redhat/atom.spec.in @@ -8,9 +8,9 @@ AutoReqProv: no # Avoid libchromiumcontent.so missing dependency Prefix: <%= installDir %> %ifarch i386 i486 i586 i686 -Requires: lsb-core-noarch, libXss.so.1 libsecret-1.so.0 +Requires: lsb-core-noarch, libXss.so.1 libsecret-1.so.0, polkit %else -Requires: lsb-core-noarch, libXss.so.1()(64bit) libsecret-1.so.0()(64bit) +Requires: lsb-core-noarch, libXss.so.1()(64bit) libsecret-1.so.0()(64bit), polkit %endif %description From 3b5eb5d2472de9dfe1f1d01487d3dc9291469c27 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Tue, 28 May 2019 11:52:47 +0200 Subject: [PATCH 20/29] Add policy to prevent asking password more than once on RPM See 50f73a5 for more details. Co-Authored-By: Rafael Oleza --- resources/linux/redhat/atom.spec.in | 2 ++ script/lib/create-rpm-package.js | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/resources/linux/redhat/atom.spec.in b/resources/linux/redhat/atom.spec.in index f28520f4e..90a79e60f 100644 --- a/resources/linux/redhat/atom.spec.in +++ b/resources/linux/redhat/atom.spec.in @@ -25,6 +25,7 @@ cp atom.sh "%{buildroot}/<%= installDir %>/bin/<%= appFileName %>" chmod 755 "%{buildroot}/<%= installDir %>/bin/<%= appFileName %>" mkdir -p "%{buildroot}/<%= installDir %>/share/applications/" cp "<%= appFileName %>.desktop" "%{buildroot}/<%= installDir %>/share/applications/" +cp "atom.policy" "%{buildroot}/<%= installDir %>/share/polkit-1/actions/atom.policy" mkdir -p "%{buildroot}/<%= installDir %>/share/icons/hicolor/1024x1024/apps" cp "icons/1024.png" "%{buildroot}/<%= installDir %>/share/icons/hicolor/1024x1024/apps/<%= appFileName %>.png" @@ -50,4 +51,5 @@ cp "icons/16.png" "%{buildroot}/<%= installDir %>/share/icons/hicolor/16x16/apps <%= installDir %>/bin/<%= apmFileName %> <%= installDir %>/share/<%= appFileName %>/ <%= installDir %>/share/applications/<%= appFileName %>.desktop +<%= installDir %>/share/polkit-1/actions/atom.policy <%= installDir %>/share/icons/hicolor/ diff --git a/script/lib/create-rpm-package.js b/script/lib/create-rpm-package.js index cdef23300..22068dcd3 100644 --- a/script/lib/create-rpm-package.js +++ b/script/lib/create-rpm-package.js @@ -76,6 +76,12 @@ module.exports = function (packagedAppPath) { path.join(rpmPackageBuildDirPath, 'atom.sh') ) + console.log(`Copying atom.policy into "${rpmPackageBuildDirPath}"`) + fs.copySync( + path.join(CONFIG.repositoryRootPath, 'resources', 'linux', 'atom.policy'), + path.join(rpmPackageBuildDirPath, 'atom.policy') + ) + console.log(`Generating .rpm package from "${rpmPackageDirPath}"`) spawnSync('rpmbuild', ['-ba', '--clean', rpmPackageSpecFilePath]) for (let generatedArch of fs.readdirSync(rpmPackageRpmsDirPath)) { From f5926fe8f1e1a12f838f3c93c452e7ac763dfd6f Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Tue, 28 May 2019 13:03:07 +0200 Subject: [PATCH 21/29] Create folder before copying polkit policy file on redhat --- resources/linux/redhat/atom.spec.in | 1 + 1 file changed, 1 insertion(+) diff --git a/resources/linux/redhat/atom.spec.in b/resources/linux/redhat/atom.spec.in index 90a79e60f..7a4888895 100644 --- a/resources/linux/redhat/atom.spec.in +++ b/resources/linux/redhat/atom.spec.in @@ -25,6 +25,7 @@ cp atom.sh "%{buildroot}/<%= installDir %>/bin/<%= appFileName %>" chmod 755 "%{buildroot}/<%= installDir %>/bin/<%= appFileName %>" mkdir -p "%{buildroot}/<%= installDir %>/share/applications/" cp "<%= appFileName %>.desktop" "%{buildroot}/<%= installDir %>/share/applications/" +mkdir -p "%{buildroot}/<%= installDir %>/share/polkit-1/actions/" cp "atom.policy" "%{buildroot}/<%= installDir %>/share/polkit-1/actions/atom.policy" mkdir -p "%{buildroot}/<%= installDir %>/share/icons/hicolor/1024x1024/apps" From eacfb78d0768dd155b359a2495e5e8e33a882702 Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Tue, 28 May 2019 17:02:02 +0200 Subject: [PATCH 22/29] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20find-and-replace@0.2?= =?UTF-8?q?18.11?= 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 081923db1..f2c710c31 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3287,8 +3287,8 @@ } }, "find-and-replace": { - "version": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.10/tarball", - "integrity": "sha512-P9pFWPlUIUO+COMR6VdTQa7Q4JUcrSS8NALq5Pc0RI8scoMoLnZ5RSReKgYp5Gnc7kshPPa09agw3GitLFmorw==", + "version": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.11/tarball", + "integrity": "sha512-STNDeRCSXCV5YjfrWbS5X4TfOFnNX7Z1k96POk3uPoPN8aQvkAIUflT7h6p0MClR9E2/I2O7nYKbYzNqBflZ6Q==", "requires": { "binary-search": "^1.3.3", "element-resize-detector": "^1.1.10", diff --git a/package.json b/package.json index a33e0d583..d824665f6 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.10/tarball", + "find-and-replace": "https://www.atom.io/api/packages/find-and-replace/versions/0.218.11/tarball", "find-parent-dir": "^0.3.0", "first-mate": "7.3.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.10", + "find-and-replace": "0.218.11", "fuzzy-finder": "1.13.3", "github": "0.29.0", "git-diff": "file:./packages/git-diff", From dcac01fc18f5e6d2e0724a890394e46548da01b2 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Wed, 29 May 2019 14:19:33 +0200 Subject: [PATCH 23/29] Upgrade text-buffer to v13.15.4-0 --- package-lock.json | 38 +++++++++++++++++++++++++------------- package.json | 2 +- script/package-lock.json | 4 +--- 3 files changed, 27 insertions(+), 17 deletions(-) diff --git a/package-lock.json b/package-lock.json index 081923db1..071f2acdf 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4442,8 +4442,14 @@ "language-json": { "version": "https://www.atom.io/api/packages/language-json/versions/1.0.2/tarball", "integrity": "sha512-2OvmYoTjO5IXnnRMVMfPb7iOMEnqD36otbpOpQUELG4eJJqgrms6Hs7HnevFs5ZB4yLc1ZU2u9h9TAp/WXUmdA==", - "requires": { - "tree-sitter-json": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea" + "dependencies": { + "tree-sitter-json": { + "version": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea", + "from": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea", + "requires": { + "nan": "^2.0.0" + } + } } }, "language-less": { @@ -6959,15 +6965,15 @@ } }, "text-buffer": { - "version": "13.15.3", - "resolved": "https://registry.npmjs.org/text-buffer/-/text-buffer-13.15.3.tgz", - "integrity": "sha512-H2fz/N15g0fBP7R33FUFLnIyND+Lji/xmuvHg9rKgmfCh7NAVxiFIvnZTabuBhL9InqPrtV5t4hkUy+r3dNXMg==", + "version": "13.15.4-0", + "resolved": "https://registry.npmjs.org/text-buffer/-/text-buffer-13.15.4-0.tgz", + "integrity": "sha512-7Cji8djB+Ncpru2TSadFvdThumwLn7sto8Omizh+W3twAZ1kWwOrbTN+UUmtnG/MrckRbOQqVutz97bIFq+CpA==", "requires": { "delegato": "^1.0.0", "diff": "^2.2.1", "emissary": "^1.0.0", "event-kit": "^2.4.0", - "fs-admin": "^0.1.7", + "fs-admin": "^0.5.0", "fs-plus": "^3.0.0", "grim": "^2.0.2", "mkdirp": "^0.5.1", @@ -6982,6 +6988,14 @@ "resolved": "https://registry.npmjs.org/diff/-/diff-2.2.3.tgz", "integrity": "sha1-YOr9DSjukG5Oj/ClLBIpUhAzv5k=" }, + "fs-admin": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/fs-admin/-/fs-admin-0.5.0.tgz", + "integrity": "sha512-jU0x86bI6wmhdGGcpaO1rI7EpNx/44cEXPsHqFIRgs9SVsk3HSWn9Zd5fd7bdDw3LcmdnazOcJFK9PZsoNecAA==", + "requires": { + "nan": "^2.13.2" + } + }, "grim": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/grim/-/grim-2.0.2.tgz", @@ -6989,6 +7003,11 @@ "requires": { "event-kit": "^2.0.0" } + }, + "nan": { + "version": "2.14.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz", + "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==" } } }, @@ -7143,13 +7162,6 @@ } } }, - "tree-sitter-json": { - "version": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea", - "from": "git://github.com/tree-sitter/tree-sitter-json.git#v0.14.0", - "requires": { - "nan": "^2.0.0" - } - }, "tree-sitter-python": { "version": "0.14.0", "resolved": "https://registry.npmjs.org/tree-sitter-python/-/tree-sitter-python-0.14.0.tgz", diff --git a/package.json b/package.json index a33e0d583..b4346b217 100644 --- a/package.json +++ b/package.json @@ -155,7 +155,7 @@ "symbols-view": "https://www.atom.io/api/packages/symbols-view/versions/0.118.2/tarball", "tabs": "https://www.atom.io/api/packages/tabs/versions/0.110.0/tarball", "temp": "^0.9.0", - "text-buffer": "13.15.3", + "text-buffer": "13.15.4-0", "timecop": "https://www.atom.io/api/packages/timecop/versions/0.36.2/tarball", "tree-sitter": "0.15.0", "tree-sitter-css": "^0.13.7", diff --git a/script/package-lock.json b/script/package-lock.json index 4c8ad5fe2..cd294d3dc 100644 --- a/script/package-lock.json +++ b/script/package-lock.json @@ -901,7 +901,6 @@ "version": "0.4.2", "resolved": "https://registry.npmjs.org/boom/-/boom-0.4.2.tgz", "integrity": "sha1-emNune1O/O+xnO9JR6PGffrukRs=", - "optional": true, "requires": { "hoek": "0.9.x" } @@ -3991,8 +3990,7 @@ "hoek": { "version": "0.9.1", "resolved": "https://registry.npmjs.org/hoek/-/hoek-0.9.1.tgz", - "integrity": "sha1-PTIkYrrfB3Fup+uFuviAec3c5QU=", - "optional": true + "integrity": "sha1-PTIkYrrfB3Fup+uFuviAec3c5QU=" }, "home-or-tmp": { "version": "1.0.0", From e9a448c0039cbefd25c2384806b835434e13c233 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Wed, 29 May 2019 15:32:29 +0200 Subject: [PATCH 24/29] Upgrade text-buffer to v13.16.0 --- package-lock.json | 23 ++++++++++++----------- package.json | 2 +- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/package-lock.json b/package-lock.json index 071f2acdf..37cbe78b7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4442,14 +4442,8 @@ "language-json": { "version": "https://www.atom.io/api/packages/language-json/versions/1.0.2/tarball", "integrity": "sha512-2OvmYoTjO5IXnnRMVMfPb7iOMEnqD36otbpOpQUELG4eJJqgrms6Hs7HnevFs5ZB4yLc1ZU2u9h9TAp/WXUmdA==", - "dependencies": { - "tree-sitter-json": { - "version": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea", - "from": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea", - "requires": { - "nan": "^2.0.0" - } - } + "requires": { + "tree-sitter-json": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea" } }, "language-less": { @@ -6965,9 +6959,9 @@ } }, "text-buffer": { - "version": "13.15.4-0", - "resolved": "https://registry.npmjs.org/text-buffer/-/text-buffer-13.15.4-0.tgz", - "integrity": "sha512-7Cji8djB+Ncpru2TSadFvdThumwLn7sto8Omizh+W3twAZ1kWwOrbTN+UUmtnG/MrckRbOQqVutz97bIFq+CpA==", + "version": "13.16.0", + "resolved": "https://registry.npmjs.org/text-buffer/-/text-buffer-13.16.0.tgz", + "integrity": "sha512-J00KcJDKvV87I/4o7F6LYu+2/fzmuEb7liBbZsIeCUM+T0kwqW7k0R7ddyk9EJR2Nqq7asng2/hVIBNYldIfEg==", "requires": { "delegato": "^1.0.0", "diff": "^2.2.1", @@ -7162,6 +7156,13 @@ } } }, + "tree-sitter-json": { + "version": "git://github.com/tree-sitter/tree-sitter-json.git#337f55be9b9b1ccb0baa7763bfe014a94acea7ea", + "from": "git://github.com/tree-sitter/tree-sitter-json.git#v0.14.0", + "requires": { + "nan": "^2.0.0" + } + }, "tree-sitter-python": { "version": "0.14.0", "resolved": "https://registry.npmjs.org/tree-sitter-python/-/tree-sitter-python-0.14.0.tgz", diff --git a/package.json b/package.json index b4346b217..f563866d0 100644 --- a/package.json +++ b/package.json @@ -155,7 +155,7 @@ "symbols-view": "https://www.atom.io/api/packages/symbols-view/versions/0.118.2/tarball", "tabs": "https://www.atom.io/api/packages/tabs/versions/0.110.0/tarball", "temp": "^0.9.0", - "text-buffer": "13.15.4-0", + "text-buffer": "13.16.0", "timecop": "https://www.atom.io/api/packages/timecop/versions/0.36.2/tarball", "tree-sitter": "0.15.0", "tree-sitter-css": "^0.13.7", From 40c26d29c8c5c9c950bdf3846dde18fd7ce1e7e1 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Mon, 27 May 2019 12:32:54 +0200 Subject: [PATCH 25/29] Don't create a promise when preloading package settings in snapshot Promise creation is forbidden within `mksnapshot` (see https://github.com/electron/libchromiumcontent/pull/363, https://github.com/nodejs/node/pull/13242 and https://github.com/electron/electron/issues/18420). Since preloading a package's settings is a synchronous action anyway, we just avoid instantiating a new Promise when calling `loadSettings`. --- src/package.js | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/src/package.js b/src/package.js index 56764a86a..37afb30b5 100644 --- a/src/package.js +++ b/src/package.js @@ -648,16 +648,15 @@ class Package { }) } - return new Promise(resolve => { - if (this.preloadedPackage && this.packageManager.packagesCache[this.name]) { - for (let settingsPath in this.packageManager.packagesCache[this.name].settings) { - const properties = this.packageManager.packagesCache[this.name].settings[settingsPath] - const settingsFile = new SettingsFile(`core:${settingsPath}`, properties || {}) - this.settings.push(settingsFile) - if (this.settingsActivated) settingsFile.activate(this.config) - } - return resolve() - } else { + if (this.preloadedPackage && this.packageManager.packagesCache[this.name]) { + for (let settingsPath in this.packageManager.packagesCache[this.name].settings) { + const properties = this.packageManager.packagesCache[this.name].settings[settingsPath] + const settingsFile = new SettingsFile(`core:${settingsPath}`, properties || {}) + this.settings.push(settingsFile) + if (this.settingsActivated) settingsFile.activate(this.config) + } + } else { + return new Promise(resolve => { const settingsDirPath = path.join(this.path, 'settings') fs.exists(settingsDirPath, (settingsDirExists) => { if (!settingsDirExists) return resolve() @@ -666,8 +665,8 @@ class Package { async.each(settingsPaths, loadSettingsFile, () => resolve()) }) }) - } - }) + }) + } } serialize () { From 20a49bb165ea6e57b2ce1be65e3cdf30dd1fb9a0 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Wed, 29 May 2019 18:59:40 +0200 Subject: [PATCH 26/29] Upgrade to Electron 3.1.10 --- package.json | 2 +- script/package-lock.json | 27 ++++++++++++++++++++++++--- script/package.json | 2 +- 3 files changed, 26 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 848f02f17..781ecba53 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "url": "https://github.com/atom/atom/issues" }, "license": "MIT", - "electronVersion": "3.1.9", + "electronVersion": "3.1.10", "dependencies": { "@atom/nsfw": "1.0.23", "@atom/source-map-support": "^0.3.4", diff --git a/script/package-lock.json b/script/package-lock.json index 042db4275..568d7d622 100644 --- a/script/package-lock.json +++ b/script/package-lock.json @@ -2008,13 +2008,34 @@ } }, "electron-mksnapshot": { - "version": "3.0.10", - "resolved": "https://registry.npmjs.org/electron-mksnapshot/-/electron-mksnapshot-3.0.10.tgz", - "integrity": "sha512-Toy6sAC3t9tgvq1kUYsx+4TRNPDj7Bzoo+1gx5FD8Q0YCS+tq+ter62Ot6dBXCKG9SwoaGBz84b++MgO0VobYw==", + "version": "3.1.10", + "resolved": "https://registry.npmjs.org/electron-mksnapshot/-/electron-mksnapshot-3.1.10.tgz", + "integrity": "sha512-hPbFENfbUNrgOsLMja3nUFbneBxgXowmfztmRdr+a7yW6X6/d9YAGw23b9kugBNDFTKcuuTo825zVpBRwjSYRQ==", "requires": { "electron-download": "^4.1.0", "extract-zip": "^1.6.5", + "fs-extra": "^7.0.1", "temp": "^0.8.3" + }, + "dependencies": { + "fs-extra": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-7.0.1.tgz", + "integrity": "sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==", + "requires": { + "graceful-fs": "^4.1.2", + "jsonfile": "^4.0.0", + "universalify": "^0.1.0" + } + }, + "jsonfile": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", + "integrity": "sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss=", + "requires": { + "graceful-fs": "^4.1.6" + } + } } }, "electron-osx-sign": { diff --git a/script/package.json b/script/package.json index 933573368..c6ed49977 100644 --- a/script/package.json +++ b/script/package.json @@ -12,7 +12,7 @@ "donna": "1.0.16", "electron-chromedriver": "^3.0.0", "electron-link": "0.4.0", - "electron-mksnapshot": "^3.0.10", + "electron-mksnapshot": "^3.1.10", "electron-packager": "12.2.0", "electron-winstaller": "2.6.4", "eslint": "^5.16.0", From 8091f202fa09057a80ab3946ed7e514195953198 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Thu, 30 May 2019 09:28:40 +0200 Subject: [PATCH 27/29] Update language-typescript to v0.5.0 --- 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 91c0a6e54..3ab6289c6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4544,10 +4544,10 @@ "integrity": "sha512-6xFDqM6nZpynmxGKUS85iUWY0yeub7GYvLyzSOqDejMuOL5UXAITnSNcb7jhr+hQA8KTj5dCmRjphkAQER4Ucg==" }, "language-typescript": { - "version": "https://www.atom.io/api/packages/language-typescript/versions/0.4.11/tarball", - "integrity": "sha512-Qz57rNC2jzo3IPRrz6LzKoHExqw1jk/UE52QmbSIziCyoOw8G1LPobpY+XpxVLW68Mh7Ad2gAmdRj1d3oeWswg==", + "version": "https://www.atom.io/api/packages/language-typescript/versions/0.5.0/tarball", + "integrity": "sha512-rRArdgBSjIxfMceapfPil4n5fraIr3lBWGWuXpRqGvYkmB7scvt01MpbCvdKlJGz/KAd7wKG8criIYqBvy2QDg==", "requires": { - "tree-sitter-typescript": "^0.13.6" + "tree-sitter-typescript": "^0.14.0" } }, "language-xml": { @@ -7217,9 +7217,9 @@ } }, "tree-sitter-typescript": { - "version": "0.13.6", - "resolved": "https://registry.npmjs.org/tree-sitter-typescript/-/tree-sitter-typescript-0.13.6.tgz", - "integrity": "sha512-1csvCrW5gf4d4D0ZXCctsVDr0M+fOCXYfX/Tve6OAeHUdFu0JsI+CEsS6X3VH7umX5/62RDYe1cwbvOhCuIiXA==", + "version": "0.14.0", + "resolved": "https://registry.npmjs.org/tree-sitter-typescript/-/tree-sitter-typescript-0.14.0.tgz", + "integrity": "sha512-gx54LvIbjIdqSYGwau5G4Kr7j1oEwfWoZDKrR3jUlINEwskNOXaOzgsSdIM92JnFyqdBU+N6mBHpzjafbJ8EFw==", "requires": { "nan": "^2.10.0" } diff --git a/package.json b/package.json index 781ecba53..5875de2e9 100644 --- a/package.json +++ b/package.json @@ -108,7 +108,7 @@ "language-text": "https://www.atom.io/api/packages/language-text/versions/0.7.4/tarball", "language-todo": "https://www.atom.io/api/packages/language-todo/versions/0.29.4/tarball", "language-toml": "https://www.atom.io/api/packages/language-toml/versions/0.20.0/tarball", - "language-typescript": "https://www.atom.io/api/packages/language-typescript/versions/0.4.11/tarball", + "language-typescript": "https://www.atom.io/api/packages/language-typescript/versions/0.5.0/tarball", "language-xml": "https://www.atom.io/api/packages/language-xml/versions/0.35.3/tarball", "language-yaml": "https://www.atom.io/api/packages/language-yaml/versions/0.32.0/tarball", "less-cache": "1.1.0", @@ -260,7 +260,7 @@ "language-text": "0.7.4", "language-todo": "0.29.4", "language-toml": "0.20.0", - "language-typescript": "0.4.11", + "language-typescript": "0.5.0", "language-xml": "0.35.3", "language-yaml": "0.32.0" }, From d571f385c2e1a5e2b1575051a27fccc02985e96a Mon Sep 17 00:00:00 2001 From: Rafael Oleza Date: Thu, 30 May 2019 10:09:54 +0200 Subject: [PATCH 28/29] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20fuzzy-finder@1.13.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package-lock.json | 441 +--------------------------------------------- package.json | 4 +- 2 files changed, 9 insertions(+), 436 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3ab6289c6..0c7834401 100644 --- a/package-lock.json +++ b/package-lock.json @@ -21,438 +21,11 @@ } }, "@atom/fuzzy-native": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@atom/fuzzy-native/-/fuzzy-native-1.0.1.tgz", - "integrity": "sha512-qqpUL9NpR7Ee04CNoHK8eOXx3ON4e2AbxMFA4v1Ch6lCb7//K9YsJKTmTNT9W49dF9snV+hdgF4TNYD1gY7Qpg==", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@atom/fuzzy-native/-/fuzzy-native-1.0.3.tgz", + "integrity": "sha512-bpFKY270m+1JVZ5xEn1RIFo44ZwIYww0o/MZnev/SyMXZSuQEcJcgXbvz8mBAOK9Tpce4iDgRWcBLuBOoMbJSw==", "requires": { - "nan": "^2.0.0", - "node-pre-gyp": "^0.10.0", - "semver": "^5.0.0" - }, - "dependencies": { - "abbrev": { - "version": "1.1.1", - "bundled": true - }, - "ansi-regex": { - "version": "2.1.1", - "bundled": true - }, - "aproba": { - "version": "1.2.0", - "bundled": true - }, - "are-we-there-yet": { - "version": "1.1.5", - "bundled": true, - "requires": { - "delegates": "^1.0.0", - "readable-stream": "^2.0.6" - } - }, - "balanced-match": { - "version": "1.0.0", - "bundled": true - }, - "brace-expansion": { - "version": "1.1.11", - "bundled": true, - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "chownr": { - "version": "1.1.1", - "bundled": true - }, - "code-point-at": { - "version": "1.1.0", - "bundled": true - }, - "concat-map": { - "version": "0.0.1", - "bundled": true - }, - "console-control-strings": { - "version": "1.1.0", - "bundled": true - }, - "core-util-is": { - "version": "1.0.2", - "bundled": true - }, - "debug": { - "version": "2.6.9", - "bundled": true, - "requires": { - "ms": "2.0.0" - } - }, - "deep-extend": { - "version": "0.6.0", - "bundled": true - }, - "delegates": { - "version": "1.0.0", - "bundled": true - }, - "detect-libc": { - "version": "1.0.3", - "bundled": true - }, - "fs-minipass": { - "version": "1.2.5", - "bundled": true, - "requires": { - "minipass": "^2.2.1" - } - }, - "fs.realpath": { - "version": "1.0.0", - "bundled": true - }, - "gauge": { - "version": "2.7.4", - "bundled": true, - "requires": { - "aproba": "^1.0.3", - "console-control-strings": "^1.0.0", - "has-unicode": "^2.0.0", - "object-assign": "^4.1.0", - "signal-exit": "^3.0.0", - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1", - "wide-align": "^1.1.0" - } - }, - "glob": { - "version": "7.1.3", - "bundled": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "has-unicode": { - "version": "2.0.1", - "bundled": true - }, - "iconv-lite": { - "version": "0.4.23", - "bundled": true, - "requires": { - "safer-buffer": ">= 2.1.2 < 3" - } - }, - "ignore-walk": { - "version": "3.0.1", - "bundled": true, - "requires": { - "minimatch": "^3.0.4" - } - }, - "inflight": { - "version": "1.0.6", - "bundled": true, - "requires": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "inherits": { - "version": "2.0.3", - "bundled": true - }, - "ini": { - "version": "1.3.5", - "bundled": true - }, - "is-fullwidth-code-point": { - "version": "1.0.0", - "bundled": true, - "requires": { - "number-is-nan": "^1.0.0" - } - }, - "isarray": { - "version": "1.0.0", - "bundled": true - }, - "minimatch": { - "version": "3.0.4", - "bundled": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "minimist": { - "version": "0.0.8", - "bundled": true - }, - "minipass": { - "version": "2.3.0", - "bundled": true, - "requires": { - "safe-buffer": "^5.1.1", - "yallist": "^3.0.0" - }, - "dependencies": { - "safe-buffer": { - "version": "5.1.1", - "bundled": true - }, - "yallist": { - "version": "3.0.2", - "bundled": true - } - } - }, - "mkdirp": { - "version": "0.5.1", - "bundled": true, - "requires": { - "minimist": "0.0.8" - } - }, - "ms": { - "version": "2.0.0", - "bundled": true - }, - "needle": { - "version": "2.2.1", - "bundled": true, - "requires": { - "debug": "^2.1.2", - "iconv-lite": "^0.4.4", - "sax": "^1.2.4" - } - }, - "node-pre-gyp": { - "version": "0.10.3", - "bundled": true, - "requires": { - "detect-libc": "^1.0.2", - "mkdirp": "^0.5.1", - "needle": "^2.2.1", - "nopt": "^4.0.1", - "npm-packlist": "^1.1.6", - "npmlog": "^4.0.2", - "rc": "^1.2.7", - "rimraf": "^2.6.1", - "semver": "^5.3.0", - "tar": "^4" - } - }, - "nopt": { - "version": "4.0.1", - "bundled": true, - "requires": { - "abbrev": "1", - "osenv": "^0.1.4" - } - }, - "npm-bundled": { - "version": "1.0.3", - "bundled": true - }, - "npm-packlist": { - "version": "1.1.10", - "bundled": true, - "requires": { - "ignore-walk": "^3.0.1", - "npm-bundled": "^1.0.1" - } - }, - "npmlog": { - "version": "4.1.2", - "bundled": true, - "requires": { - "are-we-there-yet": "~1.1.2", - "console-control-strings": "~1.1.0", - "gauge": "~2.7.3", - "set-blocking": "~2.0.0" - } - }, - "number-is-nan": { - "version": "1.0.1", - "bundled": true - }, - "object-assign": { - "version": "4.1.1", - "bundled": true - }, - "once": { - "version": "1.4.0", - "bundled": true, - "requires": { - "wrappy": "1" - } - }, - "os-homedir": { - "version": "1.0.2", - "bundled": true - }, - "os-tmpdir": { - "version": "1.0.2", - "bundled": true - }, - "osenv": { - "version": "0.1.5", - "bundled": true, - "requires": { - "os-homedir": "^1.0.0", - "os-tmpdir": "^1.0.0" - } - }, - "path-is-absolute": { - "version": "1.0.1", - "bundled": true - }, - "process-nextick-args": { - "version": "2.0.0", - "bundled": true - }, - "rc": { - "version": "1.2.8", - "bundled": true, - "requires": { - "deep-extend": "^0.6.0", - "ini": "~1.3.0", - "minimist": "^1.2.0", - "strip-json-comments": "~2.0.1" - }, - "dependencies": { - "minimist": { - "version": "1.2.0", - "bundled": true - } - } - }, - "readable-stream": { - "version": "2.3.6", - "bundled": true, - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "rimraf": { - "version": "2.6.3", - "bundled": true, - "requires": { - "glob": "^7.1.3" - } - }, - "safe-buffer": { - "version": "5.1.2", - "bundled": true - }, - "safer-buffer": { - "version": "2.1.2", - "bundled": true - }, - "sax": { - "version": "1.2.4", - "bundled": true - }, - "semver": { - "version": "5.7.0", - "bundled": true - }, - "set-blocking": { - "version": "2.0.0", - "bundled": true - }, - "signal-exit": { - "version": "3.0.2", - "bundled": true - }, - "string-width": { - "version": "1.0.2", - "bundled": true, - "requires": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" - } - }, - "string_decoder": { - "version": "1.1.1", - "bundled": true, - "requires": { - "safe-buffer": "~5.1.0" - } - }, - "strip-ansi": { - "version": "3.0.1", - "bundled": true, - "requires": { - "ansi-regex": "^2.0.0" - } - }, - "strip-json-comments": { - "version": "2.0.1", - "bundled": true - }, - "tar": { - "version": "4.4.8", - "bundled": true, - "requires": { - "chownr": "^1.1.1", - "fs-minipass": "^1.2.5", - "minipass": "^2.3.4", - "minizlib": "^1.1.1", - "mkdirp": "^0.5.0", - "safe-buffer": "^5.1.2", - "yallist": "^3.0.2" - }, - "dependencies": { - "minipass": { - "version": "2.3.5", - "bundled": true, - "requires": { - "safe-buffer": "^5.1.2", - "yallist": "^3.0.0" - } - }, - "minizlib": { - "version": "1.2.1", - "bundled": true, - "requires": { - "minipass": "^2.2.1" - } - } - } - }, - "util-deprecate": { - "version": "1.0.2", - "bundled": true - }, - "wide-align": { - "version": "1.1.3", - "bundled": true, - "requires": { - "string-width": "^1.0.2 || 2" - } - }, - "wrappy": { - "version": "1.0.2", - "bundled": true - }, - "yallist": { - "version": "3.0.3", - "bundled": true - } + "nan": "^2.0.0" } }, "@atom/nsfw": { @@ -3559,10 +3132,10 @@ "integrity": "sha1-gy9kifvodnaUWVmckUpnDsIpR+4=" }, "fuzzy-finder": { - "version": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.3/tarball", - "integrity": "sha512-wVj9JkOZaeK26OtuTi3bMr8TlZ0srwmf3avtvMBnYjza4eueHOrRM6i+yxgoaPqv2ODQl1T33IldXFo1z5YWMw==", + "version": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.5/tarball", + "integrity": "sha512-YGWs7O5f2H0An7wTKet9yst+EngKCMBMzI6E68UyM5qGs+1cEyOo4j5JEB3RtHpzsBDv+aYhT0C/WoXuOh+B/g==", "requires": { - "@atom/fuzzy-native": "^1.0.1", + "@atom/fuzzy-native": "^1.0.3", "async": "0.2.6", "atom-select-list": "^0.7.0", "fs-plus": "^3.0.0", diff --git a/package.json b/package.json index 5875de2e9..d92088b44 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.3/tarball", + "fuzzy-finder": "https://www.atom.io/api/packages/fuzzy-finder/versions/1.13.5/tarball", "git-diff": "file:packages/git-diff", "git-utils": "5.5.0", "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.11", - "fuzzy-finder": "1.13.3", + "fuzzy-finder": "1.13.5", "github": "0.29.0", "git-diff": "file:./packages/git-diff", "go-to-line": "file:./packages/go-to-line", From 8ac841b97f6dd2522b797763ca6085efa282a1ed Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Fri, 31 May 2019 09:22:21 +0200 Subject: [PATCH 29/29] Update metrics to v1.7.5 --- 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 0c7834401..046cf99f6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4657,8 +4657,8 @@ } }, "metrics": { - "version": "https://www.atom.io/api/packages/metrics/versions/1.7.4/tarball", - "integrity": "sha512-o4ggvI17jLKgKw7i8TIE81vLSlRv1YSjHEckQ2ZlzzTIppM3wkcNkWpmTQl+Rwpn/xwnopiz66YXN6G5XgJ0Jg==", + "version": "https://www.atom.io/api/packages/metrics/versions/1.7.5/tarball", + "integrity": "sha512-HcA9QKEJAdQi1p6ppk48BKsBGv5E/bLK2rlNUQZJvCPIvPAM/ufFjnqlzujQbZ1/2VFvfXIh4EgQUyS2Hkm1+w==", "requires": { "fs-plus": "^3.0.0", "grim": "^2.0.1", diff --git a/package.json b/package.json index d92088b44..b26e1c0fd 100644 --- a/package.json +++ b/package.json @@ -117,7 +117,7 @@ "link": "file:packages/link", "markdown-preview": "https://www.atom.io/api/packages/markdown-preview/versions/0.160.0/tarball", "marked": "^0.3.12", - "metrics": "https://www.atom.io/api/packages/metrics/versions/1.7.4/tarball", + "metrics": "https://www.atom.io/api/packages/metrics/versions/1.7.5/tarball", "minimatch": "^3.0.3", "mocha": "2.5.1", "mocha-junit-reporter": "^1.13.0", @@ -212,7 +212,7 @@ "line-ending-selector": "file:./packages/line-ending-selector", "link": "file:./packages/link", "markdown-preview": "0.160.0", - "metrics": "1.7.4", + "metrics": "1.7.5", "notifications": "0.70.6", "open-on-github": "1.3.1", "package-generator": "1.3.0",