Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Fixed
- Fixed issue where 403 errors were being raised during a user driven permission sync against a self-hosted code host. [#729](https://github.com/sourcebot-dev/sourcebot/pull/729)
- Fixed "ambiguous argument 'HEAD^{commit}': unknown revision or path not in the working tree" error for blank repositories. [#733](https://github.com/sourcebot-dev/sourcebot/pull/733)

## [4.10.8] - 2026-01-13

Expand Down
6 changes: 4 additions & 2 deletions packages/backend/src/git.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
import { env } from "@sourcebot/shared";
import { env, createLogger } from "@sourcebot/shared";
import { existsSync } from 'node:fs';
import { mkdir } from 'node:fs/promises';
import { dirname, resolve } from 'node:path';
import { CheckRepoActions, GitConfigScope, simpleGit, SimpleGitProgressEvent } from 'simple-git';

type onProgressFn = (event: SimpleGitProgressEvent) => void;

const logger = createLogger('git-utils');

/**
* Creates a simple-git client that has it's working directory
* set to the given path.
Expand Down Expand Up @@ -292,7 +294,7 @@ export const getCommitHashForRefName = async ({
// @note: Was hitting errors when the repository is empty,
// so we're catching the error and returning undefined.
} catch (error: unknown) {
console.error(error);
logger.debug(error);
return undefined;
}
}