jj-sparse
manages which paths from a Jujutsu working-copy commit are present on disk
TLDR
SYNOPSIS
jj sparse (list | edit | reset | set [options])
DESCRIPTION
jj sparse controls which paths from the working-copy commit are written to the working copy on disk. The commit itself still holds the full tree; only the checked-out files change. That is the Jujutsu counterpart of Git sparse checkout, implemented natively rather than through Git's sparse-checkout machinery.Typical use is a large repo where you only need a subdirectory: `jj sparse set --clear --add lib` leaves `lib/` (and whatever else you add) on disk and omits the rest. `jj sparse list` shows the current patterns; `jj sparse reset` puts every file back.
PARAMETERS
--add PATTERN
Include this path (or other pattern) in the working copy. Repeatable.--remove PATTERN
Drop this path from the working copy. Repeatable.--clear
Start from an empty set (no files present). Usually combined with --add.
SUBCOMMANDS
list
Print the patterns that are currently present in the working copy. A newly cloned or initialized repo has a single pattern matching everything from the repo root, rendered as ..edit
Open an editor on the pattern list so you can add or drop paths by hand.reset
Restore the default pattern set that includes all files in the working copy.set
Update the pattern set from flags. Combine --clear with --add to replace the list, or use --add / --remove to change it in place.
INSTALL
CAVEATS
Subcommand of jj. Patterns apply to the current workspace's working copy, not to other workspaces of the same repo. Git's own sparse-checkout is not used and is listed as unsupported in Jujutsu's Git-compatibility notes.
SEE ALSO
jj(1), jj-file(1), jj-file-list(1), git-sparse-checkout(1)
