Skip to content

fix(.github/workflows): create ~/.gemini before running Gemini CLI#4697

Merged
julieqiu merged 1 commit intogoogleapis:mainfrom
julieqiu:gemini4
Mar 20, 2026
Merged

fix(.github/workflows): create ~/.gemini before running Gemini CLI#4697
julieqiu merged 1 commit intogoogleapis:mainfrom
julieqiu:gemini4

Conversation

@julieqiu
Copy link
Member

The Gemini CLI expects ~/.gemini/ to exist when saving its project registry. On a fresh GitHub Actions runner this directory is missing, causing an ENOENT error on rename of projects.json.tmp. The error text is written to stderr, which also triggers a "stderr was not valid JSON" warning because the action expects structured JSON there.

Adding mkdir -p ~/.gemini before the action runs prevents both problems.

The Gemini CLI expects ~/.gemini/ to exist when saving its project
registry. On a fresh GitHub Actions runner this directory is missing,
causing an ENOENT error on rename of projects.json.tmp. The error
text is written to stderr, which also triggers a "stderr was not valid
JSON" warning because the action expects structured JSON there.

Adding mkdir -p ~/.gemini before the action runs prevents both
problems.
@julieqiu julieqiu requested a review from a team as a code owner March 20, 2026 02:16
@gemini-code-assist
Copy link
Contributor

Note

Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported.

@julieqiu julieqiu changed the title fix(workflows): create ~/.gemini before running Gemini CLI fix(.github/workflows): create ~/.gemini before running Gemini CLI Mar 20, 2026
@julieqiu julieqiu enabled auto-merge (squash) March 20, 2026 02:42
@julieqiu julieqiu merged commit c19db28 into googleapis:main Mar 20, 2026
16 of 17 checks passed
@codecov
Copy link

codecov bot commented Mar 20, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.10%. Comparing base (ec03ba5) to head (0d88761).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4697   +/-   ##
=======================================
  Coverage   79.10%   79.10%           
=======================================
  Files         111      111           
  Lines        9420     9420           
=======================================
  Hits         7452     7452           
  Misses       1453     1453           
  Partials      515      515           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants