GIT-STAGE-BATCH-INCLUDE(1)

NAME
git-stage-batch-include - stage changes or save them to a batch

SYNOPSIS
git-stage-batch include [--line IDS] [--file [PATH] | --files PATTERN...] [--from BATCH | --to BATCH] [--auto-advance|--no-auto-advance]

git-stage-batch include [--file PATH | --line IDS] [--as TEXT | --as-stdin] [--no-edge-overlap]

DESCRIPTION
include stages selected live changes. With --to it saves live changes to a batch instead of staging them. With --from it applies batch changes to the index and working tree.

OPTIONS

--line, --lines IDS
    Stage or save only specific displayed line IDs.

--file
    [PATH] Operate on one complete file. If PATH is omitted, use the selected hunk's file.

--files PATTERN...
    Operate on all changed files matched by gitignore-style patterns.

--from BATCH
    Stage changes from BATCH. To include a reviewed ambiguity resolution, use BATCH:include:N with --file. The BATCH:apply:N selector belongs to apply and is rejected here.

--to BATCH
    Save selected live changes to BATCH. The batch is created if needed.

--as TEXT
    Stage replacement text for selected lines, or stage TEXT as the full file content when used with --file.

--as-stdin
    Read replacement text from standard input exactly, preserving trailing newlines.

--no-edge-overlap
    Do not strip unchanged edge-overlap lines from replacement text used with --line --as.

--auto-advance
    Select the next hunk after the command completes.

--no-auto-advance
    Leave no hunk selected after the command completes.

EXAMPLES
    git-stage-batch include
    git-stage-batch include --line 1,3,5-7
    git-stage-batch include --file src/app.py
    git-stage-batch include --to cleanup --files 'src/**'
    git-stage-batch include --from cleanup --file src/app.py
    git-stage-batch show --from cleanup:include:2 --file src/app.py
    git-stage-batch include --from cleanup:include:2 --file src/app.py
    some-command | git-stage-batch include --line 1-3 --as-stdin

CANDIDATES
If a plain include --from operation finds multiple safe structural placements, it refuses without changing either the index or working tree and points to show --from BATCH:include. Review the candidate overview, or preview a numbered candidate, then include that same reviewed candidate.

SEE ALSO
git-stage-batch(1), git-stage-batch-show(1), git-stage-batch-discard(1), git-stage-batch-apply(1)