@devframes/plugin-git 0.9.0-beta.9 → 0.9.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/dist/cli.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { t as createGitDevframe } from "./src-C_EoR2YQ.mjs";
1
+ import { t as createGitDevframe } from "./src-CyRmAQrb.mjs";
2
2
  import process from "node:process";
3
3
  import { createCac } from "devframe/adapters/cac";
4
4
  //#region src/cli.ts
package/dist/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import { t as createGitDevframe } from "./src-C_EoR2YQ.mjs";
1
+ import { t as createGitDevframe } from "./src-CyRmAQrb.mjs";
2
2
  export { createGitDevframe, createGitDevframe as default };
@@ -6,13 +6,13 @@ import { promisify } from "node:util";
6
6
  import { s } from "devframe/utils/simple-schema";
7
7
  //#region package.json
8
8
  var name = "@devframes/plugin-git";
9
- var version = "0.9.0-beta.9";
9
+ var version = "0.9.1";
10
10
  var description = "Devframe plugin that shows a Git dashboard for status, log, branches, and diffs.";
11
11
  var homepage = "https://github.com/devframes/devframe#readme";
12
12
  //#endregion
13
13
  //#region src/node/git.ts
14
14
  const execFileAsync = promisify(execFile);
15
- const MAX_BUFFER = 1024 * 1024 * 64;
15
+ const MAX_BUFFER = 67108864;
16
16
  /**
17
17
  * Run a git command in `cwd`. Rejects when git exits non-zero — callers that
18
18
  * tolerate failure (e.g. "no upstream configured") should use {@link tryGit}.
@@ -225,11 +225,12 @@ function parseStatus(root, raw) {
225
225
  if (token.startsWith("# ")) {
226
226
  const [, key, ...rest] = token.split(" ");
227
227
  const value = rest.join(" ");
228
- if (key === "branch.head") if (value === "(detached)") {
229
- status.detached = true;
230
- status.branch = null;
231
- } else status.branch = value;
232
- else if (key === "branch.oid" && value !== "(initial)") status.head = value.slice(0, 9);
228
+ if (key === "branch.head") {
229
+ if (value === "(detached)") {
230
+ status.detached = true;
231
+ status.branch = null;
232
+ } else status.branch = value;
233
+ } else if (key === "branch.oid" && value !== "(initial)") status.head = value.slice(0, 9);
233
234
  else if (key === "branch.upstream") status.upstream = value;
234
235
  else if (key === "branch.ab") {
235
236
  const match = value.match(/\+(\d+)\s+-(\d+)/);
@@ -744,10 +745,12 @@ async function readCommit(git, hash, includePatch) {
744
745
  "--end-of-options",
745
746
  hash
746
747
  ]);
747
- if (raw != null) if (raw.length > PATCH_CHAR_LIMIT) {
748
- patch = raw.slice(0, PATCH_CHAR_LIMIT);
749
- truncated = true;
750
- } else patch = raw;
748
+ if (raw != null) {
749
+ if (raw.length > PATCH_CHAR_LIMIT) {
750
+ patch = raw.slice(0, PATCH_CHAR_LIMIT);
751
+ truncated = true;
752
+ } else patch = raw;
753
+ }
751
754
  }
752
755
  return {
753
756
  isRepo: true,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@devframes/plugin-git",
3
3
  "type": "module",
4
- "version": "0.9.0-beta.9",
4
+ "version": "0.9.1",
5
5
  "description": "Devframe plugin that shows a Git dashboard for status, log, branches, and diffs.",
6
6
  "author": "Anthony Fu <anthonyfu117@hotmail.com>",
7
7
  "license": "MIT",
@@ -33,7 +33,7 @@
33
33
  "dist"
34
34
  ],
35
35
  "peerDependencies": {
36
- "@devframes/plugin-git--assets": "0.9.0-beta.9"
36
+ "@devframes/plugin-git--assets": "0.9.1"
37
37
  },
38
38
  "peerDependenciesMeta": {
39
39
  "@devframes/plugin-git--assets": {
@@ -43,7 +43,7 @@
43
43
  "dependencies": {
44
44
  "cac": "^7.0.0",
45
45
  "pathe": "^2.0.3",
46
- "devframe": "0.9.0-beta.9"
46
+ "devframe": "0.9.1"
47
47
  },
48
48
  "devDependencies": {
49
49
  "@antfu/design": "^0.3.4",
@@ -61,7 +61,6 @@
61
61
  "@vitejs/plugin-react-oxc": "^0.4.3",
62
62
  "clsx": "^2.1.1",
63
63
  "colorjs.io": "^0.7.1",
64
- "get-port-please": "^3.2.0",
65
64
  "h3": "^2.0.1-rc.26",
66
65
  "next": "^16.3.0",
67
66
  "react": "^19.2.8",
@@ -72,7 +71,7 @@
72
71
  "unocss": "^66.7.5",
73
72
  "vitest": "^4.1.10",
74
73
  "ws": "^8.21.3",
75
- "@devframes/plugin-git--assets": "0.9.0-beta.9"
74
+ "@devframes/plugin-git--assets": "0.9.1"
76
75
  },
77
76
  "scripts": {
78
77
  "build": "tsdown && pnpm run build:spa",