From ac8751ef557e24d72616a06f4d21655c5a6facf4 Mon Sep 17 00:00:00 2001 From: Michael Dekoski Date: Wed, 17 Sep 2025 17:02:09 -0400 Subject: [PATCH] Quote branches argument in zoekt.ts to fix Pipe (#506) --- CHANGELOG.md | 1 + packages/backend/src/zoekt.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 813e71ea..fa465448 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - Fixed "At least one project, user, or group must be specified" for GitLab configs with `all` in web configurator. [#512](https://github.com/sourcebot-dev/sourcebot/pull/512) +- Fixed zoekt indexing failing with pipe in branch/tag names [#506](https://github.com/sourcebot-dev/sourcebot/pull/506) ## [4.6.8] - 2025-09-15 diff --git a/packages/backend/src/zoekt.ts b/packages/backend/src/zoekt.ts index 112681c3..076820c9 100644 --- a/packages/backend/src/zoekt.ts +++ b/packages/backend/src/zoekt.ts @@ -63,7 +63,7 @@ export const indexGitRepository = async (repo: Repo, settings: Settings, ctx: Ap `-index ${ctx.indexPath}`, `-max_trigram_count ${settings.maxTrigramCount}`, `-file_limit ${settings.maxFileSize}`, - `-branches ${revisions.join(',')}`, + `-branches "${revisions.join(',')}"`, `-tenant_id ${repo.orgId}`, `-repo_id ${repo.id}`, `-shard_prefix ${shardPrefix}`,