vibe64 0.1.78 → 0.1.80
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/bin/run.js +1523 -1512
- package/bin/server.js +100 -98
- package/bin/upgrade-state.js +3288 -3277
- package/dist/assets/{GithubBrowserTabs-B2r19V0U.js → GithubBrowserTabs-d5SRhPw-.js} +1 -1
- package/dist/assets/GithubBrowserTabs-d5SRhPw-.js.br +0 -0
- package/dist/assets/GithubBrowserTabs-d5SRhPw-.js.gz +0 -0
- package/dist/assets/{LocalDatabaseServer-Ck9nZrGW.js → LocalDatabaseServer-CIAX_Xx8.js} +1 -1
- package/dist/assets/LocalDatabaseServer-CIAX_Xx8.js.br +0 -0
- package/dist/assets/LocalDatabaseServer-CIAX_Xx8.js.gz +0 -0
- package/dist/assets/{Vibe64DashboardPageHeader-C4iTKeE0.js → Vibe64DashboardPageHeader-CyYFBVSw.js} +1 -1
- package/dist/assets/Vibe64DashboardPageHeader-CyYFBVSw.js.br +0 -0
- package/dist/assets/Vibe64DashboardPageHeader-CyYFBVSw.js.gz +0 -0
- package/dist/assets/{Vibe64DatabaseWorkspace-ChA-2QPU.js → Vibe64DatabaseWorkspace-Dep64whC.js} +1 -1
- package/dist/assets/Vibe64DatabaseWorkspace-Dep64whC.js.br +0 -0
- package/dist/assets/{Vibe64DatabaseWorkspace-ChA-2QPU.js.gz → Vibe64DatabaseWorkspace-Dep64whC.js.gz} +0 -0
- package/dist/assets/{Vibe64FileArea-DBEJsJSq.js → Vibe64FileArea-r9PP5pT7.js} +1 -1
- package/dist/assets/Vibe64FileArea-r9PP5pT7.js.br +0 -0
- package/dist/assets/Vibe64FileArea-r9PP5pT7.js.gz +0 -0
- package/dist/assets/Vibe64OutputControls-B6wjUtLL.js +8 -0
- package/dist/assets/Vibe64OutputControls-B6wjUtLL.js.br +0 -0
- package/dist/assets/Vibe64OutputControls-B6wjUtLL.js.gz +0 -0
- package/dist/assets/{Vibe64OutputControls-aQCEvUL2.css → Vibe64OutputControls-gSUdkqME.css} +1 -1
- package/dist/assets/Vibe64OutputControls-gSUdkqME.css.br +0 -0
- package/dist/assets/Vibe64OutputControls-gSUdkqME.css.gz +0 -0
- package/dist/assets/{Vibe64RepositoryWorkspace-sT07hHPs.js → Vibe64RepositoryWorkspace-C_ez14Jz.js} +1 -1
- package/dist/assets/Vibe64RepositoryWorkspace-C_ez14Jz.js.br +0 -0
- package/dist/assets/Vibe64RepositoryWorkspace-C_ez14Jz.js.gz +0 -0
- package/dist/assets/{Vibe64SessionFiles-Djef01EV.js → Vibe64SessionFiles-CJPrBsND.js} +1 -1
- package/dist/assets/Vibe64SessionFiles-CJPrBsND.js.br +0 -0
- package/dist/assets/Vibe64SessionFiles-CJPrBsND.js.gz +0 -0
- package/dist/assets/{Vibe64SessionSourceEditor-CIGBLYYN.js → Vibe64SessionSourceEditor-CwE0Y-ka.js} +1 -1
- package/dist/assets/Vibe64SessionSourceEditor-CwE0Y-ka.js.br +0 -0
- package/dist/assets/Vibe64SessionSourceEditor-CwE0Y-ka.js.gz +0 -0
- package/dist/assets/{Vibe64UiStoryboardView-CjkWoB8b.js → Vibe64UiStoryboardView-COViVA_8.js} +1 -1
- package/dist/assets/Vibe64UiStoryboardView-COViVA_8.js.br +0 -0
- package/dist/assets/Vibe64UiStoryboardView-COViVA_8.js.gz +0 -0
- package/dist/assets/{_pageId_-BTjeqgTN.js → _pageId_-DuE37c72.js} +1 -1
- package/dist/assets/{_sessionId_-C7Jh2bL4.js → _sessionId_-T6qoKZhb.js} +1 -1
- package/dist/assets/_sessionId_-T6qoKZhb.js.br +0 -0
- package/dist/assets/_sessionId_-T6qoKZhb.js.gz +0 -0
- package/dist/assets/{_sessionTool_-DITdXCS4.js → _sessionTool_-B-b_DFay.js} +1 -1
- package/dist/assets/{access-DIaPNdxr.js → access-Dx-76I4I.js} +1 -1
- package/dist/assets/access-Dx-76I4I.js.br +0 -0
- package/dist/assets/access-Dx-76I4I.js.gz +0 -0
- package/dist/assets/{app-mELSmS67.js → app-BM5ppUKY.js} +1 -1
- package/dist/assets/app-BM5ppUKY.js.br +0 -0
- package/dist/assets/app-BM5ppUKY.js.gz +0 -0
- package/dist/assets/{changes-DlxKdjdP.js → changes-CI15aJ2s.js} +1 -1
- package/dist/assets/{client-CL02nP02.js → client-CtgiCplj.js} +2 -2
- package/dist/assets/client-CtgiCplj.js.br +0 -0
- package/dist/assets/client-CtgiCplj.js.gz +0 -0
- package/dist/assets/{client-CLpGzGwX.js → client-wU-vn9Gt.js} +2 -2
- package/dist/assets/client-wU-vn9Gt.js.br +0 -0
- package/dist/assets/client-wU-vn9Gt.js.gz +0 -0
- package/dist/assets/{dashboard-km-kuDid.js → dashboard-DD-Kz8sQ.js} +1 -1
- package/dist/assets/{english-definitions-CMICWgdF.js → english-definitions-B-puV4oO.js} +1 -1
- package/dist/assets/english-definitions-B-puV4oO.js.br +0 -0
- package/dist/assets/english-definitions-B-puV4oO.js.gz +0 -0
- package/dist/assets/{env-DjkxkxdX.js → env-CsRMp84w.js} +1 -1
- package/dist/assets/env-CsRMp84w.js.br +0 -0
- package/dist/assets/env-CsRMp84w.js.gz +0 -0
- package/dist/assets/{error-C7q1-2bC.js → error-CL5AgVRX.js} +1 -1
- package/dist/assets/error-CL5AgVRX.js.br +0 -0
- package/dist/assets/error-CL5AgVRX.js.gz +0 -0
- package/dist/assets/{fileTypes-Dbn0qwKS.js → fileTypes-CFECKFVN.js} +1 -1
- package/dist/assets/fileTypes-CFECKFVN.js.br +0 -0
- package/dist/assets/fileTypes-CFECKFVN.js.gz +0 -0
- package/dist/assets/{health-BwJ6Z251.js → health-4aQl5EcU.js} +1 -1
- package/dist/assets/health-4aQl5EcU.js.br +0 -0
- package/dist/assets/health-4aQl5EcU.js.gz +0 -0
- package/dist/assets/{history-D2TywQVv.js → history-B5Sor4EE.js} +1 -1
- package/dist/assets/history-B5Sor4EE.js.br +0 -0
- package/dist/assets/history-B5Sor4EE.js.gz +0 -0
- package/dist/assets/{index-D14nUmm7.js → index-BAvE8_Ib.js} +5 -5
- package/dist/assets/index-BAvE8_Ib.js.br +0 -0
- package/dist/assets/index-BAvE8_Ib.js.gz +0 -0
- package/dist/assets/{integrations-BZFXW2Cp.js → integrations-DksSxQbj.js} +96 -10
- package/dist/assets/integrations-DksSxQbj.js.br +0 -0
- package/dist/assets/integrations-DksSxQbj.js.gz +0 -0
- package/dist/assets/{issues-CLvbBTek.js → issues-DK2L8AHT.js} +1 -1
- package/dist/assets/issues-DK2L8AHT.js.br +0 -0
- package/dist/assets/issues-DK2L8AHT.js.gz +0 -0
- package/dist/assets/{learning-DwytxEXC.js → learning-DeuGeINY.js} +1 -1
- package/dist/assets/{packages-BeiF8W7l.js → packages-Du3QFyu-.js} +1 -1
- package/dist/assets/packages-Du3QFyu-.js.br +0 -0
- package/dist/assets/packages-Du3QFyu-.js.gz +0 -0
- package/dist/assets/{pages-BIRQk4b8.js → pages-CBvnECLI.js} +1 -1
- package/dist/assets/{pages-BnAyUdL4.js → pages-D3MpRYy4.js} +1 -1
- package/dist/assets/pages-D3MpRYy4.js.br +0 -0
- package/dist/assets/pages-D3MpRYy4.js.gz +0 -0
- package/dist/assets/{project-GnljGud1.js → project-BFylqlOt.js} +13 -13
- package/dist/assets/project-BFylqlOt.js.br +0 -0
- package/dist/assets/project-BFylqlOt.js.gz +0 -0
- package/dist/assets/project-BZ-FhyDR.css +1 -0
- package/dist/assets/project-BZ-FhyDR.css.br +0 -0
- package/dist/assets/project-BZ-FhyDR.css.gz +0 -0
- package/dist/assets/{project-files-e4-Q65vT.js → project-files-CHgBwX2E.js} +1 -1
- package/dist/assets/project-files-CHgBwX2E.js.br +0 -0
- package/dist/assets/project-files-CHgBwX2E.js.gz +0 -0
- package/dist/assets/{project-shared-ShellOutlet-DKYDipmC.js → project-shared-ShellOutlet-CIoqgO35.js} +1 -1
- package/dist/assets/project-shared-ShellOutlet-CIoqgO35.js.br +0 -0
- package/dist/assets/project-shared-ShellOutlet-CIoqgO35.js.gz +0 -0
- package/dist/assets/{project-shared-VBottomSheet-BSE28ENQ.js → project-shared-VBottomSheet-Bezz1r7A.js} +1 -1
- package/dist/assets/project-shared-VBottomSheet-Bezz1r7A.js.br +0 -0
- package/dist/assets/project-shared-VBottomSheet-Bezz1r7A.js.gz +0 -0
- package/dist/assets/{project-shared-VToolbar-CrezJP9z.js → project-shared-VToolbar-DmXu_VIt.js} +1 -1
- package/dist/assets/project-shared-VToolbar-DmXu_VIt.js.br +0 -0
- package/dist/assets/project-shared-VToolbar-DmXu_VIt.js.gz +0 -0
- package/dist/assets/{project-shared-pageNames-6Jz0BfbS.js → project-shared-pageNames-BiomB55Q.js} +1 -1
- package/dist/assets/project-shared-pageNames-BiomB55Q.js.br +0 -0
- package/dist/assets/project-shared-pageNames-BiomB55Q.js.gz +0 -0
- package/dist/assets/{pull-requests-DH9gWw10.js → pull-requests-CPBGulVu.js} +1 -1
- package/dist/assets/pull-requests-CPBGulVu.js.br +0 -0
- package/dist/assets/pull-requests-CPBGulVu.js.gz +0 -0
- package/dist/assets/{repository-BNltUuvb.js → repository-CWDpx49H.js} +1 -1
- package/dist/assets/{session-Ck9aH4Yl.js → session-D2z1O4Y4.js} +1 -1
- package/dist/assets/session-D2z1O4Y4.js.br +0 -0
- package/dist/assets/session-D2z1O4Y4.js.gz +0 -0
- package/dist/assets/{settings-D8Ofbk56.js → settings-BZRdBSb9.js} +1 -1
- package/dist/assets/settings-BZRdBSb9.js.br +0 -0
- package/dist/assets/settings-BZRdBSb9.js.gz +0 -0
- package/dist/assets/{useArchivedVibe64Sessions-LIZjeLbd.js → useArchivedVibe64Sessions-C3jJk531.js} +1 -1
- package/dist/assets/useArchivedVibe64Sessions-C3jJk531.js.br +0 -0
- package/dist/assets/useArchivedVibe64Sessions-C3jJk531.js.gz +0 -0
- package/dist/assets/{vibe64AttachmentDownload-1_XfvfYp.js → vibe64AttachmentDownload-DcLsJc9X.js} +1 -1
- package/dist/assets/{vibe64SavedEnvValues-Bs7r4xWE.js → vibe64SavedEnvValues-hAfcxHhJ.js} +1 -1
- package/dist/assets/{vue-flow-core-iwGljzru.js → vue-flow-core-BwhpINSc.js} +1 -1
- package/dist/assets/vue-flow-core-BwhpINSc.js.br +0 -0
- package/dist/assets/vue-flow-core-BwhpINSc.js.gz +0 -0
- package/dist/index.html +2 -2
- package/docs/colleague-usage/ai-accounts.md +4 -4
- package/docs/colleague-usage/ai-tasks.md +3 -2
- package/docs/colleague-usage/auto-workflow.md +99 -43
- package/docs/colleague-usage/chat-settings.md +46 -44
- package/docs/colleague-usage/coding-agents.md +8 -5
- package/docs/colleague-usage/connected-projects.md +196 -48
- package/docs/colleague-usage/connected-repositories.md +50 -6
- package/docs/colleague-usage/development-env.md +2 -2
- package/docs/colleague-usage/github-work.md +3 -3
- package/docs/colleague-usage/main-chat-approvals.md +2 -2
- package/docs/colleague-usage/passes.md +177 -156
- package/docs/colleague-usage/plans.md +121 -38
- package/docs/colleague-usage/preview-starting-application.md +6 -0
- package/docs/colleague-usage/preview-stop-and-restart.md +51 -0
- package/docs/colleague-usage/preview.md +10 -37
- package/docs/colleague-usage/ui-pass.md +32 -22
- package/node_modules/@jskit-ai/assistant-core/package.json +1 -1
- package/node_modules/@jskit-ai/assistant-runtime/package.json +1 -1
- package/node_modules/@jskit-ai/assistant-voice/package.json +1 -1
- package/node_modules/@jskit-ai/connectors-catalog/package.json +1 -1
- package/node_modules/@jskit-ai/payments-core/CHANGELOG.md +5 -0
- package/node_modules/@jskit-ai/payments-core/README.md +72 -8
- package/node_modules/@jskit-ai/payments-core/contracts/configuration.schema.json +56 -1
- package/node_modules/@jskit-ai/payments-core/contracts/conformance.json +484 -0
- package/node_modules/@jskit-ai/payments-core/locales/en.json +17 -5
- package/node_modules/@jskit-ai/payments-core/package.json +2 -1
- package/node_modules/@local/vibe64-execution/package.json +1 -0
- package/node_modules/@local/vibe64-genesis/README.md +12 -0
- package/node_modules/@local/vibe64-genesis/bin/vibe64-genesis-host-context +96 -96
- package/node_modules/@local/vibe64-genesis/package.json +2 -1
- package/node_modules/@local/vibe64-genesis/src/server/agentSpecs.js +182 -174
- package/node_modules/@local/vibe64-genesis/src/server/index.js +573 -569
- package/node_modules/@local/vibe64-project/package.json +1 -0
- package/node_modules/@local/vibe64-terminals/package.json +1 -0
- package/node_modules/@local/vibe64-terminals/src/server/sessionWorkOperationCommand.js +900 -890
- package/node_modules/chokidar/LICENSE +21 -0
- package/node_modules/chokidar/README.md +305 -0
- package/node_modules/chokidar/package.json +14 -0
- package/node_modules/readdirp/LICENSE +21 -0
- package/node_modules/readdirp/README.md +122 -0
- package/node_modules/readdirp/package.json +9 -0
- package/package.json +11 -7
- package/server.bundle.mjs +46995 -45449
- package/dist/assets/GithubBrowserTabs-B2r19V0U.js.br +0 -0
- package/dist/assets/GithubBrowserTabs-B2r19V0U.js.gz +0 -0
- package/dist/assets/LocalDatabaseServer-Ck9nZrGW.js.br +0 -0
- package/dist/assets/LocalDatabaseServer-Ck9nZrGW.js.gz +0 -0
- package/dist/assets/Vibe64DashboardPageHeader-C4iTKeE0.js.br +0 -0
- package/dist/assets/Vibe64DashboardPageHeader-C4iTKeE0.js.gz +0 -0
- package/dist/assets/Vibe64DatabaseWorkspace-ChA-2QPU.js.br +0 -0
- package/dist/assets/Vibe64FileArea-DBEJsJSq.js.br +0 -0
- package/dist/assets/Vibe64FileArea-DBEJsJSq.js.gz +0 -0
- package/dist/assets/Vibe64OutputControls-DpFdKIO2.js +0 -8
- package/dist/assets/Vibe64OutputControls-DpFdKIO2.js.br +0 -0
- package/dist/assets/Vibe64OutputControls-DpFdKIO2.js.gz +0 -0
- package/dist/assets/Vibe64OutputControls-aQCEvUL2.css.br +0 -0
- package/dist/assets/Vibe64OutputControls-aQCEvUL2.css.gz +0 -0
- package/dist/assets/Vibe64RepositoryWorkspace-sT07hHPs.js.br +0 -0
- package/dist/assets/Vibe64RepositoryWorkspace-sT07hHPs.js.gz +0 -0
- package/dist/assets/Vibe64SessionFiles-Djef01EV.js.br +0 -0
- package/dist/assets/Vibe64SessionFiles-Djef01EV.js.gz +0 -0
- package/dist/assets/Vibe64SessionSourceEditor-CIGBLYYN.js.br +0 -0
- package/dist/assets/Vibe64SessionSourceEditor-CIGBLYYN.js.gz +0 -0
- package/dist/assets/Vibe64UiStoryboardView-CjkWoB8b.js.br +0 -0
- package/dist/assets/Vibe64UiStoryboardView-CjkWoB8b.js.gz +0 -0
- package/dist/assets/_sessionId_-C7Jh2bL4.js.br +0 -0
- package/dist/assets/_sessionId_-C7Jh2bL4.js.gz +0 -0
- package/dist/assets/access-DIaPNdxr.js.br +0 -0
- package/dist/assets/access-DIaPNdxr.js.gz +0 -0
- package/dist/assets/app-mELSmS67.js.br +0 -0
- package/dist/assets/app-mELSmS67.js.gz +0 -0
- package/dist/assets/client-CL02nP02.js.br +0 -0
- package/dist/assets/client-CL02nP02.js.gz +0 -0
- package/dist/assets/client-CLpGzGwX.js.br +0 -0
- package/dist/assets/client-CLpGzGwX.js.gz +0 -0
- package/dist/assets/english-definitions-CMICWgdF.js.br +0 -0
- package/dist/assets/english-definitions-CMICWgdF.js.gz +0 -0
- package/dist/assets/env-DjkxkxdX.js.br +0 -0
- package/dist/assets/env-DjkxkxdX.js.gz +0 -0
- package/dist/assets/error-C7q1-2bC.js.br +0 -0
- package/dist/assets/error-C7q1-2bC.js.gz +0 -0
- package/dist/assets/fileTypes-Dbn0qwKS.js.br +0 -0
- package/dist/assets/fileTypes-Dbn0qwKS.js.gz +0 -0
- package/dist/assets/health-BwJ6Z251.js.br +0 -0
- package/dist/assets/health-BwJ6Z251.js.gz +0 -0
- package/dist/assets/history-D2TywQVv.js.br +0 -0
- package/dist/assets/history-D2TywQVv.js.gz +0 -0
- package/dist/assets/index-D14nUmm7.js.br +0 -0
- package/dist/assets/index-D14nUmm7.js.gz +0 -0
- package/dist/assets/integrations-BZFXW2Cp.js.br +0 -0
- package/dist/assets/integrations-BZFXW2Cp.js.gz +0 -0
- package/dist/assets/issues-CLvbBTek.js.br +0 -0
- package/dist/assets/issues-CLvbBTek.js.gz +0 -0
- package/dist/assets/packages-BeiF8W7l.js.br +0 -0
- package/dist/assets/packages-BeiF8W7l.js.gz +0 -0
- package/dist/assets/pages-BnAyUdL4.js.br +0 -3
- package/dist/assets/pages-BnAyUdL4.js.gz +0 -0
- package/dist/assets/project-GnljGud1.js.br +0 -0
- package/dist/assets/project-GnljGud1.js.gz +0 -0
- package/dist/assets/project-W_VltXAt.css +0 -1
- package/dist/assets/project-W_VltXAt.css.br +0 -0
- package/dist/assets/project-W_VltXAt.css.gz +0 -0
- package/dist/assets/project-files-e4-Q65vT.js.br +0 -0
- package/dist/assets/project-files-e4-Q65vT.js.gz +0 -0
- package/dist/assets/project-shared-ShellOutlet-DKYDipmC.js.br +0 -0
- package/dist/assets/project-shared-ShellOutlet-DKYDipmC.js.gz +0 -0
- package/dist/assets/project-shared-VBottomSheet-BSE28ENQ.js.br +0 -0
- package/dist/assets/project-shared-VBottomSheet-BSE28ENQ.js.gz +0 -0
- package/dist/assets/project-shared-VToolbar-CrezJP9z.js.br +0 -0
- package/dist/assets/project-shared-VToolbar-CrezJP9z.js.gz +0 -0
- package/dist/assets/project-shared-pageNames-6Jz0BfbS.js.br +0 -0
- package/dist/assets/project-shared-pageNames-6Jz0BfbS.js.gz +0 -0
- package/dist/assets/pull-requests-DH9gWw10.js.br +0 -0
- package/dist/assets/pull-requests-DH9gWw10.js.gz +0 -0
- package/dist/assets/session-Ck9aH4Yl.js.br +0 -0
- package/dist/assets/session-Ck9aH4Yl.js.gz +0 -0
- package/dist/assets/settings-D8Ofbk56.js.br +0 -0
- package/dist/assets/settings-D8Ofbk56.js.gz +0 -0
- package/dist/assets/useArchivedVibe64Sessions-LIZjeLbd.js.br +0 -0
- package/dist/assets/useArchivedVibe64Sessions-LIZjeLbd.js.gz +0 -0
- package/dist/assets/vue-flow-core-iwGljzru.js.br +0 -0
- package/dist/assets/vue-flow-core-iwGljzru.js.gz +0 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2012 Paul Miller (https://paulmillr.com), Elan Shanker
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the “Software”), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
|
13
|
+
all copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
21
|
+
THE SOFTWARE.
|
|
@@ -0,0 +1,305 @@
|
|
|
1
|
+
# Chokidar [](https://github.com/paulmillr/chokidar)
|
|
2
|
+
|
|
3
|
+
Minimal and efficient cross-platform file watching library
|
|
4
|
+
|
|
5
|
+
## Why?
|
|
6
|
+
|
|
7
|
+
There are many reasons to prefer Chokidar to raw fs.watch / fs.watchFile in 2026:
|
|
8
|
+
|
|
9
|
+
- Events are properly reported
|
|
10
|
+
- macOS events report filenames
|
|
11
|
+
- events are not reported twice
|
|
12
|
+
- changes are reported as add / change / unlink instead of useless `rename`
|
|
13
|
+
- Atomic writes are supported, using `atomic` option
|
|
14
|
+
- Some file editors use them
|
|
15
|
+
- Chunked writes are supported, using `awaitWriteFinish` option
|
|
16
|
+
- Large files are commonly written in chunks
|
|
17
|
+
- File / dir filtering is supported
|
|
18
|
+
- Symbolic links are supported
|
|
19
|
+
- Recursive watching is always supported, instead of partial when using raw events
|
|
20
|
+
- Includes a way to limit recursion depth
|
|
21
|
+
|
|
22
|
+
Chokidar relies on the Node.js core `fs` module, but when using
|
|
23
|
+
`fs.watch` and `fs.watchFile` for watching, it normalizes the events it
|
|
24
|
+
receives, often checking for truth by getting file stats and/or dir contents.
|
|
25
|
+
The `fs.watch`-based implementation is the default, which
|
|
26
|
+
avoids polling and keeps CPU usage down. Be advised that chokidar will initiate
|
|
27
|
+
watchers recursively for everything within scope of the paths that have been
|
|
28
|
+
specified, so be judicious about not wasting system resources by watching much
|
|
29
|
+
more than needed. For some cases, `fs.watchFile`, which utilizes polling and uses more resources, is used.
|
|
30
|
+
|
|
31
|
+
Made for [Brunch](https://brunch.io/) in 2012,
|
|
32
|
+
it is now used in [~30 million repositories](https://www.npmjs.com/browse/depended/chokidar) and
|
|
33
|
+
has proven itself in production environments.
|
|
34
|
+
|
|
35
|
+
- **Nov 2025 update:** v5 is out. Makes package ESM-only and increases minimum node.js requirement to v20.
|
|
36
|
+
- **Sep 2024 update:** v4 is out! It decreases dependency count from 13 to 1, removes
|
|
37
|
+
support for globs, adds support for ESM / Common.js modules, and bumps minimum node.js version from v8 to v14.
|
|
38
|
+
Check out [upgrading](#upgrading).
|
|
39
|
+
|
|
40
|
+
## Getting started
|
|
41
|
+
|
|
42
|
+
Install with npm:
|
|
43
|
+
|
|
44
|
+
```sh
|
|
45
|
+
npm install chokidar
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Use it in your code:
|
|
49
|
+
|
|
50
|
+
```javascript
|
|
51
|
+
import chokidar from 'chokidar';
|
|
52
|
+
|
|
53
|
+
// One-liner for current directory
|
|
54
|
+
chokidar.watch('.').on('all', (event, path) => {
|
|
55
|
+
console.log(event, path);
|
|
56
|
+
});
|
|
57
|
+
|
|
58
|
+
// Extended options
|
|
59
|
+
// ----------------
|
|
60
|
+
|
|
61
|
+
// Initialize watcher.
|
|
62
|
+
const watcher = chokidar.watch('file, dir, or array', {
|
|
63
|
+
ignored: (path, stats) => stats?.isFile() && !path.endsWith('.js'), // only watch js files
|
|
64
|
+
persistent: true,
|
|
65
|
+
});
|
|
66
|
+
|
|
67
|
+
// Something to use when events are received.
|
|
68
|
+
const log = console.log.bind(console);
|
|
69
|
+
// Add event listeners.
|
|
70
|
+
watcher
|
|
71
|
+
.on('add', (path) => log(`File ${path} has been added`))
|
|
72
|
+
.on('change', (path) => log(`File ${path} has been changed`))
|
|
73
|
+
.on('unlink', (path) => log(`File ${path} has been removed`));
|
|
74
|
+
|
|
75
|
+
// More possible events.
|
|
76
|
+
watcher
|
|
77
|
+
.on('addDir', (path) => log(`Directory ${path} has been added`))
|
|
78
|
+
.on('unlinkDir', (path) => log(`Directory ${path} has been removed`))
|
|
79
|
+
.on('error', (error) => log(`Watcher error: ${error}`))
|
|
80
|
+
.on('ready', () => log('Initial scan complete. Ready for changes'))
|
|
81
|
+
.on('raw', (event, path, details) => {
|
|
82
|
+
// internal
|
|
83
|
+
log('Raw event info:', event, path, details);
|
|
84
|
+
});
|
|
85
|
+
|
|
86
|
+
// 'add', 'addDir' and 'change' events also receive stat() results as second
|
|
87
|
+
// argument when available: https://nodejs.org/api/fs.html#fs_class_fs_stats
|
|
88
|
+
watcher.on('change', (path, stats) => {
|
|
89
|
+
if (stats) console.log(`File ${path} changed size to ${stats.size}`);
|
|
90
|
+
});
|
|
91
|
+
|
|
92
|
+
// Watch new files.
|
|
93
|
+
watcher.add('new-file');
|
|
94
|
+
watcher.add(['new-file-2', 'new-file-3']);
|
|
95
|
+
|
|
96
|
+
// Get list of actual paths being watched on the filesystem
|
|
97
|
+
let watchedPaths = watcher.getWatched();
|
|
98
|
+
|
|
99
|
+
// Un-watch some files.
|
|
100
|
+
await watcher.unwatch('new-file');
|
|
101
|
+
|
|
102
|
+
// Stop watching. The method is async!
|
|
103
|
+
await watcher.close().then(() => console.log('closed'));
|
|
104
|
+
|
|
105
|
+
// Full list of options. See below for descriptions.
|
|
106
|
+
// Do not use this example!
|
|
107
|
+
chokidar.watch('file', {
|
|
108
|
+
persistent: true,
|
|
109
|
+
|
|
110
|
+
// ignore .txt files
|
|
111
|
+
ignored: (file) => file.endsWith('.txt'),
|
|
112
|
+
// watch only .txt files
|
|
113
|
+
// ignored: (file, _stats) => _stats?.isFile() && !file.endsWith('.txt'),
|
|
114
|
+
|
|
115
|
+
awaitWriteFinish: true, // emit single event when chunked writes are completed
|
|
116
|
+
atomic: true, // emit proper events when "atomic writes" (mv _tmp file) are used
|
|
117
|
+
|
|
118
|
+
// The options also allow specifying custom intervals in ms
|
|
119
|
+
// awaitWriteFinish: {
|
|
120
|
+
// stabilityThreshold: 2000,
|
|
121
|
+
// pollInterval: 100
|
|
122
|
+
// },
|
|
123
|
+
// atomic: 100,
|
|
124
|
+
|
|
125
|
+
interval: 100,
|
|
126
|
+
binaryInterval: 300,
|
|
127
|
+
|
|
128
|
+
cwd: '.',
|
|
129
|
+
depth: 99,
|
|
130
|
+
|
|
131
|
+
followSymlinks: true,
|
|
132
|
+
ignoreInitial: false,
|
|
133
|
+
ignorePermissionErrors: false,
|
|
134
|
+
usePolling: false,
|
|
135
|
+
alwaysStat: false,
|
|
136
|
+
});
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
`chokidar.watch(paths, [options])`
|
|
140
|
+
|
|
141
|
+
- `paths` (string or array of strings). Paths to files, dirs to be watched
|
|
142
|
+
recursively.
|
|
143
|
+
- `options` (object) Options object as defined below:
|
|
144
|
+
|
|
145
|
+
#### Persistence
|
|
146
|
+
|
|
147
|
+
- `persistent` (default: `true`). Indicates whether the process
|
|
148
|
+
should continue to run as long as files are being watched.
|
|
149
|
+
|
|
150
|
+
#### Path filtering
|
|
151
|
+
|
|
152
|
+
- `ignored` function, regex, or path. Defines files/paths to be ignored.
|
|
153
|
+
The whole relative or absolute path is tested, not just filename. If a function with two arguments
|
|
154
|
+
is provided, it gets called twice per path - once with a single argument (the path), second
|
|
155
|
+
time with two arguments (the path and the
|
|
156
|
+
[`fs.Stats`](https://nodejs.org/api/fs.html#fs_class_fs_stats)
|
|
157
|
+
object of that path).
|
|
158
|
+
- `ignoreInitial` (default: `false`). If set to `false` then `add`/`addDir` events are also emitted for matching paths while
|
|
159
|
+
instantiating the watching as chokidar discovers these file paths (before the `ready` event).
|
|
160
|
+
- `followSymlinks` (default: `true`). When `false`, only the
|
|
161
|
+
symlinks themselves will be watched for changes instead of following
|
|
162
|
+
the link references and bubbling events through the link's path.
|
|
163
|
+
- `cwd` (no default). The base directory from which watch `paths` are to be
|
|
164
|
+
derived. Paths emitted with events will be relative to this.
|
|
165
|
+
|
|
166
|
+
#### Performance
|
|
167
|
+
|
|
168
|
+
- `usePolling` (default: `false`).
|
|
169
|
+
Whether to use fs.watchFile (backed by polling), or fs.watch. If polling
|
|
170
|
+
leads to high CPU utilization, consider setting this to `false`. It is
|
|
171
|
+
typically necessary to **set this to `true` to successfully watch files over
|
|
172
|
+
a network**, and it may be necessary to successfully watch files in other
|
|
173
|
+
non-standard situations. Setting to `true` explicitly on MacOS overrides the
|
|
174
|
+
`useFsEvents` default. You may also set the CHOKIDAR_USEPOLLING env variable
|
|
175
|
+
to true (1) or false (0) in order to override this option.
|
|
176
|
+
- _Polling-specific settings_ (effective when `usePolling: true`)
|
|
177
|
+
- `interval` (default: `100`). Interval of file system polling, in milliseconds. You may also
|
|
178
|
+
set the CHOKIDAR_INTERVAL env variable to override this option.
|
|
179
|
+
- `binaryInterval` (default: `300`). Interval of file system
|
|
180
|
+
polling for binary files.
|
|
181
|
+
([see list of binary extensions](https://github.com/sindresorhus/binary-extensions/blob/master/binary-extensions.json))
|
|
182
|
+
- `alwaysStat` (default: `false`). If relying upon the
|
|
183
|
+
[`fs.Stats`](https://nodejs.org/api/fs.html#fs_class_fs_stats)
|
|
184
|
+
object that may get passed with `add`, `addDir`, and `change` events, set
|
|
185
|
+
this to `true` to ensure it is provided even in cases where it wasn't
|
|
186
|
+
already available from the underlying watch events.
|
|
187
|
+
- `depth` (default: `undefined`). If set, limits how many levels of
|
|
188
|
+
subdirectories will be traversed.
|
|
189
|
+
- `awaitWriteFinish` (default: `false`).
|
|
190
|
+
By default, the `add` event will fire when a file first appears on disk, before
|
|
191
|
+
the entire file has been written. Furthermore, in some cases some `change`
|
|
192
|
+
events will be emitted while the file is being written. In some cases,
|
|
193
|
+
especially when watching for large files there will be a need to wait for the
|
|
194
|
+
write operation to finish before responding to a file creation or modification.
|
|
195
|
+
Setting `awaitWriteFinish` to `true` (or a truthy value) will poll file size,
|
|
196
|
+
holding its `add` and `change` events until the size does not change for a
|
|
197
|
+
configurable amount of time. The appropriate duration setting is heavily
|
|
198
|
+
dependent on the OS and hardware. For accurate detection this parameter should
|
|
199
|
+
be relatively high, making file watching much less responsive.
|
|
200
|
+
Use with caution.
|
|
201
|
+
- _`options.awaitWriteFinish` can be set to an object in order to adjust
|
|
202
|
+
timing params:_
|
|
203
|
+
- `awaitWriteFinish.stabilityThreshold` (default: 2000). Amount of time in
|
|
204
|
+
milliseconds for a file size to remain constant before emitting its event.
|
|
205
|
+
- `awaitWriteFinish.pollInterval` (default: 100). File size polling interval, in milliseconds.
|
|
206
|
+
|
|
207
|
+
#### Errors
|
|
208
|
+
|
|
209
|
+
- `ignorePermissionErrors` (default: `false`). Indicates whether to watch files
|
|
210
|
+
that don't have read permissions if possible. If watching fails due to `EPERM`
|
|
211
|
+
or `EACCES` with this set to `true`, the errors will be suppressed silently.
|
|
212
|
+
- `atomic` (default: `true` if `useFsEvents` and `usePolling` are `false`).
|
|
213
|
+
Automatically filters out artifacts that occur when using editors that use
|
|
214
|
+
"atomic writes" instead of writing directly to the source file. If a file is
|
|
215
|
+
re-added within 100 ms of being deleted, Chokidar emits a `change` event
|
|
216
|
+
rather than `unlink` then `add`. If the default of 100 ms does not work well
|
|
217
|
+
for you, you can override it by setting `atomic` to a custom value, in
|
|
218
|
+
milliseconds.
|
|
219
|
+
|
|
220
|
+
### Methods & Events
|
|
221
|
+
|
|
222
|
+
`chokidar.watch()` produces an instance of `FSWatcher`. Methods of `FSWatcher`:
|
|
223
|
+
|
|
224
|
+
- `.add(path / paths)`: Add files, directories for tracking.
|
|
225
|
+
Takes an array of strings or just one string.
|
|
226
|
+
- `.on(event, callback)`: Listen for an FS event.
|
|
227
|
+
Available events: `add`, `addDir`, `change`, `unlink`, `unlinkDir`, `ready`,
|
|
228
|
+
`raw`, `error`.
|
|
229
|
+
Additionally `all` is available which gets emitted with the underlying event
|
|
230
|
+
name and path for every event other than `ready`, `raw`, and `error`. `raw` is internal, use it carefully.
|
|
231
|
+
- `.unwatch(path / paths)`: Stop watching files or directories.
|
|
232
|
+
Takes an array of strings or just one string.
|
|
233
|
+
- `.close()`: **async** Removes all listeners from watched files. Asynchronous, returns Promise. Use with `await` to ensure bugs don't happen.
|
|
234
|
+
- `.getWatched()`: Returns an object representing all the paths on the file
|
|
235
|
+
system being watched by this `FSWatcher` instance. The object's keys are all the
|
|
236
|
+
directories (using absolute paths unless the `cwd` option was used), and the
|
|
237
|
+
values are arrays of the names of the items contained in each directory.
|
|
238
|
+
|
|
239
|
+
### CLI
|
|
240
|
+
|
|
241
|
+
Check out third party [chokidar-cli](https://github.com/open-cli-tools/chokidar-cli),
|
|
242
|
+
which allows to execute a command on each change, or get a stdio stream of change events.
|
|
243
|
+
|
|
244
|
+
## Troubleshooting
|
|
245
|
+
|
|
246
|
+
Sometimes, Chokidar runs out of file handles, causing `EMFILE` and `ENOSP` errors:
|
|
247
|
+
|
|
248
|
+
- `bash: cannot set terminal process group (-1): Inappropriate ioctl for device bash: no job control in this shell`
|
|
249
|
+
- `Error: watch /home/ ENOSPC`
|
|
250
|
+
|
|
251
|
+
There are two things that can cause it.
|
|
252
|
+
|
|
253
|
+
1. Exhausted file handles for generic fs operations
|
|
254
|
+
- Can be solved by using [graceful-fs](https://www.npmjs.com/package/graceful-fs),
|
|
255
|
+
which can monkey-patch native `fs` module used by chokidar: `let fs = require('fs'); let grfs = require('graceful-fs'); grfs.gracefulify(fs);`
|
|
256
|
+
- Can also be solved by tuning OS: `echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p`.
|
|
257
|
+
2. Exhausted file handles for `fs.watch`
|
|
258
|
+
- Can't seem to be solved by graceful-fs or OS tuning
|
|
259
|
+
- It's possible to start using `usePolling: true`, which will switch backend to resource-intensive `fs.watchFile`
|
|
260
|
+
|
|
261
|
+
All fsevents-related issues (`WARN optional dep failed`, `fsevents is not a constructor`) are solved by upgrading to v4+.
|
|
262
|
+
|
|
263
|
+
## Changelog
|
|
264
|
+
|
|
265
|
+
- **v4 (Sep 2024):** remove glob support and bundled fsevents. Decrease dependency count from 13 to 1. Rewrite in typescript. Bumps minimum node.js requirement to v14+
|
|
266
|
+
- **v3 (Apr 2019):** massive CPU & RAM consumption improvements; reduces deps / package size by a factor of 17x and bumps Node.js requirement to v8.16+.
|
|
267
|
+
- **v2 (Dec 2017):** globs are now posix-style-only. Tons of bugfixes.
|
|
268
|
+
- **v1 (Apr 2015):** glob support, symlink support, tons of bugfixes. Node 0.8+ is supported
|
|
269
|
+
- **v0.1 (Apr 2012):** Initial release, extracted from [Brunch](https://github.com/brunch/brunch/blob/9847a065aea300da99bd0753f90354cde9de1261/src/helpers.coffee#L66)
|
|
270
|
+
|
|
271
|
+
### Upgrading
|
|
272
|
+
|
|
273
|
+
If you've used globs before and want do replicate the functionality with v4:
|
|
274
|
+
|
|
275
|
+
```js
|
|
276
|
+
// v3
|
|
277
|
+
chok.watch('**/*.js');
|
|
278
|
+
chok.watch('./directory/**/*');
|
|
279
|
+
|
|
280
|
+
// v4
|
|
281
|
+
chok.watch('.', {
|
|
282
|
+
ignored: (path, stats) => stats?.isFile() && !path.endsWith('.js'), // only watch js files
|
|
283
|
+
});
|
|
284
|
+
chok.watch('./directory');
|
|
285
|
+
|
|
286
|
+
// other way
|
|
287
|
+
import { glob } from 'node:fs/promises';
|
|
288
|
+
const watcher = watch(await Array.fromAsync(glob('**/*.js')));
|
|
289
|
+
|
|
290
|
+
// unwatching
|
|
291
|
+
// v3
|
|
292
|
+
chok.unwatch('**/*.js');
|
|
293
|
+
// v4
|
|
294
|
+
chok.unwatch(await Array.fromAsync(glob('**/*.js')));
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
## Also
|
|
298
|
+
|
|
299
|
+
Why was chokidar named this way? What's the meaning behind it?
|
|
300
|
+
|
|
301
|
+
> Chowkidar is a transliteration of a Hindi word meaning 'watchman, gatekeeper', चौकीदार. This ultimately comes from Sanskrit _ चतुष्क_ (crossway, quadrangle, consisting-of-four). This word is also used in other languages like Urdu as (چوکیدار) which is widely used in Pakistan and India.
|
|
302
|
+
|
|
303
|
+
## License
|
|
304
|
+
|
|
305
|
+
MIT (c) Paul Miller (<https://paulmillr.com>), see [LICENSE](LICENSE) file.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2012-2019 Thorsten Lorenz, Paul Miller (https://paulmillr.com)
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
# readdirp [](https://github.com/paulmillr/readdirp)
|
|
2
|
+
|
|
3
|
+
Recursive version of fs.readdir. Exposes a **stream API** (with small RAM & CPU footprint) and a **promise API**.
|
|
4
|
+
|
|
5
|
+
Faster than built-in `fs.readdir recursive: true`, and uses less RAM.
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
npm install readdirp
|
|
9
|
+
jsr add jsr:@paulmillr/readdirp
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
```javascript
|
|
13
|
+
// Use streams to achieve small RAM & CPU footprint.
|
|
14
|
+
// 1) Streams example with for-await.
|
|
15
|
+
import readdirp from 'readdirp';
|
|
16
|
+
for await (const entry of readdirp('.')) {
|
|
17
|
+
const {path} = entry;
|
|
18
|
+
console.log(`${JSON.stringify({path})}`);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// 2) Streams example, non for-await.
|
|
22
|
+
// Print out all JS files along with their size within the current folder & subfolders.
|
|
23
|
+
import readdirp from 'readdirp';
|
|
24
|
+
readdirp('.', {alwaysStat: true, fileFilter: (f) => f.basename.endsWith('.js')})
|
|
25
|
+
.on('data', (entry) => {
|
|
26
|
+
const {path, stats: {size}} = entry;
|
|
27
|
+
console.log(`${JSON.stringify({path, size})}`);
|
|
28
|
+
})
|
|
29
|
+
// Optionally call stream.destroy() in `warn()` in order to abort and cause 'close' to be emitted
|
|
30
|
+
.on('warn', error => console.error('non-fatal error', error))
|
|
31
|
+
.on('error', error => console.error('fatal error', error))
|
|
32
|
+
.on('end', () => console.log('done'));
|
|
33
|
+
|
|
34
|
+
// 3) Promise example. More RAM and CPU than streams / for-await.
|
|
35
|
+
import { readdirpPromise } from 'readdirp';
|
|
36
|
+
const files = await readdirpPromise('.');
|
|
37
|
+
console.log(files.map(file => file.path));
|
|
38
|
+
|
|
39
|
+
// Other options.
|
|
40
|
+
import readdirp from 'readdirp';
|
|
41
|
+
readdirp('test', {
|
|
42
|
+
fileFilter: (f) => f.basename.endsWith('.js'),
|
|
43
|
+
directoryFilter: (d) => d.basename !== '.git',
|
|
44
|
+
// directoryFilter: (di) => di.basename.length === 9
|
|
45
|
+
type: 'files_directories',
|
|
46
|
+
depth: 1
|
|
47
|
+
});
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## API
|
|
51
|
+
|
|
52
|
+
`const stream = readdirp(root[, options])` — **Stream API**
|
|
53
|
+
|
|
54
|
+
- Reads given root recursively and returns a `stream` of [entry infos](#entryinfo)
|
|
55
|
+
- Optionally can be used like `for await (const entry of stream)` with node.js 10+ (`asyncIterator`).
|
|
56
|
+
- `on('data', (entry) => {})` [entry info](#entryinfo) for every file / dir.
|
|
57
|
+
- `on('warn', (error) => {})` non-fatal `Error` that prevents a file / dir from being processed. Example: inaccessible to the user.
|
|
58
|
+
- `on('error', (error) => {})` fatal `Error` which also ends the stream. Example: illegal options where passed.
|
|
59
|
+
- `on('end')` — we are done. Called when all entries were found and no more will be emitted.
|
|
60
|
+
- `on('close')` — stream is destroyed via `stream.destroy()`.
|
|
61
|
+
Could be useful if you want to manually abort even on a non fatal error.
|
|
62
|
+
At that point the stream is no longer `readable` and no more entries, warning or errors are emitted
|
|
63
|
+
- To learn more about streams, consult the very detailed [nodejs streams documentation](https://nodejs.org/api/stream.html)
|
|
64
|
+
or the [stream-handbook](https://github.com/substack/stream-handbook)
|
|
65
|
+
|
|
66
|
+
`const entries = await readdirp.promise(root[, options])` — **Promise API**. Returns a list of [entry infos](#entryinfo).
|
|
67
|
+
|
|
68
|
+
First argument is awalys `root`, path in which to start reading and recursing into subdirectories.
|
|
69
|
+
|
|
70
|
+
### options
|
|
71
|
+
|
|
72
|
+
- `fileFilter`: filter to include or exclude files
|
|
73
|
+
- **Function**: a function that takes an entry info as a parameter and returns true to include or false to exclude the entry
|
|
74
|
+
- `directoryFilter`: filter to include/exclude directories found and to recurse into. Directories that do not pass a filter will not be recursed into.
|
|
75
|
+
- `depth: 5`: depth at which to stop recursing even if more subdirectories are found
|
|
76
|
+
- `type: 'files'`: determines if data events on the stream should be emitted for `'files'` (default), `'directories'`, `'files_directories'`, or `'all'`. Setting to `'all'` will also include entries for other types of file descriptors like character devices, unix sockets and named pipes.
|
|
77
|
+
- `alwaysStat: false`: always return `stats` property for every file. Default is `false`, readdirp will return `Dirent` entries. Setting it to `true` can double readdir execution time - use it only when you need file `size`, `mtime` etc. Cannot be enabled on node <10.10.0.
|
|
78
|
+
- `lstat: false`: include symlink entries in the stream along with files. When `true`, `fs.lstat` would be used instead of `fs.stat`
|
|
79
|
+
|
|
80
|
+
### `EntryInfo`
|
|
81
|
+
|
|
82
|
+
Has the following properties:
|
|
83
|
+
|
|
84
|
+
- `path: 'assets/javascripts/react.js'`: path to the file/directory (relative to given root)
|
|
85
|
+
- `fullPath: '/Users/dev/projects/app/assets/javascripts/react.js'`: full path to the file/directory found
|
|
86
|
+
- `basename: 'react.js'`: name of the file/directory
|
|
87
|
+
- `dirent: fs.Dirent`: built-in [dir entry object](https://nodejs.org/api/fs.html#fs_class_fs_dirent) - only with `alwaysStat: false`
|
|
88
|
+
- `stats: fs.Stats`: built in [stat object](https://nodejs.org/api/fs.html#fs_class_fs_stats) - only with `alwaysStat: true`
|
|
89
|
+
|
|
90
|
+
## Changelog
|
|
91
|
+
|
|
92
|
+
- 4.0 (Aug 25, 2024) rewritten in typescript, producing hybrid common.js / esm module.
|
|
93
|
+
- Remove glob support and all dependencies
|
|
94
|
+
- Make sure you're using `let {readdirp} = require('readdirp')` in common.js
|
|
95
|
+
- 3.5 (Oct 13, 2020) disallows recursive directory-based symlinks.
|
|
96
|
+
Before, it could have entered infinite loop.
|
|
97
|
+
- 3.4 (Mar 19, 2020) adds support for directory-based symlinks.
|
|
98
|
+
- 3.3 (Dec 6, 2019) stabilizes RAM consumption and enables perf management with `highWaterMark` option. Fixes race conditions related to `for-await` looping.
|
|
99
|
+
- 3.2 (Oct 14, 2019) improves performance by 250% and makes streams implementation more idiomatic.
|
|
100
|
+
- 3.1 (Jul 7, 2019) brings `bigint` support to `stat` output on Windows. This is backwards-incompatible for some cases. Be careful. It you use it incorrectly, you'll see "TypeError: Cannot mix BigInt and other types, use explicit conversions".
|
|
101
|
+
- 3.0 brings huge performance improvements and stream backpressure support.
|
|
102
|
+
- Upgrading 2.x to 3.x:
|
|
103
|
+
- Signature changed from `readdirp(options)` to `readdirp(root, options)`
|
|
104
|
+
- Replaced callback API with promise API.
|
|
105
|
+
- Renamed `entryType` option to `type`
|
|
106
|
+
- Renamed `entryType: 'both'` to `'files_directories'`
|
|
107
|
+
- `EntryInfo`
|
|
108
|
+
- Renamed `stat` to `stats`
|
|
109
|
+
- Emitted only when `alwaysStat: true`
|
|
110
|
+
- `dirent` is emitted instead of `stats` by default with `alwaysStat: false`
|
|
111
|
+
- Renamed `name` to `basename`
|
|
112
|
+
- Removed `parentDir` and `fullParentDir` properties
|
|
113
|
+
- Supported node.js versions:
|
|
114
|
+
- 4.x: node 14+
|
|
115
|
+
- 3.x: node 8+
|
|
116
|
+
- 2.x: node 0.6+
|
|
117
|
+
|
|
118
|
+
## License
|
|
119
|
+
|
|
120
|
+
Copyright (c) 2012-2019 Thorsten Lorenz, Paul Miller (<https://paulmillr.com>)
|
|
121
|
+
|
|
122
|
+
MIT License, see [LICENSE](LICENSE) file.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vibe64",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.80",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Run Vibe64 against the current project.",
|
|
6
6
|
"type": "module",
|
|
@@ -53,15 +53,15 @@
|
|
|
53
53
|
"@fastify/static": "10.1.4",
|
|
54
54
|
"@fastify/websocket": "11.3.1",
|
|
55
55
|
"@jskit-ai/agent": "0.1.3",
|
|
56
|
-
"@jskit-ai/assistant-core": "0.2.
|
|
57
|
-
"@jskit-ai/assistant-runtime": "0.2.
|
|
58
|
-
"@jskit-ai/assistant-voice": "0.2.
|
|
56
|
+
"@jskit-ai/assistant-core": "0.2.80",
|
|
57
|
+
"@jskit-ai/assistant-runtime": "0.2.86",
|
|
58
|
+
"@jskit-ai/assistant-voice": "0.2.86",
|
|
59
59
|
"@jskit-ai/connector-google-calendar": "0.2.49",
|
|
60
|
-
"@jskit-ai/connectors-catalog": "0.2.
|
|
60
|
+
"@jskit-ai/connectors-catalog": "0.2.52",
|
|
61
61
|
"@jskit-ai/connectors-core": "0.2.49",
|
|
62
62
|
"@jskit-ai/http-runtime": "0.2.32",
|
|
63
63
|
"@jskit-ai/kernel": "0.2.32",
|
|
64
|
-
"@jskit-ai/payments-core": "0.2.
|
|
64
|
+
"@jskit-ai/payments-core": "0.2.38",
|
|
65
65
|
"@jskit-ai/realtime": "0.2.51",
|
|
66
66
|
"@jskit-ai/resource-core": "0.1.223",
|
|
67
67
|
"@jskit-ai/uploads-runtime": "0.2.32",
|
|
@@ -107,6 +107,7 @@
|
|
|
107
107
|
"avvio": "9.3.0",
|
|
108
108
|
"base64id": "2.0.0",
|
|
109
109
|
"bundle-name": "4.1.0",
|
|
110
|
+
"chokidar": "5.0.0",
|
|
110
111
|
"cluster-key-slot": "1.1.2",
|
|
111
112
|
"content-type": "1.0.5",
|
|
112
113
|
"cookie": "0.7.2",
|
|
@@ -129,7 +130,7 @@
|
|
|
129
130
|
"fastq": "1.20.3",
|
|
130
131
|
"find-my-way": "9.9.0",
|
|
131
132
|
"flatted": "3.4.4",
|
|
132
|
-
"genesis-compiler": "1.10.
|
|
133
|
+
"genesis-compiler": "1.10.27",
|
|
133
134
|
"genesis-stack": "1.4.13",
|
|
134
135
|
"get-port": "7.2.0",
|
|
135
136
|
"glob": "13.0.6",
|
|
@@ -162,6 +163,7 @@
|
|
|
162
163
|
"process-warning": "5.1.1",
|
|
163
164
|
"quick-format-unescaped": "4.0.4",
|
|
164
165
|
"readable-stream": "3.6.2",
|
|
166
|
+
"readdirp": "5.1.1",
|
|
165
167
|
"redis": "5.12.1",
|
|
166
168
|
"ret": "0.5.0",
|
|
167
169
|
"reusify": "1.1.0",
|
|
@@ -275,6 +277,7 @@
|
|
|
275
277
|
"avvio",
|
|
276
278
|
"base64id",
|
|
277
279
|
"bundle-name",
|
|
280
|
+
"chokidar",
|
|
278
281
|
"cluster-key-slot",
|
|
279
282
|
"content-type",
|
|
280
283
|
"cookie",
|
|
@@ -323,6 +326,7 @@
|
|
|
323
326
|
"process-warning",
|
|
324
327
|
"quick-format-unescaped",
|
|
325
328
|
"readable-stream",
|
|
329
|
+
"readdirp",
|
|
326
330
|
"redis",
|
|
327
331
|
"ret",
|
|
328
332
|
"reusify",
|