Enhance pre-commit config and modernize CI workflow#1
Merged
mrkshields merged 5 commits intomasterfrom Feb 4, 2026
Merged
Conversation
Add comprehensive validation hooks for Shell, Fish, Python, YAML, and Vim files. Replace custom CI jobs with official pre-commit action for consistent validation locally and in CI. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
.github/workflows/ubuntu-latest.yml
Outdated
| uses: actions/cache@v4 | ||
| with: | ||
| path: ~/.cache/pre-commit | ||
| key: pre-commit-${{ hashFiles('.pre-commit-config.yaml') }} |
There was a problem hiding this comment.
Cache key missing linter configuration files
Medium Severity
The cache key only includes .pre-commit-config.yaml, but several hooks reference external config files (linters/.yamllint and linters/.config/flake8). When these linter configs change, the cache won't invalidate, causing CI to run with stale configurations while local pre-commit runs use the updated configs. This creates inconsistent validation behavior.
added 4 commits
February 4, 2026 17:01
- fish-shop/syntax-check is a GitHub Action, not a pre-commit hook - Replace with local hook using 'fish --no-execute' - Replace daveparsonsdev/pre-commit-vint (mutable master ref) with local hook - Local vint hook uses additional_dependencies to install vim-vint [anthropic/claude-opus-4-5]
- Replace flake8 with ruff (linting + formatting) - Remove vint (incompatible with Python 3.14) - Remove extraterm scripts (no longer used) - Exclude third-party files (__bass.py, ipython_config.py) - Add check-merge-conflict, check-json, check-toml hooks - Update README with current hook list [anthropic/claude-opus-4-5]
- Fix bash syntax in setup-generic (was using fish 'set' syntax) - Disable yamllint key-ordering rule (too strict) - Increase yamllint line-length to 120 - Install fish in CI workflow for syntax checking - Use Python 3.13 in CI (3.14 has compatibility issues) - Improve cache key for pre-commit [anthropic/claude-opus-4-5]
- Remove +x from config files that shouldn't be executable - Fix markdown formatting (blank lines around headings/code blocks) [anthropic/claude-opus-4-5]
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Summary
.pre-commit-config.yamlfor Shell, Fish, Python, YAML, and Vim filesChanges
Enhanced Pre-commit Configuration
Added new validation hooks:
linters/.yamllintconfig.shfiles.fishfileslinters/.config/flake8config.vimfiles andvimrcModernized CI Workflow
pre-commit/action@v3.0.1pull_requesttrigger for PR validationDocumentation
Benefits
✅ Comprehensive validation covering all file types in the repository
✅ Consistent validation locally and in CI
✅ Faster CI runs with environment caching
✅ Reuses existing linter configurations from
linters/directory✅ Simplified workflow maintenance (single pre-commit action vs multiple custom jobs)
Test plan
pre-commit run --all-filespasses locally🤖 Generated with Claude Code
Note
Medium Risk
Moderate risk because it changes CI gates and adds auto-fixing linters (e.g.,
ruff --fix) that can rewrite files and potentially cause new CI failures until the repo conforms.Overview
Adopts
pre-commitas the primary validation layer by adding a new.pre-commit-config.yamlwith broader checks (shebang/executable sanity, YAML/JSON/TOML validation,shellcheck, fish syntax via a local hook,rufflint+format,yamllint,markdownlint,gitleaks, and conventional commit enforcement).Simplifies and modernizes CI by replacing the prior fish/vim lint jobs with a single
pre-commitGitHub Actions workflow, addingpull_requesttriggering, and caching~/.cache/pre-commit.Also removes legacy Extraterm helper scripts from
.config/fish/extraterm/, tweakslinters/.yamllintto relaxkey-orderingand set line length to 120, updatesREADME.mdwith pre-commit usage docs, and fixes minor bash correctness insetup-generic(env var export + quoting for krew installer variables).Written by Cursor Bugbot for commit d7f427a. This will update automatically on new commits. Configure here.