Skip to content

Commit 9102f22

Browse files
committed
simplify
1 parent b8510c9 commit 9102f22

1 file changed

Lines changed: 3 additions & 13 deletions

File tree

.github/workflows/CI_check_api_ref.yml

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -38,19 +38,9 @@ jobs:
3838
runner_temp = os.environ["RUNNER_TEMP"]
3939
base_sha, _ = git("rev-parse", "HEAD^1")
4040
41-
# Get all changed files
42-
diff_output, _ = git(
43-
"diff", "--name-only", f"{base_sha}...HEAD", "--", "haystack_experimental"
44-
)
45-
changed_files = set(diff_output.splitlines())
46-
47-
changed_api_ref = False
48-
49-
# If pydoc config changed, always include
50-
for file in changed_files:
51-
if file.startswith("pydoc/"):
52-
changed_api_ref = True
53-
break
41+
# Check if pydoc config changed
42+
_, exit_code = git("diff", "--quiet", f"{base_sha}...HEAD", "--", "pydoc/")
43+
changed_api_ref = (exit_code != 0)
5444
5545
if not changed_api_ref:
5646
# Create base worktree for docstring comparison

0 commit comments

Comments
 (0)