Skip to content

ci: use CURSOR_PREFERRED_MODEL secret instead of hardcoded model#138

Merged
masnwilliams merged 1 commit intomainfrom
hypeship/use-cursor-model-secret
Mar 23, 2026
Merged

ci: use CURSOR_PREFERRED_MODEL secret instead of hardcoded model#138
masnwilliams merged 1 commit intomainfrom
hypeship/use-cursor-model-secret

Conversation

@masnwilliams
Copy link
Contributor

@masnwilliams masnwilliams commented Mar 23, 2026

Summary

Replaces the hardcoded --model opus-4.5 in the cursor-agent CLI invocation in .github/workflows/fix-ci.yaml with --model ${{ secrets.CURSOR_PREFERRED_MODEL }}, allowing the model to be configured via GitHub Actions secrets instead of requiring a code change.


Note

Low Risk
Low risk workflow-only change that just swaps a hardcoded model name for a configurable secret; main risk is misconfiguration if the secret is unset or invalid.

Overview
Updates the Fix CI Failures GitHub Actions workflow to stop hardcoding the cursor-agent --model value and instead read it from ${{ secrets.CURSOR_PREFERRED_MODEL }} for configurable model selection without code changes.

Written by Cursor Bugbot for commit c61cac1. This will update automatically on new commits. Configure here.

@masnwilliams masnwilliams marked this pull request as ready for review March 23, 2026 17:39
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

- If no actionable fix is possible, make no changes and post no comment
- PR comments must ONLY include the PR creation link, no manual merge instructions
" --model opus-4.5 --force --output-format=text
" --model ${{ secrets.CURSOR_PREFERRED_MODEL }} --force --output-format=text
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing secret causes model flag to consume next argument

Medium Severity

If the CURSOR_PREFERRED_MODEL secret is not configured (or is empty), ${{ secrets.CURSOR_PREFERRED_MODEL }} resolves to an empty string. The shell would then parse --model --force, causing --force to be consumed as the model name. Unlike the other secrets in this workflow (which fail clearly at their respective steps), this would produce a confusing error from cursor-agent. Adding a default fallback like ${{ secrets.CURSOR_PREFERRED_MODEL || 'opus-4.5' }} would preserve the previous behavior when the secret is unset.

Fix in Cursor Fix in Web

@masnwilliams masnwilliams merged commit 2866e73 into main Mar 23, 2026
2 checks passed
@masnwilliams masnwilliams deleted the hypeship/use-cursor-model-secret branch March 23, 2026 17:45
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.

1 participant