IDEA-273510 Building of distribution — provide report like webpack/rollup do

GitOrigin-RevId: 0b838c5995df58136f4af8771144aac744902555
This commit is contained in:
Vladimir Krivosheev
2021-07-12 18:39:57 +02:00
committed by intellij-monorepo-bot
parent b383c8d5ca
commit 3de0fd9b83
18 changed files with 1301 additions and 58 deletions

View File

@@ -106,7 +106,7 @@ final class IntelliJCoreArtifactsBuilder {
void generateProjectStructureMapping(@NotNull File targetFile) { void generateProjectStructureMapping(@NotNull File targetFile) {
def mapping = new ProjectStructureMapping() def mapping = new ProjectStructureMapping()
processCoreLayout(buildContext.paths.tempDir, mapping, false) processCoreLayout(buildContext.paths.tempDir, mapping, false)
mapping.addEntry(new ProjectLibraryEntry("annotations.jar", "jetbrains-annotations-java5", "")) mapping.addEntry(new ProjectLibraryEntry("annotations.jar", "jetbrains-annotations-java5", null, 0))
mapping.generateJsonFile(targetFile.toPath()) mapping.generateJsonFile(targetFile.toPath())
} }

View File

@@ -8,14 +8,16 @@ import java.nio.channels.FileChannel
import java.nio.file.Files import java.nio.file.Files
import java.nio.file.Path import java.nio.file.Path
fun mergeJars(targetFile: Path, files: List<Path>) { fun mergeJars(targetFile: Path, files: List<Path>): Map<Path, Int> {
Files.createDirectories(targetFile.parent) Files.createDirectories(targetFile.parent)
FileChannel.open(targetFile, RW_CREATE_NEW).use { outChannel -> FileChannel.open(targetFile, RW_CREATE_NEW).use { outChannel ->
val packageIndexBuilder = PackageIndexBuilder() val packageIndexBuilder = PackageIndexBuilder()
val zipCreator = ZipFileWriter(outChannel, deflater = null) val zipCreator = ZipFileWriter(outChannel, deflater = null)
val sizes = HashMap<Path, Int>()
for (file in files) { for (file in files) {
ImmutableZipFile.load(file).use { zipFile -> ImmutableZipFile.load(file).use { zipFile ->
@Suppress("SpellCheckingInspection")
val entries = zipFile.entries.filter { val entries = zipFile.entries.filter {
val name = it.name val name = it.name
!name.endsWith(".kotlin_metadata") && !name.endsWith(".kotlin_metadata") &&
@@ -42,10 +44,13 @@ fun mergeJars(targetFile: Path, files: List<Path>) {
} }
writeEntries(entries, zipCreator, zipFile) writeEntries(entries, zipCreator, zipFile)
packageIndexBuilder.add(entries) packageIndexBuilder.add(entries)
sizes.put(file, entries.asSequence().map { it.size }.sum())
} }
} }
writeDirs(packageIndexBuilder.dirsToCreate, zipCreator) writeDirs(packageIndexBuilder.dirsToCreate, zipCreator)
packageIndexBuilder.writePackageIndex(zipCreator) packageIndexBuilder.writePackageIndex(zipCreator)
zipCreator.finish() zipCreator.finish()
return sizes
} }
} }

2
docs/.gitignore vendored
View File

@@ -1,4 +1,4 @@
dist dist
plugin-graph/node_modules node_modules
plugin-graph/plugin-graph.local.json plugin-graph/plugin-graph.local.json
.DS_Store .DS_Store

View File

@@ -0,0 +1,17 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Dist Content</title>
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1, maximum-scale=1">
</head>
<body>
<input id="fileInput"
type="file"
class="p-1 fixed right-0 text-sm z-50"
accept="application/json"/>
<div id="app" class="w-screen h-screen"></div>
<script type="module" src="/src/main.js"></script>
</body>
</html>

View File

@@ -0,0 +1,20 @@
{
"version": "0.0.0",
"private": true,
"scripts": {
"dev": "vite",
"build": "vite build --emptyOutDir",
"deploy": "pnpm run build && space hosting publish --public ij dist-content ./dist",
"serve": "vite preview"
},
"dependencies": {
"echarts": "^5.1.2",
"pretty-bytes": "^5.6.0"
},
"devDependencies": {
"autoprefixer": "^10.2.6",
"postcss": "^8.3.5",
"tailwindcss": "^2.2.4",
"vite": "^2.4.2"
}
}

932
docs/dist-visualizer/pnpm-lock.yaml generated Normal file
View File

@@ -0,0 +1,932 @@
lockfileVersion: 5.3
specifiers:
autoprefixer: ^10.2.6
echarts: ^5.1.2
postcss: ^8.3.5
pretty-bytes: ^5.6.0
tailwindcss: ^2.2.4
vite: ^2.4.2
dependencies:
echarts: 5.1.2
pretty-bytes: 5.6.0
devDependencies:
autoprefixer: 10.3.0_postcss@8.3.5
postcss: 8.3.5
tailwindcss: 2.2.4_ab1f570292601e188570cd782149477a
vite: 2.4.2
packages:
/@babel/code-frame/7.14.5:
resolution: {integrity: sha512-9pzDqyc6OLDaqe+zbACgFkb6fKMNG6CObKpnYXChRsvYGyEdc7CA2BaqeOM+vOtCS5ndmJicPJhKAwYRI6UfFw==}
engines: {node: '>=6.9.0'}
dependencies:
'@babel/highlight': 7.14.5
dev: true
/@babel/helper-validator-identifier/7.14.5:
resolution: {integrity: sha512-5lsetuxCLilmVGyiLEfoHBRX8UCFD+1m2x3Rj97WrW3V7H3u4RWRXA4evMjImCsin2J2YT0QaVDGf+z8ondbAg==}
engines: {node: '>=6.9.0'}
dev: true
/@babel/highlight/7.14.5:
resolution: {integrity: sha512-qf9u2WFWVV0MppaL877j2dBtQIDgmidgjGk5VIMw3OadXvYaXn66U1BFlH2t4+t3i+8PhedppRv+i40ABzd+gg==}
engines: {node: '>=6.9.0'}
dependencies:
'@babel/helper-validator-identifier': 7.14.5
chalk: 2.4.2
js-tokens: 4.0.0
dev: true
/@fullhuman/postcss-purgecss/4.0.3_postcss@8.3.5:
resolution: {integrity: sha512-/EnQ9UDWGGqHkn1UKAwSgh+gJHPKmD+Z+5dQ4gWT4qq2NUyez3zqAfZNwFH3eSgmgO+wjTXfhlLchx2M9/K+7Q==}
peerDependencies:
postcss: ^8.0.0
dependencies:
postcss: 8.3.5
purgecss: 4.0.3
dev: true
/@nodelib/fs.scandir/2.1.5:
resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==}
engines: {node: '>= 8'}
dependencies:
'@nodelib/fs.stat': 2.0.5
run-parallel: 1.2.0
dev: true
/@nodelib/fs.stat/2.0.5:
resolution: {integrity: sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==}
engines: {node: '>= 8'}
dev: true
/@nodelib/fs.walk/1.2.8:
resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==}
engines: {node: '>= 8'}
dependencies:
'@nodelib/fs.scandir': 2.1.5
fastq: 1.11.1
dev: true
/@types/parse-json/4.0.0:
resolution: {integrity: sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==}
dev: true
/acorn-node/1.8.2:
resolution: {integrity: sha512-8mt+fslDufLYntIoPAaIMUe/lrbrehIiwmR3t2k9LljIzoigEPF27eLk2hy8zSGzmR/ogr7zbRKINMo1u0yh5A==}
dependencies:
acorn: 7.4.1
acorn-walk: 7.2.0
xtend: 4.0.2
dev: true
/acorn-walk/7.2.0:
resolution: {integrity: sha512-OPdCF6GsMIP+Az+aWfAAOEt2/+iVDKE7oy6lJ098aoe59oAmK76qV6Gw60SbZ8jHuG2wH058GF4pLFbYamYrVA==}
engines: {node: '>=0.4.0'}
dev: true
/acorn/7.4.1:
resolution: {integrity: sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A==}
engines: {node: '>=0.4.0'}
hasBin: true
dev: true
/ansi-styles/3.2.1:
resolution: {integrity: sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==}
engines: {node: '>=4'}
dependencies:
color-convert: 1.9.3
dev: true
/ansi-styles/4.3.0:
resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==}
engines: {node: '>=8'}
dependencies:
color-convert: 2.0.1
dev: true
/anymatch/3.1.2:
resolution: {integrity: sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==}
engines: {node: '>= 8'}
dependencies:
normalize-path: 3.0.0
picomatch: 2.3.0
dev: true
/arg/5.0.0:
resolution: {integrity: sha512-4P8Zm2H+BRS+c/xX1LrHw0qKpEhdlZjLCgWy+d78T9vqa2Z2SiD2wMrYuWIAFy5IZUD7nnNXroRttz+0RzlrzQ==}
dev: true
/autoprefixer/10.3.0_postcss@8.3.5:
resolution: {integrity: sha512-BzVzdjs47nT3MphTddr8eSsPVEIUCF96X6iC8V5iEB8RtxrU+ybtdhHV5rsqRqOsoyh/acQaYs7YupHPUECgmg==}
engines: {node: ^10 || ^12 || >=14}
hasBin: true
peerDependencies:
postcss: ^8.1.0
dependencies:
browserslist: 4.16.6
caniuse-lite: 1.0.30001243
colorette: 1.2.2
fraction.js: 4.1.1
normalize-range: 0.1.2
postcss: 8.3.5
postcss-value-parser: 4.1.0
dev: true
/balanced-match/1.0.2:
resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==}
dev: true
/binary-extensions/2.2.0:
resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==}
engines: {node: '>=8'}
dev: true
/brace-expansion/1.1.11:
resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==}
dependencies:
balanced-match: 1.0.2
concat-map: 0.0.1
dev: true
/braces/3.0.2:
resolution: {integrity: sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==}
engines: {node: '>=8'}
dependencies:
fill-range: 7.0.1
dev: true
/browserslist/4.16.6:
resolution: {integrity: sha512-Wspk/PqO+4W9qp5iUTJsa1B/QrYn1keNCcEP5OvP7WBwT4KaDly0uONYmC6Xa3Z5IqnUgS0KcgLYu1l74x0ZXQ==}
engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7}
hasBin: true
dependencies:
caniuse-lite: 1.0.30001243
colorette: 1.2.2
electron-to-chromium: 1.3.772
escalade: 3.1.1
node-releases: 1.1.73
dev: true
/bytes/3.1.0:
resolution: {integrity: sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==}
engines: {node: '>= 0.8'}
dev: true
/callsites/3.1.0:
resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==}
engines: {node: '>=6'}
dev: true
/camelcase-css/2.0.1:
resolution: {integrity: sha512-QOSvevhslijgYwRx6Rv7zKdMF8lbRmx+uQGx2+vDc+KI/eBnsy9kit5aj23AgGu3pa4t9AgwbnXWqS+iOY+2aA==}
engines: {node: '>= 6'}
dev: true
/caniuse-lite/1.0.30001243:
resolution: {integrity: sha512-vNxw9mkTBtkmLFnJRv/2rhs1yufpDfCkBZexG3Y0xdOH2Z/eE/85E4Dl5j1YUN34nZVsSp6vVRFQRrez9wJMRA==}
dev: true
/chalk/2.4.2:
resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==}
engines: {node: '>=4'}
dependencies:
ansi-styles: 3.2.1
escape-string-regexp: 1.0.5
supports-color: 5.5.0
dev: true
/chalk/4.1.1:
resolution: {integrity: sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg==}
engines: {node: '>=10'}
dependencies:
ansi-styles: 4.3.0
supports-color: 7.2.0
dev: true
/chokidar/3.5.2:
resolution: {integrity: sha512-ekGhOnNVPgT77r4K/U3GDhu+FQ2S8TnK/s2KbIGXi0SZWuwkZ2QNyfWdZW+TVfn84DpEP7rLeCt2UI6bJ8GwbQ==}
engines: {node: '>= 8.10.0'}
dependencies:
anymatch: 3.1.2
braces: 3.0.2
glob-parent: 5.1.2
is-binary-path: 2.1.0
is-glob: 4.0.1
normalize-path: 3.0.0
readdirp: 3.6.0
optionalDependencies:
fsevents: 2.3.2
dev: true
/color-convert/1.9.3:
resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==}
dependencies:
color-name: 1.1.3
dev: true
/color-convert/2.0.1:
resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==}
engines: {node: '>=7.0.0'}
dependencies:
color-name: 1.1.4
dev: true
/color-name/1.1.3:
resolution: {integrity: sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=}
dev: true
/color-name/1.1.4:
resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==}
dev: true
/color-string/1.5.5:
resolution: {integrity: sha512-jgIoum0OfQfq9Whcfc2z/VhCNcmQjWbey6qBX0vqt7YICflUmBCh9E9CiQD5GSJ+Uehixm3NUwHVhqUAWRivZg==}
dependencies:
color-name: 1.1.4
simple-swizzle: 0.2.2
dev: true
/color/3.1.3:
resolution: {integrity: sha512-xgXAcTHa2HeFCGLE9Xs/R82hujGtu9Jd9x4NW3T34+OMs7VoPsjwzRczKHvTAHeJwWFwX5j15+MgAppE8ztObQ==}
dependencies:
color-convert: 1.9.3
color-string: 1.5.5
dev: true
/colorette/1.2.2:
resolution: {integrity: sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==}
dev: true
/commander/6.2.1:
resolution: {integrity: sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==}
engines: {node: '>= 6'}
dev: true
/concat-map/0.0.1:
resolution: {integrity: sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=}
dev: true
/cosmiconfig/7.0.0:
resolution: {integrity: sha512-pondGvTuVYDk++upghXJabWzL6Kxu6f26ljFw64Swq9v6sQPUL3EUlVDV56diOjpCayKihL6hVe8exIACU4XcA==}
engines: {node: '>=10'}
dependencies:
'@types/parse-json': 4.0.0
import-fresh: 3.3.0
parse-json: 5.2.0
path-type: 4.0.0
yaml: 1.10.2
dev: true
/css-unit-converter/1.1.2:
resolution: {integrity: sha512-IiJwMC8rdZE0+xiEZHeru6YoONC4rfPMqGm2W85jMIbkFvv5nFTwJVFHam2eFrN6txmoUYFAFXiv8ICVeTO0MA==}
dev: true
/cssesc/3.0.0:
resolution: {integrity: sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==}
engines: {node: '>=4'}
hasBin: true
dev: true
/defined/1.0.0:
resolution: {integrity: sha1-yY2bzvdWdBiOEQlpFRGZ45sfppM=}
dev: true
/detective/5.2.0:
resolution: {integrity: sha512-6SsIx+nUUbuK0EthKjv0zrdnajCCXVYGmbYYiYjFVpzcjwEs/JMDZ8tPRG29J/HhN56t3GJp2cGSWDRjjot8Pg==}
engines: {node: '>=0.8.0'}
hasBin: true
dependencies:
acorn-node: 1.8.2
defined: 1.0.0
minimist: 1.2.5
dev: true
/didyoumean/1.2.2:
resolution: {integrity: sha512-gxtyfqMg7GKyhQmb056K7M3xszy/myH8w+B4RT+QXBQsvAOdc3XymqDDPHx1BgPgsdAA5SIifona89YtRATDzw==}
dev: true
/dlv/1.1.3:
resolution: {integrity: sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA==}
dev: true
/echarts/5.1.2:
resolution: {integrity: sha512-okUhO4sw22vwZp+rTPNjd/bvTdpug4K4sHNHyrV8NdAncIX9/AarlolFqtJCAYKGFYhUBNjIWu1EznFrSWTFxg==}
dependencies:
tslib: 2.0.3
zrender: 5.1.1
dev: false
/electron-to-chromium/1.3.772:
resolution: {integrity: sha512-X/6VRCXWALzdX+RjCtBU6cyg8WZgoxm9YA02COmDOiNJEZ59WkQggDbWZ4t/giHi/3GS+cvdrP6gbLISANAGYA==}
dev: true
/error-ex/1.3.2:
resolution: {integrity: sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==}
dependencies:
is-arrayish: 0.2.1
dev: true
/esbuild/0.12.9:
resolution: {integrity: sha512-MWRhAbMOJ9RJygCrt778rz/qNYgA4ZVj6aXnNPxFjs7PmIpb0fuB9Gmg5uWrr6n++XKwwm/RmSz6RR5JL2Ocsw==}
hasBin: true
requiresBuild: true
dev: true
/escalade/3.1.1:
resolution: {integrity: sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==}
engines: {node: '>=6'}
dev: true
/escape-string-regexp/1.0.5:
resolution: {integrity: sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=}
engines: {node: '>=0.8.0'}
dev: true
/fast-glob/3.2.7:
resolution: {integrity: sha512-rYGMRwip6lUMvYD3BTScMwT1HtAs2d71SMv66Vrxs0IekGZEjhM0pcMfjQPnknBt2zeCwQMEupiN02ZP4DiT1Q==}
engines: {node: '>=8'}
dependencies:
'@nodelib/fs.stat': 2.0.5
'@nodelib/fs.walk': 1.2.8
glob-parent: 5.1.2
merge2: 1.4.1
micromatch: 4.0.4
dev: true
/fastq/1.11.1:
resolution: {integrity: sha512-HOnr8Mc60eNYl1gzwp6r5RoUyAn5/glBolUzP/Ez6IFVPMPirxn/9phgL6zhOtaTy7ISwPvQ+wT+hfcRZh/bzw==}
dependencies:
reusify: 1.0.4
dev: true
/fill-range/7.0.1:
resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==}
engines: {node: '>=8'}
dependencies:
to-regex-range: 5.0.1
dev: true
/fraction.js/4.1.1:
resolution: {integrity: sha512-MHOhvvxHTfRFpF1geTK9czMIZ6xclsEor2wkIGYYq+PxcQqT7vStJqjhe6S1TenZrMZzo+wlqOufBDVepUEgPg==}
dev: true
/fs-extra/10.0.0:
resolution: {integrity: sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==}
engines: {node: '>=12'}
dependencies:
graceful-fs: 4.2.6
jsonfile: 6.1.0
universalify: 2.0.0
dev: true
/fs.realpath/1.0.0:
resolution: {integrity: sha1-FQStJSMVjKpA20onh8sBQRmU6k8=}
dev: true
/fsevents/2.3.2:
resolution: {integrity: sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==}
engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0}
os: [darwin]
dev: true
optional: true
/function-bind/1.1.1:
resolution: {integrity: sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==}
dev: true
/glob-parent/5.1.2:
resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==}
engines: {node: '>= 6'}
dependencies:
is-glob: 4.0.1
dev: true
/glob-parent/6.0.0:
resolution: {integrity: sha512-Hdd4287VEJcZXUwv1l8a+vXC1GjOQqXe+VS30w/ypihpcnu9M1n3xeYeJu5CBpeEQj2nAab2xxz28GuA3vp4Ww==}
engines: {node: '>=10.13.0'}
dependencies:
is-glob: 4.0.1
dev: true
/glob/7.1.7:
resolution: {integrity: sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==}
dependencies:
fs.realpath: 1.0.0
inflight: 1.0.6
inherits: 2.0.4
minimatch: 3.0.4
once: 1.4.0
path-is-absolute: 1.0.1
dev: true
/graceful-fs/4.2.6:
resolution: {integrity: sha512-nTnJ528pbqxYanhpDYsi4Rd8MAeaBA67+RZ10CM1m3bTAVFEDcd5AuA4a6W5YkGZ1iNXHzZz8T6TBKLeBuNriQ==}
dev: true
/has-flag/3.0.0:
resolution: {integrity: sha1-tdRU3CGZriJWmfNGfloH87lVuv0=}
engines: {node: '>=4'}
dev: true
/has-flag/4.0.0:
resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==}
engines: {node: '>=8'}
dev: true
/has/1.0.3:
resolution: {integrity: sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==}
engines: {node: '>= 0.4.0'}
dependencies:
function-bind: 1.1.1
dev: true
/html-tags/3.1.0:
resolution: {integrity: sha512-1qYz89hW3lFDEazhjW0yVAV87lw8lVkrJocr72XmBkMKsoSVJCQx3W8BXsC7hO2qAt8BoVjYjtAcZ9perqGnNg==}
engines: {node: '>=8'}
dev: true
/import-cwd/3.0.0:
resolution: {integrity: sha512-4pnzH16plW+hgvRECbDWpQl3cqtvSofHWh44met7ESfZ8UZOWWddm8hEyDTqREJ9RbYHY8gi8DqmaelApoOGMg==}
engines: {node: '>=8'}
dependencies:
import-from: 3.0.0
dev: true
/import-fresh/3.3.0:
resolution: {integrity: sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==}
engines: {node: '>=6'}
dependencies:
parent-module: 1.0.1
resolve-from: 4.0.0
dev: true
/import-from/3.0.0:
resolution: {integrity: sha512-CiuXOFFSzkU5x/CR0+z7T91Iht4CXgfCxVOFRhh2Zyhg5wOpWvvDLQUsWl+gcN+QscYBjez8hDCt85O7RLDttQ==}
engines: {node: '>=8'}
dependencies:
resolve-from: 5.0.0
dev: true
/inflight/1.0.6:
resolution: {integrity: sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=}
dependencies:
once: 1.4.0
wrappy: 1.0.2
dev: true
/inherits/2.0.4:
resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==}
dev: true
/is-arrayish/0.2.1:
resolution: {integrity: sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=}
dev: true
/is-arrayish/0.3.2:
resolution: {integrity: sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==}
dev: true
/is-binary-path/2.1.0:
resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==}
engines: {node: '>=8'}
dependencies:
binary-extensions: 2.2.0
dev: true
/is-core-module/2.4.0:
resolution: {integrity: sha512-6A2fkfq1rfeQZjxrZJGerpLCTHRNEBiSgnu0+obeJpEPZRUooHgsizvzv0ZjJwOz3iWIHdJtVWJ/tmPr3D21/A==}
dependencies:
has: 1.0.3
dev: true
/is-extglob/2.1.1:
resolution: {integrity: sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=}
engines: {node: '>=0.10.0'}
dev: true
/is-glob/4.0.1:
resolution: {integrity: sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==}
engines: {node: '>=0.10.0'}
dependencies:
is-extglob: 2.1.1
dev: true
/is-number/7.0.0:
resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==}
engines: {node: '>=0.12.0'}
dev: true
/js-tokens/4.0.0:
resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==}
dev: true
/json-parse-even-better-errors/2.3.1:
resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==}
dev: true
/jsonfile/6.1.0:
resolution: {integrity: sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==}
dependencies:
universalify: 2.0.0
optionalDependencies:
graceful-fs: 4.2.6
dev: true
/lilconfig/2.0.3:
resolution: {integrity: sha512-EHKqr/+ZvdKCifpNrJCKxBTgk5XupZA3y/aCPY9mxfgBzmgh93Mt/WqjjQ38oMxXuvDokaKiM3lAgvSH2sjtHg==}
engines: {node: '>=10'}
dev: true
/lines-and-columns/1.1.6:
resolution: {integrity: sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=}
dev: true
/lodash.toarray/4.4.0:
resolution: {integrity: sha1-JMS/zWsvuji/0FlNsRedjptlZWE=}
dev: true
/lodash.topath/4.5.2:
resolution: {integrity: sha1-NhY1Hzu6YZlKCTGYlmC9AyVP0Ak=}
dev: true
/lodash/4.17.21:
resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==}
dev: true
/merge2/1.4.1:
resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==}
engines: {node: '>= 8'}
dev: true
/micromatch/4.0.4:
resolution: {integrity: sha512-pRmzw/XUcwXGpD9aI9q/0XOwLNygjETJ8y0ao0wdqprrzDa4YnxLcz7fQRZr8voh8V10kGhABbNcHVk5wHgWwg==}
engines: {node: '>=8.6'}
dependencies:
braces: 3.0.2
picomatch: 2.3.0
dev: true
/minimatch/3.0.4:
resolution: {integrity: sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==}
dependencies:
brace-expansion: 1.1.11
dev: true
/minimist/1.2.5:
resolution: {integrity: sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==}
dev: true
/modern-normalize/1.1.0:
resolution: {integrity: sha512-2lMlY1Yc1+CUy0gw4H95uNN7vjbpoED7NNRSBHE25nWfLBdmMzFCsPshlzbxHz+gYMcBEUN8V4pU16prcdPSgA==}
engines: {node: '>=6'}
dev: true
/nanoid/3.1.23:
resolution: {integrity: sha512-FiB0kzdP0FFVGDKlRLEQ1BgDzU87dy5NnzjeW9YZNt+/c3+q82EQDUwniSAUxp/F0gFNI1ZhKU1FqYsMuqZVnw==}
engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1}
hasBin: true
dev: true
/node-emoji/1.10.0:
resolution: {integrity: sha512-Yt3384If5H6BYGVHiHwTL+99OzJKHhgp82S8/dktEK73T26BazdgZ4JZh92xSVtGNJvz9UbXdNAc5hcrXV42vw==}
dependencies:
lodash.toarray: 4.4.0
dev: true
/node-releases/1.1.73:
resolution: {integrity: sha512-uW7fodD6pyW2FZNZnp/Z3hvWKeEW1Y8R1+1CnErE8cXFXzl5blBOoVB41CvMer6P6Q0S5FXDwcHgFd1Wj0U9zg==}
dev: true
/normalize-path/3.0.0:
resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==}
engines: {node: '>=0.10.0'}
dev: true
/normalize-range/0.1.2:
resolution: {integrity: sha1-LRDAa9/TEuqXd2laTShDlFa3WUI=}
engines: {node: '>=0.10.0'}
dev: true
/object-hash/2.2.0:
resolution: {integrity: sha512-gScRMn0bS5fH+IuwyIFgnh9zBdo4DV+6GhygmWM9HyNJSgS0hScp1f5vjtm7oIIOiT9trXrShAkLFSc2IqKNgw==}
engines: {node: '>= 6'}
dev: true
/once/1.4.0:
resolution: {integrity: sha1-WDsap3WWHUsROsF9nFC6753Xa9E=}
dependencies:
wrappy: 1.0.2
dev: true
/parent-module/1.0.1:
resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==}
engines: {node: '>=6'}
dependencies:
callsites: 3.1.0
dev: true
/parse-json/5.2.0:
resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==}
engines: {node: '>=8'}
dependencies:
'@babel/code-frame': 7.14.5
error-ex: 1.3.2
json-parse-even-better-errors: 2.3.1
lines-and-columns: 1.1.6
dev: true
/path-is-absolute/1.0.1:
resolution: {integrity: sha1-F0uSaHNVNP+8es5r9TpanhtcX18=}
engines: {node: '>=0.10.0'}
dev: true
/path-parse/1.0.7:
resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==}
dev: true
/path-type/4.0.0:
resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==}
engines: {node: '>=8'}
dev: true
/picomatch/2.3.0:
resolution: {integrity: sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==}
engines: {node: '>=8.6'}
dev: true
/postcss-js/3.0.3:
resolution: {integrity: sha512-gWnoWQXKFw65Hk/mi2+WTQTHdPD5UJdDXZmX073EY/B3BWnYjO4F4t0VneTCnCGQ5E5GsCdMkzPaTXwl3r5dJw==}
engines: {node: '>=10.0'}
dependencies:
camelcase-css: 2.0.1
postcss: 8.3.5
dev: true
/postcss-load-config/3.1.0:
resolution: {integrity: sha512-ipM8Ds01ZUophjDTQYSVP70slFSYg3T0/zyfII5vzhN6V57YSxMgG5syXuwi5VtS8wSf3iL30v0uBdoIVx4Q0g==}
engines: {node: '>= 10'}
peerDependencies:
ts-node: '>=9.0.0'
peerDependenciesMeta:
ts-node:
optional: true
dependencies:
import-cwd: 3.0.0
lilconfig: 2.0.3
yaml: 1.10.2
dev: true
/postcss-nested/5.0.5_postcss@8.3.5:
resolution: {integrity: sha512-GSRXYz5bccobpTzLQZXOnSOfKl6TwVr5CyAQJUPub4nuRJSOECK5AqurxVgmtxP48p0Kc/ndY/YyS1yqldX0Ew==}
engines: {node: '>=10.0'}
peerDependencies:
postcss: ^8.1.13
dependencies:
postcss: 8.3.5
postcss-selector-parser: 6.0.6
dev: true
/postcss-selector-parser/6.0.6:
resolution: {integrity: sha512-9LXrvaaX3+mcv5xkg5kFwqSzSH1JIObIx51PrndZwlmznwXRfxMddDvo9gve3gVR8ZTKgoFDdWkbRFmEhT4PMg==}
engines: {node: '>=4'}
dependencies:
cssesc: 3.0.0
util-deprecate: 1.0.2
dev: true
/postcss-value-parser/3.3.1:
resolution: {integrity: sha512-pISE66AbVkp4fDQ7VHBwRNXzAAKJjw4Vw7nWI/+Q3vuly7SNfgYXvm6i5IgFylHGK5sP/xHAbB7N49OS4gWNyQ==}
dev: true
/postcss-value-parser/4.1.0:
resolution: {integrity: sha512-97DXOFbQJhk71ne5/Mt6cOu6yxsSfM0QGQyl0L25Gca4yGWEGJaig7l7gbCX623VqTBNGLRLaVUCnNkcedlRSQ==}
dev: true
/postcss/8.3.5:
resolution: {integrity: sha512-NxTuJocUhYGsMiMFHDUkmjSKT3EdH4/WbGF6GCi1NDGk+vbcUTun4fpbOqaPtD8IIsztA2ilZm2DhYCuyN58gA==}
engines: {node: ^10 || ^12 || >=14}
dependencies:
colorette: 1.2.2
nanoid: 3.1.23
source-map-js: 0.6.2
dev: true
/pretty-bytes/5.6.0:
resolution: {integrity: sha512-FFw039TmrBqFK8ma/7OL3sDz/VytdtJr044/QUJtH0wK9lb9jLq9tJyIxUwtQJHwar2BqtiA4iCWSwo9JLkzFg==}
engines: {node: '>=6'}
dev: false
/pretty-hrtime/1.0.3:
resolution: {integrity: sha1-t+PqQkNaTJsnWdmeDyAesZWALuE=}
engines: {node: '>= 0.8'}
dev: true
/purgecss/4.0.3:
resolution: {integrity: sha512-PYOIn5ibRIP34PBU9zohUcCI09c7drPJJtTDAc0Q6QlRz2/CHQ8ywGLdE7ZhxU2VTqB7p5wkvj5Qcm05Rz3Jmw==}
hasBin: true
dependencies:
commander: 6.2.1
glob: 7.1.7
postcss: 8.3.5
postcss-selector-parser: 6.0.6
dev: true
/queue-microtask/1.2.3:
resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==}
dev: true
/quick-lru/5.1.1:
resolution: {integrity: sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==}
engines: {node: '>=10'}
dev: true
/readdirp/3.6.0:
resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==}
engines: {node: '>=8.10.0'}
dependencies:
picomatch: 2.3.0
dev: true
/reduce-css-calc/2.1.8:
resolution: {integrity: sha512-8liAVezDmUcH+tdzoEGrhfbGcP7nOV4NkGE3a74+qqvE7nt9i4sKLGBuZNOnpI4WiGksiNPklZxva80061QiPg==}
dependencies:
css-unit-converter: 1.1.2
postcss-value-parser: 3.3.1
dev: true
/resolve-from/4.0.0:
resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==}
engines: {node: '>=4'}
dev: true
/resolve-from/5.0.0:
resolution: {integrity: sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==}
engines: {node: '>=8'}
dev: true
/resolve/1.20.0:
resolution: {integrity: sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==}
dependencies:
is-core-module: 2.4.0
path-parse: 1.0.7
dev: true
/reusify/1.0.4:
resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==}
engines: {iojs: '>=1.0.0', node: '>=0.10.0'}
dev: true
/rimraf/3.0.2:
resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==}
hasBin: true
dependencies:
glob: 7.1.7
dev: true
/rollup/2.52.2:
resolution: {integrity: sha512-4RlFC3k2BIHlUsJ9mGd8OO+9Lm2eDF5P7+6DNQOp5sx+7N/1tFM01kELfbxlMX3MxT6owvLB1ln4S3QvvQlbUA==}
engines: {node: '>=10.0.0'}
hasBin: true
optionalDependencies:
fsevents: 2.3.2
dev: true
/run-parallel/1.2.0:
resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==}
dependencies:
queue-microtask: 1.2.3
dev: true
/simple-swizzle/0.2.2:
resolution: {integrity: sha1-pNprY1/8zMoz9w0Xy5JZLeleVXo=}
dependencies:
is-arrayish: 0.3.2
dev: true
/source-map-js/0.6.2:
resolution: {integrity: sha512-/3GptzWzu0+0MBQFrDKzw/DvvMTUORvgY6k6jd/VS6iCR4RDTKWH6v6WPwQoUO8667uQEf9Oe38DxAYWY5F/Ug==}
engines: {node: '>=0.10.0'}
dev: true
/supports-color/5.5.0:
resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==}
engines: {node: '>=4'}
dependencies:
has-flag: 3.0.0
dev: true
/supports-color/7.2.0:
resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==}
engines: {node: '>=8'}
dependencies:
has-flag: 4.0.0
dev: true
/tailwindcss/2.2.4_ab1f570292601e188570cd782149477a:
resolution: {integrity: sha512-OdBCPgazNNsknSP+JfrPzkay9aqKjhKtFhbhgxHgvEFdHy/GuRPo2SCJ4w1SFTN8H6FPI4m6qD/Jj20NWY1GkA==}
engines: {node: '>=12.13.0'}
hasBin: true
peerDependencies:
autoprefixer: ^10.0.2
postcss: ^8.0.9
dependencies:
'@fullhuman/postcss-purgecss': 4.0.3_postcss@8.3.5
arg: 5.0.0
autoprefixer: 10.3.0_postcss@8.3.5
bytes: 3.1.0
chalk: 4.1.1
chokidar: 3.5.2
color: 3.1.3
cosmiconfig: 7.0.0
detective: 5.2.0
didyoumean: 1.2.2
dlv: 1.1.3
fast-glob: 3.2.7
fs-extra: 10.0.0
glob-parent: 6.0.0
html-tags: 3.1.0
is-glob: 4.0.1
lodash: 4.17.21
lodash.topath: 4.5.2
modern-normalize: 1.1.0
node-emoji: 1.10.0
normalize-path: 3.0.0
object-hash: 2.2.0
postcss: 8.3.5
postcss-js: 3.0.3
postcss-load-config: 3.1.0
postcss-nested: 5.0.5_postcss@8.3.5
postcss-selector-parser: 6.0.6
postcss-value-parser: 4.1.0
pretty-hrtime: 1.0.3
quick-lru: 5.1.1
reduce-css-calc: 2.1.8
resolve: 1.20.0
tmp: 0.2.1
transitivePeerDependencies:
- ts-node
dev: true
/tmp/0.2.1:
resolution: {integrity: sha512-76SUhtfqR2Ijn+xllcI5P1oyannHNHByD80W1q447gU3mp9G9PSpGdWmjUOHRDPiHYacIk66W7ubDTuPF3BEtQ==}
engines: {node: '>=8.17.0'}
dependencies:
rimraf: 3.0.2
dev: true
/to-regex-range/5.0.1:
resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==}
engines: {node: '>=8.0'}
dependencies:
is-number: 7.0.0
dev: true
/tslib/2.0.3:
resolution: {integrity: sha512-uZtkfKblCEQtZKBF6EBXVZeQNl82yqtDQdv+eck8u7tdPxjLu2/lp5/uPW+um2tpuxINHWy3GhiccY7QgEaVHQ==}
dev: false
/universalify/2.0.0:
resolution: {integrity: sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ==}
engines: {node: '>= 10.0.0'}
dev: true
/util-deprecate/1.0.2:
resolution: {integrity: sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=}
dev: true
/vite/2.4.2:
resolution: {integrity: sha512-2MifxD2I9fjyDmmEzbULOo3kOUoqX90A58cT6mECxoVQlMYFuijZsPQBuA14mqSwvV3ydUsqnq+BRWXyO9Qa+w==}
engines: {node: '>=12.0.0'}
hasBin: true
dependencies:
esbuild: 0.12.9
postcss: 8.3.5
resolve: 1.20.0
rollup: 2.52.2
optionalDependencies:
fsevents: 2.3.2
dev: true
/wrappy/1.0.2:
resolution: {integrity: sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=}
dev: true
/xtend/4.0.2:
resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==}
engines: {node: '>=0.4'}
dev: true
/yaml/1.10.2:
resolution: {integrity: sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==}
engines: {node: '>= 6'}
dev: true
/zrender/5.1.1:
resolution: {integrity: sha512-oeWlmUZPQdS9f5hK4pV21tHPqA3wgQ7CkKkw7l0CCBgWlJ/FP+lRgLFtUBW6yam4JX8y9CdHJo1o587VVrbcoQ==}
dependencies:
tslib: 2.0.3
dev: false

