From c8d18924d8b726df6174fcb729aca22cfc1f9d79 Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Tue, 5 Sep 2023 10:28:45 +0100 Subject: [PATCH] chore: rebase --- benchmark/bench/render.js | 2 +- package.json | 1 - packages/astro/src/cli/info/index.ts | 4 +- .../units/routing/route-sanitization.test.js | 10 +- packages/integrations/vercel/src/lib/nft.ts | 4 +- .../vercel/src/serverless/adapter.ts | 6 +- pnpm-lock.yaml | 153 +++++++++--------- 7 files changed, 85 insertions(+), 95 deletions(-) diff --git a/benchmark/bench/render.js b/benchmark/bench/render.js index 49f20f2676ad..373d3c7b496a 100644 --- a/benchmark/bench/render.js +++ b/benchmark/bench/render.js @@ -5,8 +5,8 @@ import { fileURLToPath } from 'node:url'; import { execaCommand } from 'execa'; import { markdownTable } from 'markdown-table'; import { waitUntilBusy } from 'port-authority'; -import { calculateStat, astroBin } from './_util.js'; import { renderFiles } from '../make-project/render-default.js'; +import { astroBin, calculateStat } from './_util.js'; const port = 4322; diff --git a/package.json b/package.json index bb47015390a8..624d62ee620e 100644 --- a/package.json +++ b/package.json @@ -88,7 +88,6 @@ "eslint-plugin-no-only-tests": "^3.1.0", "eslint-plugin-prettier": "^5.0.0", "only-allow": "^1.1.1", - "organize-imports-cli": "^0.10.0", "prettier": "^3.0.2", "prettier-plugin-astro": "^0.12.0", "tiny-glob": "^0.2.9", diff --git a/packages/astro/src/cli/info/index.ts b/packages/astro/src/cli/info/index.ts index 2ee9ffd0d784..c902bd54d43b 100644 --- a/packages/astro/src/cli/info/index.ts +++ b/packages/astro/src/cli/info/index.ts @@ -1,7 +1,7 @@ -/* eslint-disable no-console */ -import * as colors from 'kleur/colors'; import { execSync } from 'node:child_process'; import { arch, platform } from 'node:os'; +/* eslint-disable no-console */ +import * as colors from 'kleur/colors'; import prompts from 'prompts'; import type yargs from 'yargs-parser'; import { resolveConfig } from '../../core/config/index.js'; diff --git a/packages/astro/test/units/routing/route-sanitization.test.js b/packages/astro/test/units/routing/route-sanitization.test.js index 14c9c382962a..189885711778 100644 --- a/packages/astro/test/units/routing/route-sanitization.test.js +++ b/packages/astro/test/units/routing/route-sanitization.test.js @@ -1,14 +1,14 @@ +import { fileURLToPath } from 'node:url'; +import { expect } from 'chai'; +import * as cheerio from 'cheerio'; +import { createContainer } from '../../../dist/core/dev/container.js'; +import testAdapter from '../../test-adapter.js'; import { createBasicSettings, createFs, createRequestAndResponse, defaultLogger, } from '../test-utils.js'; -import { fileURLToPath } from 'node:url'; -import { expect } from 'chai'; -import { createContainer } from '../../../dist/core/dev/container.js'; -import * as cheerio from 'cheerio'; -import testAdapter from '../../test-adapter.js'; const root = new URL('../../fixtures/alias/', import.meta.url); const fileSystem = { diff --git a/packages/integrations/vercel/src/lib/nft.ts b/packages/integrations/vercel/src/lib/nft.ts index 585a45e998dc..b6fe46999a58 100644 --- a/packages/integrations/vercel/src/lib/nft.ts +++ b/packages/integrations/vercel/src/lib/nft.ts @@ -1,6 +1,6 @@ -import type { AstroIntegrationLogger } from 'astro'; -import { relative, relative as relativePath } from 'node:path'; +import { relative as relativePath } from 'node:path'; import { fileURLToPath } from 'node:url'; +import type { AstroIntegrationLogger } from 'astro'; import { copyFilesToFunction } from './fs.js'; export async function copyDependenciesToFunction( diff --git a/packages/integrations/vercel/src/serverless/adapter.ts b/packages/integrations/vercel/src/serverless/adapter.ts index a7178b3e3c59..da21130cc441 100644 --- a/packages/integrations/vercel/src/serverless/adapter.ts +++ b/packages/integrations/vercel/src/serverless/adapter.ts @@ -1,3 +1,5 @@ +import { basename } from 'node:path'; +import { fileURLToPath, pathToFileURL } from 'node:url'; import type { AstroAdapter, AstroConfig, @@ -7,9 +9,7 @@ import type { } from 'astro'; import { AstroError } from 'astro/errors'; import glob from 'fast-glob'; -import { basename } from 'node:path'; -import { fileURLToPath, pathToFileURL } from 'node:url'; -import { defaultImageConfig, getImageConfig, type VercelImageConfig } from '../image/shared.js'; +import { type VercelImageConfig, defaultImageConfig, getImageConfig } from '../image/shared.js'; import { exposeEnv } from '../lib/env.js'; import { getVercelOutput, removeDir, writeJson } from '../lib/fs.js'; import { copyDependenciesToFunction } from '../lib/nft.js'; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 9efde990009f..68d2a756d4d7 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -21,6 +21,9 @@ importers: '@astrojs/check': specifier: ^0.1.0 version: 0.1.0(prettier-plugin-astro@0.12.0)(prettier@3.0.2)(typescript@5.1.6) + '@biomejs/biome': + specifier: 1.0.0 + version: 1.0.0 '@changesets/changelog-github': specifier: ^0.4.8 version: 0.4.8 @@ -54,9 +57,6 @@ importers: only-allow: specifier: ^1.1.1 version: 1.1.1 - organize-imports-cli: - specifier: ^0.10.0 - version: 0.10.0 prettier: specifier: ^3.0.2 version: 3.0.2 @@ -6714,6 +6714,74 @@ packages: '@babel/helper-validator-identifier': 7.22.5 to-fast-properties: 2.0.0 + /@biomejs/biome@1.0.0: + resolution: {integrity: sha512-Y5CND1QZ5pF6hc4dFw5ItDutv9KJO91ksLdBIFyvHL7LmXN0UomqyyRWryvrqq+YlA8Q58cR6sqjjQuMp9E2Ig==} + engines: {node: '>=14.*'} + hasBin: true + requiresBuild: true + optionalDependencies: + '@biomejs/cli-darwin-arm64': 1.0.0 + '@biomejs/cli-darwin-x64': 1.0.0 + '@biomejs/cli-linux-arm64': 1.0.0 + '@biomejs/cli-linux-x64': 1.0.0 + '@biomejs/cli-win32-arm64': 1.0.0 + '@biomejs/cli-win32-x64': 1.0.0 + dev: true + + /@biomejs/cli-darwin-arm64@1.0.0: + resolution: {integrity: sha512-3v7kEyxkf3D246esH+q/lDK5wWn+xLCXZpHCuc1itAmC35GkEc6S7um6C1VD3XKXLx6N0sJR/rTmjKiRGV32Ig==} + engines: {node: '>=14.*'} + cpu: [arm64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@biomejs/cli-darwin-x64@1.0.0: + resolution: {integrity: sha512-uxIMt/X7TQWicjsImkqMvUUEqaFZTOJJrtEhlHl/eIaETWJmK3uAR7ihIWctpGJnN16sUgpLgwczc7FETqu/PQ==} + engines: {node: '>=14.*'} + cpu: [x64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@biomejs/cli-linux-arm64@1.0.0: + resolution: {integrity: sha512-kJWtu3Xr4MdHV2Yn4U+eZudAGPgv0kRCjWAyzLRewJiqE5TLPrX08imB9SU1n3+VxNO8e2JJ0tWWBHo4J+aSEg==} + engines: {node: '>=14.*'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@biomejs/cli-linux-x64@1.0.0: + resolution: {integrity: sha512-FK6hYZ0Lkk39eXYx1+2ZWtLkApc0RdOpcjDVM96JbvI0bxqvNnm193BPXuxh5A/fCl6N28RNUvcKnZ5LbgZ0Yw==} + engines: {node: '>=14.*'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@biomejs/cli-win32-arm64@1.0.0: + resolution: {integrity: sha512-kE+OY2isEJHBodiLPMlybZckHkl3CQWsvXuJEvSxkoMhLbGDPEV3yZ/0lEph3BlxP3KP5vUO3hOFGaTvHFOuqQ==} + engines: {node: '>=14.*'} + cpu: [arm64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@biomejs/cli-win32-x64@1.0.0: + resolution: {integrity: sha512-Ko6ZsbmbScPMEnh/xz4mwDSCZIUCAEjbbbnUVApgAAL2+1Hoe7Vnhh2RiwYRqy3tHrBIMDwXkSxj0vlf1G3EHg==} + engines: {node: '>=14.*'} + cpu: [x64] + os: [win32] + requiresBuild: true + dev: true + optional: true + /@builder.io/partytown@0.8.0: resolution: {integrity: sha512-M6H7nSMwW2dHd1/MQ+9J1Jqdw22uhl1nKv90kIiL9G7gjFVqqouQp4qSS1oZclmtW1XjAa4Q5UnbHB4iytmxZA==} hasBin: true @@ -8567,15 +8635,6 @@ packages: engines: {node: '>= 10'} dev: true - /@ts-morph/common@0.20.0: - resolution: {integrity: sha512-7uKjByfbPpwuzkstL3L5MQyuXPSKdoNG93Fmi2JoDcTf3pEP731JdRFAduRVkOs8oqxPsXKA+ScrWkdQ8t/I+Q==} - dependencies: - fast-glob: 3.3.1 - minimatch: 7.4.6 - mkdirp: 2.1.6 - path-browserify: 1.0.1 - dev: true - /@types/acorn@4.0.6: resolution: {integrity: sha512-veQTnWP+1D/xbxVrPC3zHnCZRjSrKfhbMUlEA43iMZLu7EsnTtkJklIuwrCPbOi8YkvDQAiW05VQQFvvz9oieQ==} dependencies: @@ -8885,14 +8944,6 @@ packages: '@types/node': 18.17.8 dev: true - /@types/strip-bom@3.0.0: - resolution: {integrity: sha512-xevGOReSYGM7g/kUBZzPqCrR/KYAo+F0yiPc85WFTJa0MSLtyFTVTU6cJu/aV4mid7IffDIWqo69THF2o4JiEQ==} - dev: true - - /@types/strip-json-comments@0.0.30: - resolution: {integrity: sha512-7NQmHra/JILCd1QqpSzl8+mJRc8ZHz3uDm8YV1Ks9IhK0epEiTw8aIErbvH9PI+6XbqhyIQy3462nEsn7UVzjQ==} - dev: true - /@types/trusted-types@2.0.3: resolution: {integrity: sha512-NfQ4gyz38SL8sDNrSixxU2Os1a5xcdFxipAFxYEuLUlvU2uDwS4NUpsImcf1//SlWItCVMMLiylsxbmNMToV/g==} @@ -10300,10 +10351,6 @@ packages: engines: {node: '>=6'} dev: false - /code-block-writer@12.0.0: - resolution: {integrity: sha512-q4dMFMlXtKR3XNBHyMHt/3pwYNA69EDk00lloMOaaUMKPUXBw6lpXtbu3MMVG6/uOihGnRDOlkyqsONEUj60+w==} - dev: true - /code-red@1.0.4: resolution: {integrity: sha512-7qJWqItLA8/VPVlKJlFXU+NBlo/qyfs39aJcuMT/2ere32ZqvF5OSxgdM5xOfJJ7O429gg2HM47y8v9P+9wrNw==} dependencies: @@ -10365,6 +10412,7 @@ packages: /commander@2.20.3: resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} + dev: false /commander@4.1.1: resolution: {integrity: sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==} @@ -10868,16 +10916,6 @@ packages: resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} dev: false - /editorconfig@0.15.3: - resolution: {integrity: sha512-M9wIMFx96vq0R4F+gRpY3o2exzb8hEj/n9S8unZtHSvYjibBp/iMufSzvmOcV/laG0ZtuTVGtiJggPOSW2r93g==} - hasBin: true - dependencies: - commander: 2.20.3 - lru-cache: 4.1.5 - semver: 5.7.2 - sigmund: 1.0.1 - dev: true - /ee-first@1.1.1: resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} @@ -13993,13 +14031,6 @@ packages: brace-expansion: 2.0.1 dev: false - /minimatch@7.4.6: - resolution: {integrity: sha512-sBz8G/YjVniEz6lKPNpKxXwazJe4c19fEfV2GDMX6AjFz+MX9uDWIZW8XreVhkFW3fkIdTv/gxWr/Kks5FFAVw==} - engines: {node: '>=10'} - dependencies: - brace-expansion: 2.0.1 - dev: true - /minimist-options@4.1.0: resolution: {integrity: sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A==} engines: {node: '>= 6'} @@ -14057,12 +14088,6 @@ packages: hasBin: true dev: false - /mkdirp@2.1.6: - resolution: {integrity: sha512-+hEnITedc8LAtIP9u3HJDFIdcLV2vXP33sqLLIzkv1Db1zO/1OxbvYf0Y1OC/S/Qo5dxHXepofhmxL02PsKe+A==} - engines: {node: '>=10'} - hasBin: true - dev: true - /mlly@1.4.0: resolution: {integrity: sha512-ua8PAThnTwpprIaU47EPeZ/bPUVp2QYBbWMphUQpVdBI3Lgqzm5KZQ45Agm3YJedHXaIHl6pBGabaLSUPPSptg==} dependencies: @@ -14447,16 +14472,6 @@ packages: strip-ansi: 7.1.0 dev: false - /organize-imports-cli@0.10.0: - resolution: {integrity: sha512-cVyNEeiDxX/zA6gdK1QS2rr3TK1VymIkT0LagnAk4f6eE0IC0bo3BeUkMzm3q3GnCJzYC+6lfuMpBE0Cequ7Vg==} - hasBin: true - dependencies: - chalk: 4.1.2 - editorconfig: 0.15.3 - ts-morph: 19.0.0 - tsconfig: 7.0.0 - dev: true - /os-tmpdir@1.0.2: resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} engines: {node: '>=0.10.0'} @@ -14607,10 +14622,6 @@ packages: tslib: 2.5.3 dev: false - /path-browserify@1.0.1: - resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} - dev: true - /path-exists@4.0.0: resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} engines: {node: '>=8'} @@ -16077,10 +16088,6 @@ packages: resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==} dev: false - /sigmund@1.0.1: - resolution: {integrity: sha512-fCvEXfh6NWpm+YSuY2bpXb/VIihqWA6hLsgboC+0nl71Q7N7o2eaCW8mJa/NLvQhs6jpd3VZV4UiUQlV6+lc8g==} - dev: true - /signal-exit@3.0.7: resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} @@ -16808,13 +16815,6 @@ packages: /ts-interface-checker@0.1.13: resolution: {integrity: sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==} - /ts-morph@19.0.0: - resolution: {integrity: sha512-D6qcpiJdn46tUqV45vr5UGM2dnIEuTGNxVhg0sk5NX11orcouwj6i1bMqZIz2mZTZB1Hcgy7C3oEVhAT+f6mbQ==} - dependencies: - '@ts-morph/common': 0.20.0 - code-block-writer: 12.0.0 - dev: true - /tsconfig-resolver@3.0.1: resolution: {integrity: sha512-ZHqlstlQF449v8glscGRXzL6l2dZvASPCdXJRWG4gHEZlUVx2Jtmr+a2zeVG4LCsKhDXKRj5R3h0C/98UcVAQg==} dependencies: @@ -16825,15 +16825,6 @@ packages: strip-bom: 4.0.0 type-fest: 3.0.0 - /tsconfig@7.0.0: - resolution: {integrity: sha512-vZXmzPrL+EmC4T/4rVlT2jNVMWCi/O4DIiSj3UHg1OE5kCKbk4mfrXc6dZksLgRM/TZlKnousKH9bbTazUWRRw==} - dependencies: - '@types/strip-bom': 3.0.0 - '@types/strip-json-comments': 0.0.30 - strip-bom: 3.0.0 - strip-json-comments: 2.0.1 - dev: true - /tslib@2.1.0: resolution: {integrity: sha512-hcVC3wYEziELGGmEEXue7D75zbwIIVUMWAVbHItGPx0ziyXxrOMQx4rQEVEV45Ut/1IotuEvwqPopzIOkDMf0A==} dev: true