@reteps/tree-sitter-htmlmustache 0.0.23 → 0.0.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/cli/out/check.js +16 -3
  2. package/package.json +1 -1
package/cli/out/check.js CHANGED
@@ -139,9 +139,19 @@ function formatSummary(totalErrors, filesWithErrors, totalFiles) {
139
139
  // ── Glob expansion ──
140
140
  function expandGlobs(patterns) {
141
141
  const files = new Set();
142
+ const cwd = process.cwd();
142
143
  for (const pattern of patterns) {
143
- for (const match of node_fs_1.default.globSync(pattern)) {
144
- files.add(node_path_1.default.resolve(match));
144
+ // If the pattern is an exact file path, use it directly
145
+ if (!pattern.includes('*') && !pattern.includes('?')) {
146
+ const resolved = node_path_1.default.resolve(cwd, pattern);
147
+ if (node_fs_1.default.existsSync(resolved)) {
148
+ files.add(resolved);
149
+ }
150
+ }
151
+ else {
152
+ for (const match of node_fs_1.default.globSync(pattern, { cwd })) {
153
+ files.add(node_path_1.default.resolve(cwd, match));
154
+ }
145
155
  }
146
156
  }
147
157
  return [...files].sort();
@@ -171,7 +181,10 @@ function run(args) {
171
181
  }
172
182
  const files = expandGlobs(args);
173
183
  if (files.length === 0) {
174
- console.error(chalk_1.default.yellow('No files matched the given patterns.'));
184
+ console.error(chalk_1.default.yellow('No files matched the given patterns:'));
185
+ for (const arg of args) {
186
+ console.error(chalk_1.default.yellow(` ${arg}`));
187
+ }
175
188
  return 1;
176
189
  }
177
190
  const parser = loadParser();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reteps/tree-sitter-htmlmustache",
3
- "version": "0.0.23",
3
+ "version": "0.0.24",
4
4
  "description": "HTML with Mustache/Handlebars template syntax grammar for tree-sitter",
5
5
  "repository": {
6
6
  "type": "git",