View File

@@ -0,0 +1,7 @@
// Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
}

View File

@@ -0,0 +1,4 @@
/* Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. */
@tailwind base;
@tailwind components;
@tailwind utilities;

View File

@@ -0,0 +1,120 @@
// Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
import "./main.css"
import {TreemapChart} from "echarts/charts"
import {CanvasRenderer} from "echarts/renderers"
import {init as initChart, throttle, use} from "echarts/core"
import {ToolboxComponent, TooltipComponent} from "echarts/components"
import prettyBytes from "pretty-bytes"
use([TooltipComponent, CanvasRenderer, TreemapChart, ToolboxComponent])
async function init() {
const fileInput = document.getElementById("fileInput")
fileInput.addEventListener("change", event => {
handleFile(event.target.files[0])
})
const dropbox = document.body
dropbox.addEventListener("dragenter", preventDefault)
dropbox.addEventListener("dragover", preventDefault)
dropbox.addEventListener("drop", event => {
event.stopPropagation()
event.preventDefault()
const file = event.dataTransfer.files[0]
// noinspection JSCheckFunctionSignatures
const timeFormat = new Intl.DateTimeFormat("default", {
timeStyle: "medium",
})
document.title = `${file.name} (${timeFormat.format(new Date())})`
handleFile(file)
})
const data = localStorage.getItem("data")
if (data != null) {
updateChart(JSON.parse(data))
}
}
let chart
function createChart() {
const chartManager = new ChartManagerHelper(document.getElementById("app"))
chart = chartManager.chart
chart.setOption({
toolbox: {
feature: {
saveAsImage: {},
},
},
tooltip: {
formatter: info => {
let result = `${info.marker} ${info.name}`
return result + `<span style="float: right; margin-left: 20px; font-weight: 900;">${prettyBytes(info.value, {binary: true})}</span>`
},
},
})
}
function preventDefault(e) {
e.stopPropagation();
e.preventDefault();
}
function handleFile(selectedFile) {
selectedFile.text().then(it => {
localStorage.setItem("data", it)
updateChart(JSON.parse(it))
})
}
function updateChart(data) {
if (chart == null) {
createChart()
}
chart.setOption({
series: [{
type: "treemap",
data,
levels: [
{},
{
colorSaturation: [0.35, 0.5],
itemStyle: {
borderWidth: 5,
gapWidth: 1,
borderColorSaturation: 0.6,
},
upperLabel: {show: true},
},
],
leafDepth: 2,
label: {
// formatter(data) {
// return `${(data.data as ItemExtraInfo).abbreviatedName} (${numberFormat.format(data["value"] as number)})`
// }
}
}],
})
}
class ChartManagerHelper {
constructor(container) {
this.chart = initChart(container)
this.resizeObserver = new ResizeObserver(throttle(() => {
this.chart.resize()
}, 300))
this.resizeObserver.observe(this.chart.getDom())
}
dispose() {
this.resizeObserver.unobserve(this.chart.getDom())
this.chart.dispose()
}
}
init().catch(e => {
console.error(e)
})

