{"thread":{"id":"64845","subject":".gitignore issue","startedAt":"2026-01-21T18:33:04Z","lastAt":"2026-01-21T18:33:04Z","messageCount":1,"participants":["Alf Clement"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"534370","messageId":"CAOQVjoi+Z7UgYP+CRVXFz-LWRcNOv571CNQTmLWBgB3ErhTRQA@mail.gmail.com","threadId":"64845","inReplyTo":null,"subject":".gitignore issue","fromName":"Alf Clement","fromEmail":"alf.clement@gmail.com","sentAt":"2026-01-21T18:32:47Z","receivedAt":"2026-01-21T18:33:04Z","isPatch":false,"sender":{"key":"alf.clement@gmail.com","avatar":null},"body":"Hello,\n\nI found an unexplainable behavior - see below.\n\nbest regards,\nAlf\n\nThank you for filling out a Git bug report!\nPlease answer the following questions to help us understand your issue.\n\nWhat did you do before the bug happened? (Steps to reproduce your issue)\nAdding an new line to .gitignore to filter directories.\n\nWhat did you expect to happen? (Expected behavior)\nI expected to see no backup_STOCKS* directory on git status.\n\nWhat happened instead? (Actual behavior)\nIt also surpressed the backup/ directory.\n\nWhat's different between what you expected and what actually happened?\nWhen I surpress backup_STOCKS* or backup_STOCKS*/ I expect a backup/\ndirectory still to be visible.\n\nAnything else you want to add:\nHere are the actions:\n\n$ git status\nOn branch master\nYour branch is up to date with 'origin/master'.\n\nChanges not staged for commit:\n  (use \"git add <file>...\" to update what will be committed)\n  (use \"git restore <file>...\" to discard changes in working directory)\n        modified:   .gitignore\n\nUntracked files:\n  (use \"git add <file>...\" to include in what will be committed)\n        asset_history_2025_20260114.csv\n        backup_STOCKS_20260107_060326/\n        backup_STOCKS_20260107_184151/\n        backup_STOCKS_20260110_173702/\n        backup_STOCKS_20260114_172546/\n        backup_STOCKS_20260116_201409/\n        backup_STOCKS_20260116_210037/\n        backup_STOCKS_20260117_184437/\n        backup_STOCKS_20260119_202817/\n        backups/\n        index.after.txt\n        index.before.txt\n\nno changes added to commit (use \"git add\" and/or \"git commit -a\")\n$ echo 'backup_STOCKS*/' >>.gitignore\n$ git status\nOn branch master\nYour branch is up to date with 'origin/master'.\n\nChanges not staged for commit:\n  (use \"git add <file>...\" to update what will be committed)\n  (use \"git restore <file>...\" to discard changes in working directory)\n        modified:   .gitignore\n\nUntracked files:\n  (use \"git add <file>...\" to include in what will be committed)\n        asset_history_2025_20260114.csv\n        index.after.txt\n        index.before.txt\n$ cat .gitignore\npng/\n__pycache__\nmongodb.yaml\n*.log\n*.pdf\nOLD\n.vscode\nca.pem\npy.pem\nstates/\n.skylos\nbackup_STOCKS*/\n\n[System Info]\ngit version:\ngit version 2.43.0\ncpu: x86_64\nno commit associated with this build\nsizeof-long: 8\nsizeof-size_t: 8\nshell-path: /bin/sh\nuname: Linux 6.6.87.2-microsoft-standard-WSL2 #1 SMP PREEMPT_DYNAMIC\nThu Jun  5 18:30:46 UTC 2025 x86_64\ncompiler info: gnuc: 13.3\nlibc info: glibc: 2.39\n$SHELL (typically, interactive shell): /bin/bash\n\n\n[Enabled Hooks]\n"}]}