mirror of
https://github.com/ChromeDevTools/chrome-devtools-mcp.git
synced 2026-11-04 15:00:11 +00:00
fix: prevent dropping license notices on some files when publishing (#604)
This PR prevents license notices being dropped when creating package for publication. This can happen when first import in the file is type-only import that gets removed during build. When there is no empty line between the license block comment and such import, the comment is treated as related to the import and gets removed alongside it. Adding an empty line between copyright notice and the import fixes the issue. Co-authored-by: Piotr Paulski <piotrpaulski@chromium.org>
This commit is contained in:
1 parent
eea5b80165
commit
94752ffade
27 files changed
+27
No files matched your search
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import fs from 'node:fs/promises';
|
||||
import os from 'node:os';
|
||||
import path from 'node:path';
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import {
|
||||
AggregatedIssue,
|
||||
Marked,
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import {logger} from './logger.js';
|
||||
import type {Page, Protocol, CdpPage} from './third_party/index.js';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import type {TextSnapshot, TextSnapshotNode} from '../McpContext.js';
|
||||
|
||||
export function formatSnapshotNode(
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import fs from 'node:fs';
|
||||
|
||||
import {debug} from './third_party/index.js';
|
||||
|
||||
Vendored
+1
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import 'core-js/modules/es.promise.with-resolvers.js';
|
||||
import 'core-js/proposals/iterator-helpers.js';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import type {KeyInput} from '../third_party/index.js';
|
||||
|
||||
// See the KeyInput type for the list of supported keys.
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {readFile, rm} from 'node:fs/promises';
|
||||
import {tmpdir} from 'node:os';
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {afterEach, beforeEach, describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import os from 'node:os';
|
||||
import path from 'node:path';
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import fs from 'node:fs';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import http, {
|
||||
type IncomingMessage,
|
||||
type Server,
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import '../src/polyfill.js';
|
||||
|
||||
import path from 'node:path';
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {afterEach, before, beforeEach, describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import fs from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it, afterEach} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {rm, stat, mkdir, chmod, writeFile} from 'node:fs/promises';
|
||||
import {tmpdir} from 'node:os';
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import assert from 'node:assert';
|
||||
import {describe, it} from 'node:test';
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import logger from 'debug';
|
||||
import type {Browser} from 'puppeteer';
|
||||
import puppeteer, {Locator} from 'puppeteer';
|
||||
|
||||
Reference in new issue
Block a user