Commit 416f43f
authored
Bump lint-staged from 15.5.2 to 16.0.0 (#773)
Bumps [lint-staged](https://github.com/lint-staged/lint-staged) from 15.5.2 to 16.0.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/lint-staged/lint-staged/releases">lint-staged's releases</a>.</em></p>
<blockquote>
<h2>v16.0.0</h2>
<h3>Major Changes</h3>
<ul>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - Processes are spawned using <a href="https://github.com/sindresorhus/nano-spawn">nano-spawn</a> instead of <a href="https://github.com/sindresorhus/execa">execa</a>. If you are using Node.js scripts as tasks, you might need to explicitly run them with <code>node</code>, especially when using Windows:</p>
<pre lang="json"><code>{
"*.js": "node my-js-linter.js"
}
</code></pre>
</li>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - The <code>--shell</code> flag has been removed and <em>lint-staged</em> no longer supports evaluating commands directly via a shell. To migrate existing commands, you can create a shell script and invoke it instead. Lint-staged will pass matched staged files as a list of arguments, accessible via <code>"$@"</code>:</p>
<pre lang="shell"><code># my-script.sh
#!/bin/bash
<p>echo "Staged files: $@"<br />
</code></pre></p>
<p>and</p>
<pre lang="json"><code>{ "*.js": "my-script.sh" }
</code></pre>
<p>If you were using the shell option to avoid passing filenames to tasks, for example <code>bash -c 'tsc --noEmit'</code>, use the function syntax instead:</p>
<pre lang="js"><code>export default { '*.ts': () => 'tsc --noEmit' }
</code></pre>
</li>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - Validation for deprecated advanced configuration has been removed. The advanced configuration was removed in <em>lint-staged</em> version 9 and until now validation has failed if advanced configuration options were detected. Going forward the entire configuration will be treated with the same logic and if these advanced options are still present, they might be treated as valid globs for staged files instead.</p>
</li>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - The lowest supported Node.js version is <code>20.18</code>. Please upgrade your Node.js version.</p>
</li>
</ul>
<h3>Minor Changes</h3>
<ul>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1401">#1401</a> <a href="https://github.com/lint-staged/lint-staged/commit/27110ef8ee92c5d104235b4094abb3197b5bf074"><code>27110ef</code></a> Thanks <a href="https://github.com/RohitLuthra19"><code>@RohitLuthra19</code></a>! - Added support for directly running functions on staged files. To configure a function task, use an object with a title and the task itself:</p>
<pre lang="js"><code>export default {
'*.js': {
title: 'My task',
task: async (files) => {
console.log('Staged JS files:', files)
},
},
}
</code></pre>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/lint-staged/lint-staged/blob/main/CHANGELOG.md">lint-staged's changelog</a>.</em></p>
<blockquote>
<h2>16.0.0</h2>
<h3>Major Changes</h3>
<ul>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - Processes are spawned using <a href="https://github.com/sindresorhus/nano-spawn">nano-spawn</a> instead of <a href="https://github.com/sindresorhus/execa">execa</a>. If you are using Node.js scripts as tasks, you might need to explicitly run them with <code>node</code>, especially when using Windows:</p>
<pre lang="json"><code>{
"*.js": "node my-js-linter.js"
}
</code></pre>
</li>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - The <code>--shell</code> flag has been removed and <em>lint-staged</em> no longer supports evaluating commands directly via a shell. To migrate existing commands, you can create a shell script and invoke it instead. Lint-staged will pass matched staged files as a list of arguments, accessible via <code>"$@"</code>:</p>
<pre lang="shell"><code># my-script.sh
#!/bin/bash
<p>echo "Staged files: $@"<br />
</code></pre></p>
<p>and</p>
<pre lang="json"><code>{ "*.js": "my-script.sh" }
</code></pre>
<p>If you were using the shell option to avoid passing filenames to tasks, for example <code>bash -c 'tsc --noEmit'</code>, use the function syntax instead:</p>
<pre lang="js"><code>export default { '*.ts': () => 'tsc --noEmit' }
</code></pre>
</li>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - Validation for deprecated advanced configuration has been removed. The advanced configuration was removed in <em>lint-staged</em> version 9 and until now validation has failed if advanced configuration options were detected. Going forward the entire configuration will be treated with the same logic and if these advanced options are still present, they might be treated as valid globs for staged files instead.</p>
</li>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1546">#1546</a> <a href="https://github.com/lint-staged/lint-staged/commit/158d15c9aea0a3a87790ec3766442763cf387dba"><code>158d15c</code></a> Thanks <a href="https://github.com/iiroj"><code>@iiroj</code></a>! - The lowest supported Node.js version is <code>20.18</code>. Please upgrade your Node.js version.</p>
</li>
</ul>
<h3>Minor Changes</h3>
<ul>
<li>
<p><a href="https://redirect.github.com/lint-staged/lint-staged/pull/1401">#1401</a> <a href="https://github.com/lint-staged/lint-staged/commit/27110ef8ee92c5d104235b4094abb3197b5bf074"><code>27110ef</code></a> Thanks <a href="https://github.com/RohitLuthra19"><code>@RohitLuthra19</code></a>! - Added support for directly running functions on staged files. To configure a function task, use an object with a title and the task itself:</p>
<pre lang="js"><code>export default {
'*.js': {
title: 'My task',
task: async (files) => {
console.log('Staged JS files:', files)
},
},
}
</code></pre>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="https://github.com/lint-staged/lint-staged/commit/dad5490949f31442e7580246a9fad5565257d6cb"><code>dad5490</code></a> chore(changeset): release</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/1c19e82da16db76dbc0b1f5db1dca516753c7c1a"><code>1c19e82</code></a> build(deps): update dependencies and require Node.js 20.18</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/08cf8f54e4c5520790d8f02ca5315d7d1285e414"><code>08cf8f5</code></a> docs: update README.md and bump nano-spawn as major change</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/276dcc8a05dafc1b33041865cc9bb912fbd10e7c"><code>276dcc8</code></a> refactor: simplify config validation</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/d4b7cacfb093bbd5e1a1353047a7b4e2deed0847"><code>d4b7cac</code></a> test: update tests</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/0ee9ab86b1e5ecd515e07e09e5a60932eb791174"><code>0ee9ab8</code></a> fix: update TypeScript type definitions</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/12525b2c66e314bb6d94fdc793d9b953a5f0d5c7"><code>12525b2</code></a> refactor: rename functions</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/541c35312a47106faaf861c96ec4affcac216e47"><code>541c353</code></a> refactor: separate "make cmd tasks" and "make function tasks"</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/27110ef8ee92c5d104235b4094abb3197b5bf074"><code>27110ef</code></a> feat: added support for custom configuration</li>
<li><a href="https://github.com/lint-staged/lint-staged/commit/52366f9f3bee04319b6d0856cac55ee8d9e9f94a"><code>52366f9</code></a> ci: update Node.js versions used in CI</li>
<li>Additional commits viewable in <a href="https://github.com/lint-staged/lint-staged/compare/v15.5.2...v16.0.0">compare view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
You can trigger a rebase of this PR by commenting `@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>1 parent e025e43 commit 416f43f
2 files changed
+21
-91
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
56 | | - | |
| 56 | + | |
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
824 | 824 | | |
825 | 825 | | |
826 | 826 | | |
827 | | - | |
| 827 | + | |
828 | 828 | | |
829 | 829 | | |
830 | 830 | | |
| |||
2673 | 2673 | | |
2674 | 2674 | | |
2675 | 2675 | | |
2676 | | - | |
2677 | | - | |
2678 | | - | |
2679 | | - | |
2680 | | - | |
2681 | | - | |
2682 | | - | |
2683 | | - | |
2684 | | - | |
2685 | | - | |
2686 | | - | |
2687 | | - | |
2688 | | - | |
2689 | | - | |
2690 | | - | |
2691 | | - | |
2692 | | - | |
2693 | 2676 | | |
2694 | 2677 | | |
2695 | 2678 | | |
| |||
3011 | 2994 | | |
3012 | 2995 | | |
3013 | 2996 | | |
3014 | | - | |
3015 | | - | |
3016 | | - | |
3017 | | - | |
3018 | | - | |
3019 | | - | |
3020 | | - | |
3021 | 2997 | | |
3022 | 2998 | | |
3023 | 2999 | | |
| |||
3250 | 3226 | | |
3251 | 3227 | | |
3252 | 3228 | | |
3253 | | - | |
3254 | | - | |
3255 | | - | |
3256 | | - | |
3257 | | - | |
3258 | | - | |
3259 | | - | |
3260 | 3229 | | |
3261 | 3230 | | |
3262 | 3231 | | |
| |||
3564 | 3533 | | |
3565 | 3534 | | |
3566 | 3535 | | |
3567 | | - | |
3568 | | - | |
3569 | | - | |
3570 | | - | |
3571 | | - | |
3572 | | - | |
3573 | | - | |
3574 | 3536 | | |
3575 | 3537 | | |
3576 | 3538 | | |
| |||
4324 | 4286 | | |
4325 | 4287 | | |
4326 | 4288 | | |
4327 | | - | |
4328 | | - | |
4329 | | - | |
| 4289 | + | |
| 4290 | + | |
| 4291 | + | |
4330 | 4292 | | |
4331 | 4293 | | |
4332 | 4294 | | |
4333 | 4295 | | |
4334 | | - | |
4335 | 4296 | | |
4336 | | - | |
| 4297 | + | |
4337 | 4298 | | |
| 4299 | + | |
4338 | 4300 | | |
4339 | 4301 | | |
4340 | | - | |
| 4302 | + | |
4341 | 4303 | | |
4342 | 4304 | | |
4343 | | - | |
| 4305 | + | |
4344 | 4306 | | |
4345 | 4307 | | |
4346 | 4308 | | |
4347 | | - | |
4348 | | - | |
4349 | | - | |
| 4309 | + | |
| 4310 | + | |
| 4311 | + | |
4350 | 4312 | | |
4351 | 4313 | | |
4352 | 4314 | | |
4353 | 4315 | | |
4354 | 4316 | | |
4355 | 4317 | | |
4356 | 4318 | | |
4357 | | - | |
| 4319 | + | |
4358 | 4320 | | |
4359 | 4321 | | |
4360 | 4322 | | |
| |||
4522 | 4484 | | |
4523 | 4485 | | |
4524 | 4486 | | |
4525 | | - | |
4526 | | - | |
4527 | | - | |
4528 | | - | |
4529 | | - | |
4530 | | - | |
4531 | | - | |
4532 | 4487 | | |
4533 | 4488 | | |
4534 | 4489 | | |
| |||
4670 | 4625 | | |
4671 | 4626 | | |
4672 | 4627 | | |
| 4628 | + | |
| 4629 | + | |
| 4630 | + | |
| 4631 | + | |
| 4632 | + | |
| 4633 | + | |
| 4634 | + | |
4673 | 4635 | | |
4674 | 4636 | | |
4675 | 4637 | | |
| |||
4802 | 4764 | | |
4803 | 4765 | | |
4804 | 4766 | | |
4805 | | - | |
4806 | | - | |
4807 | | - | |
4808 | | - | |
4809 | | - | |
4810 | | - | |
4811 | | - | |
4812 | | - | |
4813 | | - | |
4814 | 4767 | | |
4815 | 4768 | | |
4816 | 4769 | | |
| |||
4890 | 4843 | | |
4891 | 4844 | | |
4892 | 4845 | | |
4893 | | - | |
4894 | | - | |
4895 | | - | |
4896 | | - | |
4897 | | - | |
4898 | | - | |
4899 | | - | |
4900 | | - | |
4901 | | - | |
4902 | 4846 | | |
4903 | 4847 | | |
4904 | 4848 | | |
| |||
5016 | 4960 | | |
5017 | 4961 | | |
5018 | 4962 | | |
5019 | | - | |
5020 | | - | |
5021 | | - | |
5022 | | - | |
5023 | | - | |
5024 | | - | |
5025 | | - | |
5026 | 4963 | | |
5027 | 4964 | | |
5028 | 4965 | | |
| |||
5821 | 5758 | | |
5822 | 5759 | | |
5823 | 5760 | | |
5824 | | - | |
5825 | | - | |
5826 | | - | |
5827 | | - | |
5828 | | - | |
5829 | | - | |
5830 | | - | |
5831 | 5761 | | |
5832 | 5762 | | |
5833 | 5763 | | |
| |||
6414 | 6344 | | |
6415 | 6345 | | |
6416 | 6346 | | |
6417 | | - | |
| 6347 | + | |
6418 | 6348 | | |
6419 | 6349 | | |
6420 | 6350 | | |
| |||
0 commit comments