Skip to content

🎥 Make videos programmatically with React

Deprecate buggy versions of `remotion` on npm

Jonny Burgerfcda8a6a5bc8
diff --git a/packages/bugs/api/[v].ts b/packages/bugs/api/[v].ts
index ac118b5cc0..f2f1b7809e 100644
--- a/packages/bugs/api/[v].ts
+++ b/packages/bugs/api/[v].ts
@@ -6,7 +6,7 @@ type Bug = {
versions: string[];
};
-const bugs: Bug[] = [
+export const bugs: Bug[] = [
{
title: "Slowdown with <TransitionSeries>",
description:
diff --git a/packages/bugs/deprecate-versions.ts b/packages/bugs/deprecate-versions.ts
new file mode 100644
index 0000000000..b4451b527a
--- /dev/null
+++ b/packages/bugs/deprecate-versions.ts
@@ -0,0 +1,16 @@
+import { bugs } from "./api/[v]";
+import { $ } from "bun";
+
+const buggyRelease: string[] = [];
+
+for (const bug of bugs) {
+ buggyRelease.push(...bug.versions);
+}
+
+const uniqueVersions = [...new Set(buggyRelease)];
+console.log(uniqueVersions);
+
+for (const version of uniqueVersions) {
+ await $`npm deprecate remotion@${version} "This version contains bugs: https://bugs.remotion.dev/${version}"`;
+ console.log(`Deprecated version ${version}`);
+}