@vibe-validate/git 0.17.6 → 0.18.0
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/branch-cleanup.d.ts +289 -0
- package/dist/branch-cleanup.d.ts.map +1 -0
- package/dist/branch-cleanup.js +592 -0
- package/dist/branch-cleanup.js.map +1 -0
- package/dist/branch-sync.d.ts.map +1 -1
- package/dist/branch-sync.js +15 -31
- package/dist/branch-sync.js.map +1 -1
- package/dist/gh-commands.d.ts +165 -0
- package/dist/gh-commands.d.ts.map +1 -0
- package/dist/gh-commands.js +179 -0
- package/dist/gh-commands.js.map +1 -0
- package/dist/git-commands.d.ts +27 -0
- package/dist/git-commands.d.ts.map +1 -1
- package/dist/git-commands.js +35 -0
- package/dist/git-commands.js.map +1 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -1
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/branch-sync.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"branch-sync.js","sourceRoot":"","sources":["../src/branch-sync.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"branch-sync.js","sourceRoot":"","sources":["../src/branch-sync.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAkBtD;;;;;;;;;GASG;AACH,SAAS,OAAO,CAAC,IAAc;IAC7B,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,iBAAiB,CAAC,IAAI,EAAE,EAAE,YAAY,EAAE,KAAK,EAAE,CAAC,CAAC;QAChE,OAAO,OAAO,CAAC,OAAO,CAAC;YACrB,MAAM,EAAE,MAAM,CAAC,MAAM;YACrB,MAAM,EAAE,MAAM,CAAC,MAAM;SACtB,CAAC,CAAC;IACL,CAAC;IAAC,OA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,OAAO,CAAC,SAAS,EAAE,CAAC;AAC7B,CAAC"}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GitHub CLI Command Wrappers
|
|
3
|
+
*
|
|
4
|
+
* Centralized GitHub CLI (`gh`) command execution.
|
|
5
|
+
* All gh commands MUST go through these functions for:
|
|
6
|
+
* - Centralized execution logic
|
|
7
|
+
* - Easy mocking in tests
|
|
8
|
+
* - Architectural consistency
|
|
9
|
+
*
|
|
10
|
+
* **NEVER call safeExecSync('gh', ...) directly from other packages.**
|
|
11
|
+
*
|
|
12
|
+
* @packageDocumentation
|
|
13
|
+
*/
|
|
14
|
+
/**
|
|
15
|
+
* GitHub Pull Request
|
|
16
|
+
*/
|
|
17
|
+
export interface GitHubPullRequest {
|
|
18
|
+
number: number;
|
|
19
|
+
title: string;
|
|
20
|
+
url: string;
|
|
21
|
+
headRefName: string;
|
|
22
|
+
baseRefName: string;
|
|
23
|
+
author: {
|
|
24
|
+
login: string;
|
|
25
|
+
};
|
|
26
|
+
isDraft?: boolean;
|
|
27
|
+
mergeable?: string;
|
|
28
|
+
mergeStateStatus?: string;
|
|
29
|
+
labels?: Array<{
|
|
30
|
+
name: string;
|
|
31
|
+
}>;
|
|
32
|
+
closingIssuesReferences?: Array<{
|
|
33
|
+
number: number;
|
|
34
|
+
title: string;
|
|
35
|
+
url: string;
|
|
36
|
+
}>;
|
|
37
|
+
state?: 'OPEN' | 'CLOSED' | 'MERGED';
|
|
38
|
+
mergedAt?: string;
|
|
39
|
+
mergedBy?: {
|
|
40
|
+
login: string;
|
|
41
|
+
};
|
|
42
|
+
mergeCommit?: {
|
|
43
|
+
oid: string;
|
|
44
|
+
parents?: Array<{
|
|
45
|
+
totalCount?: number;
|
|
46
|
+
}>;
|
|
47
|
+
};
|
|
48
|
+
commits?: {
|
|
49
|
+
totalCount?: number;
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* GitHub Workflow Run
|
|
54
|
+
*/
|
|
55
|
+
export interface GitHubRun {
|
|
56
|
+
databaseId: number;
|
|
57
|
+
name: string;
|
|
58
|
+
status: string;
|
|
59
|
+
conclusion: string | null;
|
|
60
|
+
workflowName: string;
|
|
61
|
+
createdAt: string;
|
|
62
|
+
updatedAt: string;
|
|
63
|
+
url: string;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* GitHub Workflow Job
|
|
67
|
+
*/
|
|
68
|
+
export interface GitHubJob {
|
|
69
|
+
id: number;
|
|
70
|
+
run_id: number;
|
|
71
|
+
name: string;
|
|
72
|
+
status: string;
|
|
73
|
+
conclusion: string | null;
|
|
74
|
+
started_at: string;
|
|
75
|
+
completed_at: string | null;
|
|
76
|
+
html_url: string;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Fetch PR details from GitHub
|
|
80
|
+
*
|
|
81
|
+
* @param prNumber - PR number
|
|
82
|
+
* @param owner - Repository owner (optional)
|
|
83
|
+
* @param repo - Repository name (optional)
|
|
84
|
+
* @param fields - Fields to fetch (optional, defaults to common fields)
|
|
85
|
+
* @returns PR data
|
|
86
|
+
*/
|
|
87
|
+
export declare function fetchPRDetails(prNumber: number, owner?: string, repo?: string, fields?: string[]): GitHubPullRequest;
|
|
88
|
+
/**
|
|
89
|
+
* Fetch PR checks (statusCheckRollup)
|
|
90
|
+
*
|
|
91
|
+
* @param prNumber - PR number
|
|
92
|
+
* @param owner - Repository owner (optional)
|
|
93
|
+
* @param repo - Repository name (optional)
|
|
94
|
+
* @returns PR checks data
|
|
95
|
+
*/
|
|
96
|
+
export declare function fetchPRChecks(prNumber: number, owner?: string, repo?: string): {
|
|
97
|
+
statusCheckRollup: Array<Record<string, unknown>>;
|
|
98
|
+
};
|
|
99
|
+
/**
|
|
100
|
+
* Get current PR for the current branch
|
|
101
|
+
*
|
|
102
|
+
* Uses `gh pr view` without specifying a PR number,
|
|
103
|
+
* which auto-detects based on current branch/HEAD.
|
|
104
|
+
*
|
|
105
|
+
* @param owner - Repository owner (optional)
|
|
106
|
+
* @param repo - Repository name (optional)
|
|
107
|
+
* @returns PR number, or null if no PR found
|
|
108
|
+
*/
|
|
109
|
+
export declare function getCurrentPR(owner?: string, repo?: string): number | null;
|
|
110
|
+
/**
|
|
111
|
+
* List pull requests
|
|
112
|
+
*
|
|
113
|
+
* @param owner - Repository owner
|
|
114
|
+
* @param repo - Repository name
|
|
115
|
+
* @param limit - Max number of PRs to return (default: 5)
|
|
116
|
+
* @param fields - Fields to fetch (optional)
|
|
117
|
+
* @param state - PR state filter: 'open', 'closed', 'merged', or 'all' (default: 'open')
|
|
118
|
+
* @returns List of PRs
|
|
119
|
+
*/
|
|
120
|
+
export declare function listPullRequests(owner: string, repo: string, limit?: number, fields?: string[], state?: 'open' | 'closed' | 'merged' | 'all'): GitHubPullRequest[];
|
|
121
|
+
/**
|
|
122
|
+
* Fetch workflow run logs
|
|
123
|
+
*
|
|
124
|
+
* @param runId - GitHub run ID
|
|
125
|
+
* @param owner - Repository owner (optional)
|
|
126
|
+
* @param repo - Repository name (optional)
|
|
127
|
+
* @param jobId - GitHub job ID (optional, for matrix strategy jobs)
|
|
128
|
+
* @returns Raw log output
|
|
129
|
+
*
|
|
130
|
+
* When jobId is provided, fetches logs for a specific job within the run.
|
|
131
|
+
* This is CRITICAL for matrix strategy builds where a single run contains multiple jobs.
|
|
132
|
+
* Without jobId, gh returns combined logs from ALL jobs, making error extraction unreliable.
|
|
133
|
+
*/
|
|
134
|
+
export declare function fetchRunLogs(runId: number, owner?: string, repo?: string, jobId?: number): string;
|
|
135
|
+
/**
|
|
136
|
+
* Fetch workflow run details
|
|
137
|
+
*
|
|
138
|
+
* @param runId - GitHub run ID
|
|
139
|
+
* @param owner - Repository owner (optional)
|
|
140
|
+
* @param repo - Repository name (optional)
|
|
141
|
+
* @param fields - Fields to fetch (optional)
|
|
142
|
+
* @returns Run details
|
|
143
|
+
*/
|
|
144
|
+
export declare function fetchRunDetails(runId: number, owner?: string, repo?: string, fields?: string[]): GitHubRun;
|
|
145
|
+
/**
|
|
146
|
+
* Fetch jobs for a workflow run
|
|
147
|
+
*
|
|
148
|
+
* @param runId - Run ID
|
|
149
|
+
* @param owner - Repository owner (optional)
|
|
150
|
+
* @param repo - Repository name (optional)
|
|
151
|
+
* @returns List of jobs for the run
|
|
152
|
+
*/
|
|
153
|
+
export declare function fetchRunJobs(runId: number, owner?: string, repo?: string): GitHubJob[];
|
|
154
|
+
/**
|
|
155
|
+
* List workflow runs for a branch
|
|
156
|
+
*
|
|
157
|
+
* @param branch - Branch name
|
|
158
|
+
* @param owner - Repository owner (optional)
|
|
159
|
+
* @param repo - Repository name (optional)
|
|
160
|
+
* @param limit - Max number of runs to return (default: 20)
|
|
161
|
+
* @param fields - Fields to fetch (optional)
|
|
162
|
+
* @returns List of runs
|
|
163
|
+
*/
|
|
164
|
+
export declare function listWorkflowRuns(branch: string, owner?: string, repo?: string, limit?: number, fields?: string[]): GitHubRun[];
|
|
165
|
+
//# sourceMappingURL=gh-commands.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gh-commands.d.ts","sourceRoot":"","sources":["../src/gh-commands.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAIH;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;IAC1B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,MAAM,CAAC,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IACjC,uBAAuB,CA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K,CAAC,EAAE,MAAM,EACd,IAAI,CAAC,EAAE,MAAM,EACb,KAAK,SAAK,EACV,MAAM,CAAC,EAAE,MAAM,EAAE,GAChB,SAAS,EAAE,CAab"}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GitHub CLI Command Wrappers
|
|
3
|
+
*
|
|
4
|
+
* Centralized GitHub CLI (`gh`) command execution.
|
|
5
|
+
* All gh commands MUST go through these functions for:
|
|
6
|
+
* - Centralized execution logic
|
|
7
|
+
* - Easy mocking in tests
|
|
8
|
+
* - Architectural consistency
|
|
9
|
+
*
|
|
10
|
+
* **NEVER call safeExecSync('gh', ...) directly from other packages.**
|
|
11
|
+
*
|
|
12
|
+
* @packageDocumentation
|
|
13
|
+
*/
|
|
14
|
+
import { safeExecSync } from '@vibe-validate/utils';
|
|
15
|
+
/**
|
|
16
|
+
* Fetch PR details from GitHub
|
|
17
|
+
*
|
|
18
|
+
* @param prNumber - PR number
|
|
19
|
+
* @param owner - Repository owner (optional)
|
|
20
|
+
* @param repo - Repository name (optional)
|
|
21
|
+
* @param fields - Fields to fetch (optional, defaults to common fields)
|
|
22
|
+
* @returns PR data
|
|
23
|
+
*/
|
|
24
|
+
export function fetchPRDetails(prNumber, owner, repo, fields) {
|
|
25
|
+
const repoFlag = owner && repo ? ['--repo', `${owner}/${repo}`] : [];
|
|
26
|
+
const fieldList = fields ?? [
|
|
27
|
+
'number',
|
|
28
|
+
'title',
|
|
29
|
+
'url',
|
|
30
|
+
'headRefName',
|
|
31
|
+
'baseRefName',
|
|
32
|
+
'author',
|
|
33
|
+
'isDraft',
|
|
34
|
+
'mergeable',
|
|
35
|
+
'mergeStateStatus',
|
|
36
|
+
'labels',
|
|
37
|
+
'closingIssuesReferences',
|
|
38
|
+
];
|
|
39
|
+
const response = safeExecSync('gh', ['pr', 'view', String(prNumber), ...repoFlag, '--json', fieldList.join(',')], {
|
|
40
|
+
encoding: 'utf8',
|
|
41
|
+
});
|
|
42
|
+
return JSON.parse(response);
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Fetch PR checks (statusCheckRollup)
|
|
46
|
+
*
|
|
47
|
+
* @param prNumber - PR number
|
|
48
|
+
* @param owner - Repository owner (optional)
|
|
49
|
+
* @param repo - Repository name (optional)
|
|
50
|
+
* @returns PR checks data
|
|
51
|
+
*/
|
|
52
|
+
export function fetchPRChecks(prNumber, owner, repo) {
|
|
53
|
+
const repoFlag = owner && repo ? ['--repo', `${owner}/${repo}`] : [];
|
|
54
|
+
const response = safeExecSync('gh', ['pr', 'view', String(prNumber), ...repoFlag, '--json', 'statusCheckRollup'], {
|
|
55
|
+
encoding: 'utf8',
|
|
56
|
+
});
|
|
57
|
+
return JSON.parse(response);
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Get current PR for the current branch
|
|
61
|
+
*
|
|
62
|
+
* Uses `gh pr view` without specifying a PR number,
|
|
63
|
+
* which auto-detects based on current branch/HEAD.
|
|
64
|
+
*
|
|
65
|
+
* @param owner - Repository owner (optional)
|
|
66
|
+
* @param repo - Repository name (optional)
|
|
67
|
+
* @returns PR number, or null if no PR found
|
|
68
|
+
*/
|
|
69
|
+
export function getCurrentPR(owner, repo) {
|
|
70
|
+
const repoFlag = owner && repo ? ['--repo', `${owner}/${repo}`] : [];
|
|
71
|
+
try {
|
|
72
|
+
const response = safeExecSync('gh', ['pr', 'view', ...repoFlag, '--json', 'number'], {
|
|
73
|
+
encoding: 'utf8',
|
|
74
|
+
});
|
|
75
|
+
const prData = JSON.parse(response);
|
|
76
|
+
if (prData.number && typeof prData.number === 'number') {
|
|
77
|
+
return prData.number;
|
|
78
|
+
}
|
|
79
|
+
return null;
|
|
80
|
+
}
|
|
81
|
+
catch {
|
|
82
|
+
// No PR found for current branch
|
|
83
|
+
return null;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* List pull requests
|
|
88
|
+
*
|
|
89
|
+
* @param owner - Repository owner
|
|
90
|
+
* @param repo - Repository name
|
|
91
|
+
* @param limit - Max number of PRs to return (default: 5)
|
|
92
|
+
* @param fields - Fields to fetch (optional)
|
|
93
|
+
* @param state - PR state filter: 'open', 'closed', 'merged', or 'all' (default: 'open')
|
|
94
|
+
* @returns List of PRs
|
|
95
|
+
*/
|
|
96
|
+
export function listPullRequests(owner, repo, limit = 5, fields, state = 'open') {
|
|
97
|
+
const fieldList = fields ?? ['number', 'title', 'author', 'headRefName'];
|
|
98
|
+
const response = safeExecSync('gh', ['pr', 'list', '--repo', `${owner}/${repo}`, '--limit', String(limit), '--state', state, '--json', fieldList.join(',')], {
|
|
99
|
+
encoding: 'utf8',
|
|
100
|
+
});
|
|
101
|
+
return JSON.parse(response);
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Fetch workflow run logs
|
|
105
|
+
*
|
|
106
|
+
* @param runId - GitHub run ID
|
|
107
|
+
* @param owner - Repository owner (optional)
|
|
108
|
+
* @param repo - Repository name (optional)
|
|
109
|
+
* @param jobId - GitHub job ID (optional, for matrix strategy jobs)
|
|
110
|
+
* @returns Raw log output
|
|
111
|
+
*
|
|
112
|
+
* When jobId is provided, fetches logs for a specific job within the run.
|
|
113
|
+
* This is CRITICAL for matrix strategy builds where a single run contains multiple jobs.
|
|
114
|
+
* Without jobId, gh returns combined logs from ALL jobs, making error extraction unreliable.
|
|
115
|
+
*/
|
|
116
|
+
export function fetchRunLogs(runId, owner, repo, jobId) {
|
|
117
|
+
const repoFlag = owner && repo ? ['--repo', `${owner}/${repo}`] : [];
|
|
118
|
+
const jobFlag = jobId ? ['--job', String(jobId)] : [];
|
|
119
|
+
const logs = safeExecSync('gh', ['run', 'view', String(runId), ...repoFlag, ...jobFlag, '--log'], {
|
|
120
|
+
encoding: 'utf8',
|
|
121
|
+
});
|
|
122
|
+
return typeof logs === 'string' ? logs : logs.toString('utf8');
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Fetch workflow run details
|
|
126
|
+
*
|
|
127
|
+
* @param runId - GitHub run ID
|
|
128
|
+
* @param owner - Repository owner (optional)
|
|
129
|
+
* @param repo - Repository name (optional)
|
|
130
|
+
* @param fields - Fields to fetch (optional)
|
|
131
|
+
* @returns Run details
|
|
132
|
+
*/
|
|
133
|
+
export function fetchRunDetails(runId, owner, repo, fields) {
|
|
134
|
+
const repoFlag = owner && repo ? ['--repo', `${owner}/${repo}`] : [];
|
|
135
|
+
const fieldList = fields ?? ['databaseId', 'name', 'status', 'conclusion', 'workflowName', 'createdAt', 'updatedAt', 'url'];
|
|
136
|
+
const response = safeExecSync('gh', ['run', 'view', String(runId), ...repoFlag, '--json', fieldList.join(',')], {
|
|
137
|
+
encoding: 'utf8',
|
|
138
|
+
});
|
|
139
|
+
return JSON.parse(response);
|
|
140
|
+
}
|
|
141
|
+
/**
|
|
142
|
+
* Fetch jobs for a workflow run
|
|
143
|
+
*
|
|
144
|
+
* @param runId - Run ID
|
|
145
|
+
* @param owner - Repository owner (optional)
|
|
146
|
+
* @param repo - Repository name (optional)
|
|
147
|
+
* @returns List of jobs for the run
|
|
148
|
+
*/
|
|
149
|
+
export function fetchRunJobs(runId, owner, repo) {
|
|
150
|
+
// If owner/repo provided, use them in the API path
|
|
151
|
+
// Otherwise rely on gh CLI to infer from current repo
|
|
152
|
+
const apiPath = owner && repo
|
|
153
|
+
? `repos/${owner}/${repo}/actions/runs/${runId}/jobs`
|
|
154
|
+
: `repos/:owner/:repo/actions/runs/${runId}/jobs`;
|
|
155
|
+
const response = safeExecSync('gh', ['api', apiPath], {
|
|
156
|
+
encoding: 'utf8',
|
|
157
|
+
});
|
|
158
|
+
const data = JSON.parse(response);
|
|
159
|
+
return data.jobs ?? [];
|
|
160
|
+
}
|
|
161
|
+
/**
|
|
162
|
+
* List workflow runs for a branch
|
|
163
|
+
*
|
|
164
|
+
* @param branch - Branch name
|
|
165
|
+
* @param owner - Repository owner (optional)
|
|
166
|
+
* @param repo - Repository name (optional)
|
|
167
|
+
* @param limit - Max number of runs to return (default: 20)
|
|
168
|
+
* @param fields - Fields to fetch (optional)
|
|
169
|
+
* @returns List of runs
|
|
170
|
+
*/
|
|
171
|
+
export function listWorkflowRuns(branch, owner, repo, limit = 20, fields) {
|
|
172
|
+
const repoFlag = owner && repo ? ['--repo', `${owner}/${repo}`] : [];
|
|
173
|
+
const fieldList = fields ?? ['databaseId', 'name', 'status', 'conclusion', 'workflowName', 'createdAt'];
|
|
174
|
+
const response = safeExecSync('gh', ['run', 'list', ...repoFlag, '--branch', branch, '--limit', String(limit), '--json', fieldList.join(',')], {
|
|
175
|
+
encoding: 'utf8',
|
|
176
|
+
});
|
|
177
|
+
return JSON.parse(response);
|
|
178
|
+
}
|
|
179
|
+
//# sourceMappingURL=gh-commands.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gh-commands.js","sourceRoot":"","sources":["../src/gh-commands.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AA4DpD;;;;;;;;GAQG;AACH,MAAM,UAAU,cAAc,CAC5B,QAAgB,EAChB,KAAc,EACd,IAAa,EACb,MAAiB;IAEjB,MAAM,QAAQ,GAAG,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,GAAG,KAAK,IAAI,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACrE,MAAM,SAAS,GAAG,MAAM,IAAI;QAC1B,QAAQ;QACR,OAAO;QACP,KAAK;QACL,aAAa;QACb,aAAa;QACb,QAAQ;QACR,SAAS;QACT,WAAW;QACX,kBAAkB;QAClB,QAAQ;QACR,yBAAyB;KAC1B,CAAC;IAEF,MAAM,QAAQ,GAAG,YAAY,CAC3B,IAAI,EACJ,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,CAAC,QAAQ,CAAC,EAAE,GAAG,QAAQ,EAAE,QAAQ,EAAE,SAAS,CAAC,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,QAAQ,EAAE,MAAM;KACjB,CACF,CAAC;IAEF,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,QAAkB,CAAC,CAAC;IAC5C,OAAO,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC;AACzB,CAAC;AAED;;;;;;;;;GASG;AACH,MAAM,UAAU,gBAAgB,CAC9B,MAAc,EACd,KAAc,EACd,IAAa,EACb,KAAK,GAAG,EAAE,EACV,MAAiB;IAEjB,MAAM,QAAQ,GAAG,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,GAAG,KAAK,IAAI,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACrE,MAAM,SAAS,GAAG,MAAM,IAAI,CAAC,YAAY,EAAE,MAAM,EAAE,QAAQ,EAAE,YAAY,EAAE,cAAc,EAAE,WAAW,CAAC,CAAC;IAExG,MAAM,QAAQ,GAAG,YAAY,CAC3B,IAAI,EACJ,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,QAAQ,EAAE,UAAU,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EACzG;QACE,QAAQ,EAAE,MAAM;KACjB,CACF,CAAC;IAEF,OAAO,IAAI,CAAC,KAAK,CAAC,QAAkB,CAAC,CAAC;AACxC,CAAC"}
|
package/dist/git-commands.d.ts
CHANGED
|
@@ -27,6 +27,13 @@ export declare function getRepositoryRoot(): string;
|
|
|
27
27
|
* @throws Error if not on a branch (detached HEAD)
|
|
28
28
|
*/
|
|
29
29
|
export declare function getCurrentBranch(): string;
|
|
30
|
+
/**
|
|
31
|
+
* Get the URL of a git remote
|
|
32
|
+
* @param remote - The name of the remote (default: 'origin')
|
|
33
|
+
* @returns The URL of the specified remote
|
|
34
|
+
* @throws Error if remote doesn't exist
|
|
35
|
+
*/
|
|
36
|
+
export declare function getRemoteUrl(remote?: string): string;
|
|
30
37
|
/**
|
|
31
38
|
* Get the commit SHA of HEAD
|
|
32
39
|
* @returns The full SHA of the current commit
|
|
@@ -63,4 +70,24 @@ export declare function hasNotesRef(notesRef: string): boolean;
|
|
|
63
70
|
* @returns true if MERGE_HEAD exists (merge in progress), false otherwise
|
|
64
71
|
*/
|
|
65
72
|
export declare function isMergeInProgress(): boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Get diff statistics between two refs
|
|
75
|
+
* @param baseRef - Base reference (e.g., 'origin/main')
|
|
76
|
+
* @param headRef - Head reference (default: 'HEAD')
|
|
77
|
+
* @returns Diff output from git diff --numstat
|
|
78
|
+
*/
|
|
79
|
+
export declare function getDiffStats(baseRef: string, headRef?: string): string;
|
|
80
|
+
/**
|
|
81
|
+
* Get commit count between two refs
|
|
82
|
+
* @param baseRef - Base reference (e.g., 'origin/main')
|
|
83
|
+
* @param headRef - Head reference (default: 'HEAD')
|
|
84
|
+
* @returns Number of commits as string
|
|
85
|
+
*/
|
|
86
|
+
export declare function getCommitCount(baseRef: string, headRef?: string): string;
|
|
87
|
+
/**
|
|
88
|
+
* List notes references matching a pattern
|
|
89
|
+
* @param pattern - Pattern to match (e.g., 'refs/notes/vibe-validate/run/*')
|
|
90
|
+
* @returns Output from git for-each-ref
|
|
91
|
+
*/
|
|
92
|
+
export declare function getNotesRefs(pattern: string): string;
|
|
66
93
|
//# sourceMappingURL=git-commands.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git-commands.d.ts","sourceRoot":"","sources":["../src/git-commands.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH;;;GAGG;AACH,wBAAgB,eAAe,IAAI,OAAO,CAEzC;AAED;;;;GAIG;AACH,wBAAgB,SAAS,IAAI,MAAM,CAElC;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,IAAI,MAAM,CAE1C;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,IAAI,MAAM,CAEzC;AAED;;;;GA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E,OAAO,SAAS,GAAG,MAAM,CAEtE;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,SAAS,GAAG,MAAM,CAExE;AAED;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAEpD"}
|
package/dist/git-commands.js
CHANGED
|
@@ -36,6 +36,15 @@ export function getRepositoryRoot() {
|
|
|
36
36
|
export function getCurrentBranch() {
|
|
37
37
|
return execGitCommand(['rev-parse', '--abbrev-ref', 'HEAD']);
|
|
38
38
|
}
|
|
39
|
+
/**
|
|
40
|
+
* Get the URL of a git remote
|
|
41
|
+
* @param remote - The name of the remote (default: 'origin')
|
|
42
|
+
* @returns The URL of the specified remote
|
|
43
|
+
* @throws Error if remote doesn't exist
|
|
44
|
+
*/
|
|
45
|
+
export function getRemoteUrl(remote = 'origin') {
|
|
46
|
+
return execGitCommand(['remote', 'get-url', remote]);
|
|
47
|
+
}
|
|
39
48
|
/**
|
|
40
49
|
* Get the commit SHA of HEAD
|
|
41
50
|
* @returns The full SHA of the current commit
|
|
@@ -84,4 +93,30 @@ export function hasNotesRef(notesRef) {
|
|
|
84
93
|
export function isMergeInProgress() {
|
|
85
94
|
return tryGitCommand(['rev-parse', '--verify', '--quiet', 'MERGE_HEAD']);
|
|
86
95
|
}
|
|
96
|
+
/**
|
|
97
|
+
* Get diff statistics between two refs
|
|
98
|
+
* @param baseRef - Base reference (e.g., 'origin/main')
|
|
99
|
+
* @param headRef - Head reference (default: 'HEAD')
|
|
100
|
+
* @returns Diff output from git diff --numstat
|
|
101
|
+
*/
|
|
102
|
+
export function getDiffStats(baseRef, headRef = 'HEAD') {
|
|
103
|
+
return execGitCommand(['diff', '--numstat', `${baseRef}...${headRef}`]);
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Get commit count between two refs
|
|
107
|
+
* @param baseRef - Base reference (e.g., 'origin/main')
|
|
108
|
+
* @param headRef - Head reference (default: 'HEAD')
|
|
109
|
+
* @returns Number of commits as string
|
|
110
|
+
*/
|
|
111
|
+
export function getCommitCount(baseRef, headRef = 'HEAD') {
|
|
112
|
+
return execGitCommand(['rev-list', '--count', `${baseRef}...${headRef}`]);
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* List notes references matching a pattern
|
|
116
|
+
* @param pattern - Pattern to match (e.g., 'refs/notes/vibe-validate/run/*')
|
|
117
|
+
* @returns Output from git for-each-ref
|
|
118
|
+
*/
|
|
119
|
+
export function getNotesRefs(pattern) {
|
|
120
|
+
return execGitCommand(['for-each-ref', pattern]);
|
|
121
|
+
}
|
|
87
122
|
//# sourceMappingURL=git-commands.js.map
|
package/dist/git-commands.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git-commands.js","sourceRoot":"","sources":["../src/git-commands.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElE;;;GAGG;AACH,MAAM,UAAU,eAAe;IAC7B,OAAO,aAAa,CAAC,CAAC,WAAW,EAAE,uBAAuB,CAAC,CAAC,CAAC;AAC/D,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,SAAS;IACvB,OAAO,cAAc,CAAC,CAAC,WAAW,EAAE,WAAW,CAAC,CAAC,CAAC;AACpD,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,iBAAiB;IAC/B,OAAO,cAAc,CAAC,CAAC,WAAW,EAAE,iBAAiB,CAAC,CAAC,CAAC;AAC1D,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,gBAAgB;IAC9B,OAAO,cAAc,CAAC,CAAC,WAAW,EAAE,cAAc,EAAE,MAAM,CAAC,CAAC,CAAC;AAC/D,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,gBAAgB;IAC9B,OAAO,cAAc,CAAC,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC,CA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M,OAAO,EAAE,CAAC,CAAC,CAAC;AAC1E,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,cAAc,CAAC,OAAe,EAAE,OAAO,GAAG,MAAM;IAC9D,OAAO,cAAc,CAAC,CAAC,UAAU,EAAE,SAAS,EAAE,GAAG,OAAO,MAAM,OAAO,EAAE,CAAC,CAAC,CAAC;AAC5E,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,YAAY,CAAC,OAAe;IAC1C,OAAO,cAAc,CAAC,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC,CAAC;AACnD,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -12,9 +12,12 @@ export { BranchSyncChecker, checkBranchSync, type SyncCheckResult, type SyncChec
|
|
|
12
12
|
export { PostPRMergeCleanup, cleanupMergedBranches, type CleanupResult, type CleanupOptions } from './post-merge-cleanup.js';
|
|
13
13
|
export { encodeRunCacheKey } from './cache-key.js';
|
|
14
14
|
export { extractYamlContent, extractYamlWithPreamble } from './yaml-detection.js';
|
|
15
|
-
export { isGitRepository, getGitDir, getRepositoryRoot, getCurrentBranch, getHeadCommitSha, getHeadTreeSha, verifyRef, verifyRefOrThrow, hasNotesRef, isMergeInProgress } from './git-commands.js';
|
|
15
|
+
export { isGitRepository, getGitDir, getRepositoryRoot, getCurrentBranch, getRemoteUrl, getHeadCommitSha, getHeadTreeSha, verifyRef, verifyRefOrThrow, hasNotesRef, isMergeInProgress, getDiffStats, getCommitCount, getNotesRefs } from './git-commands.js';
|
|
16
16
|
export { executeGitCommand, execGitCommand, tryGitCommand, validateGitRef, validateNotesRef, validateTreeHash, type GitExecutionOptions, type GitExecutionResult } from './git-executor.js';
|
|
17
17
|
export { addNote, readNote, removeNote, listNotes, hasNote, listNotesRefs, removeNotesRefs, getNotesRefSha } from './git-notes.js';
|
|
18
18
|
export { getPartiallyStagedFiles } from './staging.js';
|
|
19
19
|
export { isCurrentBranchBehindTracking } from './tracking-branch.js';
|
|
20
|
+
export { fetchPRDetails, fetchPRChecks, getCurrentPR, listPullRequests, fetchRunLogs, fetchRunDetails, fetchRunJobs, listWorkflowRuns, type GitHubPullRequest, type GitHubRun, type GitHubJob } from './gh-commands.js';
|
|
21
|
+
export { detectDefaultBranch, isProtectedBranch, isAutoDeleteSafe, needsReview, shouldShowBranch, gatherBranchGitFacts, setupCleanupContext, parseRemoteTracking, getUnpushedCommitCount, detectMergeMethod, fetchPRDataForBranches, enrichWithGitHubData, cleanupBranches, type RemoteStatus, type BranchGitFacts, type BranchGitHubFacts, type BranchAssessment, type BranchAnalysis, type CleanupContext } from './branch-cleanup.js';
|
|
22
|
+
export type { CleanupResult as BranchCleanupResult } from './branch-cleanup.js';
|
|
20
23
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAGhE,OAAO,EACL,cAAc,EACd,eAAe,EACf,qBAAqB,EACtB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,iBAAiB,EACjB,eAAe,EACf,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACtB,MAAM,kBAAkB,CAAC;AAG1B,OAAO,EACL,kBAAkB,EAClB,qBAAqB,EACrB,KAAK,aAAa,EAClB,KAAK,cAAc,EACpB,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EACL,iBAAiB,EAClB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,kBAAkB,EAClB,uBAAuB,EACxB,MAAM,qBAAqB,CAAC;AAG7B,OAAO,EACL,eAAe,EACf,SAAS,EACT,iBAAiB,EACjB,gBAAgB,EAChB,gBAAgB,EAChB,cAAc,EACd,SAAS,EACT,gBAAgB,EAChB,WAAW,EACX,iBAAiB,
|
|
1
|
+
{"version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EACf,YAAY,EACZ,gBAAgB,EAChB,KAAK,iBAAiB,EACtB,KAAK,SAAS,EACd,KAAK,SAAS,EACf,MAAM,kBAAkB,CAAC;AAG1B,OAAO,EACL,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,WAAW,EACX,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,mBAAmB,EACnB,sBAAsB,EACtB,iBAAiB,EACjB,sBAAsB,EACtB,oBAAoB,EACpB,eAAe,EACf,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,cAAc,EACpB,MAAM,qBAAqB,CAAC;AAG7B,YAAY,EAAE,aAAa,IAAI,mBAAmB,EAAE,MAAM,qBAAqB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -17,7 +17,7 @@ export { encodeRunCacheKey } from './cache-key.js';
|
|
|
17
17
|
// YAML output detection
|
|
18
18
|
export { extractYamlContent, extractYamlWithPreamble } from './yaml-detection.js';
|
|
19
19
|
// Git command utilities (standardized rev-parse operations)
|
|
20
|
-
export { isGitRepository, getGitDir, getRepositoryRoot, getCurrentBranch, getHeadCommitSha, getHeadTreeSha, verifyRef, verifyRefOrThrow, hasNotesRef, isMergeInProgress } from './git-commands.js';
|
|
20
|
+
export { isGitRepository, getGitDir, getRepositoryRoot, getCurrentBranch, getRemoteUrl, getHeadCommitSha, getHeadTreeSha, verifyRef, verifyRefOrThrow, hasNotesRef, isMergeInProgress, getDiffStats, getCommitCount, getNotesRefs } from './git-commands.js';
|
|
21
21
|
// Secure git command execution (low-level - use high-level APIs when possible)
|
|
22
22
|
export { executeGitCommand, execGitCommand, tryGitCommand, validateGitRef, validateNotesRef, validateTreeHash } from './git-executor.js';
|
|
23
23
|
// Git notes operations (high-level abstraction)
|
|
@@ -26,4 +26,8 @@ export { addNote, readNote, removeNote, listNotes, hasNote, listNotesRefs, remov
|
|
|
26
26
|
export { getPartiallyStagedFiles } from './staging.js';
|
|
27
27
|
// Git tracking branch detection (check if current branch is behind remote)
|
|
28
28
|
export { isCurrentBranchBehindTracking } from './tracking-branch.js';
|
|
29
|
+
// GitHub CLI commands (centralized gh command execution)
|
|
30
|
+
export { fetchPRDetails, fetchPRChecks, getCurrentPR, listPullRequests, fetchRunLogs, fetchRunDetails, fetchRunJobs, listWorkflowRuns } from './gh-commands.js';
|
|
31
|
+
// Branch cleanup analysis (identify safe-to-delete branches)
|
|
32
|
+
export { detectDefaultBranch, isProtectedBranch, isAutoDeleteSafe, needsReview, shouldShowBranch, gatherBranchGitFacts, setupCleanupContext, parseRemoteTracking, getUnpushedCommitCount, detectMergeMethod, fetchPRDataForBranches, enrichWithGitHubData, cleanupBranches } from './branch-cleanup.js';
|
|
29
33
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,uDAAuD;AACvD,OAAO,EACL,cAAc,EACd,eAAe,EACf,qBAAqB,EACtB,MAAM,gBAAgB,CAAC;AAExB,6CAA6C;AAC7C,OAAO,EACL,iBAAiB,EACjB,eAAe,EAGhB,MAAM,kBAAkB,CAAC;AAE1B,8CAA8C;AAC9C,OAAO,EACL,kBAAkB,EAClB,qBAAqB,EAGtB,MAAM,yBAAyB,CAAC;AAEjC,qCAAqC;AACrC,OAAO,EACL,iBAAiB,EAClB,MAAM,gBAAgB,CAAC;AAExB,wBAAwB;AACxB,OAAO,EACL,kBAAkB,EAClB,uBAAuB,EACxB,MAAM,qBAAqB,CAAC;AAE7B,4DAA4D;AAC5D,OAAO,EACL,eAAe,EACf,SAAS,EACT,iBAAiB,EACjB,gBAAgB,EAChB,gBAAgB,EAChB,cAAc,EACd,SAAS,EACT,gBAAgB,EAChB,WAAW,EACX,iBAAiB,
|
|
1
|
+
{"version":3,"file":"index.js","sour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B,CAAC;AAE1B,6DAA6D;AAC7D,OAAO,EACL,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,WAAW,EACX,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,mBAAmB,EACnB,sBAAsB,EACtB,iBAAiB,EACjB,sBAAsB,EACtB,oBAAoB,EACpB,eAAe,EAOhB,MAAM,qBAAqB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vibe-validate/git",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.18.0",
|
|
4
4
|
"description": "Git utilities for vibe-validate - tree hash calculation, branch sync, and post-merge cleanup",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"access": "public"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@vibe-validate/utils": "0.
|
|
41
|
+
"@vibe-validate/utils": "0.18.0"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
44
|
"@types/node": "^22.19.2",
|