@hublo/sentinel 1.2.0-alpha.6 → 1.2.0-alpha.7

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.
@@ -21,7 +21,7 @@ import {
21
21
  registerAdapters,
22
22
  resolve,
23
23
  resolveBin
24
- } from "../chunk-XPWM77PB.js";
24
+ } from "../chunk-A25QVPXF.js";
25
25
 
26
26
  // bin/sentinel.ts
27
27
  import { program } from "commander";
@@ -1199,8 +1199,9 @@ function listSourceFiles(cwd, extensions) {
1199
1199
 
1200
1200
  // src/core/named-scope.ts
1201
1201
  var TOLERATE_EMPTY_FLAG = "--no-error-on-unmatched-pattern";
1202
- function scopeFlags(paths) {
1203
- return paths.length > 0 ? [TOLERATE_EMPTY_FLAG] : [];
1202
+ function scopeFlags(paths, options = []) {
1203
+ if (paths.length === 0 || options.includes(TOLERATE_EMPTY_FLAG)) return [];
1204
+ return [TOLERATE_EMPTY_FLAG];
1204
1205
  }
1205
1206
 
1206
1207
  // src/core/settings.ts
@@ -1911,7 +1912,7 @@ var OxfmtAdapter = class extends BaseAdapter {
1911
1912
  });
1912
1913
  const result = spawnSync3(
1913
1914
  oxfmt,
1914
- [mode, ...scopeFlags(paths), ...options, ...paths.length > 0 ? paths : ["."]],
1915
+ [mode, ...scopeFlags(paths, options), ...options, ...paths.length > 0 ? paths : ["."]],
1915
1916
  {
1916
1917
  cwd: ctx.cwd,
1917
1918
  stdio: "inherit"
@@ -4956,7 +4957,7 @@ ${result.stderr ?? ""}`);
4956
4957
  valueFlags: OXLINT_VALUE_FLAGS
4957
4958
  });
4958
4959
  const targets = paths.length > 0 ? paths : ["."];
4959
- const emptyScope = scopeFlags(paths);
4960
+ const emptyScope = scopeFlags(paths, passedOptions);
4960
4961
  const lint = (extra) => {
4961
4962
  const passed = [...extra, ...emptyScope, ...passedOptions];
4962
4963
  const result = spawnSync4(oxlint, ["-c", LINT_CONFIG_FILE, ...passed, ...targets], {
@@ -6280,4 +6281,4 @@ export {
6280
6281
  detectFramework,
6281
6282
  dispatch
6282
6283
  };
6283
- //# sourceMappingURL=chunk-XPWM77PB.js.map
6284
+ //# sourceMappingURL=chunk-A25QVPXF.js.map
package/dist/index.js CHANGED
@@ -7,7 +7,7 @@ import {
7
7
  registerAdapters,
8
8
  resolve,
9
9
  setDefaultRunner
10
- } from "./chunk-XPWM77PB.js";
10
+ } from "./chunk-A25QVPXF.js";
11
11
  export {
12
12
  BaseAdapter,
13
13
  all,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hublo/sentinel",
3
- "version": "1.2.0-alpha.6",
3
+ "version": "1.2.0-alpha.7",
4
4
  "description": "One CLI that guards code health across Hublo repos: shared lint/typescript/build/test presets, static & dynamic analysis, and architecture checks.",
5
5
  "type": "module",
6
6
  "license": "MIT",