@opencode/util 0.0.0-dev-21132 → 0.0.0-dev-21133

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.
package/dist/fs-util.d.ts CHANGED
@@ -133,6 +133,8 @@ export declare namespace FSUtil {
133
133
  export function normalizePathPattern(p: string): string;
134
134
  export function resolve(p: string): string;
135
135
  export function windowsPath(p: string): string;
136
+ export const ignoredDirectories: string[];
137
+ export const ignoreGlobs: string[];
136
138
  export function overlaps(a: string, b: string): boolean;
137
139
  export function contains(parent: string, child: string): boolean;
138
140
  export {};
package/dist/fs-util.js CHANGED
@@ -205,6 +205,8 @@ export var FSUtil;
205
205
  .replace(/^\/mnt\/([a-zA-Z])(?:\/|$)/, (_, drive) => `${drive.toUpperCase()}:/`);
206
206
  }
207
207
  FSUtil.windowsPath = windowsPath;
208
+ FSUtil.ignoredDirectories = ["node_modules", ".git", ".venv", "venv", "__pycache__"];
209
+ FSUtil.ignoreGlobs = [...FSUtil.ignoredDirectories, `**/{${FSUtil.ignoredDirectories.join(",")}}/**`];
208
210
  function overlaps(a, b) {
209
211
  return contains(a, b) || contains(b, a);
210
212
  }
package/dist/glob.d.ts CHANGED
@@ -5,6 +5,7 @@ export declare namespace Glob {
5
5
  include?: "file" | "all";
6
6
  dot?: boolean;
7
7
  symlink?: boolean;
8
+ ignore?: string[];
8
9
  }
9
10
  function scan(pattern: string, options?: Options): Promise<string[]>;
10
11
  function scanSync(pattern: string, options?: Options): string[];
package/dist/glob.js CHANGED
@@ -9,6 +9,7 @@ export var Glob;
9
9
  dot: options.dot,
10
10
  follow: options.symlink ?? false,
11
11
  nodir: options.include !== "all",
12
+ ignore: options.ignore,
12
13
  };
13
14
  }
14
15
  async function scan(pattern, options = {}) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@opencode/util",
4
- "version": "0.0.0-dev-21132",
4
+ "version": "0.0.0-dev-21133",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "repository": {