From c1812b8816a74b8f4d0f42cd49523e412a5152a2 Mon Sep 17 00:00:00 2001 From: Jack Baldry Date: Mon, 23 Sep 2024 14:29:11 +0100 Subject: [PATCH 1/3] Add TypeScript script that replaces website-sync Signed-off-by: Jack Baldry --- .gitignore | 1 + publish-technical-documentation/action.mts | 26 ++ publish-technical-documentation/action.yml | 29 +- .../dist/action.mjs | 15 + .../dist/lib/publish.mjs | 176 ++++++++++ .../dist/local.mjs | 28 ++ .../lib/publish.mts | 228 +++++++++++++ publish-technical-documentation/local.mts | 51 +++ .../package-lock.json | 33 ++ publish-technical-documentation/package.json | 20 ++ publish-technical-documentation/tsconfig.json | 108 ++++++ publish-technical-documentation/yarn.lock | 314 ++++++++++++++++++ 12 files changed, 1013 insertions(+), 16 deletions(-) create mode 100644 publish-technical-documentation/action.mts create mode 100644 publish-technical-documentation/dist/action.mjs create mode 100644 publish-technical-documentation/dist/lib/publish.mjs create mode 100644 publish-technical-documentation/dist/local.mjs create mode 100644 publish-technical-documentation/lib/publish.mts create mode 100644 publish-technical-documentation/local.mts create mode 100644 publish-technical-documentation/package-lock.json create mode 100644 publish-technical-documentation/package.json create mode 100644 publish-technical-documentation/tsconfig.json create mode 100644 publish-technical-documentation/yarn.lock diff --git a/.gitignore b/.gitignore index 13b9f0511..c0e872dc8 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ .idea /docs/variables.mk.local /node_modules/ +/publish-technical-documentation/node_modules/ diff --git a/publish-technical-documentation/action.mts b/publish-technical-documentation/action.mts new file mode 100644 index 000000000..7f086827e --- /dev/null +++ b/publish-technical-documentation/action.mts @@ -0,0 +1,26 @@ +import core from "@actions/core"; +import { Octokit } from "octokit"; + +import { publish } from "./lib/publish.mjs"; + +const sourceDirectory = core.getInput("source-directory"); +const websiteDirectory = core.getInput("website-directory"); + +const token = core.getInput("token"); +const octokit = new Octokit({ auth: token }); + +const sourceRepository = "."; +const websiteRepository = "website"; + +export async function main() { + publish( + octokit, + sourceRepository, + sourceDirectory, + websiteRepository, + websiteDirectory + ).catch((error) => { + console.error(error); + core.setFailed(error.message); + }); +} diff --git a/publish-technical-documentation/action.yml b/publish-technical-documentation/action.yml index 3c6432ee3..524177920 100644 --- a/publish-technical-documentation/action.yml +++ b/publish-technical-documentation/action.yml @@ -10,10 +10,10 @@ description: | id-token: write ``` inputs: - source_directory: + source-directory: default: docs/sources description: Path to source directory, relative to the project root, to sync documentation from. - website_directory: + website-directory: description: Website directory to sync the documentation to. required: true runs: @@ -22,7 +22,7 @@ runs: - name: Build website shell: bash run: | - docker run -v "${PWD}/${{ inputs.source_directory }}:/hugo/${{ inputs.website_directory }}" --rm grafana/docs-base:latest /bin/bash -c 'make hugo' + docker run -v "${PWD}/${{ inputs.source-directory }}:/hugo/${{ inputs.website-directory }}" --rm grafana/docs-base:latest /bin/bash -c 'make hugo' - id: get-secrets uses: grafana/shared-workflows/actions/get-vault-secrets@main @@ -35,23 +35,20 @@ runs: id: app-token with: app-id: ${{ env.PUBLISH_TECHNICAL_DOCUMENTATION_APP_ID }} - owner: grafana private-key: ${{ env.PUBLISH_TECHNICAL_DOCUMENTATION_PRIVATE_KEY }} - - name: Checkout sync action - uses: actions/checkout@v4 + - uses: actions/checkout@v4 with: - path: .github/actions/website-sync - repository: grafana/website-sync + repository: grafana/website token: ${{ steps.app-token.outputs.token }} - name: Sync to the website repository - uses: ./.github/actions/website-sync - id: publish + uses: actions/github-script@v7 with: - repository: grafana/website - branch: master - host: github.com - github_pat: grafanabot:${{ steps.app-token.outputs.token }} - source_folder: ${{ inputs.source_directory }} - target_folder: ${{ inputs.website_directory }} + script: | + const { main } = await import('${{ github.action_path }}/dist/action.mjs'); + + await main(); + source-directory: ${{ inputs.source-directory }} + token: ${{ steps.app-token.outputs.token }} + website-directory: ${{ inputs.website-directory }} diff --git a/publish-technical-documentation/dist/action.mjs b/publish-technical-documentation/dist/action.mjs new file mode 100644 index 000000000..c62b07f07 --- /dev/null +++ b/publish-technical-documentation/dist/action.mjs @@ -0,0 +1,15 @@ +import core from "@actions/core"; +import { Octokit } from "octokit"; +import { publish } from "./lib/publish.mjs"; +const sourceDirectory = core.getInput("source-directory"); +const websiteDirectory = core.getInput("website-directory"); +const token = core.getInput("token"); +const octokit = new Octokit({ auth: token }); +const sourceRepository = "."; +const websiteRepository = "website"; +export async function main() { + publish(octokit, sourceRepository, sourceDirectory, websiteRepository, websiteDirectory).catch((error) => { + console.error(error); + core.setFailed(error.message); + }); +} diff --git a/publish-technical-documentation/dist/lib/publish.mjs b/publish-technical-documentation/dist/lib/publish.mjs new file mode 100644 index 000000000..e768e53f7 --- /dev/null +++ b/publish-technical-documentation/dist/lib/publish.mjs @@ -0,0 +1,176 @@ +// Copyright 2024 Grafana Labs +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +import { spawn } from "node:child_process"; +import * as readline from "node:readline/promises"; +import * as fs from "node:fs"; +import path from "node:path"; +var Status; +(function (Status) { + Status["UNMODIFIED"] = " "; + Status["MODIFIED"] = "M"; + Status["ADDED"] = "A"; + Status["DELETED"] = "D"; + Status["RENAMED"] = "R"; + Status["COPIED"] = "C"; + Status["UNMERGED"] = "U"; + Status["UNTRACKED"] = "?"; + Status["IGNORED"] = "!"; +})(Status || (Status = {})); +// Git status porcelain v1 format: +// https://git-scm.com/docs/git-status#_short_format +// XY PATH +// XY ORIG_PATH -> PATH +function parsePorcelainV1(line) { + if (line.length < 4) { + throw new Error(`Invalid porcelain v1 line: ${line}`); + } + const indexStatus = line[0]; + const workingTreeStatus = line[1]; + const rest = line.slice(3); + const [originalPath, path] = rest.split(" -> "); + if (!path) { + return { + indexStatus, + workingTreeStatus, + path: rest, + }; + } + return { + indexStatus, + workingTreeStatus, + path, + originalPath, + }; +} +async function rsync(source, destination) { + return new Promise((resolve, reject) => { + const rsync = spawn("rsync", [ + "-a", + "--quiet", + "--delete", + source, + destination, + ]); + let stderrOutput = ""; + const stderr = readline.createInterface({ input: rsync.stderr }); + stderr.on("line", (line) => { + stderrOutput += line; + }); + rsync.on("close", (code) => { + if (code !== 0) { + reject(`${stderrOutput}\nrsync process exited with code ${code}`); + } + resolve(); + }); + }); +} +// Return a list of all unstaged Git files in the specified subdirectory. +async function getUnstagedFiles(repository, subdirectory) { + return new Promise((resolve, reject) => { + const git = spawn("git", ["status", "--porcelain=v1", "--", subdirectory], { + cwd: repository, + }); + const files = []; + const stdout = readline.createInterface({ input: git.stdout }); + stdout.on("line", (line) => { + files.push(parsePorcelainV1(line)); + }); + let stderrOutput = ""; + const stderr = readline.createInterface({ input: git.stderr }); + stderr.on("line", (line) => { + stderrOutput += line; + }); + git.on("close", (code) => { + if (code !== 0) { + reject(`${stderrOutput}\ngit process exited with code ${code}`); + } + resolve(files); + }); + }); +} +async function baseTreeSha(octokit, repo, branch) { + return (await octokit.rest.git.getTree({ + owner: "grafana", + repo, + tree_sha: `heads/${branch}`, + })).data.sha; +} +export async function publish(octokit, sourceRepository, sourceDirectory, websiteRepository, websiteDirectory) { + rsync(path.join(sourceRepository, sourceDirectory) + "/", path.join(websiteRepository, websiteDirectory)); + const files = await getUnstagedFiles(websiteRepository, websiteDirectory); + const baseTree = await baseTreeSha(octokit, "website", "master"); + const newTree = (await octokit.rest.git.createTree({ + owner: "grafana", + repo: "website", + base_tree: baseTree, + tree: files.map((file) => { + if (file.workingTreeStatus === Status.DELETED) { + return { + mode: "100644", + path: file.path, + sha: null, + type: "blob", + }; + } + else { + const fileInfo = fs.statSync(path.join(websiteRepository, file.path)); + if (fileInfo.isDirectory()) { + return { + mode: "040000", + path: file.path.replace(/\/$/, ""), + type: "tree", + sha: null, + }; + } + return { + content: fs + .readFileSync(path.join(websiteRepository, file.path)) + .toString(), + mode: "100644", + path: file.path, + type: "blob", + }; + } + }), + })).data.sha; + const commit = (await octokit.rest.git.createCommit({ + owner: "grafana", + repo: "website", + message: `Publish from grafana/writers-toolkit:main/${sourceDirectory}\n` + + "\n" + + "Co-authored-by: Jack Baldry ", + tree: newTree, + parents: [baseTree], + })).data.sha; + octokit.rest.git.deleteRef({ + owner: "grafana", + repo: "website", + ref: "heads/jdb/2024-09-test-publish-technical-documentation", + }); + const websiteCommit = octokit.rest.git.createRef({ + owner: "grafana", + repo: "website", + ref: "refs/heads/jdb/2024-09-test-publish-technical-documentation", + sha: commit, + }); + // const websiteCommit = ( + // await octokit.rest.git.updateRef({ + // owner: "grafana", + // repo: "website", + // ref: "heads/master", + // sha: commit, + // }) + // ).data; + return (await websiteCommit).data.object.sha; +} diff --git a/publish-technical-documentation/dist/local.mjs b/publish-technical-documentation/dist/local.mjs new file mode 100644 index 000000000..7fcce3e01 --- /dev/null +++ b/publish-technical-documentation/dist/local.mjs @@ -0,0 +1,28 @@ +import { env } from "node:process"; +import { Octokit } from "octokit"; +import { publish } from "./lib/publish.mjs"; +try { + const token = env.GITHUB_TOKEN; + if (!token) { + throw new Error("Environment variable GITHUB_TOKEN is required"); + } + const octokit = new Octokit({ auth: token }); + const sourceRepository = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY; + if (!sourceRepository) { + throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY is required"); + } + const sourceDirectory = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_DIRECTORY || "docs/sources"; + const websiteRepository = env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY; + if (!websiteRepository) { + throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY is required"); + } + const websiteDirectory = env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY; + if (!websiteDirectory) { + throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY is required"); + } + const sha = await publish(octokit, sourceRepository, sourceDirectory, websiteRepository, websiteDirectory); + console.log(sha); +} +catch (error) { + console.error(error); +} diff --git a/publish-technical-documentation/lib/publish.mts b/publish-technical-documentation/lib/publish.mts new file mode 100644 index 000000000..6adc558b8 --- /dev/null +++ b/publish-technical-documentation/lib/publish.mts @@ -0,0 +1,228 @@ +// Copyright 2024 Grafana Labs +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +import { spawn } from "node:child_process"; +import * as readline from "node:readline/promises"; +import { Octokit } from "octokit"; +import * as fs from "node:fs"; +import path from "node:path"; + +enum Status { + UNMODIFIED = " ", + MODIFIED = "M", + ADDED = "A", + DELETED = "D", + RENAMED = "R", + COPIED = "C", + UNMERGED = "U", + UNTRACKED = "?", + IGNORED = "!", +} +type PathStatus = { + indexStatus: Status; + workingTreeStatus: Status; + path: string; + originalPath?: string; +}; + +// Git status porcelain v1 format: +// https://git-scm.com/docs/git-status#_short_format +// XY PATH +// XY ORIG_PATH -> PATH +function parsePorcelainV1(line: string): PathStatus { + if (line.length < 4) { + throw new Error(`Invalid porcelain v1 line: ${line}`); + } + + const indexStatus = line[0] as Status; + const workingTreeStatus = line[1] as Status; + + const rest = line.slice(3); + const [originalPath, path] = rest.split(" -> "); + if (!path) { + return { + indexStatus, + workingTreeStatus, + path: rest, + }; + } + + return { + indexStatus, + workingTreeStatus, + path, + originalPath, + }; +} + +async function rsync(source: string, destination: string): Promise { + return new Promise((resolve, reject) => { + const rsync = spawn("rsync", [ + "-a", + "--quiet", + "--delete", + source, + destination, + ]); + + let stderrOutput = ""; + const stderr = readline.createInterface({ input: rsync.stderr }); + stderr.on("line", (line: string) => { + stderrOutput += line; + }); + + rsync.on("close", (code: number) => { + if (code !== 0) { + reject(`${stderrOutput}\nrsync process exited with code ${code}`); + } + + resolve(); + }); + }); +} + +// Return a list of all unstaged Git files in the specified subdirectory. +async function getUnstagedFiles( + repository: string, + subdirectory: string +): Promise> { + return new Promise((resolve, reject) => { + const git = spawn("git", ["status", "--porcelain=v1", "--", subdirectory], { + cwd: repository, + }); + + const files: Array = []; + + const stdout = readline.createInterface({ input: git.stdout }); + stdout.on("line", (line: string) => { + files.push(parsePorcelainV1(line)); + }); + + let stderrOutput = ""; + const stderr = readline.createInterface({ input: git.stderr }); + stderr.on("line", (line: string) => { + stderrOutput += line; + }); + + git.on("close", (code: number) => { + if (code !== 0) { + reject(`${stderrOutput}\ngit process exited with code ${code}`); + } + + resolve(files); + }); + }); +} + +async function baseTreeSha( + octokit: Octokit, + repo: string, + branch: string +): Promise { + return ( + await octokit.rest.git.getTree({ + owner: "grafana", + repo, + tree_sha: `heads/${branch}`, + }) + ).data.sha; +} + +export async function publish( + octokit: Octokit, + sourceRepository: string, + sourceDirectory: string, + websiteRepository: string, + websiteDirectory: string +): Promise { + rsync( + path.join(sourceRepository, sourceDirectory) + "/", + path.join(websiteRepository, websiteDirectory) + ); + const files = await getUnstagedFiles(websiteRepository, websiteDirectory); + const baseTree = await baseTreeSha(octokit, "website", "master"); + + const newTree = ( + await octokit.rest.git.createTree({ + owner: "grafana", + repo: "website", + base_tree: baseTree, + tree: files.map((file: PathStatus) => { + if (file.workingTreeStatus === Status.DELETED) { + return { + mode: "100644", + path: file.path, + sha: null, + type: "blob", + }; + } else { + const fileInfo = fs.statSync(path.join(websiteRepository, file.path)); + if (fileInfo.isDirectory()) { + return { + mode: "040000", + path: file.path.replace(/\/$/, ""), + type: "tree", + sha: null, + }; + } + return { + content: fs + .readFileSync(path.join(websiteRepository, file.path)) + .toString(), + mode: "100644", + path: file.path, + type: "blob", + }; + } + }), + }) + ).data.sha; + + const commit = ( + await octokit.rest.git.createCommit({ + owner: "grafana", + repo: "website", + message: + `Publish from grafana/writers-toolkit:main/${sourceDirectory}\n` + + "\n" + + "Co-authored-by: Jack Baldry ", + tree: newTree, + parents: [baseTree], + }) + ).data.sha; + + octokit.rest.git.deleteRef({ + owner: "grafana", + repo: "website", + ref: "heads/jdb/2024-09-test-publish-technical-documentation", + }); + + const websiteCommit = octokit.rest.git.createRef({ + owner: "grafana", + repo: "website", + ref: "refs/heads/jdb/2024-09-test-publish-technical-documentation", + sha: commit, + }); + + // const websiteCommit = ( + // await octokit.rest.git.updateRef({ + // owner: "grafana", + // repo: "website", + // ref: "heads/master", + // sha: commit, + // }) + // ).data; + + return (await websiteCommit).data.object.sha; +} diff --git a/publish-technical-documentation/local.mts b/publish-technical-documentation/local.mts new file mode 100644 index 000000000..1cfa4494a --- /dev/null +++ b/publish-technical-documentation/local.mts @@ -0,0 +1,51 @@ +import { env } from "node:process"; +import { Octokit } from "octokit"; + +import { publish } from "./lib/publish.mjs"; + +try { + const token = env.GITHUB_TOKEN; + if (!token) { + throw new Error("Environment variable GITHUB_TOKEN is required"); + } + + const octokit = new Octokit({ auth: token }); + + const sourceRepository = + env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY; + if (!sourceRepository) { + throw new Error( + "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY is required" + ); + } + + const sourceDirectory = + env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_DIRECTORY || "docs/sources"; + + const websiteRepository = + env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY; + if (!websiteRepository) { + throw new Error( + "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY is required" + ); + } + const websiteDirectory = + env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY; + if (!websiteDirectory) { + throw new Error( + "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY is required" + ); + } + + const sha = await publish( + octokit, + sourceRepository, + sourceDirectory, + websiteRepository, + websiteDirectory + ); + + console.log(sha); +} catch (error) { + console.error(error); +} diff --git a/publish-technical-documentation/package-lock.json b/publish-technical-documentation/package-lock.json new file mode 100644 index 000000000..484554d37 --- /dev/null +++ b/publish-technical-documentation/package-lock.json @@ -0,0 +1,33 @@ +{ + "name": "publish-technical-documentation", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "publish-technical-documentation", + "version": "1.0.0", + "license": "apache2", + "devDependencies": { + "@types/node": "^22.5.5" + } + }, + "node_modules/@types/node": { + "version": "22.5.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.5.5.tgz", + "integrity": "sha512-Xjs4y5UPO/CLdzpgR6GirZJx36yScjh73+2NlLlkFRSoQN8B0DpfXPdZGnvVmLRLOsqDpOfTNv7D9trgGhmOIA==", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~6.19.2" + } + }, + "node_modules/undici-types": { + "version": "6.19.8", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", + "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==", + "dev": true, + "license": "MIT" + } + } +} diff --git a/publish-technical-documentation/package.json b/publish-technical-documentation/package.json new file mode 100644 index 000000000..3ba29260e --- /dev/null +++ b/publish-technical-documentation/package.json @@ -0,0 +1,20 @@ +{ + "name": "publish-technical-documentation", + "version": "1.0.0", + "description": "Publish documentation from source repositories to the website repository.", + "main": "dist/index.mjs", + "repository": "https://github.com/grafana/writers-toolkit/tree/main/publish-technical-documentation/", + "author": "@jdbaldry", + "license": "Apache-2.0", + "private": false, + "devDependencies": { + "@types/node": "^22.5.5" + }, + "dependencies": { + "@actions/core": "^1.10.1", + "octokit": "^4.0.2" + }, + "scripts": { + "build": "tsc" + } +} diff --git a/publish-technical-documentation/tsconfig.json b/publish-technical-documentation/tsconfig.json new file mode 100644 index 000000000..15bcac07f --- /dev/null +++ b/publish-technical-documentation/tsconfig.json @@ -0,0 +1,108 @@ +{ + "compilerOptions": { + /* Visit https://aka.ms/tsconfig to read more about this file */ + + /* Projects */ + // "incremental": true, /* Save .tsbuildinfo files to allow for incremental compilation of projects. */ + // "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */ + // "tsBuildInfoFile": "./.tsbuildinfo", /* Specify the path to .tsbuildinfo incremental compilation file. */ + // "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects. */ + // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */ + // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */ + + /* Language and Environment */ + "target": "es2022" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */, + // "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ + // "jsx": "preserve", /* Specify what JSX code is generated. */ + // "experimentalDecorators": true, /* Enable experimental support for legacy experimental decorators. */ + // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */ + // "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h'. */ + // "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */ + // "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using 'jsx: react-jsx*'. */ + // "reactNamespace": "", /* Specify the object invoked for 'createElement'. This only applies when targeting 'react' JSX emit. */ + // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */ + // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */ + // "moduleDetection": "auto", /* Control what method is used to detect module-format JS files. */ + + /* Modules */ + "module": "nodenext" /* Specify what module code is generated. */, + // "rootDir": "./", /* Specify the root folder within your source files. */ + "moduleResolution": "nodenext" /* Specify how TypeScript looks up a file from a given module specifier. */, + // "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */ + // "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */ + // "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */ + // "typeRoots": [], /* Specify multiple folders that act like './node_modules/@types'. */ + // "types": [], /* Specify type package names to be included without being referenced in a source file. */ + // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ + // "moduleSuffixes": [], /* List of file name suffixes to search when resolving a module. */ + // "allowImportingTsExtensions": true, /* Allow imports to include TypeScript file extensions. Requires '--moduleResolution bundler' and either '--noEmit' or '--emitDeclarationOnly' to be set. */ + // "resolvePackageJsonExports": true, /* Use the package.json 'exports' field when resolving package imports. */ + // "resolvePackageJsonImports": true, /* Use the package.json 'imports' field when resolving imports. */ + // "customConditions": [], /* Conditions to set in addition to the resolver-specific defaults when resolving imports. */ + // "resolveJsonModule": true, /* Enable importing .json files. */ + // "allowArbitraryExtensions": true, /* Enable importing files with any extension, provided a declaration file is present. */ + // "noResolve": true, /* Disallow 'import's, 'require's or ''s from expanding the number of files TypeScript should add to a project. */ + + /* JavaScript Support */ + // "allowJs": true, /* Allow JavaScript files to be a part of your program. Use the 'checkJS' option to get errors from these files. */ + // "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */ + // "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from 'node_modules'. Only applicable with 'allowJs'. */ + + /* Emit */ + // "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */ + // "declarationMap": true, /* Create sourcemaps for d.ts files. */ + // "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */ + // "sourceMap": true, /* Create source map files for emitted JavaScript files. */ + // "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */ + // "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */ + "outDir": "./dist", /* Specify an output folder for all emitted files. */ + // "removeComments": true, /* Disable emitting comments. */ + // "noEmit": true, /* Disable emitting files from a compilation. */ + // "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */ + // "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */ + // "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */ + // "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */ + // "newLine": "crlf", /* Set the newline character for emitting files. */ + // "stripInternal": true, /* Disable emitting declarations that have '@internal' in their JSDoc comments. */ + // "noEmitHelpers": true, /* Disable generating custom helper functions like '__extends' in compiled output. */ + // "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */ + // "preserveConstEnums": true, /* Disable erasing 'const enum' declarations in generated code. */ + // "declarationDir": "./", /* Specify the output directory for generated declaration files. */ + + /* Interop Constraints */ + // "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */ + // "verbatimModuleSyntax": true, /* Do not transform or elide any imports or exports not marked as type-only, ensuring they are written in the output file's format based on the 'module' setting. */ + // "isolatedDeclarations": true, /* Require sufficient annotation on exports so other tools can trivially generate declaration files. */ + // "allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */ + "esModuleInterop": true /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */, + // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */ + "forceConsistentCasingInFileNames": true /* Ensure that casing is correct in imports. */, + + /* Type Checking */ + "strict": true /* Enable all strict type-checking options. */, + // "noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied 'any' type. */ + // "strictNullChecks": true, /* When type checking, take into account 'null' and 'undefined'. */ + // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */ + // "strictBindCallApply": true, /* Check that the arguments for 'bind', 'call', and 'apply' methods match the original function. */ + // "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */ + // "noImplicitThis": true, /* Enable error reporting when 'this' is given the type 'any'. */ + // "useUnknownInCatchVariables": true, /* Default catch clause variables as 'unknown' instead of 'any'. */ + // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */ + // "noUnusedLocals": true, /* Enable error reporting when local variables aren't read. */ + // "noUnusedParameters": true, /* Raise an error when a function parameter isn't read. */ + // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */ + // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */ + // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */ + // "noUncheckedIndexedAccess": true, /* Add 'undefined' to a type when accessed using an index. */ + // "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */ + // "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type. */ + // "allowUnusedLabels": true, /* Disable error reporting for unused labels. */ + // "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */ + + /* Completeness */ + // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */ + "skipLibCheck": true /* Skip type checking all .d.ts files. */ + } +} diff --git a/publish-technical-documentation/yarn.lock b/publish-technical-documentation/yarn.lock new file mode 100644 index 000000000..f3b797ac7 --- /dev/null +++ b/publish-technical-documentation/yarn.lock @@ -0,0 +1,314 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +"@actions/core@^1.10.1": + version "1.10.1" + resolved "https://registry.yarnpkg.com/@actions/core/-/core-1.10.1.tgz#61108e7ac40acae95ee36da074fa5850ca4ced8a" + integrity sha512-3lBR9EDAY+iYIpTnTIXmWcNbX3T2kCkAEQGIQx4NVQ0575nk2k3GRZDTPQG+vVtS2izSLmINlxXf0uLtnrTP+g== + dependencies: + "@actions/http-client" "^2.0.1" + uuid "^8.3.2" + +"@actions/http-client@^2.0.1": + version "2.2.3" + resolved "https://registry.yarnpkg.com/@actions/http-client/-/http-client-2.2.3.tgz#31fc0b25c0e665754ed39a9f19a8611fc6dab674" + integrity sha512-mx8hyJi/hjFvbPokCg4uRd4ZX78t+YyRPtnKWwIl+RzNaVuFpQHfmlGVfsKEJN8LwTCvL+DfVgAM04XaHkm6bA== + dependencies: + tunnel "^0.0.6" + undici "^5.25.4" + +"@fastify/busboy@^2.0.0": + version "2.1.1" + resolved "https://registry.yarnpkg.com/@fastify/busboy/-/busboy-2.1.1.tgz#b9da6a878a371829a0502c9b6c1c143ef6663f4d" + integrity sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA== + +"@octokit/app@^15.0.0": + version "15.1.0" + resolved "https://registry.yarnpkg.com/@octokit/app/-/app-15.1.0.tgz#b330d8826be088ec8d1d43a59dc27ef57d1232b2" + integrity sha512-TkBr7QgOmE6ORxvIAhDbZsqPkF7RSqTY4pLTtUQCvr6dTXqvi2fFo46q3h1lxlk/sGMQjqyZ0kEahkD/NyzOHg== + dependencies: + "@octokit/auth-app" "^7.0.0" + "@octokit/auth-unauthenticated" "^6.0.0" + "@octokit/core" "^6.1.2" + "@octokit/oauth-app" "^7.0.0" + "@octokit/plugin-paginate-rest" "^11.0.0" + "@octokit/types" "^13.0.0" + "@octokit/webhooks" "^13.0.0" + +"@octokit/auth-app@^7.0.0": + version "7.1.1" + resolved "https://registry.yarnpkg.com/@octokit/auth-app/-/auth-app-7.1.1.tgz#d8916ad01e6ffb0a0a50507aa613e91fe7a49b93" + integrity sha512-kRAd6yelV9OgvlEJE88H0VLlQdZcag9UlLr7dV0YYP37X8PPDvhgiTy66QVhDXdyoT0AleFN2w/qXkPdrSzINg== + dependencies: + "@octokit/auth-oauth-app" "^8.1.0" + "@octokit/auth-oauth-user" "^5.1.0" + "@octokit/request" "^9.1.1" + "@octokit/request-error" "^6.1.1" + "@octokit/types" "^13.4.1" + lru-cache "^10.0.0" + universal-github-app-jwt "^2.2.0" + universal-user-agent "^7.0.0" + +"@octokit/auth-oauth-app@^8.0.0", "@octokit/auth-oauth-app@^8.1.0": + version "8.1.1" + resolved "https://registry.yarnpkg.com/@octokit/auth-oauth-app/-/auth-oauth-app-8.1.1.tgz#6204affa6e86f535016799cadf2af9befe5e893c" + integrity sha512-5UtmxXAvU2wfcHIPPDWzVSAWXVJzG3NWsxb7zCFplCWEmMCArSZV0UQu5jw5goLQXbFyOr5onzEH37UJB3zQQg== + dependencies: + "@octokit/auth-oauth-device" "^7.0.0" + "@octokit/auth-oauth-user" "^5.0.1" + "@octokit/request" "^9.0.0" + "@octokit/types" "^13.0.0" + universal-user-agent "^7.0.0" + +"@octokit/auth-oauth-device@^7.0.0", "@octokit/auth-oauth-device@^7.0.1": + version "7.1.1" + resolved "https://registry.yarnpkg.com/@octokit/auth-oauth-device/-/auth-oauth-device-7.1.1.tgz#7b4f8f97cbcadbe9894d48cde4406dbdef39875a" + integrity sha512-HWl8lYueHonuyjrKKIup/1tiy0xcmQCdq5ikvMO1YwkNNkxb6DXfrPjrMYItNLyCP/o2H87WuijuE+SlBTT8eg== + dependencies: + "@octokit/oauth-methods" "^5.0.0" + "@octokit/request" "^9.0.0" + "@octokit/types" "^13.0.0" + universal-user-agent "^7.0.0" + +"@octokit/auth-oauth-user@^5.0.1", "@octokit/auth-oauth-user@^5.1.0": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@octokit/auth-oauth-user/-/auth-oauth-user-5.1.1.tgz#4f1570c6ee15bb9ddc3dcca83308dcaa159e3848" + integrity sha512-rRkMz0ErOppdvEfnemHJXgZ9vTPhBuC6yASeFaB7I2yLMd7QpjfrL1mnvRPlyKo+M6eeLxrKanXJ9Qte29SRsw== + dependencies: + "@octokit/auth-oauth-device" "^7.0.1" + "@octokit/oauth-methods" "^5.0.0" + "@octokit/request" "^9.0.1" + "@octokit/types" "^13.0.0" + universal-user-agent "^7.0.0" + +"@octokit/auth-token@^5.0.0": + version "5.1.1" + resolved "https://registry.yarnpkg.com/@octokit/auth-token/-/auth-token-5.1.1.tgz#3bbfe905111332a17f72d80bd0b51a3e2fa2cf07" + integrity sha512-rh3G3wDO8J9wSjfI436JUKzHIxq8NaiL0tVeB2aXmG6p/9859aUOAjA9pmSPNGGZxfwmaJ9ozOJImuNVJdpvbA== + +"@octokit/auth-unauthenticated@^6.0.0", "@octokit/auth-unauthenticated@^6.0.0-beta.1": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@octokit/auth-unauthenticated/-/auth-unauthenticated-6.1.0.tgz#de0fe923bb06ed93aea526ab99972a98c546d0bf" + integrity sha512-zPSmfrUAcspZH/lOFQnVnvjQZsIvmfApQH6GzJrkIunDooU1Su2qt2FfMTSVPRp7WLTQyC20Kd55lF+mIYaohQ== + dependencies: + "@octokit/request-error" "^6.0.1" + "@octokit/types" "^13.0.0" + +"@octokit/core@^6.0.0", "@octokit/core@^6.1.2": + version "6.1.2" + resolved "https://registry.yarnpkg.com/@octokit/core/-/core-6.1.2.tgz#20442d0a97c411612da206411e356014d1d1bd17" + integrity sha512-hEb7Ma4cGJGEUNOAVmyfdB/3WirWMg5hDuNFVejGEDFqupeOysLc2sG6HJxY2etBp5YQu5Wtxwi020jS9xlUwg== + dependencies: + "@octokit/auth-token" "^5.0.0" + "@octokit/graphql" "^8.0.0" + "@octokit/request" "^9.0.0" + "@octokit/request-error" "^6.0.1" + "@octokit/types" "^13.0.0" + before-after-hook "^3.0.2" + universal-user-agent "^7.0.0" + +"@octokit/endpoint@^10.0.0": + version "10.1.1" + resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-10.1.1.tgz#1a9694e7aef6aa9d854dc78dd062945945869bcc" + integrity sha512-JYjh5rMOwXMJyUpj028cu0Gbp7qe/ihxfJMLc8VZBMMqSwLgOxDI1911gV4Enl1QSavAQNJcwmwBF9M0VvLh6Q== + dependencies: + "@octokit/types" "^13.0.0" + universal-user-agent "^7.0.2" + +"@octokit/graphql@^8.0.0": + version "8.1.1" + resolved "https://registry.yarnpkg.com/@octokit/graphql/-/graphql-8.1.1.tgz#3cacab5f2e55d91c733e3bf481d3a3f8a5f639c4" + integrity sha512-ukiRmuHTi6ebQx/HFRCXKbDlOh/7xEV6QUXaE7MJEKGNAncGI/STSbOkl12qVXZrfZdpXctx5O9X1AIaebiDBg== + dependencies: + "@octokit/request" "^9.0.0" + "@octokit/types" "^13.0.0" + universal-user-agent "^7.0.0" + +"@octokit/oauth-app@^7.0.0": + version "7.1.3" + resolved "https://registry.yarnpkg.com/@octokit/oauth-app/-/oauth-app-7.1.3.tgz#a0f256dd185e7c00bfbc3e6bc3c5aad66e42c609" + integrity sha512-EHXbOpBkSGVVGF1W+NLMmsnSsJRkcrnVmDKt0TQYRBb6xWfWzoi9sBD4DIqZ8jGhOWO/V8t4fqFyJ4vDQDn9bg== + dependencies: + "@octokit/auth-oauth-app" "^8.0.0" + "@octokit/auth-oauth-user" "^5.0.1" + "@octokit/auth-unauthenticated" "^6.0.0-beta.1" + "@octokit/core" "^6.0.0" + "@octokit/oauth-authorization-url" "^7.0.0" + "@octokit/oauth-methods" "^5.0.0" + "@types/aws-lambda" "^8.10.83" + universal-user-agent "^7.0.0" + +"@octokit/oauth-authorization-url@^7.0.0": + version "7.1.1" + resolved "https://registry.yarnpkg.com/@octokit/oauth-authorization-url/-/oauth-authorization-url-7.1.1.tgz#0e17c2225eb66b58ec902d02b6f1315ffe9ff04b" + integrity sha512-ooXV8GBSabSWyhLUowlMIVd9l1s2nsOGQdlP2SQ4LnkEsGXzeCvbSbCPdZThXhEFzleGPwbapT0Sb+YhXRyjCA== + +"@octokit/oauth-methods@^5.0.0": + version "5.1.2" + resolved "https://registry.yarnpkg.com/@octokit/oauth-methods/-/oauth-methods-5.1.2.tgz#fd31d2a69f4c91d1abc1ed1814dda5252c697e02" + integrity sha512-C5lglRD+sBlbrhCUTxgJAFjWgJlmTx5bQ7Ch0+2uqRjYv7Cfb5xpX4WuSC9UgQna3sqRGBL9EImX9PvTpMaQ7g== + dependencies: + "@octokit/oauth-authorization-url" "^7.0.0" + "@octokit/request" "^9.1.0" + "@octokit/request-error" "^6.1.0" + "@octokit/types" "^13.0.0" + +"@octokit/openapi-types@^22.2.0": + version "22.2.0" + resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-22.2.0.tgz#75aa7dcd440821d99def6a60b5f014207ae4968e" + integrity sha512-QBhVjcUa9W7Wwhm6DBFu6ZZ+1/t/oYxqc2tp81Pi41YNuJinbFRx8B133qVOrAaBbF7D/m0Et6f9/pZt9Rc+tg== + +"@octokit/openapi-webhooks-types@8.3.0": + version "8.3.0" + resolved "https://registry.yarnpkg.com/@octokit/openapi-webhooks-types/-/openapi-webhooks-types-8.3.0.tgz#a7a4da00c0f27f7f5708eb3fcebefa08f8d51125" + integrity sha512-vKLsoR4xQxg4Z+6rU/F65ItTUz/EXbD+j/d4mlq2GW8TsA4Tc8Kdma2JTAAJ5hrKWUQzkR/Esn2fjsqiVRYaQg== + +"@octokit/plugin-paginate-graphql@^5.0.0": + version "5.2.3" + resolved "https://registry.yarnpkg.com/@octokit/plugin-paginate-graphql/-/plugin-paginate-graphql-5.2.3.tgz#19882ff4694066b0937aea85b7e8eac512df4e9a" + integrity sha512-EzFueuXVU3VHv5FwEXbdznn9EmyF0vA5LGDX6a8fJ9YJAlDgdYHRKJMO4Ghl2PPPJBxIPMDUJMnlUHqcvP7AnQ== + +"@octokit/plugin-paginate-rest@^11.0.0": + version "11.3.3" + resolved "https://registry.yarnpkg.com/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-11.3.3.tgz#efc97ba66aae6797e2807a082f99b9cfc0e05aba" + integrity sha512-o4WRoOJZlKqEEgj+i9CpcmnByvtzoUYC6I8PD2SA95M+BJ2x8h7oLcVOg9qcowWXBOdcTRsMZiwvM3EyLm9AfA== + dependencies: + "@octokit/types" "^13.5.0" + +"@octokit/plugin-rest-endpoint-methods@^13.0.0": + version "13.2.4" + resolved "https://registry.yarnpkg.com/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-13.2.4.tgz#543add032d3fe3f5d2839bfd619cf66d85469f01" + integrity sha512-gusyAVgTrPiuXOdfqOySMDztQHv6928PQ3E4dqVGEtOvRXAKRbJR4b1zQyniIT9waqaWk/UDaoJ2dyPr7Bk7Iw== + dependencies: + "@octokit/types" "^13.5.0" + +"@octokit/plugin-retry@^7.0.0": + version "7.1.2" + resolved "https://registry.yarnpkg.com/@octokit/plugin-retry/-/plugin-retry-7.1.2.tgz#242e2d19a72a50b5113bb25d7d2c622ce0373fa0" + integrity sha512-XOWnPpH2kJ5VTwozsxGurw+svB2e61aWlmk5EVIYZPwFK5F9h4cyPyj9CIKRyMXMHSwpIsI3mPOdpMmrRhe7UQ== + dependencies: + "@octokit/request-error" "^6.0.0" + "@octokit/types" "^13.0.0" + bottleneck "^2.15.3" + +"@octokit/plugin-throttling@^9.0.0": + version "9.3.1" + resolved "https://registry.yarnpkg.com/@octokit/plugin-throttling/-/plugin-throttling-9.3.1.tgz#5648165e1e70e861625f3a16af6c55cafe861061" + integrity sha512-Qd91H4liUBhwLB2h6jZ99bsxoQdhgPk6TdwnClPyTBSDAdviGPceViEgUwj+pcQDmB/rfAXAXK7MTochpHM3yQ== + dependencies: + "@octokit/types" "^13.0.0" + bottleneck "^2.15.3" + +"@octokit/request-error@^6.0.0", "@octokit/request-error@^6.0.1", "@octokit/request-error@^6.1.0", "@octokit/request-error@^6.1.1": + version "6.1.4" + resolved "https://registry.yarnpkg.com/@octokit/request-error/-/request-error-6.1.4.tgz#ad96e29148d19edc2ba8009fc2b5a24a36c90f16" + integrity sha512-VpAhIUxwhWZQImo/dWAN/NpPqqojR6PSLgLYAituLM6U+ddx9hCioFGwBr5Mi+oi5CLeJkcAs3gJ0PYYzU6wUg== + dependencies: + "@octokit/types" "^13.0.0" + +"@octokit/request@^9.0.0", "@octokit/request@^9.0.1", "@octokit/request@^9.1.0", "@octokit/request@^9.1.1": + version "9.1.3" + resolved "https://registry.yarnpkg.com/@octokit/request/-/request-9.1.3.tgz#42b693bc06238f43af3c037ebfd35621c6457838" + integrity sha512-V+TFhu5fdF3K58rs1pGUJIDH5RZLbZm5BI+MNF+6o/ssFNT4vWlCh/tVpF3NxGtP15HUxTTMUbsG5llAuU2CZA== + dependencies: + "@octokit/endpoint" "^10.0.0" + "@octokit/request-error" "^6.0.1" + "@octokit/types" "^13.1.0" + universal-user-agent "^7.0.2" + +"@octokit/types@^13.0.0", "@octokit/types@^13.1.0", "@octokit/types@^13.4.1", "@octokit/types@^13.5.0": + version "13.5.0" + resolved "https://registry.yarnpkg.com/@octokit/types/-/types-13.5.0.tgz#4796e56b7b267ebc7c921dcec262b3d5bfb18883" + integrity sha512-HdqWTf5Z3qwDVlzCrP8UJquMwunpDiMPt5er+QjGzL4hqr/vBVY/MauQgS1xWxCDT1oMx1EULyqxncdCY/NVSQ== + dependencies: + "@octokit/openapi-types" "^22.2.0" + +"@octokit/webhooks-methods@^5.0.0": + version "5.1.0" + resolved "https://registry.yarnpkg.com/@octokit/webhooks-methods/-/webhooks-methods-5.1.0.tgz#13b6c08f89902c1ab0ddf31c6eeeec9c2772cfe6" + integrity sha512-yFZa3UH11VIxYnnoOYCVoJ3q4ChuSOk2IVBBQ0O3xtKX4x9bmKb/1t+Mxixv2iUhzMdOl1qeWJqEhouXXzB3rQ== + +"@octokit/webhooks@^13.0.0": + version "13.3.0" + resolved "https://registry.yarnpkg.com/@octokit/webhooks/-/webhooks-13.3.0.tgz#fd5d54d47c789c75d60a00eb04e982152d7c654a" + integrity sha512-TUkJLtI163Bz5+JK0O+zDkQpn4gKwN+BovclUvCj6pI/6RXrFqQvUMRS2M+Rt8Rv0qR3wjoMoOPmpJKeOh0nBg== + dependencies: + "@octokit/openapi-webhooks-types" "8.3.0" + "@octokit/request-error" "^6.0.1" + "@octokit/webhooks-methods" "^5.0.0" + +"@types/aws-lambda@^8.10.83": + version "8.10.145" + resolved "https://registry.yarnpkg.com/@types/aws-lambda/-/aws-lambda-8.10.145.tgz#b2d31a987f4888e5553ff1819f57cafa475594d9" + integrity sha512-dtByW6WiFk5W5Jfgz1VM+YPA21xMXTuSFoLYIDY0L44jDLLflVPtZkYuu3/YxpGcvjzKFBZLU+GyKjR0HOYtyw== + +"@types/node@^22.5.5": + version "22.5.5" + resolved "https://registry.yarnpkg.com/@types/node/-/node-22.5.5.tgz#52f939dd0f65fc552a4ad0b392f3c466cc5d7a44" + integrity sha512-Xjs4y5UPO/CLdzpgR6GirZJx36yScjh73+2NlLlkFRSoQN8B0DpfXPdZGnvVmLRLOsqDpOfTNv7D9trgGhmOIA== + dependencies: + undici-types "~6.19.2" + +before-after-hook@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/before-after-hook/-/before-after-hook-3.0.2.tgz#d5665a5fa8b62294a5aa0a499f933f4a1016195d" + integrity sha512-Nik3Sc0ncrMK4UUdXQmAnRtzmNQTAAXmXIopizwZ1W1t8QmfJj+zL4OA2I7XPTPW5z5TDqv4hRo/JzouDJnX3A== + +bottleneck@^2.15.3: + version "2.19.5" + resolved "https://registry.yarnpkg.com/bottleneck/-/bottleneck-2.19.5.tgz#5df0b90f59fd47656ebe63c78a98419205cadd91" + integrity sha512-VHiNCbI1lKdl44tGrhNfU3lup0Tj/ZBMJB5/2ZbNXRCPuRCO7ed2mgcK4r17y+KB2EfuYuRaVlwNbAeaWGSpbw== + +lru-cache@^10.0.0: + version "10.4.3" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.4.3.tgz#410fc8a17b70e598013df257c2446b7f3383f119" + integrity sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ== + +octokit@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/octokit/-/octokit-4.0.2.tgz#775d68d363cdaec69d7b73d3dc82ae909d30f59b" + integrity sha512-wbqF4uc1YbcldtiBFfkSnquHtECEIpYD78YUXI6ri1Im5OO2NLo6ZVpRdbJpdnpZ05zMrVPssNiEo6JQtea+Qg== + dependencies: + "@octokit/app" "^15.0.0" + "@octokit/core" "^6.0.0" + "@octokit/oauth-app" "^7.0.0" + "@octokit/plugin-paginate-graphql" "^5.0.0" + "@octokit/plugin-paginate-rest" "^11.0.0" + "@octokit/plugin-rest-endpoint-methods" "^13.0.0" + "@octokit/plugin-retry" "^7.0.0" + "@octokit/plugin-throttling" "^9.0.0" + "@octokit/request-error" "^6.0.0" + "@octokit/types" "^13.0.0" + +tunnel@^0.0.6: + version "0.0.6" + resolved "https://registry.yarnpkg.com/tunnel/-/tunnel-0.0.6.tgz#72f1314b34a5b192db012324df2cc587ca47f92c" + integrity sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg== + +undici-types@~6.19.2: + version "6.19.8" + resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-6.19.8.tgz#35111c9d1437ab83a7cdc0abae2f26d88eda0a02" + integrity sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw== + +undici@^5.25.4: + version "5.28.4" + resolved "https://registry.yarnpkg.com/undici/-/undici-5.28.4.tgz#6b280408edb6a1a604a9b20340f45b422e373068" + integrity sha512-72RFADWFqKmUb2hmmvNODKL3p9hcB6Gt2DOQMis1SEBaV6a4MH8soBvzg+95CYhCKPFedut2JY9bMfrDl9D23g== + dependencies: + "@fastify/busboy" "^2.0.0" + +universal-github-app-jwt@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/universal-github-app-jwt/-/universal-github-app-jwt-2.2.0.tgz#dc6c8929e76f1996a766ba2a08fb420f73365d77" + integrity sha512-G5o6f95b5BggDGuUfKDApKaCgNYy2x7OdHY0zSMF081O0EJobw+1130VONhrA7ezGSV2FNOGyM+KQpQZAr9bIQ== + +universal-user-agent@^7.0.0, universal-user-agent@^7.0.2: + version "7.0.2" + resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-7.0.2.tgz#52e7d0e9b3dc4df06cc33cb2b9fd79041a54827e" + integrity sha512-0JCqzSKnStlRRQfCdowvqy3cy0Dvtlb8xecj/H8JFZuCze4rwjPZQOgvFvn0Ws/usCHQFGpyr+pB9adaGwXn4Q== + +uuid@^8.3.2: + version "8.3.2" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" + integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== From 7d64d6c7af16f48feea65b7c263c1b2a7545a9db Mon Sep 17 00:00:00 2001 From: Jack Baldry Date: Tue, 1 Oct 2024 11:36:27 +0100 Subject: [PATCH 2/3] Use sparse checkout Signed-off-by: Jack Baldry --- publish-technical-documentation/action.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/publish-technical-documentation/action.yml b/publish-technical-documentation/action.yml index 524177920..8850e1315 100644 --- a/publish-technical-documentation/action.yml +++ b/publish-technical-documentation/action.yml @@ -39,7 +39,10 @@ runs: - uses: actions/checkout@v4 with: + path: website repository: grafana/website + sparse-checkout: | + content/docs token: ${{ steps.app-token.outputs.token }} - name: Sync to the website repository From 5c5bbc78fceff85636566bf8ec7461f893ed6eee Mon Sep 17 00:00:00 2001 From: Jack Baldry Date: Tue, 1 Oct 2024 12:17:14 +0100 Subject: [PATCH 3/3] Pass through GitHub context Signed-off-by: Jack Baldry --- publish-technical-documentation/action.mts | 18 +-- .../dist/action.mjs | 13 +- .../dist/lib/publish.mjs | 12 +- .../dist/local.mjs | 36 ++++-- .../lib/publish.mts | 35 ++++-- publish-technical-documentation/local.mts | 51 +++++--- publish-technical-documentation/package.json | 1 + publish-technical-documentation/yarn.lock | 119 +++++++++++++++++- 8 files changed, 230 insertions(+), 55 deletions(-) diff --git a/publish-technical-documentation/action.mts b/publish-technical-documentation/action.mts index 7f086827e..fb7250279 100644 --- a/publish-technical-documentation/action.mts +++ b/publish-technical-documentation/action.mts @@ -1,4 +1,5 @@ import core from "@actions/core"; +import github from "@actions/github"; import { Octokit } from "octokit"; import { publish } from "./lib/publish.mjs"; @@ -9,16 +10,19 @@ const websiteDirectory = core.getInput("website-directory"); const token = core.getInput("token"); const octokit = new Octokit({ auth: token }); -const sourceRepository = "."; -const websiteRepository = "website"; - export async function main() { publish( octokit, - sourceRepository, - sourceDirectory, - websiteRepository, - websiteDirectory + { + name: github.context.repo.repo, + branch: github.context.ref, + repositoryPath: ".", + subdirectoryPath: sourceDirectory, + }, + { + repositoryPath: "website", + subdirectoryPath: websiteDirectory, + } ).catch((error) => { console.error(error); core.setFailed(error.message); diff --git a/publish-technical-documentation/dist/action.mjs b/publish-technical-documentation/dist/action.mjs index c62b07f07..b347bada8 100644 --- a/publish-technical-documentation/dist/action.mjs +++ b/publish-technical-documentation/dist/action.mjs @@ -1,14 +1,21 @@ import core from "@actions/core"; +import github from "@actions/github"; import { Octokit } from "octokit"; import { publish } from "./lib/publish.mjs"; const sourceDirectory = core.getInput("source-directory"); const websiteDirectory = core.getInput("website-directory"); const token = core.getInput("token"); const octokit = new Octokit({ auth: token }); -const sourceRepository = "."; -const websiteRepository = "website"; export async function main() { - publish(octokit, sourceRepository, sourceDirectory, websiteRepository, websiteDirectory).catch((error) => { + publish(octokit, { + name: github.context.repo.repo, + branch: github.context.ref, + repositoryPath: ".", + subdirectoryPath: sourceDirectory, + }, { + repositoryPath: "website", + subdirectoryPath: websiteDirectory, + }).catch((error) => { console.error(error); core.setFailed(error.message); }); diff --git a/publish-technical-documentation/dist/lib/publish.mjs b/publish-technical-documentation/dist/lib/publish.mjs index e768e53f7..0a755d0bb 100644 --- a/publish-technical-documentation/dist/lib/publish.mjs +++ b/publish-technical-documentation/dist/lib/publish.mjs @@ -106,9 +106,9 @@ async function baseTreeSha(octokit, repo, branch) { tree_sha: `heads/${branch}`, })).data.sha; } -export async function publish(octokit, sourceRepository, sourceDirectory, websiteRepository, websiteDirectory) { - rsync(path.join(sourceRepository, sourceDirectory) + "/", path.join(websiteRepository, websiteDirectory)); - const files = await getUnstagedFiles(websiteRepository, websiteDirectory); +export async function publish(octokit, source, website) { + rsync(path.join(source.repositoryPath, source.subdirectoryPath) + "/", path.join(website.repositoryPath, website.subdirectoryPath)); + const files = await getUnstagedFiles(website.repositoryPath, website.subdirectoryPath); const baseTree = await baseTreeSha(octokit, "website", "master"); const newTree = (await octokit.rest.git.createTree({ owner: "grafana", @@ -124,7 +124,7 @@ export async function publish(octokit, sourceRepository, sourceDirectory, websit }; } else { - const fileInfo = fs.statSync(path.join(websiteRepository, file.path)); + const fileInfo = fs.statSync(path.join(website.repositoryPath, file.path)); if (fileInfo.isDirectory()) { return { mode: "040000", @@ -135,7 +135,7 @@ export async function publish(octokit, sourceRepository, sourceDirectory, websit } return { content: fs - .readFileSync(path.join(websiteRepository, file.path)) + .readFileSync(path.join(website.repositoryPath, file.path)) .toString(), mode: "100644", path: file.path, @@ -147,7 +147,7 @@ export async function publish(octokit, sourceRepository, sourceDirectory, websit const commit = (await octokit.rest.git.createCommit({ owner: "grafana", repo: "website", - message: `Publish from grafana/writers-toolkit:main/${sourceDirectory}\n` + + message: `Publish from grafana/${source.name}:${source.branch}/${source.subdirectoryPath}\n` + "\n" + "Co-authored-by: Jack Baldry ", tree: newTree, diff --git a/publish-technical-documentation/dist/local.mjs b/publish-technical-documentation/dist/local.mjs index 7fcce3e01..6d7173882 100644 --- a/publish-technical-documentation/dist/local.mjs +++ b/publish-technical-documentation/dist/local.mjs @@ -7,20 +7,34 @@ try { throw new Error("Environment variable GITHUB_TOKEN is required"); } const octokit = new Octokit({ auth: token }); - const sourceRepository = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY; - if (!sourceRepository) { - throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY is required"); + const sourceName = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_NAME; + if (!sourceName) { + throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_NAME is required"); } - const sourceDirectory = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_DIRECTORY || "docs/sources"; - const websiteRepository = env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY; - if (!websiteRepository) { - throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY is required"); + const sourceBranch = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_BRANCH || "main"; + const sourceRepositoryPath = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY_PATH; + if (!sourceRepositoryPath) { + throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY_PATH is required"); } - const websiteDirectory = env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY; - if (!websiteDirectory) { - throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY is required"); + const sourceSubdirectoryPath = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_SUBDIRECTORY_PATH || + "docs/sources"; + const websiteRepositoryPath = env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY; + if (!websiteRepositoryPath) { + throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY_PATH is required"); } - const sha = await publish(octokit, sourceRepository, sourceDirectory, websiteRepository, websiteDirectory); + const websiteSubdirectoryPath = env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_SUBDIRECTORY_PATH; + if (!websiteSubdirectoryPath) { + throw new Error("Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_SUBDIRECTORY_PATH is required"); + } + const sha = await publish(octokit, { + name: sourceName, + branch: sourceBranch, + repositoryPath: sourceRepositoryPath, + subdirectoryPath: sourceSubdirectoryPath, + }, { + repositoryPath: websiteRepositoryPath, + subdirectoryPath: websiteSubdirectoryPath, + }); console.log(sha); } catch (error) { diff --git a/publish-technical-documentation/lib/publish.mts b/publish-technical-documentation/lib/publish.mts index 6adc558b8..680fdbda7 100644 --- a/publish-technical-documentation/lib/publish.mts +++ b/publish-technical-documentation/lib/publish.mts @@ -139,18 +139,31 @@ async function baseTreeSha( ).data.sha; } +type sourceContext = { + name: string; + branch: string; + repositoryPath: string; + subdirectoryPath: string; +}; + +type websiteContext = { + repositoryPath: string; + subdirectoryPath: string; +}; + export async function publish( octokit: Octokit, - sourceRepository: string, - sourceDirectory: string, - websiteRepository: string, - websiteDirectory: string + source: sourceContext, + website: websiteContext ): Promise { rsync( - path.join(sourceRepository, sourceDirectory) + "/", - path.join(websiteRepository, websiteDirectory) + path.join(source.repositoryPath, source.subdirectoryPath) + "/", + path.join(website.repositoryPath, website.subdirectoryPath) + ); + const files = await getUnstagedFiles( + website.repositoryPath, + website.subdirectoryPath ); - const files = await getUnstagedFiles(websiteRepository, websiteDirectory); const baseTree = await baseTreeSha(octokit, "website", "master"); const newTree = ( @@ -167,7 +180,9 @@ export async function publish( type: "blob", }; } else { - const fileInfo = fs.statSync(path.join(websiteRepository, file.path)); + const fileInfo = fs.statSync( + path.join(website.repositoryPath, file.path) + ); if (fileInfo.isDirectory()) { return { mode: "040000", @@ -178,7 +193,7 @@ export async function publish( } return { content: fs - .readFileSync(path.join(websiteRepository, file.path)) + .readFileSync(path.join(website.repositoryPath, file.path)) .toString(), mode: "100644", path: file.path, @@ -194,7 +209,7 @@ export async function publish( owner: "grafana", repo: "website", message: - `Publish from grafana/writers-toolkit:main/${sourceDirectory}\n` + + `Publish from grafana/${source.name}:${source.branch}/${source.subdirectoryPath}\n` + "\n" + "Co-authored-by: Jack Baldry ", tree: newTree, diff --git a/publish-technical-documentation/local.mts b/publish-technical-documentation/local.mts index 1cfa4494a..9c79a71ff 100644 --- a/publish-technical-documentation/local.mts +++ b/publish-technical-documentation/local.mts @@ -11,38 +11,55 @@ try { const octokit = new Octokit({ auth: token }); - const sourceRepository = - env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY; - if (!sourceRepository) { + const sourceName = env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_NAME; + if (!sourceName) { throw new Error( - "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY is required" + "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_NAME is required" ); } - const sourceDirectory = - env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_DIRECTORY || "docs/sources"; + const sourceBranch = + env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_BRANCH || "main"; - const websiteRepository = + const sourceRepositoryPath = + env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY_PATH; + if (!sourceRepositoryPath) { + throw new Error( + "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_REPOSITORY_PATH is required" + ); + } + + const sourceSubdirectoryPath = + env.PUBLISH_TECHNICAL_DOCUMENTATION_SOURCE_SUBDIRECTORY_PATH || + "docs/sources"; + + const websiteRepositoryPath = env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY; - if (!websiteRepository) { + if (!websiteRepositoryPath) { throw new Error( - "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY is required" + "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_REPOSITORY_PATH is required" ); } - const websiteDirectory = - env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY; - if (!websiteDirectory) { + const websiteSubdirectoryPath = + env.PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_SUBDIRECTORY_PATH; + if (!websiteSubdirectoryPath) { throw new Error( - "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_DIRECTORY is required" + "Environment variable PUBLISH_TECHNICAL_DOCUMENTATION_WEBSITE_SUBDIRECTORY_PATH is required" ); } const sha = await publish( octokit, - sourceRepository, - sourceDirectory, - websiteRepository, - websiteDirectory + { + name: sourceName, + branch: sourceBranch, + repositoryPath: sourceRepositoryPath, + subdirectoryPath: sourceSubdirectoryPath, + }, + { + repositoryPath: websiteRepositoryPath, + subdirectoryPath: websiteSubdirectoryPath, + } ); console.log(sha); diff --git a/publish-technical-documentation/package.json b/publish-technical-documentation/package.json index 3ba29260e..408c86d98 100644 --- a/publish-technical-documentation/package.json +++ b/publish-technical-documentation/package.json @@ -12,6 +12,7 @@ }, "dependencies": { "@actions/core": "^1.10.1", + "@actions/github": "^6.0.0", "octokit": "^4.0.2" }, "scripts": { diff --git a/publish-technical-documentation/yarn.lock b/publish-technical-documentation/yarn.lock index f3b797ac7..d1d508860 100644 --- a/publish-technical-documentation/yarn.lock +++ b/publish-technical-documentation/yarn.lock @@ -10,7 +10,17 @@ "@actions/http-client" "^2.0.1" uuid "^8.3.2" -"@actions/http-client@^2.0.1": +"@actions/github@^6.0.0": + version "6.0.0" + resolved "https://registry.yarnpkg.com/@actions/github/-/github-6.0.0.tgz#65883433f9d81521b782a64cc1fd45eef2191ea7" + integrity sha512-alScpSVnYmjNEXboZjarjukQEzgCRmjMv6Xj47fsdnqGS73bjJNDpiiXmp8jr0UZLdUB6d9jW63IcmddUP+l0g== + dependencies: + "@actions/http-client" "^2.2.0" + "@octokit/core" "^5.0.1" + "@octokit/plugin-paginate-rest" "^9.0.0" + "@octokit/plugin-rest-endpoint-methods" "^10.0.0" + +"@actions/http-client@^2.0.1", "@actions/http-client@^2.2.0": version "2.2.3" resolved "https://registry.yarnpkg.com/@actions/http-client/-/http-client-2.2.3.tgz#31fc0b25c0e665754ed39a9f19a8611fc6dab674" integrity sha512-mx8hyJi/hjFvbPokCg4uRd4ZX78t+YyRPtnKWwIl+RzNaVuFpQHfmlGVfsKEJN8LwTCvL+DfVgAM04XaHkm6bA== @@ -82,6 +92,11 @@ "@octokit/types" "^13.0.0" universal-user-agent "^7.0.0" +"@octokit/auth-token@^4.0.0": + version "4.0.0" + resolved "https://registry.yarnpkg.com/@octokit/auth-token/-/auth-token-4.0.0.tgz#40d203ea827b9f17f42a29c6afb93b7745ef80c7" + integrity sha512-tY/msAuJo6ARbK6SPIxZrPBms3xPbfwBrulZe0Wtr/DIY9lje2HeV1uoebShn6mx7SjCHif6EjMvoREj+gZ+SA== + "@octokit/auth-token@^5.0.0": version "5.1.1" resolved "https://registry.yarnpkg.com/@octokit/auth-token/-/auth-token-5.1.1.tgz#3bbfe905111332a17f72d80bd0b51a3e2fa2cf07" @@ -95,6 +110,19 @@ "@octokit/request-error" "^6.0.1" "@octokit/types" "^13.0.0" +"@octokit/core@^5.0.1": + version "5.2.0" + resolved "https://registry.yarnpkg.com/@octokit/core/-/core-5.2.0.tgz#ddbeaefc6b44a39834e1bb2e58a49a117672a7ea" + integrity sha512-1LFfa/qnMQvEOAdzlQymH0ulepxbxnCYAKJZfMci/5XJyIHWgEYnDmgnKakbTh7CH2tFQ5O60oYDvns4i9RAIg== + dependencies: + "@octokit/auth-token" "^4.0.0" + "@octokit/graphql" "^7.1.0" + "@octokit/request" "^8.3.1" + "@octokit/request-error" "^5.1.0" + "@octokit/types" "^13.0.0" + before-after-hook "^2.2.0" + universal-user-agent "^6.0.0" + "@octokit/core@^6.0.0", "@octokit/core@^6.1.2": version "6.1.2" resolved "https://registry.yarnpkg.com/@octokit/core/-/core-6.1.2.tgz#20442d0a97c411612da206411e356014d1d1bd17" @@ -116,6 +144,23 @@ "@octokit/types" "^13.0.0" universal-user-agent "^7.0.2" +"@octokit/endpoint@^9.0.1": + version "9.0.5" + resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-9.0.5.tgz#e6c0ee684e307614c02fc6ac12274c50da465c44" + integrity sha512-ekqR4/+PCLkEBF6qgj8WqJfvDq65RH85OAgrtnVp1mSxaXF03u2xW/hUdweGS5654IlC0wkNYC18Z50tSYTAFw== + dependencies: + "@octokit/types" "^13.1.0" + universal-user-agent "^6.0.0" + +"@octokit/graphql@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@octokit/graphql/-/graphql-7.1.0.tgz#9bc1c5de92f026648131f04101cab949eeffe4e0" + integrity sha512-r+oZUH7aMFui1ypZnAvZmn0KSqAUgE1/tUXIWaqUCa1758ts/Jio84GZuzsvUkme98kv0WFY8//n0J1Z+vsIsQ== + dependencies: + "@octokit/request" "^8.3.0" + "@octokit/types" "^13.0.0" + universal-user-agent "^6.0.0" + "@octokit/graphql@^8.0.0": version "8.1.1" resolved "https://registry.yarnpkg.com/@octokit/graphql/-/graphql-8.1.1.tgz#3cacab5f2e55d91c733e3bf481d3a3f8a5f639c4" @@ -154,6 +199,11 @@ "@octokit/request-error" "^6.1.0" "@octokit/types" "^13.0.0" +"@octokit/openapi-types@^20.0.0": + version "20.0.0" + resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-20.0.0.tgz#9ec2daa0090eeb865ee147636e0c00f73790c6e5" + integrity sha512-EtqRBEjp1dL/15V7WiX5LJMIxxkdiGJnabzYx5Apx4FkQIFgAfKumXeYAqqJCj1s+BMX4cPFIFC4OLCR6stlnA== + "@octokit/openapi-types@^22.2.0": version "22.2.0" resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-22.2.0.tgz#75aa7dcd440821d99def6a60b5f014207ae4968e" @@ -176,6 +226,20 @@ dependencies: "@octokit/types" "^13.5.0" +"@octokit/plugin-paginate-rest@^9.0.0": + version "9.2.1" + resolved "https://registry.yarnpkg.com/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-9.2.1.tgz#2e2a2f0f52c9a4b1da1a3aa17dabe3c459b9e401" + integrity sha512-wfGhE/TAkXZRLjksFXuDZdmGnJQHvtU/joFQdweXUgzo1XwvBCD4o4+75NtFfjfLK5IwLf9vHTfSiU3sLRYpRw== + dependencies: + "@octokit/types" "^12.6.0" + +"@octokit/plugin-rest-endpoint-methods@^10.0.0": + version "10.4.1" + resolved "https://registry.yarnpkg.com/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-10.4.1.tgz#41ba478a558b9f554793075b2e20cd2ef973be17" + integrity sha512-xV1b+ceKV9KytQe3zCVqjg+8GTGfDYwaT1ATU5isiUyVtlVAO3HNdzpS4sr4GBx4hxQ46s7ITtZrAsxG22+rVg== + dependencies: + "@octokit/types" "^12.6.0" + "@octokit/plugin-rest-endpoint-methods@^13.0.0": version "13.2.4" resolved "https://registry.yarnpkg.com/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-13.2.4.tgz#543add032d3fe3f5d2839bfd619cf66d85469f01" @@ -200,6 +264,15 @@ "@octokit/types" "^13.0.0" bottleneck "^2.15.3" +"@octokit/request-error@^5.1.0": + version "5.1.0" + resolved "https://registry.yarnpkg.com/@octokit/request-error/-/request-error-5.1.0.tgz#ee4138538d08c81a60be3f320cd71063064a3b30" + integrity sha512-GETXfE05J0+7H2STzekpKObFe765O5dlAKUTLNGeH+x47z7JjXHfsHKo5z21D/o/IOZTUEI6nyWyR+bZVP/n5Q== + dependencies: + "@octokit/types" "^13.1.0" + deprecation "^2.0.0" + once "^1.4.0" + "@octokit/request-error@^6.0.0", "@octokit/request-error@^6.0.1", "@octokit/request-error@^6.1.0", "@octokit/request-error@^6.1.1": version "6.1.4" resolved "https://registry.yarnpkg.com/@octokit/request-error/-/request-error-6.1.4.tgz#ad96e29148d19edc2ba8009fc2b5a24a36c90f16" @@ -207,6 +280,16 @@ dependencies: "@octokit/types" "^13.0.0" +"@octokit/request@^8.3.0", "@octokit/request@^8.3.1": + version "8.4.0" + resolved "https://registry.yarnpkg.com/@octokit/request/-/request-8.4.0.tgz#7f4b7b1daa3d1f48c0977ad8fffa2c18adef8974" + integrity sha512-9Bb014e+m2TgBeEJGEbdplMVWwPmL1FPtggHQRkV+WVsMggPtEkLKPlcVYm/o8xKLkpJ7B+6N8WfQMtDLX2Dpw== + dependencies: + "@octokit/endpoint" "^9.0.1" + "@octokit/request-error" "^5.1.0" + "@octokit/types" "^13.1.0" + universal-user-agent "^6.0.0" + "@octokit/request@^9.0.0", "@octokit/request@^9.0.1", "@octokit/request@^9.1.0", "@octokit/request@^9.1.1": version "9.1.3" resolved "https://registry.yarnpkg.com/@octokit/request/-/request-9.1.3.tgz#42b693bc06238f43af3c037ebfd35621c6457838" @@ -217,6 +300,13 @@ "@octokit/types" "^13.1.0" universal-user-agent "^7.0.2" +"@octokit/types@^12.6.0": + version "12.6.0" + resolved "https://registry.yarnpkg.com/@octokit/types/-/types-12.6.0.tgz#8100fb9eeedfe083aae66473bd97b15b62aedcb2" + integrity sha512-1rhSOfRa6H9w4YwK0yrf5faDaDTb+yLyBUKOCV4xtCDB5VmIPqd/v9yr9o6SAzOAlRxMiRiCic6JVM1/kunVkw== + dependencies: + "@octokit/openapi-types" "^20.0.0" + "@octokit/types@^13.0.0", "@octokit/types@^13.1.0", "@octokit/types@^13.4.1", "@octokit/types@^13.5.0": version "13.5.0" resolved "https://registry.yarnpkg.com/@octokit/types/-/types-13.5.0.tgz#4796e56b7b267ebc7c921dcec262b3d5bfb18883" @@ -250,6 +340,11 @@ dependencies: undici-types "~6.19.2" +before-after-hook@^2.2.0: + version "2.2.3" + resolved "https://registry.yarnpkg.com/before-after-hook/-/before-after-hook-2.2.3.tgz#c51e809c81a4e354084422b9b26bad88249c517c" + integrity sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ== + before-after-hook@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/before-after-hook/-/before-after-hook-3.0.2.tgz#d5665a5fa8b62294a5aa0a499f933f4a1016195d" @@ -260,6 +355,11 @@ bottleneck@^2.15.3: resolved "https://registry.yarnpkg.com/bottleneck/-/bottleneck-2.19.5.tgz#5df0b90f59fd47656ebe63c78a98419205cadd91" integrity sha512-VHiNCbI1lKdl44tGrhNfU3lup0Tj/ZBMJB5/2ZbNXRCPuRCO7ed2mgcK4r17y+KB2EfuYuRaVlwNbAeaWGSpbw== +deprecation@^2.0.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/deprecation/-/deprecation-2.3.1.tgz#6368cbdb40abf3373b525ac87e4a260c3a700919" + integrity sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ== + lru-cache@^10.0.0: version "10.4.3" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.4.3.tgz#410fc8a17b70e598013df257c2446b7f3383f119" @@ -281,6 +381,13 @@ octokit@^4.0.2: "@octokit/request-error" "^6.0.0" "@octokit/types" "^13.0.0" +once@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== + dependencies: + wrappy "1" + tunnel@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/tunnel/-/tunnel-0.0.6.tgz#72f1314b34a5b192db012324df2cc587ca47f92c" @@ -303,6 +410,11 @@ universal-github-app-jwt@^2.2.0: resolved "https://registry.yarnpkg.com/universal-github-app-jwt/-/universal-github-app-jwt-2.2.0.tgz#dc6c8929e76f1996a766ba2a08fb420f73365d77" integrity sha512-G5o6f95b5BggDGuUfKDApKaCgNYy2x7OdHY0zSMF081O0EJobw+1130VONhrA7ezGSV2FNOGyM+KQpQZAr9bIQ== +universal-user-agent@^6.0.0: + version "6.0.1" + resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-6.0.1.tgz#15f20f55da3c930c57bddbf1734c6654d5fd35aa" + integrity sha512-yCzhz6FN2wU1NiiQRogkTQszlQSlpWaw8SvVegAc+bDxbzHgh1vX8uIe8OYyMH6DwH+sdTJsgMl36+mSMdRJIQ== + universal-user-agent@^7.0.0, universal-user-agent@^7.0.2: version "7.0.2" resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-7.0.2.tgz#52e7d0e9b3dc4df06cc33cb2b9fd79041a54827e" @@ -312,3 +424,8 @@ uuid@^8.3.2: version "8.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== + +wrappy@1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" + integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==