vibeman 0.0.13 → 0.0.16
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/LICENSE +201 -0
- package/NOTICE +4 -0
- package/dist/api.js +1155 -300
- package/dist/commit.txt +1 -1
- package/dist/index.js +127 -48
- package/dist/node_modules/node-pty/LICENSE +69 -0
- package/dist/node_modules/node-pty/README.md +165 -0
- package/dist/node_modules/node-pty/binding.gyp +111 -0
- package/dist/node_modules/node-pty/deps/.editorconfig +2 -0
- package/dist/node_modules/node-pty/deps/winpty/.drone.yml +17 -0
- package/dist/node_modules/node-pty/deps/winpty/.gitattributes +19 -0
- package/dist/node_modules/node-pty/deps/winpty/LICENSE +21 -0
- package/dist/node_modules/node-pty/deps/winpty/Makefile +166 -0
- package/dist/node_modules/node-pty/deps/winpty/README.md +151 -0
- package/dist/node_modules/node-pty/deps/winpty/RELEASES.md +280 -0
- package/dist/node_modules/node-pty/deps/winpty/VERSION.txt +1 -0
- package/dist/node_modules/node-pty/deps/winpty/configure +167 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/BufferResizeTests.cc +90 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ChangeScreenBuffer.cc +53 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ClearConsole.cc +72 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ConinMode.cc +117 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ConinMode.ps1 +116 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ConoutMode.cc +113 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/DebugClient.py +42 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/DebugServer.py +63 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/DumpLines.py +5 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/EnableExtendedFlags.txt +46 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP437-Consolas.txt +528 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP437-Lucida.txt +633 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP932.txt +630 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP936.txt +630 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP949.txt +630 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/CP950.txt +630 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/MinimumWindowWidths.txt +16 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/Results.txt +4 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Font-Report-June2016/Windows10SetFontBugginess.txt +144 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/FontSurvey.cc +100 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/FormatChar.h +21 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/FreezePerfTest.cc +62 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/GetCh.cc +20 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/GetConsolePos.cc +41 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/GetFont.cc +261 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/IdentifyConsoleWindow.ps1 +51 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/IsNewConsole.cc +87 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/MouseInputNotes.txt +90 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/MoveConsoleWindow.cc +34 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Notes.txt +219 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/OSVersion.cc +27 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ScreenBufferFreezeInactive.cc +101 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ScreenBufferTest.cc +671 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ScreenBufferTest2.cc +151 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/SelectAllTest.cc +45 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/SetBufferSize.cc +32 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/SetCursorPos.cc +10 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/SetFont.cc +145 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/SetWindowRect.cc +36 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ShowArgv.cc +12 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/ShowConsoleInput.cc +40 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Spew.py +5 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/TestUtil.cc +172 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/UnicodeDoubleWidthTest.cc +102 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/UnicodeWideTest1.cc +246 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/UnicodeWideTest2.cc +130 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/UnixEcho.cc +89 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Utf16Echo.cc +46 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/VeryLargeRead.cc +122 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/VkEscapeTest.cc +56 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win10ResizeWhileFrozen.cc +52 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win10WrapTest1.cc +57 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win10WrapTest2.cc +30 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win32Echo1.cc +26 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win32Echo2.cc +19 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win32Test1.cc +46 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win32Test2.cc +70 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win32Test3.cc +78 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/Win32Write1.cc +44 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/WindowsBugCrashReader.cc +27 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/WriteConsole.cc +106 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/build32.sh +9 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/build64.sh +9 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/color-test.sh +212 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/font-notes.txt +300 -0
- package/dist/node_modules/node-pty/deps/winpty/misc/winbug-15048.cc +201 -0
- package/dist/node_modules/node-pty/deps/winpty/ship/build-pty4j-libpty.bat +36 -0
- package/dist/node_modules/node-pty/deps/winpty/ship/common_ship.py +53 -0
- package/dist/node_modules/node-pty/deps/winpty/ship/make_msvc_package.py +165 -0
- package/dist/node_modules/node-pty/deps/winpty/ship/ship.py +108 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Agent.cc +613 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Agent.h +103 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/AgentCreateDesktop.cc +84 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/AgentCreateDesktop.h +28 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleFont.cc +632 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleFont.h +28 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleInput.cc +852 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleInput.h +109 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleInputReencoding.cc +121 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleInputReencoding.h +36 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleLine.cc +152 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/ConsoleLine.h +41 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Coord.h +87 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/DebugShowInput.cc +239 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/DebugShowInput.h +32 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/DefaultInputMap.cc +422 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/DefaultInputMap.h +28 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/DsrSender.h +30 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/EventLoop.cc +99 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/EventLoop.h +47 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/InputMap.cc +246 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/InputMap.h +114 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/LargeConsoleRead.cc +71 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/LargeConsoleRead.h +68 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/NamedPipe.cc +378 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/NamedPipe.h +125 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Scraper.cc +699 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Scraper.h +103 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/SimplePool.h +75 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/SmallRect.h +143 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Terminal.cc +535 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Terminal.h +69 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/UnicodeEncoding.h +157 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/UnicodeEncodingTest.cc +189 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Win32Console.cc +107 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Win32Console.h +67 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Win32ConsoleBuffer.cc +193 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/Win32ConsoleBuffer.h +99 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/main.cc +114 -0
- package/dist/node_modules/node-pty/deps/winpty/src/agent/subdir.mk +61 -0
- package/dist/node_modules/node-pty/deps/winpty/src/configurations.gypi +60 -0
- package/dist/node_modules/node-pty/deps/winpty/src/debugserver/DebugServer.cc +117 -0
- package/dist/node_modules/node-pty/deps/winpty/src/debugserver/subdir.mk +41 -0
- package/dist/node_modules/node-pty/deps/winpty/src/include/winpty.h +242 -0
- package/dist/node_modules/node-pty/deps/winpty/src/include/winpty_constants.h +131 -0
- package/dist/node_modules/node-pty/deps/winpty/src/libwinpty/AgentLocation.cc +75 -0
- package/dist/node_modules/node-pty/deps/winpty/src/libwinpty/AgentLocation.h +28 -0
- package/dist/node_modules/node-pty/deps/winpty/src/libwinpty/LibWinptyException.h +54 -0
- package/dist/node_modules/node-pty/deps/winpty/src/libwinpty/WinptyInternal.h +72 -0
- package/dist/node_modules/node-pty/deps/winpty/src/libwinpty/subdir.mk +46 -0
- package/dist/node_modules/node-pty/deps/winpty/src/libwinpty/winpty.cc +970 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/AgentMsg.h +38 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/BackgroundDesktop.cc +122 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/BackgroundDesktop.h +73 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/Buffer.cc +103 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/Buffer.h +102 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/DebugClient.cc +187 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/DebugClient.h +38 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/GenRandom.cc +138 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/GenRandom.h +55 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/GetCommitHash.bat +13 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/Mutex.h +54 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/OsModule.h +63 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/OwnedHandle.cc +36 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/OwnedHandle.h +45 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/PrecompiledHeader.h +43 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/StringBuilder.h +227 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/StringBuilderTest.cc +114 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/StringUtil.cc +55 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/StringUtil.h +80 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/TimeMeasurement.h +63 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/UnixCtrlChars.h +45 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/UpdateGenVersion.bat +20 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WindowsSecurity.cc +460 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WindowsSecurity.h +104 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WindowsVersion.cc +252 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WindowsVersion.h +29 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WinptyAssert.cc +55 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WinptyAssert.h +64 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WinptyException.cc +57 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WinptyException.h +43 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WinptyVersion.cc +42 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/WinptyVersion.h +27 -0
- package/dist/node_modules/node-pty/deps/winpty/src/shared/winpty_snprintf.h +99 -0
- package/dist/node_modules/node-pty/deps/winpty/src/subdir.mk +5 -0
- package/dist/node_modules/node-pty/deps/winpty/src/tests/subdir.mk +28 -0
- package/dist/node_modules/node-pty/deps/winpty/src/tests/trivial_test.cc +158 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/InputHandler.cc +114 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/InputHandler.h +56 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/OutputHandler.cc +80 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/OutputHandler.h +53 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/Util.cc +86 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/Util.h +31 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/WakeupFd.cc +70 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/WakeupFd.h +42 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/main.cc +729 -0
- package/dist/node_modules/node-pty/deps/winpty/src/unix-adapter/subdir.mk +41 -0
- package/dist/node_modules/node-pty/deps/winpty/src/winpty.gyp +234 -0
- package/dist/node_modules/node-pty/deps/winpty/vcbuild.bat +83 -0
- package/dist/node_modules/node-pty/lib/conpty_console_list_agent.js +16 -0
- package/dist/node_modules/node-pty/lib/conpty_console_list_agent.js.map +1 -0
- package/dist/node_modules/node-pty/lib/eventEmitter2.js +47 -0
- package/dist/node_modules/node-pty/lib/eventEmitter2.js.map +1 -0
- package/dist/node_modules/node-pty/lib/eventEmitter2.test.js +30 -0
- package/dist/node_modules/node-pty/lib/eventEmitter2.test.js.map +1 -0
- package/dist/node_modules/node-pty/lib/index.js +52 -0
- package/dist/node_modules/node-pty/lib/index.js.map +1 -0
- package/dist/node_modules/node-pty/lib/interfaces.js +7 -0
- package/dist/node_modules/node-pty/lib/interfaces.js.map +1 -0
- package/dist/node_modules/node-pty/lib/shared/conout.js +11 -0
- package/dist/node_modules/node-pty/lib/shared/conout.js.map +1 -0
- package/dist/node_modules/node-pty/lib/terminal.js +190 -0
- package/dist/node_modules/node-pty/lib/terminal.js.map +1 -0
- package/dist/node_modules/node-pty/lib/terminal.test.js +139 -0
- package/dist/node_modules/node-pty/lib/terminal.test.js.map +1 -0
- package/dist/node_modules/node-pty/lib/testUtils.test.js +28 -0
- package/dist/node_modules/node-pty/lib/testUtils.test.js.map +1 -0
- package/dist/node_modules/node-pty/lib/types.js +7 -0
- package/dist/node_modules/node-pty/lib/types.js.map +1 -0
- package/dist/node_modules/node-pty/lib/unixTerminal.js +346 -0
- package/dist/node_modules/node-pty/lib/unixTerminal.js.map +1 -0
- package/dist/node_modules/node-pty/lib/unixTerminal.test.js +351 -0
- package/dist/node_modules/node-pty/lib/unixTerminal.test.js.map +1 -0
- package/dist/node_modules/node-pty/lib/utils.js +39 -0
- package/dist/node_modules/node-pty/lib/utils.js.map +1 -0
- package/dist/node_modules/node-pty/lib/windowsConoutConnection.js +125 -0
- package/dist/node_modules/node-pty/lib/windowsConoutConnection.js.map +1 -0
- package/dist/node_modules/node-pty/lib/windowsPtyAgent.js +320 -0
- package/dist/node_modules/node-pty/lib/windowsPtyAgent.js.map +1 -0
- package/dist/node_modules/node-pty/lib/windowsPtyAgent.test.js +90 -0
- package/dist/node_modules/node-pty/lib/windowsPtyAgent.test.js.map +1 -0
- package/dist/node_modules/node-pty/lib/windowsTerminal.js +199 -0
- package/dist/node_modules/node-pty/lib/windowsTerminal.js.map +1 -0
- package/dist/node_modules/node-pty/lib/windowsTerminal.test.js +219 -0
- package/dist/node_modules/node-pty/lib/windowsTerminal.test.js.map +1 -0
- package/dist/node_modules/node-pty/lib/worker/conoutSocketWorker.js +22 -0
- package/dist/node_modules/node-pty/lib/worker/conoutSocketWorker.js.map +1 -0
- package/dist/node_modules/node-pty/package.json +64 -0
- package/dist/node_modules/node-pty/prebuilds/darwin-arm64/pty.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/darwin-arm64/spawn-helper +0 -0
- package/dist/node_modules/node-pty/prebuilds/darwin-x64/pty.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/darwin-x64/spawn-helper +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/conpty/OpenConsole.exe +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/conpty/conpty.dll +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/conpty.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/conpty.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/conpty_console_list.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/conpty_console_list.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/pty.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/pty.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/winpty-agent.exe +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/winpty-agent.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/winpty.dll +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-arm64/winpty.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/conpty/OpenConsole.exe +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/conpty/conpty.dll +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/conpty.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/conpty.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/conpty_console_list.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/conpty_console_list.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/pty.node +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/pty.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/winpty-agent.exe +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/winpty-agent.pdb +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/winpty.dll +0 -0
- package/dist/node_modules/node-pty/prebuilds/win32-x64/winpty.pdb +0 -0
- package/dist/node_modules/node-pty/scripts/gen-compile-commands.js +8 -0
- package/dist/node_modules/node-pty/scripts/increment-version.js +54 -0
- package/dist/node_modules/node-pty/scripts/post-install.js +80 -0
- package/dist/node_modules/node-pty/scripts/prebuild.js +34 -0
- package/dist/node_modules/node-pty/src/conpty_console_list_agent.ts +15 -0
- package/dist/node_modules/node-pty/src/eventEmitter2.test.ts +30 -0
- package/dist/node_modules/node-pty/src/eventEmitter2.ts +48 -0
- package/dist/node_modules/node-pty/src/index.ts +52 -0
- package/dist/node_modules/node-pty/src/interfaces.ts +130 -0
- package/dist/node_modules/node-pty/src/native.d.ts +54 -0
- package/dist/node_modules/node-pty/src/shared/conout.ts +15 -0
- package/dist/node_modules/node-pty/src/terminal.test.ts +119 -0
- package/dist/node_modules/node-pty/src/terminal.ts +211 -0
- package/dist/node_modules/node-pty/src/testUtils.test.ts +23 -0
- package/dist/node_modules/node-pty/src/tsconfig.json +22 -0
- package/dist/node_modules/node-pty/src/types.ts +15 -0
- package/dist/node_modules/node-pty/src/unix/pty.cc +799 -0
- package/dist/node_modules/node-pty/src/unix/spawn-helper.cc +23 -0
- package/dist/node_modules/node-pty/src/unixTerminal.test.ts +367 -0
- package/dist/node_modules/node-pty/src/unixTerminal.ts +388 -0
- package/dist/node_modules/node-pty/src/utils.ts +29 -0
- package/dist/node_modules/node-pty/src/win/conpty.cc +583 -0
- package/dist/node_modules/node-pty/src/win/conpty.h +41 -0
- package/dist/node_modules/node-pty/src/win/conpty_console_list.cc +44 -0
- package/dist/node_modules/node-pty/src/win/path_util.cc +95 -0
- package/dist/node_modules/node-pty/src/win/path_util.h +26 -0
- package/dist/node_modules/node-pty/src/win/winpty.cc +333 -0
- package/dist/node_modules/node-pty/src/windowsConoutConnection.ts +82 -0
- package/dist/node_modules/node-pty/src/windowsPtyAgent.test.ts +94 -0
- package/dist/node_modules/node-pty/src/windowsPtyAgent.ts +321 -0
- package/dist/node_modules/node-pty/src/windowsTerminal.test.ts +229 -0
- package/dist/node_modules/node-pty/src/windowsTerminal.ts +203 -0
- package/dist/node_modules/node-pty/src/worker/conoutSocketWorker.ts +22 -0
- package/dist/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-arm64/OpenConsole.exe +0 -0
- package/dist/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-arm64/conpty.dll +0 -0
- package/dist/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-x64/OpenConsole.exe +0 -0
- package/dist/node_modules/node-pty/third_party/conpty/1.23.251008001/win10-x64/conpty.dll +0 -0
- package/dist/node_modules/node-pty/typings/node-pty.d.ts +211 -0
- package/dist/scripts/lib/test-fixtures.mjs +1 -1
- package/dist/ui/assets/{index-CWcSlUCR.js → index-B49cVd68.js} +1 -1
- package/dist/ui/assets/{index-BrOS5hPg.js → index-B77m9jwg.js} +1 -1
- package/dist/ui/assets/{index-DWT6BjYW.js → index-C61bzN1F.js} +1 -1
- package/dist/ui/assets/index-CEeUnKFj.js +1101 -0
- package/dist/ui/assets/{index-Btdv65e_.js → index-CHinfK5y.js} +1 -1
- package/dist/ui/assets/{index-DkFfIHJr.js → index-CdwIPvvC.js} +1 -1
- package/dist/ui/assets/{index-C-AZWfRD.js → index-CkMEKMtG.js} +1 -1
- package/dist/ui/assets/{index-B-SoOQ3F.js → index-Cl5D1lr0.js} +1 -1
- package/dist/ui/assets/{index-q7X3WW0-.js → index-CnWjvgnt.js} +1 -1
- package/dist/ui/assets/{index-B_lr0R8Z.js → index-CpEU6Vxs.js} +1 -1
- package/dist/ui/assets/{index-CBQN5qXY.js → index-D6YdKIji.js} +1 -1
- package/dist/ui/assets/{index-BK62XAzY.js → index-DARaaYLg.js} +1 -1
- package/dist/ui/assets/{index-D3gXfrX-.js → index-DErcnUD0.js} +1 -1
- package/dist/ui/assets/{index-D1F9nIOz.js → index-DJxs2IHl.js} +1 -1
- package/dist/ui/assets/{index-AacKgcwz.js → index-DKTHpT6c.js} +1 -1
- package/dist/ui/assets/{index-CXV7fZxu.js → index-DPgndyQt.js} +1 -1
- package/dist/ui/assets/{index-BvHGNf4Y.js → index-DRYG0hWl.js} +1 -1
- package/dist/ui/assets/{index-BCRvuZjU.js → index-D_--wkOk.js} +1 -1
- package/dist/ui/assets/{index-o8f2ilDp.js → index-Db2EhJOX.js} +1 -1
- package/dist/ui/assets/index-DcDF1o3A.css +1 -0
- package/dist/ui/assets/{index-BnaWildZ.js → index-Dck1mk1E.js} +1 -1
- package/dist/ui/assets/{index-Dhu8BZu7.js → index-b2CKrEE6.js} +1 -1
- package/dist/ui/assets/{index-cS068OSU.js → index-mhz4dktY.js} +1 -1
- package/dist/ui/assets/{index-CuieGJbi.js → index-ssu5S1KA.js} +1 -1
- package/dist/ui/index.html +2 -2
- package/package.json +6 -3
- package/dist/ui/assets/index-C8FDQRxy.js +0 -1095
- package/dist/ui/assets/index-D_uhpUwJ.css +0 -1
package/dist/commit.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
5d09cb2
|
package/dist/index.js
CHANGED
|
@@ -1803,7 +1803,6 @@ var require_semver2 = __commonJS((exports, module) => {
|
|
|
1803
1803
|
// src/index.ts
|
|
1804
1804
|
import { spawn } from "node:child_process";
|
|
1805
1805
|
import { existsSync as existsSync2, readFileSync as readFileSync2 } from "node:fs";
|
|
1806
|
-
import { request } from "node:http";
|
|
1807
1806
|
import { basename, dirname as dirname2, resolve as resolve2 } from "node:path";
|
|
1808
1807
|
import { fileURLToPath as fileURLToPath2 } from "node:url";
|
|
1809
1808
|
|
|
@@ -2053,12 +2052,113 @@ var DIST_LAYOUT = {
|
|
|
2053
2052
|
prismaRoot: "prisma",
|
|
2054
2053
|
prismaSchema: "prisma/schema.prisma",
|
|
2055
2054
|
resourcesRoot: "resources",
|
|
2055
|
+
nodePtyPackageRoot: "node_modules/node-pty",
|
|
2056
2056
|
scriptsRoot: "scripts",
|
|
2057
2057
|
fixtureInitScript: "scripts/init-test-repo.mjs",
|
|
2058
2058
|
fixtureSeedScript: "scripts/seed-test-fixtures.mjs",
|
|
2059
2059
|
fixtureLibraryScript: "scripts/lib/test-fixtures.mjs"
|
|
2060
2060
|
};
|
|
2061
2061
|
|
|
2062
|
+
// src/startup-discovery.ts
|
|
2063
|
+
import { request } from "node:http";
|
|
2064
|
+
import { resolve as resolvePath } from "node:path";
|
|
2065
|
+
async function waitForMatchingApiReady(options) {
|
|
2066
|
+
const { startPort, expectedRoot, timeoutMs = 30000, intervalMs = 250, scanWindow = 20 } = options;
|
|
2067
|
+
const startedAt = Date.now();
|
|
2068
|
+
const normalizedExpectedRoot = resolvePath(expectedRoot);
|
|
2069
|
+
while (Date.now() - startedAt < timeoutMs) {
|
|
2070
|
+
const match = await findMatchingApiPort({
|
|
2071
|
+
startPort,
|
|
2072
|
+
expectedRoot: normalizedExpectedRoot,
|
|
2073
|
+
scanWindow
|
|
2074
|
+
});
|
|
2075
|
+
if (match) {
|
|
2076
|
+
return match;
|
|
2077
|
+
}
|
|
2078
|
+
await delay(intervalMs);
|
|
2079
|
+
}
|
|
2080
|
+
return null;
|
|
2081
|
+
}
|
|
2082
|
+
async function findMatchingApiPort(options) {
|
|
2083
|
+
const { startPort, expectedRoot, scanWindow = 20 } = options;
|
|
2084
|
+
const maxPort = Math.min(65535, startPort + Math.max(0, scanWindow));
|
|
2085
|
+
for (let port = startPort;port <= maxPort; port += 1) {
|
|
2086
|
+
const root = await readApiHealthRoot(port);
|
|
2087
|
+
if (!root) {
|
|
2088
|
+
continue;
|
|
2089
|
+
}
|
|
2090
|
+
if (resolvePath(root) === expectedRoot) {
|
|
2091
|
+
return { port };
|
|
2092
|
+
}
|
|
2093
|
+
}
|
|
2094
|
+
return null;
|
|
2095
|
+
}
|
|
2096
|
+
async function readApiHealthRoot(port) {
|
|
2097
|
+
const liveResponse = await requestJson(port, "/api/health/live");
|
|
2098
|
+
if (liveResponse?.statusCode === 200 && liveResponse.body) {
|
|
2099
|
+
const liveRoot = resolveHealthRoot(liveResponse.body);
|
|
2100
|
+
if (liveRoot) {
|
|
2101
|
+
return liveRoot;
|
|
2102
|
+
}
|
|
2103
|
+
}
|
|
2104
|
+
const response = await requestJson(port, "/api/health");
|
|
2105
|
+
if (!response || response.statusCode !== 200 || !response.body) {
|
|
2106
|
+
return null;
|
|
2107
|
+
}
|
|
2108
|
+
return resolveHealthRoot(response.body);
|
|
2109
|
+
}
|
|
2110
|
+
function resolveHealthRoot(payload) {
|
|
2111
|
+
if (typeof payload.root === "string" && payload.root.trim().length > 0) {
|
|
2112
|
+
return payload.root;
|
|
2113
|
+
}
|
|
2114
|
+
if (payload.data && typeof payload.data.root === "string" && payload.data.root.trim().length > 0) {
|
|
2115
|
+
return payload.data.root;
|
|
2116
|
+
}
|
|
2117
|
+
return null;
|
|
2118
|
+
}
|
|
2119
|
+
function requestJson(port, path) {
|
|
2120
|
+
return new Promise((resolvePromise) => {
|
|
2121
|
+
const req = request({
|
|
2122
|
+
hostname: "127.0.0.1",
|
|
2123
|
+
port,
|
|
2124
|
+
path,
|
|
2125
|
+
method: "GET",
|
|
2126
|
+
timeout: 1000
|
|
2127
|
+
}, (res) => {
|
|
2128
|
+
let raw = "";
|
|
2129
|
+
res.setEncoding("utf8");
|
|
2130
|
+
res.on("data", (chunk) => {
|
|
2131
|
+
raw += chunk;
|
|
2132
|
+
});
|
|
2133
|
+
res.on("end", () => {
|
|
2134
|
+
if (!raw) {
|
|
2135
|
+
resolvePromise({ statusCode: res.statusCode, body: null });
|
|
2136
|
+
return;
|
|
2137
|
+
}
|
|
2138
|
+
try {
|
|
2139
|
+
resolvePromise({
|
|
2140
|
+
statusCode: res.statusCode,
|
|
2141
|
+
body: JSON.parse(raw)
|
|
2142
|
+
});
|
|
2143
|
+
} catch {
|
|
2144
|
+
resolvePromise(null);
|
|
2145
|
+
}
|
|
2146
|
+
});
|
|
2147
|
+
});
|
|
2148
|
+
req.on("timeout", () => {
|
|
2149
|
+
req.destroy();
|
|
2150
|
+
resolvePromise(null);
|
|
2151
|
+
});
|
|
2152
|
+
req.on("error", () => resolvePromise(null));
|
|
2153
|
+
req.end();
|
|
2154
|
+
});
|
|
2155
|
+
}
|
|
2156
|
+
function delay(ms) {
|
|
2157
|
+
return new Promise((resolvePromise) => {
|
|
2158
|
+
setTimeout(resolvePromise, ms);
|
|
2159
|
+
});
|
|
2160
|
+
}
|
|
2161
|
+
|
|
2062
2162
|
// src/index.ts
|
|
2063
2163
|
enforceNodeRuntimeCompatibility(import.meta.url);
|
|
2064
2164
|
var args = process.argv.slice(2);
|
|
@@ -2142,16 +2242,30 @@ async function startApps(options) {
|
|
|
2142
2242
|
},
|
|
2143
2243
|
stdio: "inherit"
|
|
2144
2244
|
});
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2245
|
+
let readyPort = resolvedPort;
|
|
2246
|
+
const startupSpinner = options.open ? createStartupSpinner(resolvedPort) : null;
|
|
2247
|
+
const ready = await waitForMatchingApiReady({
|
|
2248
|
+
startPort: resolvedPort,
|
|
2249
|
+
expectedRoot: targetRoot
|
|
2250
|
+
});
|
|
2251
|
+
if (ready) {
|
|
2252
|
+
readyPort = ready.port;
|
|
2253
|
+
if (readyPort !== resolvedPort) {
|
|
2254
|
+
console.warn(`[WARN] [startup] Vibeman resolved to port ${readyPort} after a late startup conflict on ${resolvedPort}.`);
|
|
2255
|
+
}
|
|
2256
|
+
if (startupSpinner) {
|
|
2257
|
+
startupSpinner.stop("ready", `http://localhost:${readyPort}/`);
|
|
2258
|
+
}
|
|
2259
|
+
if (options.open) {
|
|
2260
|
+
await openBrowser(`http://localhost:${readyPort}/`);
|
|
2261
|
+
}
|
|
2262
|
+
} else if (startupSpinner) {
|
|
2263
|
+
startupSpinner.stop("timeout", `http://localhost:${resolvedPort}/`);
|
|
2264
|
+
console.warn(`Unable to confirm a Vibeman API for ${targetRoot} on ports ${resolvedPort}-${Math.min(65535, resolvedPort + 20)}. Skipping automatic browser open.`);
|
|
2265
|
+
} else {
|
|
2266
|
+
console.warn(`Unable to confirm a Vibeman API for ${targetRoot} on ports ${resolvedPort}-${Math.min(65535, resolvedPort + 20)}. Reporting the requested startup port until the API becomes observable.`);
|
|
2154
2267
|
}
|
|
2268
|
+
const url = new URL(`http://localhost:${readyPort}/`);
|
|
2155
2269
|
const readyLine = process.stdout.isTTY ? `
|
|
2156
2270
|
\x1B[32mReady\x1B[0m \x1B[96m${url.toString()}\x1B[0m (Ctrl+C to stop)` : `
|
|
2157
2271
|
Ready ${url.toString()} (Ctrl+C to stop)`;
|
|
@@ -2288,11 +2402,11 @@ function waitForExit(child) {
|
|
|
2288
2402
|
child.once("exit", (code) => resolvePromise(code));
|
|
2289
2403
|
});
|
|
2290
2404
|
}
|
|
2291
|
-
function createStartupSpinner(
|
|
2405
|
+
function createStartupSpinner(port) {
|
|
2292
2406
|
if (!process.stdout.isTTY) {
|
|
2293
2407
|
console.log(`[startup] Loading Vibeman... waiting for API on port ${port}`);
|
|
2294
2408
|
return {
|
|
2295
|
-
stop: (result) => {
|
|
2409
|
+
stop: (result, url) => {
|
|
2296
2410
|
if (result === "ready") {
|
|
2297
2411
|
console.log(`[startup] Vibeman API is ready: ${url}`);
|
|
2298
2412
|
return;
|
|
@@ -2311,7 +2425,7 @@ function createStartupSpinner(url, port) {
|
|
|
2311
2425
|
process.stdout.write(`\r${frames[frameIndex]} Loading Vibeman... waiting for API on port ${port} (${elapsed}s) `);
|
|
2312
2426
|
}, 120);
|
|
2313
2427
|
return {
|
|
2314
|
-
stop: (result) => {
|
|
2428
|
+
stop: (result, url) => {
|
|
2315
2429
|
clearInterval(timer);
|
|
2316
2430
|
const elapsed = ((Date.now() - startMs) / 1000).toFixed(1);
|
|
2317
2431
|
if (result === "ready") {
|
|
@@ -2324,41 +2438,6 @@ function createStartupSpinner(url, port) {
|
|
|
2324
2438
|
}
|
|
2325
2439
|
};
|
|
2326
2440
|
}
|
|
2327
|
-
async function waitForApiReady(port, timeoutMs = 30000, intervalMs = 250) {
|
|
2328
|
-
const startedAt = Date.now();
|
|
2329
|
-
while (Date.now() - startedAt < timeoutMs) {
|
|
2330
|
-
const ok = await checkApiHealth(port);
|
|
2331
|
-
if (ok)
|
|
2332
|
-
return true;
|
|
2333
|
-
await delay(intervalMs);
|
|
2334
|
-
}
|
|
2335
|
-
return false;
|
|
2336
|
-
}
|
|
2337
|
-
function checkApiHealth(port) {
|
|
2338
|
-
return new Promise((resolvePromise) => {
|
|
2339
|
-
const req = request({
|
|
2340
|
-
hostname: "127.0.0.1",
|
|
2341
|
-
port,
|
|
2342
|
-
path: "/api/health",
|
|
2343
|
-
method: "GET",
|
|
2344
|
-
timeout: 2000
|
|
2345
|
-
}, (res) => {
|
|
2346
|
-
res.resume();
|
|
2347
|
-
resolvePromise(res.statusCode === 200);
|
|
2348
|
-
});
|
|
2349
|
-
req.on("timeout", () => {
|
|
2350
|
-
req.destroy();
|
|
2351
|
-
resolvePromise(false);
|
|
2352
|
-
});
|
|
2353
|
-
req.on("error", () => resolvePromise(false));
|
|
2354
|
-
req.end();
|
|
2355
|
-
});
|
|
2356
|
-
}
|
|
2357
|
-
function delay(ms) {
|
|
2358
|
-
return new Promise((resolvePromise) => {
|
|
2359
|
-
setTimeout(resolvePromise, ms);
|
|
2360
|
-
});
|
|
2361
|
-
}
|
|
2362
2441
|
function resolvePackagedDistRoot(moduleDir) {
|
|
2363
2442
|
return moduleDir.endsWith("/dist") || moduleDir.endsWith("\\dist") ? moduleDir : resolve2(moduleDir, "..", "dist");
|
|
2364
2443
|
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
Copyright (c) 2012-2015, Christopher Jeffrey (https://github.com/chjj/)
|
|
2
|
+
|
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
4
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
5
|
+
in the Software without restriction, including without limitation the rights
|
|
6
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
7
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
8
|
+
furnished to do so, subject to the following conditions:
|
|
9
|
+
|
|
10
|
+
The above copyright notice and this permission notice shall be included in
|
|
11
|
+
all copies or substantial portions of the Software.
|
|
12
|
+
|
|
13
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
14
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
15
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
16
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
17
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
18
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
19
|
+
THE SOFTWARE.
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
The MIT License (MIT)
|
|
24
|
+
|
|
25
|
+
Copyright (c) 2016, Daniel Imms (http://www.growingwiththeweb.com)
|
|
26
|
+
|
|
27
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
28
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
29
|
+
in the Software without restriction, including without limitation the rights
|
|
30
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
31
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
32
|
+
furnished to do so, subject to the following conditions:
|
|
33
|
+
|
|
34
|
+
The above copyright notice and this permission notice shall be included in all
|
|
35
|
+
copies or substantial portions of the Software.
|
|
36
|
+
|
|
37
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
38
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
39
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
40
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
41
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
42
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
43
|
+
SOFTWARE.
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
MIT License
|
|
48
|
+
|
|
49
|
+
Copyright (c) 2018 - present Microsoft Corporation
|
|
50
|
+
|
|
51
|
+
All rights reserved.
|
|
52
|
+
|
|
53
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
54
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
55
|
+
in the Software without restriction, including without limitation the rights
|
|
56
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
57
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
58
|
+
furnished to do so, subject to the following conditions:
|
|
59
|
+
|
|
60
|
+
The above copyright notice and this permission notice shall be included in all
|
|
61
|
+
copies or substantial portions of the Software.
|
|
62
|
+
|
|
63
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
64
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
65
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
66
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
67
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
68
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
69
|
+
SOFTWARE.
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
# node-pty
|
|
2
|
+
|
|
3
|
+
[](https://dev.azure.com/vscode/node-pty/_build/latest?definitionId=11&branchName=main)
|
|
4
|
+
|
|
5
|
+
`forkpty(3)` bindings for node.js. This allows you to fork processes with pseudoterminal file descriptors. It returns a terminal object which allows reads and writes.
|
|
6
|
+
|
|
7
|
+
This is useful for:
|
|
8
|
+
|
|
9
|
+
- Writing a terminal emulator (eg. via [xterm.js](https://github.com/sourcelair/xterm.js)).
|
|
10
|
+
- Getting certain programs to *think* you're a terminal, such as when you need a program to send you control sequences.
|
|
11
|
+
|
|
12
|
+
`node-pty` supports Linux, macOS and Windows. Windows support is possible by utilizing the [Windows conpty API](https://blogs.msdn.microsoft.com/commandline/2018/08/02/windows-command-line-introducing-the-windows-pseudo-console-conpty/) on Windows 1809+ and the [winpty](https://github.com/rprichard/winpty) library in older version.
|
|
13
|
+
|
|
14
|
+
## API
|
|
15
|
+
|
|
16
|
+
The full API for node-pty is contained within the [TypeScript declaration file](https://github.com/microsoft/node-pty/blob/main/typings/node-pty.d.ts), use the branch/tag picker in GitHub (`w`) to navigate to the correct version of the API.
|
|
17
|
+
|
|
18
|
+
## Example Usage
|
|
19
|
+
|
|
20
|
+
```js
|
|
21
|
+
import * as os from 'node:os';
|
|
22
|
+
import * as pty from 'node-pty';
|
|
23
|
+
|
|
24
|
+
const shell = os.platform() === 'win32' ? 'powershell.exe' : 'bash';
|
|
25
|
+
|
|
26
|
+
const ptyProcess = pty.spawn(shell, [], {
|
|
27
|
+
name: 'xterm-color',
|
|
28
|
+
cols: 80,
|
|
29
|
+
rows: 30,
|
|
30
|
+
cwd: process.env.HOME,
|
|
31
|
+
env: process.env
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
ptyProcess.onData((data) => {
|
|
35
|
+
process.stdout.write(data);
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
ptyProcess.write('ls\r');
|
|
39
|
+
ptyProcess.resize(100, 40);
|
|
40
|
+
ptyProcess.write('ls\r');
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
## Real-world Uses
|
|
44
|
+
|
|
45
|
+
`node-pty` powers many different terminal emulators, including:
|
|
46
|
+
|
|
47
|
+
- [Microsoft Visual Studio Code](https://code.visualstudio.com)
|
|
48
|
+
- [Hyper](https://hyper.is/)
|
|
49
|
+
- [Upterm](https://github.com/railsware/upterm)
|
|
50
|
+
- [Script Runner](https://github.com/ioquatix/script-runner) for Atom.
|
|
51
|
+
- [Theia](https://github.com/theia-ide/theia)
|
|
52
|
+
- [FreeMAN](https://github.com/matthew-matvei/freeman) file manager
|
|
53
|
+
- [terminus](https://atom.io/packages/terminus) - An Atom plugin for providing terminals inside your Atom workspace.
|
|
54
|
+
- [x-terminal](https://atom.io/packages/x-terminal) - Also an Atom plugin that provides terminals inside your Atom workspace.
|
|
55
|
+
- [Termination](https://atom.io/packages/termination) - Also an Atom plugin that provides terminals inside your Atom workspace.
|
|
56
|
+
- [atom-xterm](https://atom.io/packages/atom-xterm) - Also an Atom plugin that provides terminals inside your Atom workspace.
|
|
57
|
+
- [electerm](https://github.com/electerm/electerm) Terminal/SSH/SFTP client(Linux, macOS, Windows).
|
|
58
|
+
- [Extraterm](http://extraterm.org/)
|
|
59
|
+
- [Wetty](https://github.com/krishnasrinivas/wetty) Browser based Terminal over HTTP and HTTPS
|
|
60
|
+
- [nomad](https://github.com/lukebarnard1/nomad-term)
|
|
61
|
+
- [DockerStacks](https://github.com/sfx101/docker-stacks) Local LAMP/LEMP stack using Docker
|
|
62
|
+
- [TeleType](https://github.com/akshaykmr/TeleType): cli tool that allows you to share your terminal online conveniently. Show off mad cli-fu, help a colleague, teach, or troubleshoot.
|
|
63
|
+
- [mesos-term](https://github.com/criteo/mesos-term): A web terminal for Apache Mesos. It allows to execute commands within containers.
|
|
64
|
+
- [Commas](https://github.com/CyanSalt/commas): A hackable terminal and command runner.
|
|
65
|
+
- [ENiGMA½ BBS Software](https://github.com/NuSkooler/enigma-bbs): A modern BBS software with a nostalgic flair!
|
|
66
|
+
- [Tinkerun](https://github.com/tinkerun/tinkerun): A new way of running Tinker.
|
|
67
|
+
- [Tess](https://tessapp.dev): Hackable, simple and rapid terminal for the new era of technology 👍
|
|
68
|
+
- [NxShell](https://nxshell.github.io/): An easy to use new terminal for Windows/Linux/MacOS platform.
|
|
69
|
+
- [OpenSumi](https://github.com/opensumi/core): A framework helps you quickly build Cloud or Desktop IDE products.
|
|
70
|
+
- [Enjoy Git](https://github.com/huangcs427/enjoy-git-release): A modern Git client featuring an intuitive user interface, built with Electron, Vue 3, and TypeScript.
|
|
71
|
+
|
|
72
|
+
Do you use node-pty in your application as well? Please open a [Pull Request](https://github.com/Tyriar/node-pty/pulls) to include it here. We would love to have it in our list.
|
|
73
|
+
|
|
74
|
+
## Building
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
# Install dependencies and build C++
|
|
78
|
+
npm install
|
|
79
|
+
# Compile TypeScript -> JavaScript
|
|
80
|
+
npm run build
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Dependencies
|
|
84
|
+
|
|
85
|
+
Node.JS 16 or Electron 19 is required to use `node-pty`. What version of node is supported is currently mostly bound to [whatever version Visual Studio Code is using](https://github.com/microsoft/node-pty/issues/557#issuecomment-1332193541).
|
|
86
|
+
|
|
87
|
+
### Linux (apt)
|
|
88
|
+
|
|
89
|
+
```sh
|
|
90
|
+
sudo apt install -y make python build-essential
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
### macOS
|
|
94
|
+
|
|
95
|
+
Xcode is needed to compile the sources, this can be installed from the App Store.
|
|
96
|
+
|
|
97
|
+
### Windows
|
|
98
|
+
|
|
99
|
+
`npm install` requires some tools to be present in the system like Python and C++ compiler. Windows users can easily install them by running the following command in PowerShell as administrator. For more information see https://github.com/felixrieseberg/windows-build-tools:
|
|
100
|
+
|
|
101
|
+
```sh
|
|
102
|
+
npm install --global --production windows-build-tools
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
The following are also needed:
|
|
106
|
+
|
|
107
|
+
- [Windows SDK](https://developer.microsoft.com/en-us/windows/downloads/windows-10-sdk) - only the "Desktop C++ Apps" components are needed to be installed
|
|
108
|
+
- Spectre-mitigated libraries - In order to avoid the build error "MSB8040: Spectre-mitigated libraries are required for this project", open the Visual Studio Installer, press the Modify button, navigate to the "Individual components" tab, search "Spectre", and install an option like "MSVC v143 - VS 2022 C++ x64/x86 Spectre-mitigated libs (Latest)" (the exact option to install will depend on your version of Visual Studio as well as your operating system architecture)
|
|
109
|
+
|
|
110
|
+
## Debugging
|
|
111
|
+
|
|
112
|
+
[The wiki](https://github.com/Microsoft/node-pty/wiki/Debugging) contains instructions for debugging node-pty.
|
|
113
|
+
|
|
114
|
+
## Security
|
|
115
|
+
|
|
116
|
+
All processes launched from node-pty will launch at the same permission level of the parent process. Take care particularly when using node-pty inside a server that's accessible on the internet. We recommend launching the pty inside a container to protect your host machine.
|
|
117
|
+
|
|
118
|
+
## Thread Safety
|
|
119
|
+
|
|
120
|
+
Note that node-pty is not thread safe so running it across multiple worker threads in node.js could cause issues.
|
|
121
|
+
|
|
122
|
+
## Flow Control
|
|
123
|
+
|
|
124
|
+
Automatic flow control can be enabled by either providing `handleFlowControl = true` in the constructor options or setting it later on:
|
|
125
|
+
|
|
126
|
+
```js
|
|
127
|
+
const PAUSE = '\x13'; // XOFF
|
|
128
|
+
const RESUME = '\x11'; // XON
|
|
129
|
+
|
|
130
|
+
const ptyProcess = pty.spawn(shell, [], {handleFlowControl: true});
|
|
131
|
+
|
|
132
|
+
// flow control in action
|
|
133
|
+
ptyProcess.write(PAUSE); // pty will block and pause the child program
|
|
134
|
+
...
|
|
135
|
+
ptyProcess.write(RESUME); // pty will enter flow mode and resume the child program
|
|
136
|
+
|
|
137
|
+
// temporarily disable/re-enable flow control
|
|
138
|
+
ptyProcess.handleFlowControl = false;
|
|
139
|
+
...
|
|
140
|
+
ptyProcess.handleFlowControl = true;
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
By default `PAUSE` and `RESUME` are XON/XOFF control codes (as shown above). To avoid conflicts in environments that use these control codes for different purposes the messages can be customized as `flowControlPause: string` and `flowControlResume: string` in the constructor options. `PAUSE` and `RESUME` are not passed to the underlying pseudoterminal if flow control is enabled.
|
|
144
|
+
|
|
145
|
+
## Troubleshooting
|
|
146
|
+
|
|
147
|
+
### Powershell gives error 8009001d
|
|
148
|
+
|
|
149
|
+
> Internal Windows PowerShell error. Loading managed Windows PowerShell failed with error 8009001d.
|
|
150
|
+
|
|
151
|
+
This happens when PowerShell is launched with no `SystemRoot` environment variable present.
|
|
152
|
+
|
|
153
|
+
### ConnectNamedPipe failed: Windows error 232
|
|
154
|
+
|
|
155
|
+
This error can occur due to anti-virus software intercepting winpty from creating a pty. To workaround this you can exclude this file from your anti-virus scanning `node-pty\build\Release\winpty-agent.exe`
|
|
156
|
+
|
|
157
|
+
## pty.js
|
|
158
|
+
|
|
159
|
+
This project is forked from [chjj/pty.js](https://github.com/chjj/pty.js) with the primary goals being to provide better support for later Node.js versions and Windows.
|
|
160
|
+
|
|
161
|
+
## License
|
|
162
|
+
|
|
163
|
+
Copyright (c) 2012-2015, Christopher Jeffrey (MIT License).<br>
|
|
164
|
+
Copyright (c) 2016, Daniel Imms (MIT License).<br>
|
|
165
|
+
Copyright (c) 2018, Microsoft Corporation (MIT License).
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
{
|
|
2
|
+
'target_defaults': {
|
|
3
|
+
'dependencies': [
|
|
4
|
+
"<!(node -p \"require('node-addon-api').targets\"):node_addon_api_except",
|
|
5
|
+
],
|
|
6
|
+
'conditions': [
|
|
7
|
+
['OS=="win"', {
|
|
8
|
+
'msvs_configuration_attributes': {
|
|
9
|
+
'SpectreMitigation': 'Spectre'
|
|
10
|
+
},
|
|
11
|
+
'msvs_settings': {
|
|
12
|
+
'VCCLCompilerTool': {
|
|
13
|
+
'AdditionalOptions': [
|
|
14
|
+
'/guard:cf',
|
|
15
|
+
'/sdl',
|
|
16
|
+
'/W3',
|
|
17
|
+
'/w34244',
|
|
18
|
+
'/w34267',
|
|
19
|
+
'/ZH:SHA_256'
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
'VCLinkerTool': {
|
|
23
|
+
'AdditionalOptions': [
|
|
24
|
+
'/DYNAMICBASE',
|
|
25
|
+
'/guard:cf'
|
|
26
|
+
]
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
}],
|
|
30
|
+
],
|
|
31
|
+
},
|
|
32
|
+
'conditions': [
|
|
33
|
+
['OS=="win"', {
|
|
34
|
+
'targets': [
|
|
35
|
+
{
|
|
36
|
+
'target_name': 'conpty',
|
|
37
|
+
'sources' : [
|
|
38
|
+
'src/win/conpty.cc',
|
|
39
|
+
'src/win/path_util.cc'
|
|
40
|
+
],
|
|
41
|
+
'libraries': [
|
|
42
|
+
'-lshlwapi'
|
|
43
|
+
],
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
'target_name': 'conpty_console_list',
|
|
47
|
+
'sources' : [
|
|
48
|
+
'src/win/conpty_console_list.cc'
|
|
49
|
+
],
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
'target_name': 'pty',
|
|
53
|
+
'include_dirs' : [
|
|
54
|
+
'<!(node -p "require(\'node-addon-api\').include_dir")',
|
|
55
|
+
'deps/winpty/src/include',
|
|
56
|
+
],
|
|
57
|
+
# Disabled due to winpty
|
|
58
|
+
'msvs_disabled_warnings': [ 4506, 4530 ],
|
|
59
|
+
'dependencies' : [
|
|
60
|
+
'deps/winpty/src/winpty.gyp:winpty-agent',
|
|
61
|
+
'deps/winpty/src/winpty.gyp:winpty',
|
|
62
|
+
],
|
|
63
|
+
'sources' : [
|
|
64
|
+
'src/win/winpty.cc',
|
|
65
|
+
'src/win/path_util.cc'
|
|
66
|
+
],
|
|
67
|
+
'libraries': [
|
|
68
|
+
'-lshlwapi'
|
|
69
|
+
],
|
|
70
|
+
}
|
|
71
|
+
]
|
|
72
|
+
}, { # OS!="win"
|
|
73
|
+
'targets': [
|
|
74
|
+
{
|
|
75
|
+
'target_name': 'pty',
|
|
76
|
+
'sources': [
|
|
77
|
+
'src/unix/pty.cc',
|
|
78
|
+
],
|
|
79
|
+
'libraries': [
|
|
80
|
+
'-lutil'
|
|
81
|
+
],
|
|
82
|
+
'cflags': ['-Wall', '-O2', '-D_FORTIFY_SOURCE=2'],
|
|
83
|
+
'conditions': [
|
|
84
|
+
# http://www.gnu.org/software/gnulib/manual/html_node/forkpty.html
|
|
85
|
+
# One some systems (at least including Cygwin, Interix,
|
|
86
|
+
# OSF/1 4 and 5, and Mac OS X) linking with -lutil is not required.
|
|
87
|
+
['OS=="mac" or OS=="solaris"', {
|
|
88
|
+
'libraries!': [
|
|
89
|
+
'-lutil'
|
|
90
|
+
]
|
|
91
|
+
}]
|
|
92
|
+
]
|
|
93
|
+
}
|
|
94
|
+
]
|
|
95
|
+
}],
|
|
96
|
+
['OS=="mac"', {
|
|
97
|
+
'targets': [
|
|
98
|
+
{
|
|
99
|
+
'target_name': 'spawn-helper',
|
|
100
|
+
'type': 'executable',
|
|
101
|
+
'sources': [
|
|
102
|
+
'src/unix/spawn-helper.cc',
|
|
103
|
+
],
|
|
104
|
+
"xcode_settings": {
|
|
105
|
+
"MACOSX_DEPLOYMENT_TARGET":"10.7"
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
]
|
|
109
|
+
}]
|
|
110
|
+
]
|
|
111
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Build configure for https://www.tea-ci.org (fork of Drone CI with Msys2 support)
|
|
2
|
+
build:
|
|
3
|
+
image: teaci/msys$$arch
|
|
4
|
+
pull: true
|
|
5
|
+
shell: msys$$arch
|
|
6
|
+
commands:
|
|
7
|
+
- pacman -S --needed --noconfirm --noprogressbar mingw-w64-cross-gcc mingw-w64-cross-crt-git
|
|
8
|
+
- ./configure
|
|
9
|
+
- make
|
|
10
|
+
- make tests
|
|
11
|
+
- build/trivial_test.exe
|
|
12
|
+
- mintty --log - --exec build/winpty.exe cmd /c ver | grep Windows
|
|
13
|
+
|
|
14
|
+
matrix:
|
|
15
|
+
arch:
|
|
16
|
+
- 64
|
|
17
|
+
- 32
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
* text=auto
|
|
2
|
+
*.bat text eol=crlf
|
|
3
|
+
*.c text
|
|
4
|
+
*.cc text
|
|
5
|
+
*.gyp text
|
|
6
|
+
*.gypi text
|
|
7
|
+
*.h text
|
|
8
|
+
*.ps1 text eol=crlf
|
|
9
|
+
*.rst text
|
|
10
|
+
*.sh text
|
|
11
|
+
*.txt text
|
|
12
|
+
.gitignore text
|
|
13
|
+
.gitattributes text
|
|
14
|
+
Makefile text
|
|
15
|
+
configure text
|
|
16
|
+
|
|
17
|
+
*.sh eol=lf
|
|
18
|
+
configure eol=lf
|
|
19
|
+
VERSION.txt eol=lf
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2011-2016 Ryan Prichard
|
|
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
|
|
7
|
+
deal in the Software without restriction, including without limitation the
|
|
8
|
+
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
|
9
|
+
sell 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
|
|
20
|
+
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
|
|
21
|
+
IN THE SOFTWARE.
|