Commit d735e9f
Fix .juliabundleignore: directory patterns, comments, and content exclusion
Three bugs in the bundleignore parser:
1. Directory patterns (e.g. "output-data/") were compiled into
Glob.FilenameMatch which only matched the literal string, not files
inside the directory. A pattern "foo/" would exclude the entry "foo/"
but NOT "foo/bar.jl".
Fix: plain directory prefixes (no glob chars) are matched via
startswith(). Glob-containing directory patterns (e.g. "*/bar/")
emit both the dir match and a "*/bar/*" contents match.
2. Comment lines (starting with #) and blank lines were compiled into
Glob.FilenameMatch patterns, potentially causing spurious matches.
Fix: _parse_bundleignore_line() skips comments and blanks.
3. A file named "foo.csv" could be incorrectly excluded by a directory
pattern "foo.csv/" because joinpath("foo.csv", "") == "foo.csv/".
Fix: the rpath_dir startswith check is only applied when the path
is actually a directory (isdir guard).
Updates existing tests to reflect the corrected behavior: files inside
directories matched by "*/bar/" patterns are now properly excluded.
Relates to #130 (negated paths — this fix is a prerequisite, cleaning
up the same code path).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent 60ed8bb commit d735e9f
2 files changed
Lines changed: 56 additions & 22 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
76 | 106 | | |
77 | 107 | | |
78 | 108 | | |
79 | 109 | | |
80 | 110 | | |
81 | 111 | | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
86 | 116 | | |
87 | 117 | | |
88 | 118 | | |
| |||
117 | 147 | | |
118 | 148 | | |
119 | 149 | | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
130 | 166 | | |
131 | 167 | | |
132 | 168 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
240 | 240 | | |
241 | 241 | | |
242 | 242 | | |
243 | | - | |
244 | | - | |
245 | | - | |
246 | | - | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
247 | 246 | | |
248 | 247 | | |
249 | 248 | | |
| |||
259 | 258 | | |
260 | 259 | | |
261 | 260 | | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
266 | 264 | | |
267 | 265 | | |
268 | 266 | | |
| |||
0 commit comments