diff --git a/.github/shared/src/spec-model.js b/.github/shared/src/spec-model.js index 77805d7f25b5..93e9e586b716 100644 --- a/.github/shared/src/spec-model.js +++ b/.github/shared/src/spec-model.js @@ -3,6 +3,7 @@ import { readdir } from "fs/promises"; import { resolve } from "path"; import { flatMapAsync, mapAsync } from "./array.js"; +import { readme } from "./changed-files.js"; import { Readme } from "./readme.js"; /** @type {Map} */ @@ -226,14 +227,3 @@ export class SpecModel { return `SpecModel(${this.#folder}, {logger: ${this.#logger}}})`; } } - -// TODO: Remove duplication with changed-files.js (which currently requires paths relative to repo root) - -/** - * @param {string} [file] - * @returns {boolean} - */ -function readme(file) { - // Filename "readme.md" with any case is a valid README file - return typeof file === "string" && file.toLowerCase().endsWith("readme.md"); -}