chore(deps): remove dependency on typescript-closure-tools (#5776)

* build: remove typings tasks from build and test

* chore(deps): remove typescript-closure-tools

* chore(deps): update package-lock.json
This commit is contained in:
Rachel Fenichel
2021-12-03 10:47:24 -08:00
committed by GitHub
parent 8635942248
commit 3770f20448
7 changed files with 17 additions and 526 deletions

View File

@@ -11,7 +11,6 @@
var gulp = require('gulp');
var typings = require('./scripts/gulpfiles/typings');
var buildTasks = require('./scripts/gulpfiles/build_tasks');
var packageTasks = require('./scripts/gulpfiles/package_tasks');
var gitTasks = require('./scripts/gulpfiles/git_tasks');
@@ -30,7 +29,9 @@ module.exports = {
buildLangfiles: buildTasks.langfiles,
buildCompiled: buildTasks.compiled,
buildAdvancedCompilationTest: buildTasks.advancedCompilationTest,
checkin: gulp.parallel(buildTasks.checkinBuilt, typings.checkinTypings),
// TODO(5621): Re-enable once typings generation is fixed.
// checkin: gulp.parallel(buildTasks.checkinBuilt, typings.checkinTypings),
checkin: gulp.parallel(buildTasks.checkinBuilt),
checkinBuilt: buildTasks.checkinBuilt,
clangFormat: buildTasks.format,
clean: gulp.parallel(buildTasks.cleanBuildDir, packageTasks.cleanReleaseDir),
@@ -40,8 +41,9 @@ module.exports = {
gitSyncMaster: gitTasks.syncMaster,
gitCreateRC: gitTasks.createRC,
gitUpdateGithubPages: gitTasks.updateGithubPages,
typings: gulp.series(typings.typings, typings.msgTypings),
checkinTypings: typings.checkinTypings,
// TODO(5621): Re-enable once typings generation is fixed.
// typings: gulp.series(typings.typings, typings.msgTypings),
// checkinTypings: typings.checkinTypings,
package: packageTasks.package,
checkLicenses: licenseTasks.checkLicenses,
recompile: releaseTasks.recompile,

355
package-lock.json generated
View File

@@ -43,7 +43,6 @@
"selenium-standalone": "^8.0.3",
"through2": "^4.0.2",
"typescript": "^4.3.2",
"typescript-closure-tools": "^0.0.7",
"webdriverio": "^7.0.3",
"yargs": "^17.2.1"
}
@@ -1681,12 +1680,6 @@
"jsdom": "15.2.1"
}
},
"node_modules/bluebird": {
"version": "3.7.2",
"resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz",
"integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==",
"dev": true
},
"node_modules/brace-expansion": {
"version": "1.1.11",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
@@ -2092,18 +2085,6 @@
"resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz",
"integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw="
},
"node_modules/catharsis": {
"version": "0.9.0",
"resolved": "https://registry.npmjs.org/catharsis/-/catharsis-0.9.0.tgz",
"integrity": "sha512-prMTQVpcns/tzFgFVkVp6ak6RykZyWb3gu8ckUpd6YkTlacOd3DXGJjIpD4Q6zJirizvaiAjSSHlOsA+6sNh2A==",
"dev": true,
"dependencies": {
"lodash": "^4.17.15"
},
"engines": {
"node": ">= 10"
}
},
"node_modules/chai": {
"version": "4.3.4",
"resolved": "https://registry.npmjs.org/chai/-/chai-4.3.4.tgz",
@@ -3381,12 +3362,6 @@
"node": ">=8.6"
}
},
"node_modules/entities": {
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/entities/-/entities-2.0.3.tgz",
"integrity": "sha512-MyoZ0jgnLvB2X3Lg5HqpFmn1kybDiIfEQmKzTb5apr51Rb+T3KdmMiqa70T+bhGnyv7bQ6WMj2QMHpGMmlrUYQ==",
"dev": true
},
"node_modules/error-ex": {
"version": "1.3.2",
"resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz",
@@ -6759,57 +6734,11 @@
"js-yaml": "bin/js-yaml.js"
}
},
"node_modules/js2xmlparser": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/js2xmlparser/-/js2xmlparser-4.0.2.tgz",
"integrity": "sha512-6n4D8gLlLf1n5mNLQPRfViYzu9RATblzPEtm1SthMX1Pjao0r9YI9nw7ZIfRxQMERS87mcswrg+r/OYrPRX6jA==",
"dev": true,
"dependencies": {
"xmlcreate": "^2.0.4"
}
},
"node_modules/jsbn": {
"version": "0.1.1",
"resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz",
"integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM="
},
"node_modules/jsdoc": {
"version": "3.6.7",
"resolved": "https://registry.npmjs.org/jsdoc/-/jsdoc-3.6.7.tgz",
"integrity": "sha512-sxKt7h0vzCd+3Y81Ey2qinupL6DpRSZJclS04ugHDNmRUXGzqicMJ6iwayhSA0S0DwwX30c5ozyUthr1QKF6uw==",
"dev": true,
"dependencies": {
"@babel/parser": "^7.9.4",
"bluebird": "^3.7.2",
"catharsis": "^0.9.0",
"escape-string-regexp": "^2.0.0",
"js2xmlparser": "^4.0.1",
"klaw": "^3.0.0",
"markdown-it": "^10.0.0",
"markdown-it-anchor": "^5.2.7",
"marked": "^2.0.3",
"mkdirp": "^1.0.4",
"requizzle": "^0.2.3",
"strip-json-comments": "^3.1.0",
"taffydb": "2.6.2",
"underscore": "~1.13.1"
},
"bin": {
"jsdoc": "jsdoc.js"
},
"engines": {
"node": ">=8.15.0"
}
},
"node_modules/jsdoc/node_modules/escape-string-regexp": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz",
"integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==",
"dev": true,
"engines": {
"node": ">=8"
}
},
"node_modules/jsdom": {
"version": "15.2.1",
"resolved": "https://registry.npmjs.org/jsdom/-/jsdom-15.2.1.tgz",
@@ -6971,15 +6900,6 @@
"node": ">=0.10.0"
}
},
"node_modules/klaw": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/klaw/-/klaw-3.0.0.tgz",
"integrity": "sha512-0Fo5oir+O9jnXu5EefYbVK+mHMBeEVEy2cmctR1O1NECcCkPRreJKrS6Qt/j3KC2C148Dfo9i3pCmCMsdqGr0g==",
"dev": true,
"dependencies": {
"graceful-fs": "^4.1.9"
}
},
"node_modules/ky": {
"version": "0.28.7",
"resolved": "https://registry.npmjs.org/ky/-/ky-0.28.7.tgz",
@@ -7116,15 +7036,6 @@
"integrity": "sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=",
"dev": true
},
"node_modules/linkify-it": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-2.2.0.tgz",
"integrity": "sha512-GnAl/knGn+i1U/wjBz3akz2stz+HrHLsxMwHQGofCDfPvlf+gDKN58UtfmUquTY4/MXeE2x7k19KQmeoZi94Iw==",
"dev": true,
"dependencies": {
"uc.micro": "^1.0.1"
}
},
"node_modules/load-json-file": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz",
@@ -7506,43 +7417,6 @@
"node": ">=0.10.0"
}
},
"node_modules/markdown-it": {
"version": "10.0.0",
"resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-10.0.0.tgz",
"integrity": "sha512-YWOP1j7UbDNz+TumYP1kpwnP0aEa711cJjrAQrzd0UXlbJfc5aAq0F/PZHjiioqDC1NKgvIMX+o+9Bk7yuM2dg==",
"dev": true,
"dependencies": {
"argparse": "^1.0.7",
"entities": "~2.0.0",
"linkify-it": "^2.0.0",
"mdurl": "^1.0.1",
"uc.micro": "^1.0.5"
},
"bin": {
"markdown-it": "bin/markdown-it.js"
}
},
"node_modules/markdown-it-anchor": {
"version": "5.3.0",
"resolved": "https://registry.npmjs.org/markdown-it-anchor/-/markdown-it-anchor-5.3.0.tgz",
"integrity": "sha512-/V1MnLL/rgJ3jkMWo84UR+K+jF1cxNG1a+KwqeXqTIJ+jtA8aWSHuigx8lTzauiIjBDbwF3NcWQMotd0Dm39jA==",
"dev": true,
"peerDependencies": {
"markdown-it": "*"
}
},
"node_modules/marked": {
"version": "2.1.3",
"resolved": "https://registry.npmjs.org/marked/-/marked-2.1.3.tgz",
"integrity": "sha512-/Q+7MGzaETqifOMWYEA7HVMaZb4XbcRfaOzcSsHZEith83KGlvaSG33u0SKu89Mj5h+T8V2hM+8O45Qc5XTgwA==",
"dev": true,
"bin": {
"marked": "bin/marked"
},
"engines": {
"node": ">= 10"
}
},
"node_modules/marky": {
"version": "1.2.2",
"resolved": "https://registry.npmjs.org/marky/-/marky-1.2.2.tgz",
@@ -7591,12 +7465,6 @@
"node": ">=0.10.0"
}
},
"node_modules/mdurl": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/mdurl/-/mdurl-1.0.1.tgz",
"integrity": "sha1-/oWy7HWlkDfyrf7BAP1sYBdhFS4=",
"dev": true
},
"node_modules/memoizee": {
"version": "0.4.15",
"resolved": "https://registry.npmjs.org/memoizee/-/memoizee-0.4.15.tgz",
@@ -9972,15 +9840,6 @@
"integrity": "sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=",
"dev": true
},
"node_modules/requizzle": {
"version": "0.2.3",
"resolved": "https://registry.npmjs.org/requizzle/-/requizzle-0.2.3.tgz",
"integrity": "sha512-YanoyJjykPxGHii0fZP0uUPEXpvqfBDxWV7s6GKAiiOsiqhX6vHNyW3Qzdmqp/iq/ExbhaGbVrjB4ruEVSM4GQ==",
"dev": true,
"dependencies": {
"lodash": "^4.17.14"
}
},
"node_modules/resolve": {
"version": "1.20.0",
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz",
@@ -11087,12 +10946,6 @@
"integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
"dev": true
},
"node_modules/taffydb": {
"version": "2.6.2",
"resolved": "https://registry.npmjs.org/taffydb/-/taffydb-2.6.2.tgz",
"integrity": "sha1-fLy2S1oUG2ou/CxdLGe04VCyomg=",
"dev": true
},
"node_modules/tar-fs": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.1.tgz",
@@ -11504,32 +11357,6 @@
"node": ">=4.2.0"
}
},
"node_modules/typescript-closure-tools": {
"version": "0.0.7",
"resolved": "https://registry.npmjs.org/typescript-closure-tools/-/typescript-closure-tools-0.0.7.tgz",
"integrity": "sha512-trz9OhHC8d96c8aqlolk7ckNWlxqqgLPkeSqwi4PuEPu5zMjQqTg8m0E2gNpS3uUPyL0wwBTQOVB/rigFCPJPw==",
"dev": true,
"dependencies": {
"colors": "*",
"doctrine": "github:fivetran/doctrine",
"escodegen": "*",
"esprima": "*",
"jsdoc": "*",
"mkdirp": "*"
},
"bin": {
"closure2ts": "definition-generator/src/cli.js",
"ts2externs": "externs-generator/src/cli.js"
}
},
"node_modules/typescript-closure-tools/node_modules/doctrine": {
"version": "0.5.2-dev",
"resolved": "git+ssh://git@github.com/fivetran/doctrine.git#169ebc1cbf23492363f9442543d1e78e1df9c3d5",
"dev": true,
"engines": {
"node": ">=0.4.0"
}
},
"node_modules/ua-parser-js": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-1.0.2.tgz",
@@ -11549,12 +11376,6 @@
"node": "*"
}
},
"node_modules/uc.micro": {
"version": "1.0.6",
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",
"integrity": "sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA==",
"dev": true
},
"node_modules/unbzip2-stream": {
"version": "1.4.3",
"resolved": "https://registry.npmjs.org/unbzip2-stream/-/unbzip2-stream-1.4.3.tgz",
@@ -11574,12 +11395,6 @@
"node": ">=0.10.0"
}
},
"node_modules/underscore": {
"version": "1.13.1",
"resolved": "https://registry.npmjs.org/underscore/-/underscore-1.13.1.tgz",
"integrity": "sha512-hzSoAVtJF+3ZtiFX0VgfFPHEDRm7Y/QPjGyNo4TVdnDTdft3tr8hEkD25a1jC+TjTuE7tkHGKkhwCgs9dgBB2g==",
"dev": true
},
"node_modules/undertaker": {
"version": "1.3.0",
"resolved": "https://registry.npmjs.org/undertaker/-/undertaker-1.3.0.tgz",
@@ -12173,12 +11988,6 @@
"resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz",
"integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw=="
},
"node_modules/xmlcreate": {
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/xmlcreate/-/xmlcreate-2.0.4.tgz",
"integrity": "sha512-nquOebG4sngPmGPICTS5EnxqhKbCmz5Ox5hsszI2T6U5qdrJizBc+0ilYSEjTSzU0yZcmvppztXe/5Al5fUwdg==",
"dev": true
},
"node_modules/xtend": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz",
@@ -13750,12 +13559,6 @@
"jsdom": "15.2.1"
}
},
"bluebird": {
"version": "3.7.2",
"resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz",
"integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==",
"dev": true
},
"brace-expansion": {
"version": "1.1.11",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
@@ -14070,15 +13873,6 @@
"resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz",
"integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw="
},
"catharsis": {
"version": "0.9.0",
"resolved": "https://registry.npmjs.org/catharsis/-/catharsis-0.9.0.tgz",
"integrity": "sha512-prMTQVpcns/tzFgFVkVp6ak6RykZyWb3gu8ckUpd6YkTlacOd3DXGJjIpD4Q6zJirizvaiAjSSHlOsA+6sNh2A==",
"dev": true,
"requires": {
"lodash": "^4.17.15"
}
},
"chai": {
"version": "4.3.4",
"resolved": "https://registry.npmjs.org/chai/-/chai-4.3.4.tgz",
@@ -15113,12 +14907,6 @@
"ansi-colors": "^4.1.1"
}
},
"entities": {
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/entities/-/entities-2.0.3.tgz",
"integrity": "sha512-MyoZ0jgnLvB2X3Lg5HqpFmn1kybDiIfEQmKzTb5apr51Rb+T3KdmMiqa70T+bhGnyv7bQ6WMj2QMHpGMmlrUYQ==",
"dev": true
},
"error-ex": {
"version": "1.3.2",
"resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz",
@@ -17795,50 +17583,11 @@
"esprima": "^4.0.0"
}
},
"js2xmlparser": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/js2xmlparser/-/js2xmlparser-4.0.2.tgz",
"integrity": "sha512-6n4D8gLlLf1n5mNLQPRfViYzu9RATblzPEtm1SthMX1Pjao0r9YI9nw7ZIfRxQMERS87mcswrg+r/OYrPRX6jA==",
"dev": true,
"requires": {
"xmlcreate": "^2.0.4"
}
},
"jsbn": {
"version": "0.1.1",
"resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz",
"integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM="
},
"jsdoc": {
"version": "3.6.7",
"resolved": "https://registry.npmjs.org/jsdoc/-/jsdoc-3.6.7.tgz",
"integrity": "sha512-sxKt7h0vzCd+3Y81Ey2qinupL6DpRSZJclS04ugHDNmRUXGzqicMJ6iwayhSA0S0DwwX30c5ozyUthr1QKF6uw==",
"dev": true,
"requires": {
"@babel/parser": "^7.9.4",
"bluebird": "^3.7.2",
"catharsis": "^0.9.0",
"escape-string-regexp": "^2.0.0",
"js2xmlparser": "^4.0.1",
"klaw": "^3.0.0",
"markdown-it": "^10.0.0",
"markdown-it-anchor": "^5.2.7",
"marked": "^2.0.3",
"mkdirp": "^1.0.4",
"requizzle": "^0.2.3",
"strip-json-comments": "^3.1.0",
"taffydb": "2.6.2",
"underscore": "~1.13.1"
},
"dependencies": {
"escape-string-regexp": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz",
"integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==",
"dev": true
}
}
},
"jsdom": {
"version": "15.2.1",
"resolved": "https://registry.npmjs.org/jsdom/-/jsdom-15.2.1.tgz",
@@ -17977,15 +17726,6 @@
"integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==",
"dev": true
},
"klaw": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/klaw/-/klaw-3.0.0.tgz",
"integrity": "sha512-0Fo5oir+O9jnXu5EefYbVK+mHMBeEVEy2cmctR1O1NECcCkPRreJKrS6Qt/j3KC2C148Dfo9i3pCmCMsdqGr0g==",
"dev": true,
"requires": {
"graceful-fs": "^4.1.9"
}
},
"ky": {
"version": "0.28.7",
"resolved": "https://registry.npmjs.org/ky/-/ky-0.28.7.tgz",
@@ -18099,15 +17839,6 @@
"integrity": "sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=",
"dev": true
},
"linkify-it": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-2.2.0.tgz",
"integrity": "sha512-GnAl/knGn+i1U/wjBz3akz2stz+HrHLsxMwHQGofCDfPvlf+gDKN58UtfmUquTY4/MXeE2x7k19KQmeoZi94Iw==",
"dev": true,
"requires": {
"uc.micro": "^1.0.1"
}
},
"load-json-file": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz",
@@ -18444,32 +18175,6 @@
"object-visit": "^1.0.0"
}
},
"markdown-it": {
"version": "10.0.0",
"resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-10.0.0.tgz",
"integrity": "sha512-YWOP1j7UbDNz+TumYP1kpwnP0aEa711cJjrAQrzd0UXlbJfc5aAq0F/PZHjiioqDC1NKgvIMX+o+9Bk7yuM2dg==",
"dev": true,
"requires": {
"argparse": "^1.0.7",
"entities": "~2.0.0",
"linkify-it": "^2.0.0",
"mdurl": "^1.0.1",
"uc.micro": "^1.0.5"
}
},
"markdown-it-anchor": {
"version": "5.3.0",
"resolved": "https://registry.npmjs.org/markdown-it-anchor/-/markdown-it-anchor-5.3.0.tgz",
"integrity": "sha512-/V1MnLL/rgJ3jkMWo84UR+K+jF1cxNG1a+KwqeXqTIJ+jtA8aWSHuigx8lTzauiIjBDbwF3NcWQMotd0Dm39jA==",
"dev": true,
"requires": {}
},
"marked": {
"version": "2.1.3",
"resolved": "https://registry.npmjs.org/marked/-/marked-2.1.3.tgz",
"integrity": "sha512-/Q+7MGzaETqifOMWYEA7HVMaZb4XbcRfaOzcSsHZEith83KGlvaSG33u0SKu89Mj5h+T8V2hM+8O45Qc5XTgwA==",
"dev": true
},
"marky": {
"version": "1.2.2",
"resolved": "https://registry.npmjs.org/marky/-/marky-1.2.2.tgz",
@@ -18511,12 +18216,6 @@
}
}
},
"mdurl": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/mdurl/-/mdurl-1.0.1.tgz",
"integrity": "sha1-/oWy7HWlkDfyrf7BAP1sYBdhFS4=",
"dev": true
},
"memoizee": {
"version": "0.4.15",
"resolved": "https://registry.npmjs.org/memoizee/-/memoizee-0.4.15.tgz",
@@ -20389,15 +20088,6 @@
"integrity": "sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=",
"dev": true
},
"requizzle": {
"version": "0.2.3",
"resolved": "https://registry.npmjs.org/requizzle/-/requizzle-0.2.3.tgz",
"integrity": "sha512-YanoyJjykPxGHii0fZP0uUPEXpvqfBDxWV7s6GKAiiOsiqhX6vHNyW3Qzdmqp/iq/ExbhaGbVrjB4ruEVSM4GQ==",
"dev": true,
"requires": {
"lodash": "^4.17.14"
}
},
"resolve": {
"version": "1.20.0",
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz",
@@ -21322,12 +21012,6 @@
}
}
},
"taffydb": {
"version": "2.6.2",
"resolved": "https://registry.npmjs.org/taffydb/-/taffydb-2.6.2.tgz",
"integrity": "sha1-fLy2S1oUG2ou/CxdLGe04VCyomg=",
"dev": true
},
"tar-fs": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.1.tgz",
@@ -21665,39 +21349,12 @@
"integrity": "sha512-DqGhF5IKoBl8WNf8C1gu8q0xZSInh9j1kJJMqT3a94w1JzVaBU4EXOSMrz9yDqMT0xt3selp83fuFMQ0uzv6qA==",
"dev": true
},
"typescript-closure-tools": {
"version": "0.0.7",
"resolved": "https://registry.npmjs.org/typescript-closure-tools/-/typescript-closure-tools-0.0.7.tgz",
"integrity": "sha512-trz9OhHC8d96c8aqlolk7ckNWlxqqgLPkeSqwi4PuEPu5zMjQqTg8m0E2gNpS3uUPyL0wwBTQOVB/rigFCPJPw==",
"dev": true,
"requires": {
"colors": "*",
"doctrine": "github:fivetran/doctrine",
"escodegen": "*",
"esprima": "*",
"jsdoc": "*",
"mkdirp": "*"
},
"dependencies": {
"doctrine": {
"version": "git+ssh://git@github.com/fivetran/doctrine.git#169ebc1cbf23492363f9442543d1e78e1df9c3d5",
"dev": true,
"from": "doctrine@github:fivetran/doctrine"
}
}
},
"ua-parser-js": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-1.0.2.tgz",
"integrity": "sha512-00y/AXhx0/SsnI51fTc0rLRmafiGOM4/O+ny10Ps7f+j/b8p/ZY11ytMgznXkOVo4GQ+KwQG5UQLkLGirsACRg==",
"dev": true
},
"uc.micro": {
"version": "1.0.6",
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",
"integrity": "sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA==",
"dev": true
},
"unbzip2-stream": {
"version": "1.4.3",
"resolved": "https://registry.npmjs.org/unbzip2-stream/-/unbzip2-stream-1.4.3.tgz",
@@ -21714,12 +21371,6 @@
"integrity": "sha1-5z3T17DXxe2G+6xrCufYxqadUPo=",
"dev": true
},
"underscore": {
"version": "1.13.1",
"resolved": "https://registry.npmjs.org/underscore/-/underscore-1.13.1.tgz",
"integrity": "sha512-hzSoAVtJF+3ZtiFX0VgfFPHEDRm7Y/QPjGyNo4TVdnDTdft3tr8hEkD25a1jC+TjTuE7tkHGKkhwCgs9dgBB2g==",
"dev": true
},
"undertaker": {
"version": "1.3.0",
"resolved": "https://registry.npmjs.org/undertaker/-/undertaker-1.3.0.tgz",
@@ -22221,12 +21872,6 @@
"resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz",
"integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw=="
},
"xmlcreate": {
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/xmlcreate/-/xmlcreate-2.0.4.tgz",
"integrity": "sha512-nquOebG4sngPmGPICTS5EnxqhKbCmz5Ox5hsszI2T6U5qdrJizBc+0ilYSEjTSzU0yZcmvppztXe/5Al5fUwdg==",
"dev": true
},
"xtend": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz",