View File

@@ -0,0 +1,13 @@
// Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
module.exports = {
purge: ["./index.html", "./src/**/*.{vue,ts,js}"],
darkMode: "class",
mode: "jit",
theme: {
extend: {},
},
variants: {
extend: {},
},
plugins: [],
}

View File

@@ -0,0 +1,3 @@
// Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
export default {
}

View File

@@ -7,6 +7,7 @@
<excludeFolder url="file://$MODULE_DIR$/config" /> <excludeFolder url="file://$MODULE_DIR$/config" />
<excludeFolder url="file://$MODULE_DIR$/system" /> <excludeFolder url="file://$MODULE_DIR$/system" />
<excludeFolder url="file://$MODULE_DIR$/docs/plugin-graph/dist" /> <excludeFolder url="file://$MODULE_DIR$/docs/plugin-graph/dist" />
<excludeFolder url="file://$MODULE_DIR$/docs/dist-visualizer/dist" />
</content> </content>
<orderEntry type="inheritedJdk" /> <orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" /> <orderEntry type="sourceFolder" forTests="false" />

View File

@@ -1,4 +1,4 @@
// Copyright 2000-2021 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. // Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package org.jetbrains.intellij.build.devServer package org.jetbrains.intellij.build.devServer
import com.intellij.util.PathUtilRt import com.intellij.util.PathUtilRt
@@ -139,7 +139,7 @@ private fun createLibClassPath(buildContext: BuildContext,
classPath.add(buildContext.getModuleOutputPath(buildContext.findRequiredModule(entry.moduleName))) classPath.add(buildContext.getModuleOutputPath(buildContext.findRequiredModule(entry.moduleName)))
} }
is ProjectLibraryEntry -> { is ProjectLibraryEntry -> {
classPath.add(entry.libraryFilePath) classPath.add(entry.libraryFile.toString())
} }
is ModuleLibraryFileEntry -> { is ModuleLibraryFileEntry -> {
classPath.add(entry.libraryFilePath) classPath.add(entry.libraryFilePath)

View File

@@ -75,8 +75,8 @@ final class BuildHelper {
string, path, string, path,
logger)) logger))
mergeJars = lookup.findStatic(helperClassLoader.loadClass("org.jetbrains.intellij.build.tasks.MergeJarsKt"), mergeJars = lookup.findStatic(helperClassLoader.loadClass("org.jetbrains.intellij.build.tasks.MergeJarsKt"),
"mergeJars", "mergeJars",
MethodType.methodType(voidClass, path, List.class as Class<?>)) MethodType.methodType(Map.class as Class<?>, path, List.class as Class<?>))
} }
static void copyDir(Path fromDir, Path targetDir, BuildContext buildContext) { static void copyDir(Path fromDir, Path targetDir, BuildContext buildContext) {

View File

@@ -1,6 +1,7 @@
// Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. // Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package org.jetbrains.intellij.build.impl package org.jetbrains.intellij.build.impl
import com.intellij.openapi.util.Pair import com.intellij.openapi.util.Pair
import com.intellij.openapi.util.io.FileUtil import com.intellij.openapi.util.io.FileUtil
import com.intellij.openapi.util.io.FileUtilRt import com.intellij.openapi.util.io.FileUtilRt
@@ -44,7 +45,6 @@ import java.util.stream.Collectors
import java.util.stream.Stream import java.util.stream.Stream
import java.util.zip.ZipEntry import java.util.zip.ZipEntry
import java.util.zip.ZipOutputStream import java.util.zip.ZipOutputStream
/** /**
* Assembles output of modules to platform JARs (in {@link org.jetbrains.intellij.build.BuildPaths#distAll distAll}/lib directory), * Assembles output of modules to platform JARs (in {@link org.jetbrains.intellij.build.BuildPaths#distAll distAll}/lib directory),
* bundled plugins' JARs (in {@link org.jetbrains.intellij.build.BuildPaths#distAll distAll}/plugins directory) and zip archives with * bundled plugins' JARs (in {@link org.jetbrains.intellij.build.BuildPaths#distAll distAll}/plugins directory) and zip archives with
@@ -60,6 +60,8 @@ final class DistributionJARsBuilder {
private static final String THIRD_PARTY_LIBRARIES_FILE_PATH = "license/third-party-libraries.html" private static final String THIRD_PARTY_LIBRARIES_FILE_PATH = "license/third-party-libraries.html"
private static final String PLUGINS_DIRECTORY = "plugins" private static final String PLUGINS_DIRECTORY = "plugins"
private static final String UBER_JAR_NAME = "3rd-party.jar"
private final BuildContext buildContext private final BuildContext buildContext
final ProjectStructureMapping projectStructureMapping = new ProjectStructureMapping() final ProjectStructureMapping projectStructureMapping = new ProjectStructureMapping()
final PlatformLayout platform final PlatformLayout platform
@@ -196,6 +198,13 @@ final class DistributionJARsBuilder {
buildNonBundledPluginsBlockMaps() buildNonBundledPluginsBlockMaps()
} }
buildThirdPartyLibrariesList(projectStructureMapping) buildThirdPartyLibrariesList(projectStructureMapping)
Path artifactOut = Path.of(buildContext.paths.artifacts)
Files.createDirectories(artifactOut)
projectStructureMapping.generateJsonFile(artifactOut.resolve("content-mapping.json"))
Files.newBufferedWriter(artifactOut.resolve("content.json")).withCloseable {
ProjectStructureMapping.buildJarContentReport(projectStructureMapping, it, buildContext.paths)
}
} }
static void reorderJars(@NotNull BuildContext buildContext) { static void reorderJars(@NotNull BuildContext buildContext) {
@@ -1018,7 +1027,7 @@ final class DistributionJARsBuilder {
boolean mergeLibs, boolean mergeLibs,
BuildContext buildContext) { BuildContext buildContext) {
Map<Path, ProjectLibraryData> copiedFiles = new HashMap<>() Map<Path, ProjectLibraryData> copiedFiles = new HashMap<>()
Map<String, List<Path>> toMerge = mergeLibs ? new HashMap<String, List<Path>>() : Collections.<String, List<Path>>emptyMap() Map<JpsLibrary, List<Path>> toMerge = mergeLibs ? new HashMap<JpsLibrary, List<Path>>() : Collections.<JpsLibrary, List<Path>>emptyMap()
boolean copyFiles = layoutSpec.copyFiles boolean copyFiles = layoutSpec.copyFiles
libProcessing: libProcessing:
@@ -1049,35 +1058,35 @@ final class DistributionJARsBuilder {
} }
} }
if (copyFiles) { String lowerCasedLibName = libName.toLowerCase()
String lowerCasedLibName = libName.toLowerCase() if (mergeLibs &&
if (mergeLibs) { !excludedFromMergeLibs.contains(libName) &&
String uberJarName !libName.startsWith("kotlin") && !libName.startsWith("rd-") &&
if (!excludedFromMergeLibs.contains(libName) && !lowerCasedLibName.contains("annotations") &&
!libName.startsWith("kotlin") && !libName.startsWith("rd-") && !lowerCasedLibName.startsWith("junit") &&
!lowerCasedLibName.contains("annotations") && !lowerCasedLibName.startsWith("cucumber-") &&
!lowerCasedLibName.startsWith("junit") && !lowerCasedLibName.contains("groovy")) {
!lowerCasedLibName.startsWith("cucumber-") && buildContext.messages.debug(" pack $libName into $UBER_JAR_NAME")
!lowerCasedLibName.contains("groovy")) {
uberJarName = "3rd-party.jar"
buildContext.messages.debug(" pack $libName into $uberJarName")
}
else {
uberJarName = null
}
if (uberJarName != null) { if (copyFiles) {
toMerge.computeIfAbsent(uberJarName, { new ArrayList<>() }).addAll(nioFiles) toMerge.put(library, nioFiles)
layoutSpec.addLibraryMapping(library, uberJarName, outputDir.resolve(uberJarName).toString()) }
continue libProcessing else {
for (Path nioFile : nioFiles) {
layoutSpec.addLibraryMapping(library, UBER_JAR_NAME, nioFile)
} }
} }
continue libProcessing
}
if (copyFiles) {
Files.createDirectories(libOutputDir) Files.createDirectories(libOutputDir)
if (!removeVersionFromJarName && nioFiles.size() > 1 && lowerCasedLibName != "gradle") { if (!removeVersionFromJarName && nioFiles.size() > 1 && lowerCasedLibName != "gradle") {
Path targetFile = outputDir.resolve(FileUtil.sanitizeFileName(lowerCasedLibName, false) + ".jar") Path targetFile = outputDir.resolve(FileUtil.sanitizeFileName(lowerCasedLibName, false) + ".jar")
BuildHelper.getInstance(buildContext).mergeJars.invokeWithArguments(targetFile, nioFiles) BuildHelper.getInstance(buildContext).mergeJars.invokeWithArguments(targetFile, nioFiles)
layoutSpec.addLibraryMapping(library, targetFile.fileName.toString(), targetFile.toString()) for (Path nioFile : nioFiles) {
layoutSpec.addLibraryMapping(library, targetFile.fileName.toString(), nioFile)
}
continue libProcessing continue libProcessing
} }
} }
@@ -1089,14 +1098,14 @@ final class DistributionJARsBuilder {
if (copyFiles) { if (copyFiles) {
Files.copy(file, libOutputDir.resolve(newName)) Files.copy(file, libOutputDir.resolve(newName))
} }
layoutSpec.addLibraryMapping(library, newName, file.toString()) layoutSpec.addLibraryMapping(library, newName, file)
buildContext.messages.debug(" include $newName (renamed from $file) from library '${LayoutBuilder.LayoutSpec.getLibraryName(library)}'") buildContext.messages.debug(" include $newName (renamed from $file) from library '${LayoutBuilder.LayoutSpec.getLibraryName(library)}'")
} }
else { else {
if (copyFiles) { if (copyFiles) {
Files.copy(file, libOutputDir.resolve(file.fileName)) Files.copy(file, libOutputDir.resolve(file.fileName))
} }
layoutSpec.addLibraryMapping(library, file.fileName.toString(), file.toString()) layoutSpec.addLibraryMapping(library, file.fileName.toString(), file)
buildContext.messages.debug(" include $file from library '${LayoutBuilder.LayoutSpec.getLibraryName(library)}'") buildContext.messages.debug(" include $file from library '${LayoutBuilder.LayoutSpec.getLibraryName(library)}'")
} }
} }
@@ -1104,11 +1113,18 @@ final class DistributionJARsBuilder {
if (!toMerge.isEmpty()) { if (!toMerge.isEmpty()) {
MethodHandle mergeJarsMethod = BuildHelper.getInstance(buildContext).mergeJars MethodHandle mergeJarsMethod = BuildHelper.getInstance(buildContext).mergeJars
for (Map.Entry<String, List<Path>> entry : toMerge.entrySet()) { List<Path> allFiles = new ArrayList<>()
List<Path> list = entry.value for (Map.Entry<JpsLibrary, List<Path>> entry : toMerge.entrySet()) {
list.sort(null) allFiles.addAll(entry.value)
buildContext.messages.debug(" merge $list to ${entry.key}") }
mergeJarsMethod.invokeWithArguments(outputDir.resolve(entry.key), list) allFiles.sort(null)
buildContext.messages.debug(" merge $allFiles to $UBER_JAR_NAME")
Path uberJarFile = outputDir.resolve(UBER_JAR_NAME)
Map<Path, Integer> sizes = mergeJarsMethod.invokeWithArguments(uberJarFile, allFiles) as Map<Path, Integer>
for (Map.Entry<JpsLibrary, List<Path>> entry : toMerge.entrySet()) {
for (Path nioFile : entry.value) {
layoutSpec.addProjectLibraryMapping(entry.key, nioFile, sizes.get(nioFile), uberJarFile)
}
} }
} }
} }

View File

@@ -1,20 +1,15 @@
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. // Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package org.jetbrains.intellij.build.impl package org.jetbrains.intellij.build.impl
import com.intellij.openapi.util.io.FileUtil import com.intellij.openapi.util.io.FileUtil
import com.intellij.util.PathUtilRt import com.intellij.util.PathUtilRt
import com.intellij.util.SystemProperties
import com.intellij.util.containers.MultiMap import com.intellij.util.containers.MultiMap
import groovy.transform.CompileStatic import groovy.transform.CompileStatic
import groovy.transform.TypeCheckingMode import groovy.transform.TypeCheckingMode
import org.apache.tools.ant.AntClassLoader import org.apache.tools.ant.AntClassLoader
import org.jetbrains.annotations.NotNull import org.jetbrains.annotations.NotNull
import org.jetbrains.intellij.build.CompilationContext import org.jetbrains.intellij.build.CompilationContext
import org.jetbrains.intellij.build.impl.projectStructureMapping.ModuleLibraryFileEntry import org.jetbrains.intellij.build.impl.projectStructureMapping.*
import org.jetbrains.intellij.build.impl.projectStructureMapping.ModuleOutputEntry
import org.jetbrains.intellij.build.impl.projectStructureMapping.ModuleTestOutputEntry
import org.jetbrains.intellij.build.impl.projectStructureMapping.ProjectLibraryEntry
import org.jetbrains.intellij.build.impl.projectStructureMapping.ProjectStructureMapping
import org.jetbrains.jps.model.artifact.JpsArtifact import org.jetbrains.jps.model.artifact.JpsArtifact
import org.jetbrains.jps.model.artifact.JpsArtifactService import org.jetbrains.jps.model.artifact.JpsArtifactService
import org.jetbrains.jps.model.artifact.elements.JpsArchivePackagingElement import org.jetbrains.jps.model.artifact.elements.JpsArchivePackagingElement
@@ -304,14 +299,14 @@ final class LayoutBuilder {
if (copyFiles) { if (copyFiles) {
ant.renamedFile(filePath: file.absolutePath, newName: newName) ant.renamedFile(filePath: file.absolutePath, newName: newName)
} }
addLibraryMapping(library, newName, file.absolutePath) addLibraryMapping(library, newName, file.toPath())
context.messages.debug(" include $newName (renamed from $file.absolutePath) from library '${getLibraryName(library)}'") context.messages.debug(" include $newName (renamed from $file.absolutePath) from library '${getLibraryName(library)}'")
} }
else { else {
if (copyFiles) { if (copyFiles) {
ant.fileset(file: file.absolutePath) ant.fileset(file: file.absolutePath)
} }
addLibraryMapping(library, file.name, file.absolutePath) addLibraryMapping(library, file.name, file.toPath())
context.messages.debug(" include $file.name ($file.absolutePath) from library '${getLibraryName(library)}'") context.messages.debug(" include $file.name ($file.absolutePath) from library '${getLibraryName(library)}'")
} }
} }
@@ -343,20 +338,26 @@ final class LayoutBuilder {
return name return name
} }
void addLibraryMapping(JpsLibrary library, String outputFileName, String libraryFilePath) { void addLibraryMapping(JpsLibrary library, String outputFileName, Path libraryFile) {
def outputFilePath = getCurrentPathString().isEmpty() ? outputFileName : getCurrentPathString() + "/" + outputFileName
def parentReference = library.createReference().parentReference def parentReference = library.createReference().parentReference
if (parentReference instanceof JpsModuleReference) { if (parentReference instanceof JpsModuleReference) {
def projectHome = context.paths.projectHome + File.separator String shortenedPath = ProjectStructureMapping.shortenPath(libraryFile, context.paths)
def mavenLocalRepo = new File(SystemProperties.getUserHome(), ".m2/repository").absolutePath + File.separator projectStructureMapping.addEntry(new ModuleLibraryFileEntry(getOutputFilePath(outputFileName), shortenedPath, libraryFile.toString()))
String shortenedPath = libraryFilePath.replace(projectHome, "\$PROJECT_DIR\$/").replace(mavenLocalRepo, "\$MAVEN_REPOSITORY\$/")
projectStructureMapping.addEntry(new ModuleLibraryFileEntry(outputFilePath, shortenedPath, libraryFilePath))
} }
else { else {
projectStructureMapping.addEntry(new ProjectLibraryEntry(outputFilePath, library.name, libraryFilePath)) projectStructureMapping.addEntry(new ProjectLibraryEntry(getOutputFilePath(outputFileName), library.name, libraryFile, 0))
} }
} }
void addProjectLibraryMapping(JpsLibrary library, Path libraryFile, int fileSize, Path outputFile) {
assert !(library.createReference().parentReference instanceof JpsModuleReference)
projectStructureMapping.addEntry(new ProjectLibraryEntry(getOutputFilePath(outputFile.fileName.toString()), library.name, libraryFile, fileSize))
}
private String getOutputFilePath(String outputFileName) {
return currentPath.isEmpty() ? outputFileName : getCurrentPathString() + "/" + outputFileName
}
private void addArtifactMapping(@NotNull JpsArtifact artifact) { private void addArtifactMapping(@NotNull JpsArtifact artifact) {
JpsCompositePackagingElement rootElement = artifact.getRootElement() JpsCompositePackagingElement rootElement = artifact.getRootElement()
String artifactFilePath = getCurrentPathString() String artifactFilePath = getCurrentPathString()

View File

@@ -1,21 +1,25 @@
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. // Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package org.jetbrains.intellij.build.impl.projectStructureMapping package org.jetbrains.intellij.build.impl.projectStructureMapping
import groovy.transform.AutoClone import groovy.transform.AutoClone
import groovy.transform.CompileStatic import groovy.transform.CompileStatic
import java.nio.file.Path
/** /**
* Represents a project-level library * Represents a project-level library
*/ */
@CompileStatic @CompileStatic
@AutoClone @AutoClone
final class ProjectLibraryEntry extends DistributionFileEntry { final class ProjectLibraryEntry extends DistributionFileEntry {
String libraryName final String libraryName
String libraryFilePath final transient Path libraryFile
final int fileSize
ProjectLibraryEntry(String path, String libraryName, String libraryFilePath) { ProjectLibraryEntry(String path, String libraryName, Path libraryFile, int fileSize) {
super(path, "project-library") super(path, "project-library")
this.libraryName = libraryName this.libraryName = libraryName
this.libraryFilePath = libraryFilePath this.libraryFile = libraryFile
this.fileSize = fileSize
} }
} }

View File

@@ -2,7 +2,10 @@
package org.jetbrains.intellij.build.impl.projectStructureMapping package org.jetbrains.intellij.build.impl.projectStructureMapping
import com.google.gson.GsonBuilder import com.google.gson.GsonBuilder
import com.google.gson.stream.JsonWriter
import com.intellij.util.SystemProperties
import groovy.transform.CompileStatic import groovy.transform.CompileStatic
import org.jetbrains.intellij.build.BuildPaths
import java.nio.file.Files import java.nio.file.Files
import java.nio.file.Path import java.nio.file.Path
@@ -58,4 +61,101 @@ final class ProjectStructureMapping {
new GsonBuilder().setPrettyPrinting().create().toJson(entries, it) new GsonBuilder().setPrettyPrinting().create().toJson(entries, it)
} }
} }
static void buildJarContentReport(ProjectStructureMapping projectStructureMapping, Writer out, BuildPaths buildPaths) {
// jackson is not available in build scripts - use GSON
JsonWriter writer = new JsonWriter(out)
writer.setIndent(" ")
List<DistributionFileEntry> entries = projectStructureMapping.entries
Map<String, List<DistributionFileEntry>> fileToEntry = new HashMap<>()
for (DistributionFileEntry entry : entries) {
fileToEntry.computeIfAbsent(entry.path, { new ArrayList<DistributionFileEntry>() }).add(entry)
}
List<String> files = fileToEntry.keySet().toList()
files.sort(null)
writer.beginArray()
for (String file : files) {
List<DistributionFileEntry> fileEntries = fileToEntry.get(file)
writer.beginObject()
writer.name("name").value(file);
writer.name("children")
writer.beginArray()
writeProjectLibs(fileEntries, writer, buildPaths)
for (DistributionFileEntry entry : fileEntries) {
if (entry instanceof ProjectLibraryEntry) {
continue
}
writer.beginObject()
long fileSize = 0
if (entry instanceof ModuleOutputEntry) {
writer.name("name").value(entry.moduleName)
// well, the only possible way to compute the size of the module - calculate it as part of writing to JAR,
// maybe it will be done later
}
else if (entry instanceof ModuleLibraryFileEntry) {
writer.name("name").value(entry.filePath)
fileSize = Files.size(Path.of(entry.libraryFilePath))
}
else {
throw new IllegalStateException("Unsupported entry: $entry")
}
writer.name("value").value(fileSize)
writer.endObject()
}
writer.endArray()
writer.endObject()
}
writer.endArray()
}
private static void writeProjectLibs(List<DistributionFileEntry> entries, JsonWriter writer, BuildPaths buildPaths) {
Path mavenLocalRepo = Path.of(SystemProperties.getUserHome(), ".m2/repository")
// group by library
Map<String, List<ProjectLibraryEntry>> map = new TreeMap<>()
for (DistributionFileEntry entry : entries) {
if (entry instanceof ProjectLibraryEntry) {
map.computeIfAbsent(entry.libraryName, { new ArrayList<ProjectLibraryEntry>()}).add(entry as ProjectLibraryEntry)
}
}
for (Map.Entry<String, List<ProjectLibraryEntry>> entry : map.entrySet()) {
writer.beginObject()
writer.name("name").value(entry.key)
writer.name("children")
writer.beginArray()
for (ProjectLibraryEntry fileEntry : entry.value) {
writer.beginObject()
writer.name("name").value(shortenPath(fileEntry.libraryFile, buildPaths))
writer.name("value").value(fileEntry.fileSize as long)
writer.endObject()
}
writer.endArray()
writer.endObject()
}
}
static String shortenPath(Path libraryFile, BuildPaths buildPaths) {
Path mavenRepo = Path.of(SystemProperties.getUserHome(), ".m2/repository")
Path projectHome = Path.of(buildPaths.projectHome)
if (libraryFile.startsWith(mavenRepo)) {
return "\$MAVEN_REPOSITORY\$" + File.separatorChar + mavenRepo.relativize(libraryFile).toString()
}
else if (libraryFile.startsWith(projectHome)) {
return "\$PROJECT_DIR\$" + File.separatorChar + projectHome.relativize(libraryFile).toString()
}
else {
return libraryFile.toString()
}
}
} }