-
-
Notifications
You must be signed in to change notification settings - Fork 668
feat(tools): consolidate development tool installations into unified script [skip ci] #7530
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
We can try this out if you like it. It works OK for me. I'm glad to have the linkchecker and pyspelling available now for when I need them, was never able to get a reliable install before. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
All good, except for the new linkspector commands.
.editorconfig
Outdated
# Script files | ||
[*.sh] | ||
indent_size = 2 | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Recommended by:
- Google https://google.github.io/styleguide/shellguide.html#indentation
- GoatStyles https://styles.goatbytes.io/lang/shell/
And ChatGPT recommends 2 spaces.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't even realize that .editorconfig was changed here. I prefer 2.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added this to .editorconfig
. My IDE uses 2 spaces by default, but declaring a rule for this is better.
## The Issue DDEV's development requires specialized tools like pyspelling, textlint, markdownlint, mkdocs, and linkspector. Currently, .envrc installs these per-project, causing overhead and slow startup. Tools are rarely used for link checking locally due to performance issues. ## How This Commit Solves The Issue ### Unified Installation Script - Created scripts/install-dev-tools.sh for one-time global installation to ~/.ddev-dev-tools/ - Supports macOS (brew) and Linux (apt) with automatic platform detection - Dynamically fetches mkdocs requirements from repository to stay current - Installs all tools: mkdocs, pyspelling, markdownlint, textlint, linkspector, aspell ### Optimized .envrc - Removed 80+ lines of per-project tool installation code - Now simply adds global tools to PATH when available - Shows helpful prompts with installation instructions when tools are missing - Executes instantly instead of checking/installing tools on every cd ### Focused Link Checking - Added make linkspector-changed - checks only files modified since main branch - Added make linkspector-dir DIR=path/ - checks specific directory - Keeps make linkspector for full CI-compatible checking - Makes link checking practical for local development workflows ### Updated Documentation - Updated docs/content/developers/building-contributing.md with unified installation approach - Updated docs/content/developers/testing-docs.md with focused linkspector usage - Clear distinction between automatic .envrc integration vs global shell profile setup ## Implementation Details **Installation Script Features:** - Cross-platform support (macOS/Linux/WSL2) - Virtual environments for Python and Node.js isolation - Fetches latest mkdocs requirements from repository - Comprehensive verification and helpful error messages **PATH Management:** - .envrc automatically adds tools when in DDEV directory - Optional global access via shell profile modification - Graceful fallback with clear installation guidance **Performance Benefits:** - One-time setup instead of per-project overhead - .envrc execution time reduced from seconds to milliseconds - Tools remain current via repository-sourced requirements 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…nces - Added textlint-disable comments around link text that legitimately uses 'Golang' - This preserves the original link titles while avoiding false positives from terminology rules 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…uildkite] The installation instructions for documentation development tools should only be in testing-docs.md since that's specifically about working on documentation. Removed the duplicate section from building-contributing.md to avoid confusion. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…p ci] 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
36da68c
to
26b3b6d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
The Issue
DDEV's development, especially for docs, requires specialized tools like pyspelling, textlint, markdownlint, mkdocs, and linkspector. Currently, .envrc installs these per-project, causing overhead and slow startup. Tools are rarely used for link checking locally due to performance issues.
How This PR Solves The Problem
Unified Installation Script
Optimized .envrc
Focused Link Checking
Updated Documentation
Implementation Details
Installation Script Features:
PATH Management:
Performance Benefits:
🤖 Generated with Claude Code
Co-Authored-By: Claude noreply@anthropic.com