Skip to content

list: show fallback recipes when fallback is enabled#3097

Open
veeceey wants to merge 1 commit intocasey:masterfrom
veeceey:feat/issue-1500-list-fallback-recipes
Open

list: show fallback recipes when fallback is enabled#3097
veeceey wants to merge 1 commit intocasey:masterfrom
veeceey:feat/issue-1500-list-fallback-recipes

Conversation

@veeceey
Copy link

@veeceey veeceey commented Feb 23, 2026

When set fallback is active, just --list now walks up the directory tree and also displays recipes from parent justfiles. Each parent's recipes appear under a clearly labeled heading:

Available recipes:
    child-recipe # A child recipe

# Fallback recipes from /path/to/parent
Available recipes:
    build         # Another one
    parent-recipe # A parent recipe

It keeps walking as long as each parent also has set fallback enabled, and respects the same search config constraints as the run fallback logic (only works with directory-based search, not --justfile).

Changes:

  • Search now derives Clone so we can iterate parent directories
  • list() takes loader and search parameters to compile parent justfiles
  • Added integration test

Manual test results:

$ cd /tmp/just-test/sub && just --list
Available recipes:
    child-recipe # A child recipe

# Fallback recipes from /private/tmp/just-test
Available recipes:
    build         # Another one
    parent-recipe # A parent recipe

All existing fallback (14) and list (45) tests pass.

Fixes #1500

When `set fallback` is active and `just --list` is run, the output now
also includes recipes from parent justfiles, displayed under a
"Fallback recipes from <path>" heading. This walks up the directory
tree, loading each parent justfile until one without fallback is found.

Fixes casey#1500
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"just --list" should list fallback recipes

1 participant