pi-cc-extensions 0.1.2 → 0.1.5

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.
@@ -140,6 +140,15 @@ async function fetchDiffStat(cwd: string): Promise<{ added: number; deleted: num
140
140
  return parseDiffStat(output);
141
141
  }
142
142
 
143
+ /**
144
+ * Fetch git status asynchronously.
145
+ */
146
+ async function fetchGitStatus(cwd: string): Promise<{ staged: number; unstaged: number; untracked: number } | null> {
147
+ const output = await runGit(["status", "--porcelain"], cwd, 500);
148
+ if (output === null) return null;
149
+ return parseGitStatusOutput(output);
150
+ }
151
+
143
152
  /**
144
153
  * Get the current git branch with caching.
145
154
  * Falls back to provider branch if our cache is empty.