docs(functions): add DEPENDENCIES sections to doc headers #168
No Reviewers
Labels
Clear labels
Area/CI
Area/Completions
Area/Components
Area/Config
Area/Docs
Area/Functions
Area/Integrations
Area/Prompt & Theme
Area/Scripts
Area/Tests
Compat/Breaking
Kind/Bug
Kind/Chore
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Performance
Kind/Refactor
Kind/Security
Kind/Testing
good first issue
help wanted
.github/workflows and repository automation
completions/ - tab-completion scripts
The opinionated-component system (C1-C6)
config.fish and conf.d/ - startup and environment
docs/manual/ and the generated manual, man page, and site
functions/ - user-facing functions and helpers
integrations/ - third-party tool wiring
themes/ and prompt appearance
scripts/ - standalone helper scripts
tests/ - the syntax lint and functional suite
Breaking change that won't be backward compatible
Something is not working
Tooling, dependencies, and housekeeping
Documentation changes
Improve existing functionality
New functionality
Makes existing behavior faster or lighter
Restructures code without changing behavior
This is security issue
Issue or pull request related to testing
Well-scoped and self-contained; a good place to start
Maintainer is looking for someone to pick this up
Priority
Critical
1
The priority is critical
Priority
High
2
The priority is high
Priority
Medium
3
The priority is medium
Priority
Low
4
The priority is low
Reviewed
Confirmed
1
Issue has been confirmed
Reviewed
Duplicate
2
This issue or pull request already exists
Reviewed
Invalid
3
Invalid issue
Reviewed
Won't Fix
3
This issue won't be fixed
Status
Blocked
1
Something is blocking this issue or pull request
Status
Need More Info
2
Feedback is required to reproduce issue or to continue work
Status
Abandoned
3
Somebody has started to work on this but abandoned work
Milestone
No items
No Milestone
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: rootiest/fish-config#168
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
Adds a
# DEPENDENCIESsection to every function's doc header that has real dependencies to declare, alongside the existing# CLASSIFICATIONsection — documenting what each function needs for full functionality: other repo functions it calls, and/or external CLI tools it uses (required, or optional-with-graceful-fallback likerm's use oftrash).functions/*.fishwith# CATEGORY) now carry aDEPENDENCIESsection — the ~22 that already had one, plus ~67 newly added. The remaining functions genuinely have none (pure fish logic, or an unguarded/unwhitelisted external tool — see Notes).CATEGORY, COMPONENT, DEPENDENCIES, CLASSIFICATION, SYNOPSIS, ...), matchingdocs/manualtools.py'sSECTIONStuple and every pre-existing example.uses-shadow(...)/bypasses-shadow(...)/self-limiting(...)CLASSIFICATIONtag (e.g.cat.fishcallingls) is not duplicated intoDEPENDENCIES— that system already documents the C1 shadow-command relationship (seedocs/function-classification-schema.md).functions/rm.fishgetsDEPENDENCIES: trash— the exact case this feature was requested for (enhanced trash-based delete, falls back cleanly to plainrmwhentrashisn't installed).Docs
docs/fish-config.mdregenerated viapython3 docs/build-manual.py --concat -o docs/fish-config.mdto pick up the new sections (the man page and Starlight site are left for CI, perCONTRIBUTING.md).CONTRIBUTING.md's header-label table updated: theDEPENDENCIESrow only mentioned "other functions," but ~20 pre-existing examples (and this PR) also use it for external tools — reworded to match actual practice.docs/verify-manual.py'stest_dependencies_resolvebroadened to recognize this repo's other existence-check idioms (command -q,command -v,which, not justtype -q) anddng2avif.fish's dynamicfor cmd in magick ffmpeg avifenc exiftool; type -q $cmdloop — several genuine dependencies (eza,lsd,fastfetch,neofetch,fd,ps,shuf,magick,ffmpeg,avifenc,exiftool, ...) were only ever guarded one of those other ways, not literally viatype -q <name>.Notes
A handful of functions have a real external-tool dependency that isn't guarded by
type -q/command -q/command -v/whichanywhere in the tree yet (so it can't be cited without breakingtest_dependencies_resolve), and were deliberately left out rather than inventing a guard: e.g.nohup(bkg.fish,detach.fish),gitui(gitui.fish),mpv/vlc(play-media.fish),systemd-inhibit(steam-dl.fish,wake-lock.fish),wezterm/konsole(split.fish,spwin.fish,tab.fish), among a few others. Happy to follow up on any of these if you'd like the guard added.Verification
python3 docs/build-manual.py --concat -o docs/fish-config.md— regenerates cleanly.python3 docs/verify-manual.py— 84/84 passed,test_dependencies_resolveincluded,test_render_registry_is_valid_fish_and_round_tripsincluded (this sandbox hasfishinstalled).fish tests/run-tests.fish— 757/757 assertions passed, exit 0, zeroFAILlines.fish -n/fish_indenton touched files — all changed.fishfiles matchfish_indentoutput byte-for-byte; no executable code changed, only comment headers.Transferred from GitHub mirror PR rootiest/fish-config#3 — closed there to avoid a duplicate; canonical PR lives here.
fd64335207tofceddfc43f