Summary
Add linting tools for common configuration and documentation formats (YAML and Markdown).
Tools to Add
1. yamllint (YAML Linter)
- Purpose: Linter for YAML files checking syntax and cosmetic problems
- Use cases: Ansible playbooks, Kubernetes manifests, CI/CD configs, docker-compose
- Installation:
- macOS:
brew install yamllint
- Debian:
apt install yamllint or pip install yamllint
- Termux:
pip install yamllint
- Usage:
yamllint <file.yaml> or yamllint .
- Config:
.yamllint.yml or .yamllint.yaml
2. markdownlint-cli (Markdown Linter)
- Purpose: Style checker and lint tool for Markdown files
- Use cases: README files, documentation, wikis
- Installation:
- macOS:
brew install markdownlint-cli
- Debian/Termux:
npm install -g markdownlint-cli
- Usage:
markdownlint <file.md> or markdownlint '**/*.md'
- Config:
.markdownlint.json or .markdownlint.yaml
Implementation Notes
1. Add to packages_data.go
{
command: "yamllint",
platforms: map[PlatformName]InstallMethod{
PlatformDarwin: BrewInstallMethod{Name: "yamllint"},
PlatformDebianLike: PackageInstallMethod{Name: "yamllint"},
PlatformTermux: PipInstallMethod{Name: "yamllint"},
},
},
{
command: "markdownlint",
platforms: map[PlatformName]InstallMethod{
PlatformDarwin: BrewInstallMethod{Name: "markdownlint-cli"},
PlatformDebianLike: NpmInstallMethod{Name: "markdownlint-cli"},
PlatformTermux: NpmInstallMethod{Name: "markdownlint-cli"},
},
Imports: []Import{{Playbook: "setup-npm"}},
},
2. Create setup-config-tools.yml grouping playbook
---
# setup-config-tools.yml - Configuration and documentation format tools
- import_playbook: yamllint.yml # YAML linting
- import_playbook: markdownlint.yml # Markdown linting
# Note: prettier (already in playbooks) can also format YAML and Markdown
3. Add to all.yml
- import_playbook: setup-config-tools.yml
Integration with Existing Tools
- prettier (already in playbooks): Can format both YAML and Markdown
- yamllint: Focuses on linting (catching errors, enforcing style rules)
- markdownlint: Focuses on Markdown-specific rules (headings, lists, links)
Together they provide complete tooling:
- Use prettier for formatting
- Use yamllint/markdownlint for catching issues
Acceptance Criteria
Summary
Add linting tools for common configuration and documentation formats (YAML and Markdown).
Tools to Add
1. yamllint (YAML Linter)
brew install yamllintapt install yamllintorpip install yamllintpip install yamllintyamllint <file.yaml>oryamllint ..yamllint.ymlor.yamllint.yaml2. markdownlint-cli (Markdown Linter)
brew install markdownlint-clinpm install -g markdownlint-climarkdownlint <file.md>ormarkdownlint '**/*.md'.markdownlint.jsonor.markdownlint.yamlImplementation Notes
1. Add to
packages_data.go{ command: "yamllint", platforms: map[PlatformName]InstallMethod{ PlatformDarwin: BrewInstallMethod{Name: "yamllint"}, PlatformDebianLike: PackageInstallMethod{Name: "yamllint"}, PlatformTermux: PipInstallMethod{Name: "yamllint"}, }, }, { command: "markdownlint", platforms: map[PlatformName]InstallMethod{ PlatformDarwin: BrewInstallMethod{Name: "markdownlint-cli"}, PlatformDebianLike: NpmInstallMethod{Name: "markdownlint-cli"}, PlatformTermux: NpmInstallMethod{Name: "markdownlint-cli"}, }, Imports: []Import{{Playbook: "setup-npm"}}, },2. Create
setup-config-tools.ymlgrouping playbook3. Add to
all.ymlIntegration with Existing Tools
Together they provide complete tooling:
Acceptance Criteria
setup-config-tools.ymlgrouping playbookall.ymlto import config tools group