comfy-pr 1.3.0 → 1.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "comfy-pr",
3
- "version": "1.3.0",
3
+ "version": "1.4.1",
4
4
  "description": "Make PRs that publishes ComfyUI Custom Nodes to [ComfyUI Registry]( https://registry.comfy.org/ ).",
5
5
  "keywords": [],
6
6
  "license": "ISC",
@@ -97,14 +97,13 @@
97
97
  "clsx": "^2.1.1",
98
98
  "comparing": "^1.3.1",
99
99
  "concurrent-lock": "^1.0.7",
100
- "d3": "^7.9.0",
100
+ "d3-dsv": "^3.0.1",
101
101
  "daisyui": "^4.12.10",
102
102
  "date-fns": "^4.1.0",
103
103
  "defer-close": "^1.1.0",
104
104
  "dotenv": "^16.4.5",
105
105
  "enhanced-ms": "^3.0.0",
106
106
  "execa": "^9.6.1",
107
- "faker": "^6.6.6",
108
107
  "fast-diff": "^1.3.0",
109
108
  "file-saver": "^2.0.5",
110
109
  "flat": "^6.0.1",
@@ -149,7 +148,6 @@
149
148
  "peek-log": "^0.0.8",
150
149
  "polyfill-text-decoder-stream": "^0.0.9",
151
150
  "polyfill-text-encoder-stream": "^0.0.8",
152
- "prettier": "^3.7.4",
153
151
  "pretty-ms": "^9.1.0",
154
152
  "promise-all-properties": "^4.0.4",
155
153
  "rambda": "^9.2.1",
@@ -184,8 +182,7 @@
184
182
  "winston": "^3.17.0",
185
183
  "yaml": "^2.5.0",
186
184
  "zod": "^4.3.2",
187
- "zod-deep-partial": "^1.0.0",
188
- "zx": "^8.5.3"
185
+ "zod-deep-partial": "^1.0.0"
189
186
  },
190
187
  "devDependencies": {
191
188
  "@jest/globals": "^30.1.2",
@@ -198,7 +195,7 @@
198
195
  "@semantic-release/npm": "^13.1.5",
199
196
  "@semantic-release/release-notes-generator": "^14.1.0",
200
197
  "@types/bun": "^1.1.6",
201
- "@types/d3": "^7.4.3",
198
+ "@types/d3-dsv": "^3.0.7",
202
199
  "@types/file-saver": "^2.0.7",
203
200
  "@types/git-diff": "^2.0.7",
204
201
  "@types/jest": "^29.5.12",
@@ -216,6 +213,7 @@
216
213
  "@types/url-regex-safe": "^1.0.2",
217
214
  "@typescript/native-preview": "^7.0.0-dev.20260113.1",
218
215
  "and": "^0.0.3",
216
+ "faker": "^6.6.6",
219
217
  "husky": "^9.1.7",
220
218
  "lint-staged": "^16.1.2",
221
219
  "msw": "^2.11.6",
@@ -223,6 +221,7 @@
223
221
  "oxfmt": "^0.24.0",
224
222
  "oxlint": "^1.41.0",
225
223
  "postcss": "^8.4.40",
224
+ "prettier": "^3.7.4",
226
225
  "prettier-plugin-organize-imports": "^3.2.4",
227
226
  "prettier-plugin-packagejson": "^2.5.1",
228
227
  "push": "^0.1.1",
package/src/Authors.ts CHANGED
@@ -33,9 +33,10 @@ export type Author = {
33
33
  export const Authors = db.collection<Author>("Authors");
34
34
  export const GithubUsers = db.collection<{ username: string } & GHUser>("GithubUsers");
35
35
 
36
+ await Authors.createIndex({ githubId: 1 }, { background: true });
37
+ await Authors.createIndex({ email: 1 }, { background: true });
38
+
36
39
  if (import.meta.main) {
37
- await Authors.createIndex("githubId");
38
- await Authors.createIndex("email");
39
40
  // collect github id from cn repos
40
41
  await updateAuthors();
41
42
  console.log("done");
@@ -1,6 +1,5 @@
1
1
  import DIE from "@snomiao/die";
2
2
  import { $ as bunSh } from "bun";
3
- import { os } from "zx";
4
3
  import { getActivateCMD } from "./cli/getActivateCMD";
5
4
 
6
5
  export async function checkComfyActivated() {
@@ -10,21 +9,16 @@ export async function checkComfyActivated() {
10
9
  const activate = getActivateCMD();
11
10
  // apt-get install -y python3 python3-venv
12
11
  const installPython =
13
- os.platform() === "win32"
12
+ process.platform === "win32"
14
13
  ? "python3 --version || winget install python3 || choco install -y python3"
15
14
  : "apt-get install -y python3 python3-venv";
16
15
 
17
- await bunSh`
18
- ${installPython}
19
- python -m venv .venv
20
- ${activate}
21
- pip install comfy-cli
22
- comfy-cli --help
23
- `.catch(console.error);
16
+ const setupScript = `${installPython} && python -m venv .venv && ${activate} && pip install comfy-cli && comfy-cli --help`;
17
+ await bunSh`/bin/sh -c ${setupScript}`.catch(console.error);
24
18
 
25
19
  DIE(
26
20
  `
27
- Cound not found comfy-cli.
21
+ Could not find comfy-cli.
28
22
  Please install comfy-cli before run "bunx comfy-pr" here.
29
23
 
30
24
  $ >>>>>>>>>>>>>>>>>>>>>>>>>>
@@ -1,18 +1,13 @@
1
- import { $ as zx } from "zx";
1
+ import { execaCommand } from "execa";
2
2
  import { getActivateCMD } from "./cli/getActivateCMD";
3
3
 
4
4
  if (import.meta.main) {
5
- // await checkComfyActivated();
6
- zx.verbose = true;
7
5
  const $ = getActivatedShell();
8
- const p = await $`comfy-cli --version`;
6
+ const p = await $("comfy-cli --version");
9
7
  console.log(p.stdout);
10
- // zx({ prefix: })`comfy-cli --help`;
11
8
  }
12
9
 
13
10
  export function getActivatedShell() {
14
11
  const activate = getActivateCMD();
15
- return zx({
16
- prefix: `echo Comfy CLI version: $(comfy-cli --version) || (apt-get install -y python3-venv && python -m venv .venv && ${activate} && pip install comfy-cli); `,
17
- });
12
+ return (cmd: string) => execaCommand(`${activate} && ${cmd}`, { shell: true });
18
13
  }
@@ -6,7 +6,7 @@ import stableStringify from "json-stable-stringify";
6
6
  import pMap from "p-map";
7
7
  import sflow from "sflow";
8
8
  import { match } from "ts-pattern";
9
- import { glob } from "zx";
9
+ import { globby as glob } from "globby";
10
10
  import { $OK, TaskError, TaskOK, tsmatch } from "../packages/mongodb-pipeline-ts/Task";
11
11
  import { CNRepos, type CRPull } from "./CNRepos";
12
12
  import { $flatten, $stale } from "./db";