Skip to content

chore(deps-dev): add missing @types/uuid #3237

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 25, 2022

Conversation

trivikr
Copy link
Member

@trivikr trivikr commented Jan 24, 2022

Issue

The missing @types/uuid was noticed while trying to bump yarn to berry in #3235

Description

Adds missing @types/uuid as devDependencies in impacted packages.

Script used
// @ts-check

import { readFileSync, writeFileSync } from "fs";
import { join } from "path";

import { getWorkspacePaths } from "./update-versions/getWorkspacePaths.mjs";

getWorkspacePaths().forEach((workspacePath) => {
  const packageJsonPath = join(workspacePath, "package.json");
  const packageJson = JSON.parse(readFileSync(packageJsonPath).toString());
  if (packageJson.dependencies && packageJson.dependencies["uuid"]) {
    if (packageJson.devDependencies && packageJson.devDependencies["@types/uuid"] === undefined) {
      packageJson.devDependencies["@types/uuid"] = "^8.3.0";
      packageJson.devDependencies = Object.fromEntries(Object.entries(packageJson.devDependencies).sort());
      writeFileSync(packageJsonPath, JSON.stringify(packageJson, null, 2).concat(`\n`));
    }
  }
});

Testing

N/A


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@trivikr trivikr requested a review from a team as a code owner January 24, 2022 20:39
@trivikr trivikr requested a review from AllanZhengYP January 25, 2022 01:32
@trivikr trivikr merged commit ad61024 into aws:main Jan 25, 2022
@trivikr trivikr deleted the add-missing-types-uuid branch January 25, 2022 02:05
@github-actions
Copy link

github-actions bot commented Feb 9, 2022

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants