You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: action.yml
+34-2Lines changed: 34 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -290,13 +290,16 @@ runs:
290
290
FAILED=false
291
291
292
292
# Run Gemini CLI with the provided prompt, streaming responses in debug
293
+
EXIT_CODE=0
293
294
if [[ "${DEBUG}" = true ]]; then
294
295
echo "::warning::Gemini CLI debug logging is enabled. This will stream responses, which could reveal sensitive information if processed with untrusted inputs."
295
296
if ! { gemini --yolo --prompt "${PROMPT}" 2> >(tee "${TEMP_STDERR}" >&2) | tee "${TEMP_STDOUT}"; }; then
297
+
EXIT_CODE=$?
296
298
FAILED=true
297
299
fi
298
300
else
299
301
if ! gemini --yolo --prompt "${PROMPT}" 2> "${TEMP_STDERR}" 1> "${TEMP_STDOUT}"; then
302
+
EXIT_CODE=$?
300
303
FAILED=true
301
304
fi
302
305
fi
@@ -323,10 +326,39 @@ runs:
323
326
echo "EOF" >> "${GITHUB_OUTPUT}"
324
327
325
328
if [[ "${FAILED}" = true ]]; then
329
+
case "${EXIT_CODE}" in
330
+
1)
331
+
MSG="General error"
332
+
;;
333
+
41)
334
+
MSG="Authentication failure. Please check your credentials (API key or Google Cloud auth)."
335
+
;;
336
+
42)
337
+
MSG="Invalid input or configuration. Please check your prompt or CLI arguments."
338
+
;;
339
+
52)
340
+
MSG="Configuration error. Failed to save settings."
341
+
;;
342
+
53)
343
+
MSG="Turn limit exceeded. The conversation has reached its maximum length."
344
+
;;
345
+
126)
346
+
MSG="Command invoked cannot execute"
347
+
;;
348
+
127)
349
+
MSG="Command not found"
350
+
;;
351
+
130)
352
+
MSG="User cancelled. The operation was interrupted."
0 commit comments