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
Make /run-skipped-ci persistent using full-ci label (#2007)
## Summary
- `/run-skipped-ci` now adds a persistent `full-ci` label to the PR
- New `/stop-run-skipped-ci` command removes the label to disable full
CI mode
- All workflows updated to check for the `full-ci` label in addition to
`force_run` input
- Label persists across commits, ensuring full CI runs until explicitly
stopped
## Problem
Previously, when running `/run-skipped-ci`:
1. Tests would start
2. Making a commit would stop all tests
3. Full CI never completed
## Solution
The `full-ci` label acts as a persistent flag:
- Added by `/run-skipped-ci` command
- Checked by all workflow `detect-changes` jobs
- Remains active across all future commits
- Only removed by `/stop-run-skipped-ci` command
## Workflows Updated
- `main.yml` - Main integration tests
- `examples.yml` - Generator tests
- `pro-integration-tests.yml` - Pro integration tests
- `pro-package-tests.yml` - Pro package tests
- `pro-lint.yml` - Pro linting
All workflows now:
1. Check for `full-ci` label on PRs
2. If label present, run full CI suite (including minimum dependency
tests)
3. Otherwise, use standard change detection
## Usage
```bash
# Enable full CI mode (persists across commits)
/run-skipped-ci
# Disable full CI mode
/stop-run-skipped-ci
```
## Test Plan
- [ ] Test `/run-skipped-ci` adds the label and triggers workflows
- [ ] Verify label persists after pushing new commits
- [ ] Confirm full CI runs on subsequent commits with label present
- [ ] Test `/stop-run-skipped-ci` removes the label
- [ ] Verify CI returns to normal mode after label removal
🤖 Generated with [Claude Code](https://claude.com/claude-code)
<!-- Reviewable:start -->
- - -
This change is [<img src="https://reviewable.io/review_button.svg"
height="34" align="absmiddle"
alt="Reviewable"/>](https://reviewable.io/reviews/shakacode/react_on_rails/2007)
<!-- Reviewable:end -->
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **Chores**
* CI now supports a "full-ci" label to trigger the full test suite and
propagate that state across workflows.
* New commands to enable/disable full CI via PR comments:
/run-skipped-ci and /stop-run-skipped-ci.
* Automatic cleanup of the full-ci label when PRs are merged.
* **Documentation**
* CONTRIBUTING.md updated with CI control commands and an updated
install example.
* **New Features**
* Welcome message posted on new PRs explaining CI controls and status.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: Claude <noreply@anthropic.com>
'This PR will run CI tests based on the files you changed. If some tests are skipped and you want to run the full test suite (including minimum dependency tests), you can use these commands:',
22
+
'',
23
+
'### CI Control Commands',
24
+
'',
25
+
'- **`/run-skipped-ci`** - Runs all skipped CI checks and enables full CI mode for this PR',
26
+
' - Adds the `full-ci` label to ensure future commits also run the full test suite',
27
+
' - Useful when you want comprehensive testing across all configurations',
28
+
'',
29
+
'- **`/stop-run-skipped-ci`** - Disables full CI mode and returns to standard CI',
30
+
' - Removes the `full-ci` label',
31
+
' - Future commits will only run tests for changed files',
32
+
'',
33
+
'**Note:**',
34
+
'- These commands require write access to the repository',
35
+
'- The `full-ci` label is preserved on merged PRs as a historical record',
36
+
'',
37
+
'View CI progress in the [Actions tab](${context.serverUrl}/${context.repo.owner}/${context.repo.repo}/actions).'
const body = `🚀 **Skipped CI Checks - Trigger Results**
219
+
// Add full-ci label only if we actually triggered workflows or if checks are already running
220
+
let labelAdded = false;
221
+
try {
222
+
await github.rest.issues.addLabels({
223
+
owner: context.repo.owner,
224
+
repo: context.repo.repo,
225
+
issue_number: context.issue.number,
226
+
labels: ['full-ci']
227
+
});
228
+
labelAdded = true;
229
+
console.log('✅ Added full-ci label to PR');
230
+
} catch (error) {
231
+
console.error('⚠️ Failed to add label:', error.message);
232
+
}
233
+
234
+
const body = `🚀 **Full CI Mode Enabled**
220
235
221
236
${status}
222
237
${skippedChecksList}
223
238
${verifiedList}${notFoundList}${failedList}
224
239
225
-
${verified.length > 0 ? `\n**Note:** These workflows will run with \`force_run: true\` to bypass detect-changes logic that caused them to skip.
240
+
${labelAdded && verified.length > 0 ? `\n**Note:** Added the \`full-ci\` label to this PR. All future commits will run the full CI suite (including minimum dependency tests) until the label is removed.
241
+
242
+
To disable full CI mode, use the \`/stop-run-skipped-ci\` command.
226
243
227
244
View progress in the [Actions tab](${context.serverUrl}/${context.repo.owner}/${context.repo.repo}/actions).` : ''}
228
245
229
-
${notApplicable.length > 0 ? `\nAll CI checks are already running on this PR. Use this command when you see skipped checks that you want to run.` : ''}`;
246
+
${labelAdded && notApplicable.length > 0 ? `\nAll CI checks are already running on this PR. Added the \`full-ci\` label - future commits will run the full CI suite.` : ''}`;
0 commit comments