View File

@@ -96,7 +96,6 @@
"selenium-standalone": "^8.0.3",
"through2": "^4.0.2",
"typescript": "^4.3.2",
"typescript-closure-tools": "^0.0.7",
"webdriverio": "^7.0.3",
"yargs": "^17.2.1"
},

View File

@@ -58,7 +58,7 @@ function checkBuildDir(done) {
// Check that directory exists.
if (!fs.existsSync(BUILD_DIR)) {
done(new Error(`The ${BUILD_DIR} directory does not exist. ` +
'Have both packageTasks.build and typingsTasks.typings been run?'));
'Has packageTasks.build been run?'));
return;
}
// Check files built by buildTasks.build exist in BUILD_DIR.
@@ -75,15 +75,6 @@ function checkBuildDir(done) {
return;
}
}
// Check files built by typings.typings exist in BUILD_DIR.
for (const fileName of ['blockly.d.ts', 'msg/en.d.ts']) {
if (!fs.existsSync(`${TYPINGS_BUILD_DIR}/${fileName}`)) {
done(new Error(
`Your ${TYPINGS_BUILD_DIR} directory does not contain ${fileName}. ` +
'Has typings.typings been run? Try "npm run typings".'));
return;
}
}
done();
}
@@ -395,19 +386,17 @@ function packageReadme() {
* This task copies the typings/blockly.d.ts TypeScript definition
* file into the release directory. The bundled declaration file is
* referenced in package.json in the types property.
* As of Q4 2021 this simply copies the existing ts definition files, since
* generation through typescript-closure-tools does not work with goog.module.
* TODO(5621): Regenerate definition files and copy them into the release dir as
* needed.
*/
function packageDTS() {
const handwrittenSrcs = [
'typings/*.d.ts',
'!typings/blockly.d.ts', // Exclude checked-in copy of blockly.d.ts.
'typings/msg/msg.d.ts',
];
const builtSrcs = [
`${TYPINGS_BUILD_DIR}/blockly.d.ts`, // Use freshly-built one instead.
`${TYPINGS_BUILD_DIR}/msg/*.d.ts`,
];
return gulp.src(handwrittenSrcs, {base: 'typings'})
.pipe(gulp.src(builtSrcs, {base: TYPINGS_BUILD_DIR}))
.pipe(gulp.dest(RELEASE_DIR));
};

View File

@@ -12,7 +12,6 @@ var execSync = require('child_process').execSync;
var fs = require('fs');
var gulp = require('gulp');
var readlineSync = require('readline-sync');
var typings = require('./typings');
var buildTasks = require('./build_tasks');
var gitTasks = require('./git_tasks');
@@ -154,9 +153,10 @@ const rebuildAll = gulp.series(
buildTasks.cleanBuildDir,
buildTasks.build,
buildTasks.checkinBuilt,
typings.typings,
typings.msgTypings,
typings.checkinTypings,
// TODO(5621): Re-enable once typings generation is fixed.
// typings.typings,
// typings.msgTypings,
// typings.checkinTypings,
);
// Package and publish to npm.

View File

@@ -1,145 +0,0 @@
/**
* @license
* Copyright 2018 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
/**
* @fileoverview Gulp script to generate the Typescript definition file (d.ts)
* for Blockly.
*/
var gulp = require('gulp');
gulp.concat = require('gulp-concat');
var argv = require('yargs').argv;
var path = require('path');
var fs = require('fs');
var rimraf = require('rimraf');
var execSync = require('child_process').execSync;
var {TYPINGS_BUILD_DIR} = require('./config');
/**
* Recursively generates a list of file paths with the specified extension
* contained within the specified basePath.
* @param {string} basePath The base path to use.
* @param {string} filter The extension name to filter for.
* @param {Array<string>} excludePaths The paths to exclude from search.
* @return {Array<string>} The generated file paths.
*/
function getFilePath(basePath, filter, excludePaths) {
const files = [];
const dirContents = fs.readdirSync(basePath);
dirContents.forEach((fn) => {
const filePath = path.join(basePath, fn);
const excluded =
!excludePaths.every((exPath) => !filePath.startsWith(exPath));
if (excluded) {
return;
}
const stat = fs.lstatSync(filePath);
if (stat.isDirectory()) {
files.push(...getFilePath(filePath, filter, excludePaths));
} else if (filePath.endsWith(filter)) {
files.push(filePath);
}
});
return files;
}
// Generates the TypeScript definition file (d.ts) for Blockly.
// As well as generating the typings of each of the files under core/ and msg/,
// the script also pulls in a number of part files from typings/parts.
// This includes the header (incl License), additional useful interfaces
// including Blockly Options and Google Closure typings.
function typings() {
const tmpDir = path.join(TYPINGS_BUILD_DIR, 'tmp');
// Clean directory if exists.
if (fs.existsSync(tmpDir)) {
rimraf.sync(tmpDir);
}
fs.mkdirSync(tmpDir, {recursive: true});
const excludePaths = [
"core/renderers/geras",
"core/renderers/minimalist",
"core/renderers/thrasos",
"core/renderers/zelos",
];
const blocklySrcs = [
'core',
'msg'
]
// Find all files that will be included in the typings file.
let files = [];
blocklySrcs.forEach((basePath) => {
files.push(...getFilePath(basePath, '.js', excludePaths));
});
// Generate typings file for each file.
files.forEach((file) => {
const typescriptFileName = `${path.join(tmpDir, file)}.d.ts`;
if (file.indexOf('core/msg.js') > -1) {
return;
}
const cmd = `closure2ts ${file} ${typescriptFileName}`;
let outputMode = 'ignore';
if (argv.verbose) {
console.log(`Generating typings for ${file}`);
outputMode = 'inherit';
}
execSync(cmd, { stdio: outputMode });
});
const srcs = [
'typings/templates/blockly-header.template',
'typings/templates/blockly-interfaces.template',
`${tmpDir}/core/**/*`,
`${tmpDir}/msg/**`
];
return gulp.src(srcs)
.pipe(gulp.concat('blockly.d.ts'))
.pipe(gulp.dest(TYPINGS_BUILD_DIR))
.on('end', function () {
// Clean up tmp directory.
if (fs.existsSync(tmpDir)) {
rimraf.sync(tmpDir);
}
});
};
// Generates the TypeScript definition files (d.ts) for Blockly locales.
function msgTypings(cb) {
const template =
fs.readFileSync(path.join('typings/templates/msg.template'), 'utf-8');
const msgFiles = fs.readdirSync(path.join('msg', 'json'));
const msgDir = path.join(TYPINGS_BUILD_DIR, 'msg');
if (!fs.existsSync(msgDir)) {
fs.mkdirSync(msgDir, {recursive: true});
}
msgFiles.forEach(msg => {
const localeName = msg.substring(0, msg.indexOf('.json'));
const msgTypings = template.slice().replace(/<%= locale %>/gi, localeName);
fs.writeFileSync(path.join(TYPINGS_BUILD_DIR, 'msg', localeName + '.d.ts'),
msgTypings, 'utf-8');
});
cb();
}
/**
* This task copies built files from BUILD_DIR back to the repository
* so they can be committed to git.
*/
function checkinTypings() {
return gulp.src([
`${TYPINGS_BUILD_DIR}/**.d.ts`,
`${TYPINGS_BUILD_DIR}/**/**.d.ts`,
]).pipe(gulp.dest('typings'));
};
module.exports = {
typings: typings,
msgTypings: msgTypings,
checkinTypings: checkinTypings,
};

View File

@@ -59,7 +59,8 @@ fi
run_test_command "build-debug" "npm run build-debug"
# Generate TypeScript typings and ensure there are no errors.
run_test_command "typings" "npm run typings"
# TODO(5621): Re-enable this test once typings generation is fixed.
# run_test_command "typings" "npm run typings"
# Check the sizes of built files for unexpected growth.
run_test_command "metadata" "tests/scripts/check_metadata.sh"