When a learner can reproduce a familiar example but a small variation causes confusion, the problem is usually an incomplete model rather than a lack of effort. The fastest useful response is to expose the hidden state and test one boundary at a time.
git check-ignore diagnoses whether pathnames are excluded by Git ignore rules and, with verbose output, identifies the source file, source line and matching pattern. By default it does not report tracked files, because ignore rules concern untracked-path treatment; –no-index can include tracked paths for debugging. Mastery means reading precedence and last-match rules, understanding directory exclusions and negation limits, interpreting exit status, handling stdin and NUL delimiters safely, and keeping ignore diagnosis distinct from sparse-checkout selection. This guide begins with that mechanism, then develops it through worked traces, deliberate mistakes, explained practice and transfer decisions.
The aim is independent reasoning. A learner should be able to predict behaviour, locate the earliest wrong assumption, use a safe diagnostic procedure and defend a design choice in a new project.
Punggol families can use the guide in short sessions around homework, CCAs and rest. The activities are proposed learning exercises, not claims about a physical branch, timetable, class size, fee, school relationship or guaranteed result.
Use disposable data and repositories, preserve backups, and check version-sensitive details against the official source. Current documentation settles a technical contract; observation and explanation turn that contract into usable knowledge.
Find your next learning step
Choose the route that matches the present difficulty. Use the complete index for a systematic course.
Build the model
Chapters 1-4 . Begin here, then continue after the learner can predict, verify and explain.
Use the core tools
Chapters 5-8 . Begin here, then continue after the learner can predict, verify and explain.
Handle boundaries
Chapters 9-12 . Begin here, then continue after the learner can predict, verify and explain.
Debug and verify
Chapters 13-16 . Begin here, then continue after the learner can predict, verify and explain.
Transfer with judgment
Chapters 17-20 . Begin here, then continue after the learner can predict, verify and explain.
Open the full chapter index . Jump to capstone practice . Use the How Studying Works hub . Read the official documentation
Complete chapter index
Chapters 1-4 . Build the model
Chapters 5-8 . Use the core tools
Chapters 9-12 . Handle boundaries
Chapters 13-16 . Debug and verify
The command tests pathnames against Git ignore and exclude rules rather than listing every repository file. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is using it as a general tracked-file search command. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the check-ignore asks an exclusion question chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on using it as a general tracked-file search command. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git check-ignore build/report.txtExplained result. Success with printed output means the pathname matched an exclusion rule under the default mode. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: homework repository. Predict the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command tests pathnames against Git ignore and exclude rules rather than listing every repository file.” Apply this procedure: State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Success with printed output means the pathname matched an exclusion rule under the default mode. For the homework repository, add one near-miss that exposes using it as a general tracked-file search command. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: reading tracker. Contrast the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command tests pathnames against Git ignore and exclude rules rather than listing every repository file.” Apply this procedure: State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Success with printed output means the pathname matched an exclusion rule under the default mode. For the reading tracker, add one near-miss that exposes using it as a general tracked-file search command. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: science project. Stress-test the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command tests pathnames against Git ignore and exclude rules rather than listing every repository file.” Apply this procedure: State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Success with printed output means the pathname matched an exclusion rule under the default mode. For the science project, add one near-miss that exposes using it as a general tracked-file search command. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: CCA website. Explain the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command tests pathnames against Git ignore and exclude rules rather than listing every repository file.” Apply this procedure: State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Success with printed output means the pathname matched an exclusion rule under the default mode. For the CCA website, add one near-miss that exposes using it as a general tracked-file search command. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers using it as a general tracked-file search command.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from check-ignore asks an exclusion question?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing using it as a general tracked-file search command be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny library catalogue with stdin and NUL-safe paths support an automation check. Include one ordinary case, one boundary and one deliberate failure caused by using it as a general tracked-file search command. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: The command tests pathnames against Git ignore and exclude rules rather than listing every repository file. It shows a trace, not only a final value. The ordinary case should demonstrate “Success with printed output means the pathname matched an exclusion rule under the default mode.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For check-ignore asks an exclusion question, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
-q suppresses ordinary output so scripts can branch on zero for matched and one for not matched. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is testing whether stdout is empty instead of reading the process status. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Quiet mode communicates by exit status chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on testing whether stdout is empty instead of reading the process status. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
if git check-ignore -q build/report.txt; then echo ignored; fiExplained result. The shell condition uses the documented status contract. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: science project. Contrast the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-q suppresses ordinary output so scripts can branch on zero for matched and one for not matched.” Apply this procedure: State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The shell condition uses the documented status contract. For the science project, add one near-miss that exposes testing whether stdout is empty instead of reading the process status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: CCA website. Stress-test the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-q suppresses ordinary output so scripts can branch on zero for matched and one for not matched.” Apply this procedure: State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The shell condition uses the documented status contract. For the CCA website, add one near-miss that exposes testing whether stdout is empty instead of reading the process status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: family archive. Explain the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-q suppresses ordinary output so scripts can branch on zero for matched and one for not matched.” Apply this procedure: State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The shell condition uses the documented status contract. For the family archive, add one near-miss that exposes testing whether stdout is empty instead of reading the process status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: library catalogue. Transfer the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-q suppresses ordinary output so scripts can branch on zero for matched and one for not matched.” Apply this procedure: State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The shell condition uses the documented status contract. For the library catalogue, add one near-miss that exposes testing whether stdout is empty instead of reading the process status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers testing whether stdout is empty instead of reading the process status.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Quiet mode communicates by exit status?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing testing whether stdout is empty instead of reading the process status be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny test laboratory with negation, nested directories, tracked files and non-matches are isolated. Include one ordinary case, one boundary and one deliberate failure caused by testing whether stdout is empty instead of reading the process status. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: -q suppresses ordinary output so scripts can branch on zero for matched and one for not matched. It shows a trace, not only a final value. The ordinary case should demonstrate “The shell condition uses the documented status contract.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Quiet mode communicates by exit status, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
-v prints the source, line number, pattern and pathname, revealing why the result occurred. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is editing several ignore files blindly because a path is absent from status. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Verbose mode identifies the winning rule, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Verbose mode identifies the winning rule chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on editing several ignore files blindly because a path is absent from status. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git check-ignore -v build/report.txtExplained result. The record points to the rule that determined the match. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: family archive. Stress-test the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-v prints the source, line number, pattern and pathname, revealing why the result occurred.” Apply this procedure: State the contract for Verbose mode identifies the winning rule, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The record points to the rule that determined the match. For the family archive, add one near-miss that exposes editing several ignore files blindly because a path is absent from status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: library catalogue. Explain the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-v prints the source, line number, pattern and pathname, revealing why the result occurred.” Apply this procedure: State the contract for Verbose mode identifies the winning rule, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The record points to the rule that determined the match. For the library catalogue, add one near-miss that exposes editing several ignore files blindly because a path is absent from status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: test laboratory. Transfer the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-v prints the source, line number, pattern and pathname, revealing why the result occurred.” Apply this procedure: State the contract for Verbose mode identifies the winning rule, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The record points to the rule that determined the match. For the test laboratory, add one near-miss that exposes editing several ignore files blindly because a path is absent from status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: design decision. Predict the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-v prints the source, line number, pattern and pathname, revealing why the result occurred.” Apply this procedure: State the contract for Verbose mode identifies the winning rule, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The record points to the rule that determined the match. For the design decision, add one near-miss that exposes editing several ignore files blindly because a path is absent from status. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers editing several ignore files blindly because a path is absent from status.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Verbose mode identifies the winning rule, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Verbose mode identifies the winning rule?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing editing several ignore files blindly because a path is absent from status be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny design decision with check-ignore is compared with status, add -f, ls-files and sparse-checkout. Include one ordinary case, one boundary and one deliberate failure caused by editing several ignore files blindly because a path is absent from status. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: -v prints the source, line number, pattern and pathname, revealing why the result occurred. It shows a trace, not only a final value. The ordinary case should demonstrate “The record points to the rule that determined the match.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Verbose mode identifies the winning rule, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Verbose mode identifies the winning rule, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
Command-line patterns, per-directory .gitignore files, info/exclude and configured core.excludesFile participate in documented precedence levels. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is assuming the nearest-looking file always wins regardless of source level. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Ignore sources have precedence chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on assuming the nearest-looking file always wins regardless of source level. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git check-ignore -v path/to/output.logExplained result. Verbose evidence identifies the actual source rather than relying on directory intuition. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: test laboratory. Explain the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Command-line patterns, per-directory .gitignore files, info/exclude and configured core.excludesFile participate in documented precedence levels.” Apply this procedure: State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose evidence identifies the actual source rather than relying on directory intuition. For the test laboratory, add one near-miss that exposes assuming the nearest-looking file always wins regardless of source level. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: design decision. Transfer the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Command-line patterns, per-directory .gitignore files, info/exclude and configured core.excludesFile participate in documented precedence levels.” Apply this procedure: State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose evidence identifies the actual source rather than relying on directory intuition. For the design decision, add one near-miss that exposes assuming the nearest-looking file always wins regardless of source level. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: homework repository. Predict the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Command-line patterns, per-directory .gitignore files, info/exclude and configured core.excludesFile participate in documented precedence levels.” Apply this procedure: State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose evidence identifies the actual source rather than relying on directory intuition. For the homework repository, add one near-miss that exposes assuming the nearest-looking file always wins regardless of source level. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: reading tracker. Contrast the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Command-line patterns, per-directory .gitignore files, info/exclude and configured core.excludesFile participate in documented precedence levels.” Apply this procedure: State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose evidence identifies the actual source rather than relying on directory intuition. For the reading tracker, add one near-miss that exposes assuming the nearest-looking file always wins regardless of source level. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers assuming the nearest-looking file always wins regardless of source level.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Ignore sources have precedence?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing assuming the nearest-looking file always wins regardless of source level be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny homework repository with generated answer caches are ignored while source notes remain visible. Include one ordinary case, one boundary and one deliberate failure caused by assuming the nearest-looking file always wins regardless of source level. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: Command-line patterns, per-directory .gitignore files, info/exclude and configured core.excludesFile participate in documented precedence levels. It shows a trace, not only a final value. The ordinary case should demonstrate “Verbose evidence identifies the actual source rather than relying on directory intuition.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Ignore sources have precedence, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
When multiple patterns at the same precedence level match, the last applicable pattern determines the result. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is stopping at the first textual match in a .gitignore file. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Within one level the last match decides, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Within one level the last match decides chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on stopping at the first textual match in a .gitignore file. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
printf '*.log\n!important.log\n' > .gitignore
git check-ignore -v important.logExplained result. The later negation can make important.log non-ignored when its parent path remains traversable. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: homework repository. Transfer the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “When multiple patterns at the same precedence level match, the last applicable pattern determines the result.” Apply this procedure: State the contract for Within one level the last match decides, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation can make important.log non-ignored when its parent path remains traversable. For the homework repository, add one near-miss that exposes stopping at the first textual match in a .gitignore file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: reading tracker. Predict the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “When multiple patterns at the same precedence level match, the last applicable pattern determines the result.” Apply this procedure: State the contract for Within one level the last match decides, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation can make important.log non-ignored when its parent path remains traversable. For the reading tracker, add one near-miss that exposes stopping at the first textual match in a .gitignore file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: science project. Contrast the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “When multiple patterns at the same precedence level match, the last applicable pattern determines the result.” Apply this procedure: State the contract for Within one level the last match decides, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation can make important.log non-ignored when its parent path remains traversable. For the science project, add one near-miss that exposes stopping at the first textual match in a .gitignore file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: CCA website. Stress-test the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “When multiple patterns at the same precedence level match, the last applicable pattern determines the result.” Apply this procedure: State the contract for Within one level the last match decides, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation can make important.log non-ignored when its parent path remains traversable. For the CCA website, add one near-miss that exposes stopping at the first textual match in a .gitignore file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers stopping at the first textual match in a .gitignore file.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Within one level the last match decides, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Within one level the last match decides?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing stopping at the first textual match in a .gitignore file be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny reading tracker with a nested .gitignore explains why one export path disappears from status. Include one ordinary case, one boundary and one deliberate failure caused by stopping at the first textual match in a .gitignore file. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: When multiple patterns at the same precedence level match, the last applicable pattern determines the result. It shows a trace, not only a final value. The ordinary case should demonstrate “The later negation can make important.log non-ignored when its parent path remains traversable.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Within one level the last match decides, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Within one level the last match decides, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
A negation pattern can re-include a previously excluded path subject to Git’s directory traversal rules. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is reading exclamation as a shell operator rather than ignore-pattern syntax. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for A leading exclamation mark negates, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the A leading exclamation mark negates chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on reading exclamation as a shell operator rather than ignore-pattern syntax. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
printf '*.txt\n!README.txt\n' > .gitignore
git check-ignore -v README.txtExplained result. The later negation reverses the earlier file pattern for README.txt. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: science project. Predict the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A negation pattern can re-include a previously excluded path subject to Git’s directory traversal rules.” Apply this procedure: State the contract for A leading exclamation mark negates, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation reverses the earlier file pattern for README.txt. For the science project, add one near-miss that exposes reading exclamation as a shell operator rather than ignore-pattern syntax. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: CCA website. Contrast the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A negation pattern can re-include a previously excluded path subject to Git’s directory traversal rules.” Apply this procedure: State the contract for A leading exclamation mark negates, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation reverses the earlier file pattern for README.txt. For the CCA website, add one near-miss that exposes reading exclamation as a shell operator rather than ignore-pattern syntax. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: family archive. Stress-test the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A negation pattern can re-include a previously excluded path subject to Git’s directory traversal rules.” Apply this procedure: State the contract for A leading exclamation mark negates, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation reverses the earlier file pattern for README.txt. For the family archive, add one near-miss that exposes reading exclamation as a shell operator rather than ignore-pattern syntax. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: library catalogue. Explain the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A negation pattern can re-include a previously excluded path subject to Git’s directory traversal rules.” Apply this procedure: State the contract for A leading exclamation mark negates, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The later negation reverses the earlier file pattern for README.txt. For the library catalogue, add one near-miss that exposes reading exclamation as a shell operator rather than ignore-pattern syntax. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers reading exclamation as a shell operator rather than ignore-pattern syntax.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for A leading exclamation mark negates, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from A leading exclamation mark negates?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing reading exclamation as a shell operator rather than ignore-pattern syntax be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny science project with large derived data are diagnosed without hiding source measurements. Include one ordinary case, one boundary and one deliberate failure caused by reading exclamation as a shell operator rather than ignore-pattern syntax. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: A negation pattern can re-include a previously excluded path subject to Git’s directory traversal rules. It shows a trace, not only a final value. The ordinary case should demonstrate “The later negation reverses the earlier file pattern for README.txt.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for A leading exclamation mark negates, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For A leading exclamation mark negates, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
CHAPTER 7 OF 20 . Use the core tools
7. Excluded parent directories limit re-inclusion
Git cannot re-include a file when an ancestor directory itself remains excluded, because excluded directories are not traversed for performance. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is adding only a child negation after ignoring its directory and expecting discovery. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Excluded parent directories limit re-inclusion chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on adding only a child negation after ignoring its directory and expecting discovery. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
printf 'dir/\n!dir/file.txt\n' > .gitignoreExplained result. The parent-directory rule must be designed so Git can descend before a child re-inclusion can matter. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: family archive. Contrast the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Git cannot re-include a file when an ancestor directory itself remains excluded, because excluded directories are not traversed for performance.” Apply this procedure: State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The parent-directory rule must be designed so Git can descend before a child re-inclusion can matter. For the family archive, add one near-miss that exposes adding only a child negation after ignoring its directory and expecting discovery. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: library catalogue. Stress-test the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Git cannot re-include a file when an ancestor directory itself remains excluded, because excluded directories are not traversed for performance.” Apply this procedure: State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The parent-directory rule must be designed so Git can descend before a child re-inclusion can matter. For the library catalogue, add one near-miss that exposes adding only a child negation after ignoring its directory and expecting discovery. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: test laboratory. Explain the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Git cannot re-include a file when an ancestor directory itself remains excluded, because excluded directories are not traversed for performance.” Apply this procedure: State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The parent-directory rule must be designed so Git can descend before a child re-inclusion can matter. For the test laboratory, add one near-miss that exposes adding only a child negation after ignoring its directory and expecting discovery. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: design decision. Transfer the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Git cannot re-include a file when an ancestor directory itself remains excluded, because excluded directories are not traversed for performance.” Apply this procedure: State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The parent-directory rule must be designed so Git can descend before a child re-inclusion can matter. For the design decision, add one near-miss that exposes adding only a child negation after ignoring its directory and expecting discovery. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers adding only a child negation after ignoring its directory and expecting discovery.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Excluded parent directories limit re-inclusion?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing adding only a child negation after ignoring its directory and expecting discovery be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny CCA website with a global exclude and repository rule compete for one path. Include one ordinary case, one boundary and one deliberate failure caused by adding only a child negation after ignoring its directory and expecting discovery. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: Git cannot re-include a file when an ancestor directory itself remains excluded, because excluded directories are not traversed for performance. It shows a trace, not only a final value. The ordinary case should demonstrate “The parent-directory rule must be designed so Git can descend before a child re-inclusion can matter.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Excluded parent directories limit re-inclusion, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
check-ignore normally suppresses tracked files because ignore rules do not make tracked content untracked. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is concluding a rule does not exist because the named file is already in the index. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Tracked files are hidden by default, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Tracked files are hidden by default chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on concluding a rule does not exist because the named file is already in the index. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git add tracked.log
git check-ignore -v tracked.logExplained result. The default command produces no match report for the tracked pathname. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: test laboratory. Stress-test the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore normally suppresses tracked files because ignore rules do not make tracked content untracked.” Apply this procedure: State the contract for Tracked files are hidden by default, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The default command produces no match report for the tracked pathname. For the test laboratory, add one near-miss that exposes concluding a rule does not exist because the named file is already in the index. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: design decision. Explain the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore normally suppresses tracked files because ignore rules do not make tracked content untracked.” Apply this procedure: State the contract for Tracked files are hidden by default, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The default command produces no match report for the tracked pathname. For the design decision, add one near-miss that exposes concluding a rule does not exist because the named file is already in the index. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: homework repository. Transfer the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore normally suppresses tracked files because ignore rules do not make tracked content untracked.” Apply this procedure: State the contract for Tracked files are hidden by default, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The default command produces no match report for the tracked pathname. For the homework repository, add one near-miss that exposes concluding a rule does not exist because the named file is already in the index. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: reading tracker. Predict the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore normally suppresses tracked files because ignore rules do not make tracked content untracked.” Apply this procedure: State the contract for Tracked files are hidden by default, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The default command produces no match report for the tracked pathname. For the reading tracker, add one near-miss that exposes concluding a rule does not exist because the named file is already in the index. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers concluding a rule does not exist because the named file is already in the index.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Tracked files are hidden by default, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Tracked files are hidden by default?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing concluding a rule does not exist because the named file is already in the index be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny family archive with a tracked file is tested with –no-index rather than misclassified. Include one ordinary case, one boundary and one deliberate failure caused by concluding a rule does not exist because the named file is already in the index. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: check-ignore normally suppresses tracked files because ignore rules do not make tracked content untracked. It shows a trace, not only a final value. The ordinary case should demonstrate “The default command produces no match report for the tracked pathname.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Tracked files are hidden by default, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Tracked files are hidden by default, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
–no-index removes the index check so a tracked pathname can be tested against ignore patterns. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is using –no-index as if it removed the file from version control. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for –no-index diagnoses tracked paths, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the –no-index diagnoses tracked paths chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on using –no-index as if it removed the file from version control. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git check-ignore -v --no-index tracked.logExplained result. The matching rule can be shown, while the file remains tracked. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: homework repository. Explain the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–no-index removes the index check so a tracked pathname can be tested against ignore patterns.” Apply this procedure: State the contract for –no-index diagnoses tracked paths, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The matching rule can be shown, while the file remains tracked. For the homework repository, add one near-miss that exposes using –no-index as if it removed the file from version control. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: reading tracker. Transfer the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–no-index removes the index check so a tracked pathname can be tested against ignore patterns.” Apply this procedure: State the contract for –no-index diagnoses tracked paths, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The matching rule can be shown, while the file remains tracked. For the reading tracker, add one near-miss that exposes using –no-index as if it removed the file from version control. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: science project. Predict the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–no-index removes the index check so a tracked pathname can be tested against ignore patterns.” Apply this procedure: State the contract for –no-index diagnoses tracked paths, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The matching rule can be shown, while the file remains tracked. For the science project, add one near-miss that exposes using –no-index as if it removed the file from version control. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: CCA website. Contrast the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–no-index removes the index check so a tracked pathname can be tested against ignore patterns.” Apply this procedure: State the contract for –no-index diagnoses tracked paths, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The matching rule can be shown, while the file remains tracked. For the CCA website, add one near-miss that exposes using –no-index as if it removed the file from version control. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers using –no-index as if it removed the file from version control.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for –no-index diagnoses tracked paths, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from –no-index diagnoses tracked paths?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing using –no-index as if it removed the file from version control be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny library catalogue with stdin and NUL-safe paths support an automation check. Include one ordinary case, one boundary and one deliberate failure caused by using –no-index as if it removed the file from version control. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: –no-index removes the index check so a tracked pathname can be tested against ignore patterns. It shows a trace, not only a final value. The ordinary case should demonstrate “The matching rule can be shown, while the file remains tracked.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for –no-index diagnoses tracked paths, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For –no-index diagnoses tracked paths, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
–stdin reads pathnames from standard input instead of command-line arguments. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is starting a separate Git process for every path in a large list. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the –stdin accepts many pathnames chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on starting a separate Git process for every path in a large list. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
printf 'build/a.txt\ncache/b.bin\n' | git check-ignore --stdin -vExplained result. Each input path is checked under one command invocation. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: science project. Transfer the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–stdin reads pathnames from standard input instead of command-line arguments.” Apply this procedure: State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each input path is checked under one command invocation. For the science project, add one near-miss that exposes starting a separate Git process for every path in a large list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: CCA website. Predict the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–stdin reads pathnames from standard input instead of command-line arguments.” Apply this procedure: State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each input path is checked under one command invocation. For the CCA website, add one near-miss that exposes starting a separate Git process for every path in a large list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: family archive. Contrast the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–stdin reads pathnames from standard input instead of command-line arguments.” Apply this procedure: State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each input path is checked under one command invocation. For the family archive, add one near-miss that exposes starting a separate Git process for every path in a large list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: library catalogue. Stress-test the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “–stdin reads pathnames from standard input instead of command-line arguments.” Apply this procedure: State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each input path is checked under one command invocation. For the library catalogue, add one near-miss that exposes starting a separate Git process for every path in a large list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers starting a separate Git process for every path in a large list.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from –stdin accepts many pathnames?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing starting a separate Git process for every path in a large list be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny test laboratory with negation, nested directories, tracked files and non-matches are isolated. Include one ordinary case, one boundary and one deliberate failure caused by starting a separate Git process for every path in a large list. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: –stdin reads pathnames from standard input instead of command-line arguments. It shows a trace, not only a final value. The ordinary case should demonstrate “Each input path is checked under one command invocation.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For –stdin accepts many pathnames, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
With –stdin, -z treats inputs as NUL-delimited and also uses NUL output fields so newline-containing names can be handled safely. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is building a newline parser for arbitrary repository pathnames. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for NUL input protects unusual pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the NUL input protects unusual pathnames chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on building a newline parser for arbitrary repository pathnames. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
printf 'build/a.txt\0' | git check-ignore --stdin -z -vExplained result. NUL boundaries make the protocol unambiguous for automation. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: family archive. Predict the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “With –stdin, -z treats inputs as NUL-delimited and also uses NUL output fields so newline-containing names can be handled safely.” Apply this procedure: State the contract for NUL input protects unusual pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: NUL boundaries make the protocol unambiguous for automation. For the family archive, add one near-miss that exposes building a newline parser for arbitrary repository pathnames. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: library catalogue. Contrast the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “With –stdin, -z treats inputs as NUL-delimited and also uses NUL output fields so newline-containing names can be handled safely.” Apply this procedure: State the contract for NUL input protects unusual pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: NUL boundaries make the protocol unambiguous for automation. For the library catalogue, add one near-miss that exposes building a newline parser for arbitrary repository pathnames. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: test laboratory. Stress-test the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “With –stdin, -z treats inputs as NUL-delimited and also uses NUL output fields so newline-containing names can be handled safely.” Apply this procedure: State the contract for NUL input protects unusual pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: NUL boundaries make the protocol unambiguous for automation. For the test laboratory, add one near-miss that exposes building a newline parser for arbitrary repository pathnames. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: design decision. Explain the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “With –stdin, -z treats inputs as NUL-delimited and also uses NUL output fields so newline-containing names can be handled safely.” Apply this procedure: State the contract for NUL input protects unusual pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: NUL boundaries make the protocol unambiguous for automation. For the design decision, add one near-miss that exposes building a newline parser for arbitrary repository pathnames. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers building a newline parser for arbitrary repository pathnames.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for NUL input protects unusual pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from NUL input protects unusual pathnames?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing building a newline parser for arbitrary repository pathnames be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny design decision with check-ignore is compared with status, add -f, ls-files and sparse-checkout. Include one ordinary case, one boundary and one deliberate failure caused by building a newline parser for arbitrary repository pathnames. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: With –stdin, -z treats inputs as NUL-delimited and also uses NUL output fields so newline-containing names can be handled safely. It shows a trace, not only a final value. The ordinary case should demonstrate “NUL boundaries make the protocol unambiguous for automation.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for NUL input protects unusual pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For NUL input protects unusual pathnames, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
-n or –non-matching emits a record for non-matches and is useful only with –verbose, where empty fields mark the absence of a winning pattern. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is expecting -n alone to print a friendly Boolean list. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for –non-matching needs verbose mode, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the –non-matching needs verbose mode chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on expecting -n alone to print a friendly Boolean list. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
printf 'kept.txt\n' | git check-ignore --stdin -v -nExplained result. The verbose record preserves input correspondence even when no pattern matches. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: test laboratory. Contrast the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-n or –non-matching emits a record for non-matches and is useful only with –verbose, where empty fields mark the absence of a winning pattern.” Apply this procedure: State the contract for –non-matching needs verbose mode, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The verbose record preserves input correspondence even when no pattern matches. For the test laboratory, add one near-miss that exposes expecting -n alone to print a friendly Boolean list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: design decision. Stress-test the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-n or –non-matching emits a record for non-matches and is useful only with –verbose, where empty fields mark the absence of a winning pattern.” Apply this procedure: State the contract for –non-matching needs verbose mode, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The verbose record preserves input correspondence even when no pattern matches. For the design decision, add one near-miss that exposes expecting -n alone to print a friendly Boolean list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: homework repository. Explain the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-n or –non-matching emits a record for non-matches and is useful only with –verbose, where empty fields mark the absence of a winning pattern.” Apply this procedure: State the contract for –non-matching needs verbose mode, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The verbose record preserves input correspondence even when no pattern matches. For the homework repository, add one near-miss that exposes expecting -n alone to print a friendly Boolean list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: reading tracker. Transfer the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “-n or –non-matching emits a record for non-matches and is useful only with –verbose, where empty fields mark the absence of a winning pattern.” Apply this procedure: State the contract for –non-matching needs verbose mode, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The verbose record preserves input correspondence even when no pattern matches. For the reading tracker, add one near-miss that exposes expecting -n alone to print a friendly Boolean list. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers expecting -n alone to print a friendly Boolean list.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for –non-matching needs verbose mode, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from –non-matching needs verbose mode?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing expecting -n alone to print a friendly Boolean list be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny homework repository with generated answer caches are ignored while source notes remain visible. Include one ordinary case, one boundary and one deliberate failure caused by expecting -n alone to print a friendly Boolean list. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: -n or –non-matching emits a record for non-matches and is useful only with –verbose, where empty fields mark the absence of a winning pattern. It shows a trace, not only a final value. The ordinary case should demonstrate “The verbose record preserves input correspondence even when no pattern matches.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for –non-matching needs verbose mode, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For –non-matching needs verbose mode, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
CHAPTER 13 OF 20 . Debug and verify
13. Path interpretation follows invocation context
Pathnames are interpreted relative to the worktree and current directory according to documented rules, so scripts should control cwd explicitly. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is running the same relative argument from another directory and calling different output nondeterministic. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Path interpretation follows invocation context chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on running the same relative argument from another directory and calling different output nondeterministic. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git -C /path/to/repo check-ignore -v build/out.txtExplained result. -C establishes the repository context before the relative pathname is evaluated. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: homework repository. Stress-test the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Pathnames are interpreted relative to the worktree and current directory according to documented rules, so scripts should control cwd explicitly.” Apply this procedure: State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: -C establishes the repository context before the relative pathname is evaluated. For the homework repository, add one near-miss that exposes running the same relative argument from another directory and calling different output nondeterministic. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: reading tracker. Explain the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Pathnames are interpreted relative to the worktree and current directory according to documented rules, so scripts should control cwd explicitly.” Apply this procedure: State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: -C establishes the repository context before the relative pathname is evaluated. For the reading tracker, add one near-miss that exposes running the same relative argument from another directory and calling different output nondeterministic. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: science project. Transfer the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Pathnames are interpreted relative to the worktree and current directory according to documented rules, so scripts should control cwd explicitly.” Apply this procedure: State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: -C establishes the repository context before the relative pathname is evaluated. For the science project, add one near-miss that exposes running the same relative argument from another directory and calling different output nondeterministic. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: CCA website. Predict the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Pathnames are interpreted relative to the worktree and current directory according to documented rules, so scripts should control cwd explicitly.” Apply this procedure: State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: -C establishes the repository context before the relative pathname is evaluated. For the CCA website, add one near-miss that exposes running the same relative argument from another directory and calling different output nondeterministic. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers running the same relative argument from another directory and calling different output nondeterministic.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Path interpretation follows invocation context?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing running the same relative argument from another directory and calling different output nondeterministic be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny reading tracker with a nested .gitignore explains why one export path disappears from status. Include one ordinary case, one boundary and one deliberate failure caused by running the same relative argument from another directory and calling different output nondeterministic. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: Pathnames are interpreted relative to the worktree and current directory according to documented rules, so scripts should control cwd explicitly. It shows a trace, not only a final value. The ordinary case should demonstrate “-C establishes the repository context before the relative pathname is evaluated.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Path interpretation follows invocation context, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
CHAPTER 14 OF 20 . Debug and verify
14. Several path arguments are independent checks
The command can test multiple pathnames and prints matching ones in input order under ordinary output. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is assuming one match makes the entire set ignored. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Several path arguments are independent checks, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Several path arguments are independent checks chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on assuming one match makes the entire set ignored. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git check-ignore -v build/a.txt src/main.py cache/xExplained result. Each pathname receives its own match or non-match outcome. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: science project. Explain the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command can test multiple pathnames and prints matching ones in input order under ordinary output.” Apply this procedure: State the contract for Several path arguments are independent checks, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each pathname receives its own match or non-match outcome. For the science project, add one near-miss that exposes assuming one match makes the entire set ignored. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: CCA website. Transfer the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command can test multiple pathnames and prints matching ones in input order under ordinary output.” Apply this procedure: State the contract for Several path arguments are independent checks, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each pathname receives its own match or non-match outcome. For the CCA website, add one near-miss that exposes assuming one match makes the entire set ignored. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: family archive. Predict the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command can test multiple pathnames and prints matching ones in input order under ordinary output.” Apply this procedure: State the contract for Several path arguments are independent checks, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each pathname receives its own match or non-match outcome. For the family archive, add one near-miss that exposes assuming one match makes the entire set ignored. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: library catalogue. Contrast the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The command can test multiple pathnames and prints matching ones in input order under ordinary output.” Apply this procedure: State the contract for Several path arguments are independent checks, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Each pathname receives its own match or non-match outcome. For the library catalogue, add one near-miss that exposes assuming one match makes the entire set ignored. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers assuming one match makes the entire set ignored.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Several path arguments are independent checks, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Several path arguments are independent checks?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing assuming one match makes the entire set ignored be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny science project with large derived data are diagnosed without hiding source measurements. Include one ordinary case, one boundary and one deliberate failure caused by assuming one match makes the entire set ignored. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: The command can test multiple pathnames and prints matching ones in input order under ordinary output. It shows a trace, not only a final value. The ordinary case should demonstrate “Each pathname receives its own match or non-match outcome.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Several path arguments are independent checks, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Several path arguments are independent checks, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
core.excludesFile can hide personal editor or operating-system files without committing repository policy. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is placing a team-required build rule only in one learner’s global file. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Global excludes are user-level policy, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Global excludes are user-level policy chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on placing a team-required build rule only in one learner’s global file. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git config --get core.excludesFileExplained result. The configured path identifies the personal exclude source; shared project rules belong in committed .gitignore files. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: family archive. Transfer the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “core.excludesFile can hide personal editor or operating-system files without committing repository policy.” Apply this procedure: State the contract for Global excludes are user-level policy, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The configured path identifies the personal exclude source; shared project rules belong in committed .gitignore files. For the family archive, add one near-miss that exposes placing a team-required build rule only in one learner’s global file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: library catalogue. Predict the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “core.excludesFile can hide personal editor or operating-system files without committing repository policy.” Apply this procedure: State the contract for Global excludes are user-level policy, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The configured path identifies the personal exclude source; shared project rules belong in committed .gitignore files. For the library catalogue, add one near-miss that exposes placing a team-required build rule only in one learner’s global file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: test laboratory. Contrast the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “core.excludesFile can hide personal editor or operating-system files without committing repository policy.” Apply this procedure: State the contract for Global excludes are user-level policy, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The configured path identifies the personal exclude source; shared project rules belong in committed .gitignore files. For the test laboratory, add one near-miss that exposes placing a team-required build rule only in one learner’s global file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: design decision. Stress-test the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “core.excludesFile can hide personal editor or operating-system files without committing repository policy.” Apply this procedure: State the contract for Global excludes are user-level policy, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The configured path identifies the personal exclude source; shared project rules belong in committed .gitignore files. For the design decision, add one near-miss that exposes placing a team-required build rule only in one learner’s global file. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers placing a team-required build rule only in one learner’s global file.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Global excludes are user-level policy, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Global excludes are user-level policy?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing placing a team-required build rule only in one learner’s global file be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny CCA website with a global exclude and repository rule compete for one path. Include one ordinary case, one boundary and one deliberate failure caused by placing a team-required build rule only in one learner’s global file. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: core.excludesFile can hide personal editor or operating-system files without committing repository policy. It shows a trace, not only a final value. The ordinary case should demonstrate “The configured path identifies the personal exclude source; shared project rules belong in committed .gitignore files.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Global excludes are user-level policy, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Global excludes are user-level policy, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
CHAPTER 16 OF 20 . Debug and verify
16. info exclude is repository-local and uncommitted
The repository’s .git/info/exclude holds local rules that are not distributed with commits. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is expecting collaborators to receive an info/exclude pattern. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the info exclude is repository-local and uncommitted chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on expecting collaborators to receive an info/exclude pattern. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
printf 'scratch/\n' >> .git/info/exclude
git check-ignore -v scratch/note.txtExplained result. Verbose output can name .git/info/exclude, revealing that the policy is local. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: test laboratory. Predict the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The repository’s .git/info/exclude holds local rules that are not distributed with commits.” Apply this procedure: State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose output can name .git/info/exclude, revealing that the policy is local. For the test laboratory, add one near-miss that exposes expecting collaborators to receive an info/exclude pattern. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: design decision. Contrast the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The repository’s .git/info/exclude holds local rules that are not distributed with commits.” Apply this procedure: State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose output can name .git/info/exclude, revealing that the policy is local. For the design decision, add one near-miss that exposes expecting collaborators to receive an info/exclude pattern. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: homework repository. Stress-test the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The repository’s .git/info/exclude holds local rules that are not distributed with commits.” Apply this procedure: State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose output can name .git/info/exclude, revealing that the policy is local. For the homework repository, add one near-miss that exposes expecting collaborators to receive an info/exclude pattern. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: reading tracker. Explain the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “The repository’s .git/info/exclude holds local rules that are not distributed with commits.” Apply this procedure: State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Verbose output can name .git/info/exclude, revealing that the policy is local. For the reading tracker, add one near-miss that exposes expecting collaborators to receive an info/exclude pattern. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers expecting collaborators to receive an info/exclude pattern.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from info exclude is repository-local and uncommitted?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing expecting collaborators to receive an info/exclude pattern be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny family archive with a tracked file is tested with –no-index rather than misclassified. Include one ordinary case, one boundary and one deliberate failure caused by expecting collaborators to receive an info/exclude pattern. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: The repository’s .git/info/exclude holds local rules that are not distributed with commits. It shows a trace, not only a final value. The ordinary case should demonstrate “Verbose output can name .git/info/exclude, revealing that the policy is local.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For info exclude is repository-local and uncommitted, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
A .gitignore lower in the directory tree can apply patterns relative to its location and override applicable lower-priority effects for descendants. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is interpreting every pattern as rooted at the repository top. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Nested gitignore files refine subtrees, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Nested gitignore files refine subtrees chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on interpreting every pattern as rooted at the repository top. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
mkdir -p docs
echo '*.tmp' > docs/.gitignore
git check-ignore -v docs/draft.tmpExplained result. The source and pattern fields show the nested rule applied to that subtree. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: homework repository. Contrast the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A .gitignore lower in the directory tree can apply patterns relative to its location and override applicable lower-priority effects for descendants.” Apply this procedure: State the contract for Nested gitignore files refine subtrees, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The source and pattern fields show the nested rule applied to that subtree. For the homework repository, add one near-miss that exposes interpreting every pattern as rooted at the repository top. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: reading tracker. Stress-test the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A .gitignore lower in the directory tree can apply patterns relative to its location and override applicable lower-priority effects for descendants.” Apply this procedure: State the contract for Nested gitignore files refine subtrees, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The source and pattern fields show the nested rule applied to that subtree. For the reading tracker, add one near-miss that exposes interpreting every pattern as rooted at the repository top. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: science project. Explain the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A .gitignore lower in the directory tree can apply patterns relative to its location and override applicable lower-priority effects for descendants.” Apply this procedure: State the contract for Nested gitignore files refine subtrees, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The source and pattern fields show the nested rule applied to that subtree. For the science project, add one near-miss that exposes interpreting every pattern as rooted at the repository top. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: CCA website. Transfer the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A .gitignore lower in the directory tree can apply patterns relative to its location and override applicable lower-priority effects for descendants.” Apply this procedure: State the contract for Nested gitignore files refine subtrees, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The source and pattern fields show the nested rule applied to that subtree. For the CCA website, add one near-miss that exposes interpreting every pattern as rooted at the repository top. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers interpreting every pattern as rooted at the repository top.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Nested gitignore files refine subtrees, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Nested gitignore files refine subtrees?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing interpreting every pattern as rooted at the repository top be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny library catalogue with stdin and NUL-safe paths support an automation check. Include one ordinary case, one boundary and one deliberate failure caused by interpreting every pattern as rooted at the repository top. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: A .gitignore lower in the directory tree can apply patterns relative to its location and override applicable lower-priority effects for descendants. It shows a trace, not only a final value. The ordinary case should demonstrate “The source and pattern fields show the nested rule applied to that subtree.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Nested gitignore files refine subtrees, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Nested gitignore files refine subtrees, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
check-ignore explains policy; git add -f deliberately overrides ignore handling for a chosen add operation. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is using force before discovering which broad rule caused the problem. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Diagnosis differs from forcing an add, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Diagnosis differs from forcing an add chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on using force before discovering which broad rule caused the problem. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git check-ignore -v artifact.bin
# review before: git add -f artifact.binExplained result. Diagnosis comes first so a narrow policy repair can replace an accidental force habit. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: science project. Stress-test the rule using large derived data are diagnosed without hiding source measurements. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore explains policy; git add -f deliberately overrides ignore handling for a chosen add operation.” Apply this procedure: State the contract for Diagnosis differs from forcing an add, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Diagnosis comes first so a narrow policy repair can replace an accidental force habit. For the science project, add one near-miss that exposes using force before discovering which broad rule caused the problem. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: CCA website. Explain the rule using a global exclude and repository rule compete for one path. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore explains policy; git add -f deliberately overrides ignore handling for a chosen add operation.” Apply this procedure: State the contract for Diagnosis differs from forcing an add, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Diagnosis comes first so a narrow policy repair can replace an accidental force habit. For the CCA website, add one near-miss that exposes using force before discovering which broad rule caused the problem. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: family archive. Transfer the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore explains policy; git add -f deliberately overrides ignore handling for a chosen add operation.” Apply this procedure: State the contract for Diagnosis differs from forcing an add, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Diagnosis comes first so a narrow policy repair can replace an accidental force habit. For the family archive, add one near-miss that exposes using force before discovering which broad rule caused the problem. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: library catalogue. Predict the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “check-ignore explains policy; git add -f deliberately overrides ignore handling for a chosen add operation.” Apply this procedure: State the contract for Diagnosis differs from forcing an add, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: Diagnosis comes first so a narrow policy repair can replace an accidental force habit. For the library catalogue, add one near-miss that exposes using force before discovering which broad rule caused the problem. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers using force before discovering which broad rule caused the problem.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Diagnosis differs from forcing an add, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Diagnosis differs from forcing an add?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing using force before discovering which broad rule caused the problem be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny test laboratory with negation, nested directories, tracked files and non-matches are isolated. Include one ordinary case, one boundary and one deliberate failure caused by using force before discovering which broad rule caused the problem. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: check-ignore explains policy; git add -f deliberately overrides ignore handling for a chosen add operation. It shows a trace, not only a final value. The ordinary case should demonstrate “Diagnosis comes first so a narrow policy repair can replace an accidental force habit.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Diagnosis differs from forcing an add, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Diagnosis differs from forcing an add, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
CHAPTER 19 OF 20 . Transfer with judgment
19. Ignore rules differ from sparse checkout
Ignore rules affect untracked-file visibility and adding, while sparse checkout controls which tracked paths are materialised in the worktree. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is using .gitignore to remove tracked directories from a large working tree. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Ignore rules differ from sparse checkout chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on using .gitignore to remove tracked directories from a large working tree. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git check-ignore -v path
git sparse-checkout listExplained result. The commands answer different questions; a tracked path may be sparse without being ignored. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: family archive. Explain the rule using a tracked file is tested with –no-index rather than misclassified. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Ignore rules affect untracked-file visibility and adding, while sparse checkout controls which tracked paths are materialised in the worktree.” Apply this procedure: State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The commands answer different questions; a tracked path may be sparse without being ignored. For the family archive, add one near-miss that exposes using .gitignore to remove tracked directories from a large working tree. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: library catalogue. Transfer the rule using stdin and NUL-safe paths support an automation check. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Ignore rules affect untracked-file visibility and adding, while sparse checkout controls which tracked paths are materialised in the worktree.” Apply this procedure: State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The commands answer different questions; a tracked path may be sparse without being ignored. For the library catalogue, add one near-miss that exposes using .gitignore to remove tracked directories from a large working tree. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: test laboratory. Predict the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Ignore rules affect untracked-file visibility and adding, while sparse checkout controls which tracked paths are materialised in the worktree.” Apply this procedure: State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The commands answer different questions; a tracked path may be sparse without being ignored. For the test laboratory, add one near-miss that exposes using .gitignore to remove tracked directories from a large working tree. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: design decision. Contrast the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “Ignore rules affect untracked-file visibility and adding, while sparse checkout controls which tracked paths are materialised in the worktree.” Apply this procedure: State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The commands answer different questions; a tracked path may be sparse without being ignored. For the design decision, add one near-miss that exposes using .gitignore to remove tracked directories from a large working tree. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers using .gitignore to remove tracked directories from a large working tree.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Ignore rules differ from sparse checkout?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing using .gitignore to remove tracked directories from a large working tree be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny design decision with check-ignore is compared with status, add -f, ls-files and sparse-checkout. Include one ordinary case, one boundary and one deliberate failure caused by using .gitignore to remove tracked directories from a large working tree. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: Ignore rules affect untracked-file visibility and adding, while sparse checkout controls which tracked paths are materialised in the worktree. It shows a trace, not only a final value. The ordinary case should demonstrate “The commands answer different questions; a tracked path may be sparse without being ignored.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Ignore rules differ from sparse checkout, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
CHAPTER 20 OF 20 . Transfer with judgment
20. Automate with explicit status and delimiters
A robust script fixes its repository cwd, chooses tracked-file policy, uses verbose records for evidence and selects NUL delimiters when pathnames are arbitrary. Treat that sentence as a testable model. A secure learner can point to the relevant input, name the operation, describe the resulting state and identify one observation that would prove the model incomplete.
The high-value mistake in this chapter is parsing human prose or treating every nonzero status as the same failure. It matters because the output may look reasonable while the ownership, ordering, identity or safety rule is wrong. State the contract for Automate with explicit status and delimiters, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.
For the Automate with explicit status and delimiters chapter on Git check-ignore, use a two-column trace during a short Punggol home session. On the left, write the predicted state for this exact mechanism before the tool runs. On the right, record the observation that bears on parsing human prose or treating every nonzero status as the same failure. Explain the earliest difference with one causal sentence, then repeat only the smallest changed case.
Core worked example
git -C "$repo" check-ignore --stdin -z -v -n < paths.zlistExplained result. The protocol preserves one record per input and lets the caller distinguish match, non-match and execution error deliberately. Check the boundary as well as the happy path: ask what happens with an empty input, a duplicate or tied value, an unsupported type, a missing path, a NULL, or a second reference to the same object. Only the relevant boundary should be kept; the list is a prompt for judgment, not a demand to force every case into every example.
Four purposeful transfer cases
Case 1: test laboratory. Transfer the rule using negation, nested directories, tracked files and non-matches are isolated. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A robust script fixes its repository cwd, chooses tracked-file policy, uses verbose records for evidence and selects NUL delimiters when pathnames are arbitrary.” Apply this procedure: State the contract for Automate with explicit status and delimiters, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The protocol preserves one record per input and lets the caller distinguish match, non-match and execution error deliberately. For the test laboratory, add one near-miss that exposes parsing human prose or treating every nonzero status as the same failure. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 2: design decision. Predict the rule using check-ignore is compared with status, add -f, ls-files and sparse-checkout. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A robust script fixes its repository cwd, chooses tracked-file policy, uses verbose records for evidence and selects NUL delimiters when pathnames are arbitrary.” Apply this procedure: State the contract for Automate with explicit status and delimiters, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The protocol preserves one record per input and lets the caller distinguish match, non-match and execution error deliberately. For the design decision, add one near-miss that exposes parsing human prose or treating every nonzero status as the same failure. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 3: homework repository. Contrast the rule using generated answer caches are ignored while source notes remain visible. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A robust script fixes its repository cwd, chooses tracked-file policy, uses verbose records for evidence and selects NUL delimiters when pathnames are arbitrary.” Apply this procedure: State the contract for Automate with explicit status and delimiters, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The protocol preserves one record per input and lets the caller distinguish match, non-match and execution error deliberately. For the homework repository, add one near-miss that exposes parsing human prose or treating every nonzero status as the same failure. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Case 4: reading tracker. Stress-test the rule using a nested .gitignore explains why one export path disappears from status. State the input grain or object graph, the chapter boundary and the intended output before choosing syntax. Change only one variable, so a wrong prediction has a single plausible cause.
Reasoned route. Begin with “A robust script fixes its repository cwd, chooses tracked-file policy, uses verbose records for evidence and selects NUL delimiters when pathnames are arbitrary.” Apply this procedure: State the contract for Automate with explicit status and delimiters, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. The expected mechanism is: The protocol preserves one record per input and lets the caller distinguish match, non-match and execution error deliberately. For the reading tracker, add one near-miss that exposes parsing human prose or treating every nonzero status as the same failure. The answer is complete only when it says why the near-miss fails and how the corrected model transfers to a different project without relying on the original variable names.
Diagnostic route
- Model check: ask the learner to draw or list the exact rows, fields, references, paths or states involved.
- Boundary check: create the smallest input that triggers parsing human prose or treating every nonzero status as the same failure.
- Evidence check: separate a printed value from identity, ordering, ownership, type or repository state.
- Repair check: use the reversible procedure “State the contract for Automate with explicit status and delimiters, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence.” and record the first changed observation.
- Transfer check: repeat the rule in a second context and identify what remains invariant.
A parent does not need to know the final Git check-ignore syntax. For this chapter, useful prompts are: “What did you expect from Automate with explicit status and delimiters?”, “Which state changed first?”, “What evidence tests that prediction?”, and “Can the case exposing parsing human prose or treating every nonzero status as the same failure be made smaller?” The learner, not the parent, should supply the technical explanation.
Practice with an explained answer
Question. Build a tiny homework repository with generated answer caches are ignored while source notes remain visible. Include one ordinary case, one boundary and one deliberate failure caused by parsing human prose or treating every nonzero status as the same failure. Predict each result before using a tool, then report the first point where observation differs from prediction.
Answer guide. A strong response starts with the rule: A robust script fixes its repository cwd, chooses tracked-file policy, uses verbose records for evidence and selects NUL delimiters when pathnames are arbitrary. It shows a trace, not only a final value. The ordinary case should demonstrate “The protocol preserves one record per input and lets the caller distinguish match, non-match and execution error deliberately.” The boundary must exercise the same mechanism at an edge, and the deliberate failure must be repaired with: State the contract for Automate with explicit status and delimiters, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Other data choices are valid when the evidence supports the same causal chain.
Decision and transfer
For Automate with explicit status and delimiters, separate the documented Git check-ignore mechanism from the project policy. State exactly what the technical contract guarantees, then state the project choice about validation, ordering, ownership, performance or recovery. Test whether the same distinction survives one transfer case, and keep stateful experiments disposable and backed up.
Previous chapter . Contents . Next chapter
Parent guide: choose the next useful step
Start with evidence, not a label such as careless. Ask for one prediction and one trace. If the first transition is wrong, rebuild the model. If the model is sound but syntax fails, practise reference use. If routine cases are correct but boundaries fail, vary ties, defaults, unsupported inputs, ownership or missing paths. If explanations transfer, move to a small project.
Keep a weekly record with four lines: concept, prediction, observed difference and next test. Stop when fatigue replaces reasoning. A smaller case tomorrow is more useful than another hour of copying tonight.
Seek specialist help when cause and effect remain invisible after examples are reduced, when accessibility or data-loss implications are unclear, or when an important repository, database or application state may be at risk. Good support should make the learner’s reasoning more independent.
Capstone practice with explained routes
1. homework repository: model, boundary and recovery
Create a small homework repository using generated answer caches are ignored while source notes remain visible. Combine “check-ignore asks an exclusion question” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: The command tests pathnames against Git ignore and exclude rules rather than listing every repository file. Apply: State the contract for check-ignore asks an exclusion question, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: Success with printed output means the pathname matched an exclusion rule under the default mode. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
2. reading tracker: model, boundary and recovery
Create a small reading tracker using a nested .gitignore explains why one export path disappears from status. Combine “Ignore sources have precedence” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: Command-line patterns, per-directory .gitignore files, info/exclude and configured core.excludesFile participate in documented precedence levels. Apply: State the contract for Ignore sources have precedence, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: Verbose evidence identifies the actual source rather than relying on directory intuition. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
3. science project: model, boundary and recovery
Create a small science project using large derived data are diagnosed without hiding source measurements. Combine “Excluded parent directories limit re-inclusion” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: Git cannot re-include a file when an ancestor directory itself remains excluded, because excluded directories are not traversed for performance. Apply: State the contract for Excluded parent directories limit re-inclusion, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: The parent-directory rule must be designed so Git can descend before a child re-inclusion can matter. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
4. CCA website: model, boundary and recovery
Create a small CCA website using a global exclude and repository rule compete for one path. Combine “–stdin accepts many pathnames” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: –stdin reads pathnames from standard input instead of command-line arguments. Apply: State the contract for –stdin accepts many pathnames, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: Each input path is checked under one command invocation. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
5. family archive: model, boundary and recovery
Create a small family archive using a tracked file is tested with –no-index rather than misclassified. Combine “Path interpretation follows invocation context” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: Pathnames are interpreted relative to the worktree and current directory according to documented rules, so scripts should control cwd explicitly. Apply: State the contract for Path interpretation follows invocation context, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: -C establishes the repository context before the relative pathname is evaluated. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
6. library catalogue: model, boundary and recovery
Create a small library catalogue using stdin and NUL-safe paths support an automation check. Combine “info exclude is repository-local and uncommitted” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: The repository’s .git/info/exclude holds local rules that are not distributed with commits. Apply: State the contract for info exclude is repository-local and uncommitted, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: Verbose output can name .git/info/exclude, revealing that the policy is local. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
7. test laboratory: model, boundary and recovery
Create a small test laboratory using negation, nested directories, tracked files and non-matches are isolated. Combine “Ignore rules differ from sparse checkout” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: Ignore rules affect untracked-file visibility and adding, while sparse checkout controls which tracked paths are materialised in the worktree. Apply: State the contract for Ignore rules differ from sparse checkout, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: The commands answer different questions; a tracked path may be sparse without being ignored. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
8. design decision: model, boundary and recovery
Create a small design decision using check-ignore is compared with status, add -f, ls-files and sparse-checkout. Combine “Quiet mode communicates by exit status” with one later chapter. Include an ordinary case, a boundary, a deliberate failure and a recovery. Write the expected state before each operation.
Explained route. Start with: -q suppresses ordinary output so scripts can branch on zero for matched and one for not matched. Apply: State the contract for Quiet mode communicates by exit status, predict one ordinary case and one boundary, run the smallest disposable test, then explain the earliest difference between prediction and evidence. Verify: The shell condition uses the documented status contract. Then add a second chapter whose boundary could change the outcome. A complete solution contains the input model, a trace, observed evidence, a correction and one transfer statement. The exact data may differ; the causal chain must be checkable.
Frequently asked questions
How long should a practice session be?
Use one complete prediction–observation–explanation cycle while attention remains good. Ten to twenty focused minutes can be enough.
Should every option or function be memorised?
No. Memorise the governing distinctions and practise retrieving the official reference. Understanding means predicting and explaining, not reciting a parameter list.
What if the result is correct but the explanation is weak?
Treat it as partial success. Ask for a trace and change one boundary. A reliable model survives controlled variation.
Is the shortest solution the best?
Not automatically. Prefer the solution whose semantics, failure modes and maintenance cost are easiest to justify for the actual project.
When should official documentation be used?
Use it whenever syntax, supported types, SQL dialect behaviour or Git version details matter. Primary documentation settles the current contract.
How can a parent help without technical expertise?
Ask what was predicted, where the first difference appeared, what evidence matters and which smaller example could isolate it.
How do we test transfer?
Change the context, vocabulary and one boundary. Require the learner to identify the invariant before using a tool.
What should be saved after practice?
Keep the corrected rule, one trace, one boundary case and the next question. Avoid storing pages of unexplained output.
Can these exercises replace backups?
No. Use disposable examples and proper backups. Learning should not endanger schoolwork, repositories or personal data.
What counts as mastery?
The learner can predict, verify, diagnose, recover and justify a choice across more than one context, while knowing when to consult the current reference.

