difit 3.1.7 → 3.1.8

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.
@@ -9,18 +9,7 @@ export interface PullRequestInfo {
9
9
  pullNumber: number;
10
10
  hostname: string;
11
11
  }
12
- export interface PullRequestDetails {
13
- baseSha: string;
14
- headSha: string;
15
- baseRef: string;
16
- headRef: string;
17
- }
18
12
  export declare function parseGitHubPrUrl(url: string): PullRequestInfo | null;
19
- export declare function fetchPrDetails(prInfo: PullRequestInfo): Promise<PullRequestDetails>;
20
- export declare function resolveCommitInLocalRepo(sha: string, context?: {
21
- owner: string;
22
- repo: string;
23
- }): string;
24
13
  export declare function resolvePrCommits(prUrl: string): Promise<{
25
14
  targetCommitish: string;
26
15
  baseCommitish: string;
package/dist/cli/utils.js CHANGED
@@ -114,7 +114,7 @@ function getGitHubToken() {
114
114
  return undefined;
115
115
  }
116
116
  }
117
- export async function fetchPrDetails(prInfo) {
117
+ async function fetchPrDetails(prInfo) {
118
118
  const token = getGitHubToken();
119
119
  const octokitOptions = {
120
120
  auth: token,
@@ -160,7 +160,7 @@ export async function fetchPrDetails(prInfo) {
160
160
  throw new Error('Failed to fetch PR details: Unknown error');
161
161
  }
162
162
  }
163
- export function resolveCommitInLocalRepo(sha, context) {
163
+ function resolveCommitInLocalRepo(sha, context) {
164
164
  try {
165
165
  // Verify if the commit exists locally
166
166
  execSync(`git cat-file -e ${sha}`, { stdio: 'ignore' });