@treasuredata/tdx 2026.3.16 → 2026.3.17

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.
Files changed (201) hide show
  1. package/dist/bin.js +1 -1
  2. package/dist/build-info.json +3 -3
  3. package/dist/cli-categories.js +1 -1
  4. package/dist/cli.js +1 -1
  5. package/dist/commands/activations.js +1 -1
  6. package/dist/commands/agent-command.js +1 -1
  7. package/dist/commands/agent-test-command.js +1 -1
  8. package/dist/commands/api-command.js +1 -1
  9. package/dist/commands/auth-command.js +1 -1
  10. package/dist/commands/auth-login-command.js +1 -1
  11. package/dist/commands/chat-command.js +1 -1
  12. package/dist/commands/claude-command.js +1 -1
  13. package/dist/commands/claude-statusline-command.js +1 -1
  14. package/dist/commands/claude-usage-command.js +1 -1
  15. package/dist/commands/command.js +1 -1
  16. package/dist/commands/connection-command.js +1 -1
  17. package/dist/commands/databases.js +1 -1
  18. package/dist/commands/delivery-command.js +1 -1
  19. package/dist/commands/describe.js +1 -1
  20. package/dist/commands/engage-campaign-pull-command.js +1 -1
  21. package/dist/commands/engage-campaign-push-command.js +1 -1
  22. package/dist/commands/engage-campaign-validate-command.js +1 -1
  23. package/dist/commands/engage-command.js +1 -1
  24. package/dist/commands/engage-template-pull-command.js +1 -1
  25. package/dist/commands/engage-template-push-command.js +1 -1
  26. package/dist/commands/engage-template-validate-command.js +1 -1
  27. package/dist/commands/job-command.js +1 -1
  28. package/dist/commands/journey-command.js +1 -1
  29. package/dist/commands/journey-validate-command.js +1 -1
  30. package/dist/commands/llm-command.js +1 -1
  31. package/dist/commands/mcp-command.js +1 -1
  32. package/dist/commands/parent-segment-command.js +1 -1
  33. package/dist/commands/profile-command.js +1 -1
  34. package/dist/commands/profiles-command.js +1 -1
  35. package/dist/commands/query-command.js +1 -1
  36. package/dist/commands/schedule-command.js +1 -1
  37. package/dist/commands/segment-command.js +1 -1
  38. package/dist/commands/segment-create-command.js +1 -1
  39. package/dist/commands/segment-fields-command.js +1 -1
  40. package/dist/commands/segment-pull-command.js +1 -1
  41. package/dist/commands/segment-push-command.js +1 -1
  42. package/dist/commands/segment-update-command.js +1 -1
  43. package/dist/commands/segment-use-command.js +1 -1
  44. package/dist/commands/segment-validate-command.js +1 -1
  45. package/dist/commands/segments.js +1 -1
  46. package/dist/commands/show.js +1 -1
  47. package/dist/commands/status-command.js +1 -1
  48. package/dist/commands/tables.js +1 -1
  49. package/dist/commands/unset-command.js +1 -1
  50. package/dist/commands/upgrade-command.js +1 -1
  51. package/dist/commands/use-command.js +1 -1
  52. package/dist/commands/user-command.js +1 -1
  53. package/dist/commands/workflow-command.js +1 -1
  54. package/dist/core/auth.js +1 -1
  55. package/dist/core/command-output.js +1 -1
  56. package/dist/core/config.js +1 -1
  57. package/dist/core/connection-cache.js +1 -1
  58. package/dist/core/constants.js +1 -1
  59. package/dist/core/credential-cache.js +1 -1
  60. package/dist/core/global-context.js +1 -1
  61. package/dist/core/keychain.js +1 -1
  62. package/dist/core/oauth-keychain.js +1 -1
  63. package/dist/core/oauth.js +1 -1
  64. package/dist/core/profile.js +1 -1
  65. package/dist/core/project-config.js +1 -1
  66. package/dist/core/session.js +1 -1
  67. package/dist/core/user-cache.js +1 -1
  68. package/dist/core/version.js +1 -1
  69. package/dist/index.js +1 -1
  70. package/dist/mcp/server.js +1 -1
  71. package/dist/mcp/tools/index.js +1 -1
  72. package/dist/mcp/tools/tdx-run.js +1 -1
  73. package/dist/mcp/tools/tdx-search.js +1 -1
  74. package/dist/mcp/utils.js +1 -1
  75. package/dist/proxy/claude-usage-tracker.js +1 -1
  76. package/dist/proxy/passthrough-server.js +1 -1
  77. package/dist/proxy/sse-usage-parser.js +1 -1
  78. package/dist/sdk/agent/agent-config.js +1 -1
  79. package/dist/sdk/agent/agent-ref-parser.js +1 -1
  80. package/dist/sdk/agent/agent-yaml.js +1 -1
  81. package/dist/sdk/agent/test/evaluator.js +1 -1
  82. package/dist/sdk/agent/test/executor.js +1 -1
  83. package/dist/sdk/agent/test/index.js +1 -1
  84. package/dist/sdk/agent/test/output.js +1 -1
  85. package/dist/sdk/agent/test/parser.js +1 -1
  86. package/dist/sdk/agent/tool-target-registry.js +1 -1
  87. package/dist/sdk/api.js +1 -1
  88. package/dist/sdk/client/cdp-api-client.js +1 -1
  89. package/dist/sdk/client/delivery-api-client.js +1 -1
  90. package/dist/sdk/client/endpoints.js +1 -1
  91. package/dist/sdk/client/engage-api-client.js +1 -1
  92. package/dist/sdk/client/http-client.js +1 -1
  93. package/dist/sdk/client/llm-api-client.js +1 -1
  94. package/dist/sdk/client/oauth-refresh.js +1 -1
  95. package/dist/sdk/client/rate-limiter.js +1 -1
  96. package/dist/sdk/client/td-api-client.js +1 -1
  97. package/dist/sdk/client/trino-api-client.js +1 -1
  98. package/dist/sdk/client/workflow-client.js +1 -1
  99. package/dist/sdk/connection-validator.js +1 -1
  100. package/dist/sdk/connection.js +1 -1
  101. package/dist/sdk/delivery.js +1 -1
  102. package/dist/sdk/engage/campaign-pull.js +1 -1
  103. package/dist/sdk/engage/campaign-push.js +1 -1
  104. package/dist/sdk/engage/campaign-validator.js +1 -1
  105. package/dist/sdk/engage/campaign-yaml.js +1 -1
  106. package/dist/sdk/engage/template-pull.js +1 -1
  107. package/dist/sdk/engage/template-push.js +1 -1
  108. package/dist/sdk/engage/template-validator.js +1 -1
  109. package/dist/sdk/engage/template-yaml.js +1 -1
  110. package/dist/sdk/engage/types/campaign-def.js +1 -1
  111. package/dist/sdk/engage/types/campaign-schema.js +1 -1
  112. package/dist/sdk/engage/types/template-schema.js +1 -1
  113. package/dist/sdk/engage.js +1 -1
  114. package/dist/sdk/errors.js +1 -1
  115. package/dist/sdk/index.js +1 -1
  116. package/dist/sdk/io/index.js +1 -1
  117. package/dist/sdk/io/node-filesystem.js +1 -1
  118. package/dist/sdk/job.js +1 -1
  119. package/dist/sdk/journey.js +1 -1
  120. package/dist/sdk/llm/chat-cache.js +1 -1
  121. package/dist/sdk/llm/index.js +1 -1
  122. package/dist/sdk/llm/llm-backup-utils.js +1 -1
  123. package/dist/sdk/llm/model-factors.js +1 -1
  124. package/dist/sdk/personalization.js +1 -1
  125. package/dist/sdk/query/index.js +1 -1
  126. package/dist/sdk/query/sql-parser.js +1 -1
  127. package/dist/sdk/realtime.js +1 -1
  128. package/dist/sdk/schedule.js +1 -1
  129. package/dist/sdk/segment/child-segment-yaml.js +1 -1
  130. package/dist/sdk/segment/fields-display.js +1 -1
  131. package/dist/sdk/segment/file-discovery.js +1 -1
  132. package/dist/sdk/segment/journey-utils.js +1 -1
  133. package/dist/sdk/segment/journey-validator.js +1 -1
  134. package/dist/sdk/segment/journey-yaml.js +1 -1
  135. package/dist/sdk/segment/parent-segment-preview.js +1 -1
  136. package/dist/sdk/segment/parent-segment-yaml.js +1 -1
  137. package/dist/sdk/segment/pull-workflow.js +1 -1
  138. package/dist/sdk/segment/push-recovery.js +1 -1
  139. package/dist/sdk/segment/push-workflow.js +1 -1
  140. package/dist/sdk/segment/resolution-context.js +1 -1
  141. package/dist/sdk/segment/segment-path-parser.js +1 -1
  142. package/dist/sdk/segment/segment-ref-parser.js +1 -1
  143. package/dist/sdk/segment/segment-validator.js +1 -1
  144. package/dist/sdk/segment/target-resolution.js +1 -1
  145. package/dist/sdk/segment/tdx-config.js +1 -1
  146. package/dist/sdk/segment/types/activation-schema.js +1 -1
  147. package/dist/sdk/segment/types/journey-def.js +1 -1
  148. package/dist/sdk/segment/types/journey-schema.js +1 -1
  149. package/dist/sdk/segment/types/segment-def.js +1 -1
  150. package/dist/sdk/segment/types/segment-schema.js +1 -1
  151. package/dist/sdk/segment/validate-files.js +1 -1
  152. package/dist/sdk/segment/yaml-validator.js +1 -1
  153. package/dist/sdk/segment.js +1 -1
  154. package/dist/sdk/types/index.js +1 -1
  155. package/dist/sdk/types/progress.js +1 -1
  156. package/dist/sdk/user.js +1 -1
  157. package/dist/sdk/util/format-detector.js +1 -1
  158. package/dist/sdk/util/formatters.js +1 -1
  159. package/dist/sdk/util/index.js +1 -1
  160. package/dist/sdk/util/paginate.js +1 -1
  161. package/dist/sdk/util/tree-formatter.js +1 -1
  162. package/dist/sdk/workflow/archive-validation.js +1 -1
  163. package/dist/sdk/workflow/clone-workflow.js +1 -1
  164. package/dist/sdk/workflow/index.js +1 -1
  165. package/dist/sdk/workflow/pull-workflow.js +1 -1
  166. package/dist/sdk/workflow/push-workflow.js +1 -1
  167. package/dist/sdk/workflow/tdx-config.js +1 -1
  168. package/dist/sdk/workflow/workflow-utils.js +1 -1
  169. package/dist/test-utils/command-runner.js +1 -1
  170. package/dist/test-utils/factories.js +1 -1
  171. package/dist/test-utils/fixtures.js +1 -1
  172. package/dist/test-utils/http-mock.js +1 -1
  173. package/dist/test-utils/index.js +1 -1
  174. package/dist/utils/async.js +1 -1
  175. package/dist/utils/colors.js +1 -1
  176. package/dist/utils/diff.js +1 -1
  177. package/dist/utils/file-permissions.js +1 -1
  178. package/dist/utils/file-reader.js +1 -1
  179. package/dist/utils/github-releases.js +1 -1
  180. package/dist/utils/global-cache.js +1 -1
  181. package/dist/utils/json-loader.js +1 -1
  182. package/dist/utils/local-cache.js +1 -1
  183. package/dist/utils/logger/formatters/default-formatter.js +1 -1
  184. package/dist/utils/logger/formatters/index.js +1 -1
  185. package/dist/utils/logger/handlers/console-handler.js +1 -1
  186. package/dist/utils/logger/handlers/file-handler.js +1 -1
  187. package/dist/utils/logger/handlers/index.js +1 -1
  188. package/dist/utils/logger/handlers/null-handler.js +1 -1
  189. package/dist/utils/logger/index.js +1 -1
  190. package/dist/utils/logger/logger.js +1 -1
  191. package/dist/utils/logger/types.js +1 -1
  192. package/dist/utils/option-validation.js +1 -1
  193. package/dist/utils/process.js +1 -1
  194. package/dist/utils/prompt.js +1 -1
  195. package/dist/utils/spinner.js +1 -1
  196. package/dist/utils/sse-parser.js +1 -1
  197. package/dist/utils/string-utils.js +1 -1
  198. package/dist/utils/table-ref-parser.js +1 -1
  199. package/dist/utils/tdx-logger.js +1 -1
  200. package/dist/utils/version-check.js +1 -1
  201. package/package.json +2 -2
@@ -1 +1 @@
1
- const a206_0x50627a=a206_0x4a2d;function a206_0xd7b1(){const _0x149ac0=['isInteger','pipe','1625991UOncVF','http:','753929nGjUBj','join','pid','pwsh','kill','stderr','fish','\x20-o\x20ppid=,comm=','trim','ignore','powershell','test','platform','which','7AjbgEh','elvish','start','error','5458608XsHFgv','replace','pop','18algZOn','protocol','toLowerCase','data','treasure\x20studio','win32','where.exe','tcsh','dash','xdg-open','xonsh','164wZySek','has','open','30UJBiKo','Get-CimInstance\x20Win32_Process\x20-Filter\x20\x22ProcessId=','\x22\x20|\x20Select-Object\x20-Property\x20ParentProcessId,Name\x20|\x20ForEach-Object\x20{\x20\x22$($_.ParentProcessId),$($_.Name)\x22\x20}','2259064XcxvTw','electron','74855mGhryf','zsh','code','toString','unref','map','utf-8','exit','1159380vabwWn','https:','comm','split','ppid','Invalid\x20URL:\x20','547019OPNtVW','cursor'];a206_0xd7b1=function(){return _0x149ac0;};return a206_0xd7b1();}(function(_0x20f923,_0xffb1e0){const _0x39b96e=a206_0x4a2d,_0x141407=_0x20f923();while(!![]){try{const _0x4e2169=parseInt(_0x39b96e(0x1ad))/0x1+parseInt(_0x39b96e(0x1a7))/0x2+-parseInt(_0x39b96e(0x1b1))/0x3+parseInt(_0x39b96e(0x197))/0x4*(parseInt(_0x39b96e(0x19f))/0x5)+parseInt(_0x39b96e(0x1c5))/0x6*(-parseInt(_0x39b96e(0x1c1))/0x7)+parseInt(_0x39b96e(0x19d))/0x8*(parseInt(_0x39b96e(0x18c))/0x9)+parseInt(_0x39b96e(0x19a))/0xa*(-parseInt(_0x39b96e(0x1b3))/0xb);if(_0x4e2169===_0xffb1e0)break;else _0x141407['push'](_0x141407['shift']());}catch(_0x31a8e6){_0x141407['push'](_0x141407['shift']());}}}(a206_0xd7b1,0x9e2e0));import{execSync,spawn}from'node:child_process';const SHELL_NAMES=new Set(['bash',a206_0x50627a(0x1a0),'sh',a206_0x50627a(0x1b9),'ksh',a206_0x50627a(0x193),'csh',a206_0x50627a(0x194),a206_0x50627a(0x1b6),a206_0x50627a(0x1bd),'nu','ion',a206_0x50627a(0x1c2),a206_0x50627a(0x196)]),EPHEMERAL_SHELL_SPAWNERS=new Set(['claude',a206_0x50627a(0x1a1),a206_0x50627a(0x1ae),a206_0x50627a(0x19e),a206_0x50627a(0x190)]);function getProcessInfoWindows(_0x5bd058){const _0x47b219=a206_0x50627a;try{if(!Number[_0x47b219(0x1af)](_0x5bd058)||_0x5bd058<=0x0)return null;const _0x3d3f17=_0x47b219(0x19b)+_0x5bd058+_0x47b219(0x19c),_0x48e0ba=execSync('powershell.exe\x20-NoProfile\x20-NonInteractive\x20-Command\x20\x22'+_0x3d3f17+'\x22',{'encoding':'utf-8','windowsHide':!![],'stdio':['pipe',_0x47b219(0x1b0),_0x47b219(0x1b0)]})[_0x47b219(0x1bb)]();if(!_0x48e0ba)return null;const [_0x50a91e,..._0x14c246]=_0x48e0ba[_0x47b219(0x1aa)](','),_0xcd6d98=parseInt(_0x50a91e,0xa),_0x4755cc=_0x14c246[_0x47b219(0x1b4)](',')[_0x47b219(0x1bb)]();if(isNaN(_0xcd6d98)||!_0x4755cc)return null;return{'pid':_0x5bd058,'ppid':_0xcd6d98,'comm':_0x4755cc[_0x47b219(0x1c6)](/\.exe$/i,'')};}catch{return null;}}function getProcessInfoPosix(_0xd755d0){const _0x19685b=a206_0x50627a;try{const _0x15c0fd=0x400000;if(!Number[_0x19685b(0x1af)](_0xd755d0)||_0xd755d0<=0x0||_0xd755d0>_0x15c0fd)return null;const _0x50ccec=execSync('ps\x20-p\x20'+_0xd755d0+_0x19685b(0x1ba),{'encoding':_0x19685b(0x1a5),'stdio':_0x19685b(0x1b0)})['trim'](),[_0x51b9dc,..._0x1462c2]=_0x50ccec[_0x19685b(0x1aa)](/\s+/),_0x53a3a5=parseInt(_0x51b9dc,0xa),_0x5162a4=_0x1462c2[_0x19685b(0x1b4)]('\x20');if(isNaN(_0x53a3a5))return null;return{'pid':_0xd755d0,'ppid':_0x53a3a5,'comm':_0x5162a4};}catch{return null;}}function getProcessInfo(_0x41306d){const _0x3c00ce=a206_0x50627a;if(process[_0x3c00ce(0x1bf)]===_0x3c00ce(0x191))return getProcessInfoWindows(_0x41306d);return getProcessInfoPosix(_0x41306d);}function getBasename(_0x5b25ec){const _0x23250c=a206_0x50627a;return _0x5b25ec[_0x23250c(0x1c6)](/^-/,'')['split']('/')[_0x23250c(0x18b)]()?.[_0x23250c(0x18e)]()||'';}function isShell(_0x375066){const _0x443f04=a206_0x50627a;return SHELL_NAMES[_0x443f04(0x198)](getBasename(_0x375066));}function a206_0x4a2d(_0x19aeee,_0x2ab33f){_0x19aeee=_0x19aeee-0x18b;const _0xd7b160=a206_0xd7b1();let _0x4a2de3=_0xd7b160[_0x19aeee];return _0x4a2de3;}function isEphemeralShellSpawner(_0x229b19){const _0x54eb79=a206_0x50627a;return EPHEMERAL_SHELL_SPAWNERS[_0x54eb79(0x198)](getBasename(_0x229b19));}let cachedShellPID;function findShellPID(){const _0x4edaa3=a206_0x50627a;if(process[_0x4edaa3(0x1ab)]===undefined)return process[_0x4edaa3(0x1b5)];let _0x2725fb=process[_0x4edaa3(0x1ab)];const _0x398d6f=0xa;let _0x2ef228=0x0;while(_0x2ef228<_0x398d6f){const _0xedae94=getProcessInfo(_0x2725fb);if(!_0xedae94)break;if(isShell(_0xedae94[_0x4edaa3(0x1a9)])){const _0x6ae35c=getProcessInfo(_0xedae94[_0x4edaa3(0x1ab)]);if(_0x6ae35c&&isEphemeralShellSpawner(_0x6ae35c[_0x4edaa3(0x1a9)])){_0x2725fb=_0xedae94['ppid'],_0x2ef228++;continue;}return _0xedae94['pid'];}if(_0xedae94[_0x4edaa3(0x1ab)]===0x0||_0xedae94['ppid']===0x1){if(isShell(_0xedae94[_0x4edaa3(0x1a9)]))return _0xedae94['pid'];break;}_0x2725fb=_0xedae94['ppid'],_0x2ef228++;}return process[_0x4edaa3(0x1ab)]!==undefined?process[_0x4edaa3(0x1ab)]:process[_0x4edaa3(0x1b5)];}export function getPPID(){return cachedShellPID===undefined&&(cachedShellPID=findShellPID()),cachedShellPID;}export function clearPPIDCache(){cachedShellPID=undefined;}export function isProcessRunning(_0x33a6e6){const _0x3b015e=a206_0x50627a;if(!Number[_0x3b015e(0x1af)](_0x33a6e6)||_0x33a6e6<=0x0)return![];try{return process[_0x3b015e(0x1b7)](_0x33a6e6,0x0),!![];}catch{return![];}}export function openBrowser(_0x275328){const _0x2bfff7=a206_0x50627a;let _0x3860c9;try{_0x3860c9=new URL(_0x275328);}catch{throw new Error(_0x2bfff7(0x1ac)+_0x275328);}if(_0x3860c9['protocol']!==_0x2bfff7(0x1b2)&&_0x3860c9[_0x2bfff7(0x18d)]!==_0x2bfff7(0x1a8))throw new Error('Unsupported\x20protocol:\x20'+_0x3860c9[_0x2bfff7(0x18d)]);const _0x3c4756=_0x3860c9['href'],_0x1609fb=process[_0x2bfff7(0x1bf)];if(_0x1609fb===_0x2bfff7(0x191))spawn('cmd.exe',['/c',_0x2bfff7(0x1c3),'',_0x3c4756],{'detached':!![],'stdio':_0x2bfff7(0x1bc)})[_0x2bfff7(0x1a3)]();else{const _0x3bacb6=_0x1609fb==='darwin'?_0x2bfff7(0x199):_0x2bfff7(0x195);spawn(_0x3bacb6,[_0x3c4756],{'detached':!![],'stdio':_0x2bfff7(0x1bc)})[_0x2bfff7(0x1a3)]();}}export function isWindows(){const _0x3565b8=a206_0x50627a;return process[_0x3565b8(0x1bf)]===_0x3565b8(0x191);}export function getCrossSpawnOptions(_0x1ea80f){return{..._0x1ea80f??{},'shell':isWindows()};}export function escapeWindowsArg(_0x5e3169){const _0x2e5e5c=a206_0x50627a;if(!/[ \t"&|<>^%!`\r\n]/[_0x2e5e5c(0x1be)](_0x5e3169))return _0x5e3169;const _0xd08a2a=_0x5e3169[_0x2e5e5c(0x1c6)](/"/g,'\x22\x22');return'\x22'+_0xd08a2a+'\x22';}export function crossSpawn(_0x47e0c0,_0x309c3f,_0x19f43a){const _0x2f1c4f=a206_0x50627a;if(isWindows()){const _0x337272=escapeWindowsArg(_0x47e0c0),_0x4475f2=_0x309c3f[_0x2f1c4f(0x1a4)](escapeWindowsArg),_0xb778a=[_0x337272,..._0x4475f2][_0x2f1c4f(0x1b4)]('\x20');return spawn(_0xb778a,[],{..._0x19f43a,'shell':!![]});}return spawn(_0x47e0c0,_0x309c3f,{..._0x19f43a,'shell':![]});}export function gracefulExit(_0x55e8b1=0x0){const _0xe72cbd=a206_0x50627a;isWindows()?setTimeout(()=>process[_0xe72cbd(0x1a6)](_0x55e8b1),0x32):process[_0xe72cbd(0x1a6)](_0x55e8b1);}export function findExecutable(_0x1f482c,_0x560442=0x1388){return new Promise(_0x47d2e8=>{const _0x579423=a206_0x4a2d,_0x10dfef=isWindows()?_0x579423(0x192):_0x579423(0x1c0);let _0x41eaac=![];const _0x499be4=crossSpawn(_0x10dfef,[_0x1f482c],{'stdio':_0x579423(0x1b0),'shell':isWindows()}),_0x294c1e=setTimeout(()=>{const _0x2cd9db=_0x579423;!_0x41eaac&&(_0x41eaac=!![],_0x499be4[_0x2cd9db(0x1b7)](),_0x47d2e8(null));},_0x560442);let _0x49af53='';_0x499be4['stdout']?.['on']('data',_0x5167ed=>{const _0x46d831=_0x579423;_0x49af53+=_0x5167ed[_0x46d831(0x1a2)]();}),_0x499be4[_0x579423(0x1b8)]?.['on'](_0x579423(0x18f),()=>{}),_0x499be4['on'](_0x579423(0x1a6),_0x18a09f=>{const _0x5e0c3e=_0x579423;if(_0x41eaac)return;_0x41eaac=!![],clearTimeout(_0x294c1e);if(_0x18a09f===0x0&&_0x49af53[_0x5e0c3e(0x1bb)]()){const _0x20d5a3=_0x49af53[_0x5e0c3e(0x1bb)]()[_0x5e0c3e(0x1aa)](/\r?\n/)[0x0];_0x47d2e8(_0x20d5a3);}else _0x47d2e8(null);}),_0x499be4['on'](_0x579423(0x1c4),()=>{if(_0x41eaac)return;_0x41eaac=!![],clearTimeout(_0x294c1e),_0x47d2e8(null);});});}
1
+ const a206_0x17b7e9=a206_0xa6af;(function(_0x2d7b18,_0x59f40b){const _0x28d480=a206_0xa6af,_0x46d8b3=_0x2d7b18();while(!![]){try{const _0x4ddac4=parseInt(_0x28d480(0x164))/0x1+parseInt(_0x28d480(0x186))/0x2+parseInt(_0x28d480(0x16c))/0x3+parseInt(_0x28d480(0x168))/0x4+-parseInt(_0x28d480(0x15d))/0x5*(parseInt(_0x28d480(0x187))/0x6)+parseInt(_0x28d480(0x16f))/0x7+parseInt(_0x28d480(0x18c))/0x8*(-parseInt(_0x28d480(0x170))/0x9);if(_0x4ddac4===_0x59f40b)break;else _0x46d8b3['push'](_0x46d8b3['shift']());}catch(_0x2654d2){_0x46d8b3['push'](_0x46d8b3['shift']());}}}(a206_0x49ec,0xee4a7));import{execSync,spawn}from'node:child_process';const SHELL_NAMES=new Set([a206_0x17b7e9(0x184),a206_0x17b7e9(0x166),'sh','fish',a206_0x17b7e9(0x15e),a206_0x17b7e9(0x161),'csh',a206_0x17b7e9(0x163),'pwsh','powershell','nu','ion',a206_0x17b7e9(0x15c),a206_0x17b7e9(0x17a)]),EPHEMERAL_SHELL_SPAWNERS=new Set([a206_0x17b7e9(0x181),a206_0x17b7e9(0x178),a206_0x17b7e9(0x15f),a206_0x17b7e9(0x179),a206_0x17b7e9(0x169)]);function getProcessInfoWindows(_0x161185){const _0x4512d6=a206_0x17b7e9;try{if(!Number['isInteger'](_0x161185)||_0x161185<=0x0)return null;const _0x504f8f='Get-CimInstance\x20Win32_Process\x20-Filter\x20\x22ProcessId='+_0x161185+_0x4512d6(0x188),_0x744e0a=execSync('powershell.exe\x20-NoProfile\x20-NonInteractive\x20-Command\x20\x22'+_0x504f8f+'\x22',{'encoding':_0x4512d6(0x18f),'windowsHide':!![],'stdio':[_0x4512d6(0x175),_0x4512d6(0x175),_0x4512d6(0x175)]})[_0x4512d6(0x16e)]();if(!_0x744e0a)return null;const [_0xe235c6,..._0x315e8a]=_0x744e0a[_0x4512d6(0x173)](','),_0x5d87b8=parseInt(_0xe235c6,0xa),_0x1139ea=_0x315e8a[_0x4512d6(0x177)](',')['trim']();if(isNaN(_0x5d87b8)||!_0x1139ea)return null;return{'pid':_0x161185,'ppid':_0x5d87b8,'comm':_0x1139ea[_0x4512d6(0x174)](/\.exe$/i,'')};}catch{return null;}}function a206_0xa6af(_0x505842,_0x5ccd4a){_0x505842=_0x505842-0x156;const _0x49ecf5=a206_0x49ec();let _0xa6afcd=_0x49ecf5[_0x505842];return _0xa6afcd;}function getProcessInfoPosix(_0x52014a){const _0x4f5ec5=a206_0x17b7e9;try{const _0x41c379=0x400000;if(!Number[_0x4f5ec5(0x167)](_0x52014a)||_0x52014a<=0x0||_0x52014a>_0x41c379)return null;const _0x28d046=execSync(_0x4f5ec5(0x18d)+_0x52014a+_0x4f5ec5(0x162),{'encoding':_0x4f5ec5(0x18f),'stdio':_0x4f5ec5(0x175)})[_0x4f5ec5(0x16e)](),[_0x1a0c2b,..._0x1db0db]=_0x28d046[_0x4f5ec5(0x173)](/\s+/),_0x13e7df=parseInt(_0x1a0c2b,0xa),_0x10e4e7=_0x1db0db[_0x4f5ec5(0x177)]('\x20');if(isNaN(_0x13e7df))return null;return{'pid':_0x52014a,'ppid':_0x13e7df,'comm':_0x10e4e7};}catch{return null;}}function getProcessInfo(_0x3678bb){const _0x4ffe6c=a206_0x17b7e9;if(process[_0x4ffe6c(0x176)]===_0x4ffe6c(0x16b))return getProcessInfoWindows(_0x3678bb);return getProcessInfoPosix(_0x3678bb);}function getBasename(_0x33a3fa){const _0x4c5f57=a206_0x17b7e9;return _0x33a3fa['replace'](/^-/,'')[_0x4c5f57(0x173)]('/')[_0x4c5f57(0x156)]()?.[_0x4c5f57(0x18b)]()||'';}function isShell(_0x3016da){const _0x4c35c9=a206_0x17b7e9;return SHELL_NAMES[_0x4c35c9(0x185)](getBasename(_0x3016da));}function isEphemeralShellSpawner(_0xd5f8a0){return EPHEMERAL_SHELL_SPAWNERS['has'](getBasename(_0xd5f8a0));}let cachedShellPID;function findShellPID(){const _0x5c30f3=a206_0x17b7e9;if(process[_0x5c30f3(0x183)]===undefined)return process[_0x5c30f3(0x17d)];let _0x27cd0e=process[_0x5c30f3(0x183)];const _0x3a7ad5=0xa;let _0x26b171=0x0;while(_0x26b171<_0x3a7ad5){const _0x23b09d=getProcessInfo(_0x27cd0e);if(!_0x23b09d)break;if(isShell(_0x23b09d[_0x5c30f3(0x159)])){const _0x3ff6e5=getProcessInfo(_0x23b09d[_0x5c30f3(0x183)]);if(_0x3ff6e5&&isEphemeralShellSpawner(_0x3ff6e5[_0x5c30f3(0x159)])){_0x27cd0e=_0x23b09d[_0x5c30f3(0x183)],_0x26b171++;continue;}return _0x23b09d[_0x5c30f3(0x17d)];}if(_0x23b09d['ppid']===0x0||_0x23b09d[_0x5c30f3(0x183)]===0x1){if(isShell(_0x23b09d[_0x5c30f3(0x159)]))return _0x23b09d[_0x5c30f3(0x17d)];break;}_0x27cd0e=_0x23b09d[_0x5c30f3(0x183)],_0x26b171++;}return process[_0x5c30f3(0x183)]!==undefined?process[_0x5c30f3(0x183)]:process[_0x5c30f3(0x17d)];}export function getPPID(){return cachedShellPID===undefined&&(cachedShellPID=findShellPID()),cachedShellPID;}export function clearPPIDCache(){cachedShellPID=undefined;}export function isProcessRunning(_0x1b4493){const _0x108c5c=a206_0x17b7e9;if(!Number[_0x108c5c(0x167)](_0x1b4493)||_0x1b4493<=0x0)return![];try{return process[_0x108c5c(0x165)](_0x1b4493,0x0),!![];}catch{return![];}}export function openBrowser(_0x3f4283){const _0x1bdef9=a206_0x17b7e9;let _0x407799;try{_0x407799=new URL(_0x3f4283);}catch{throw new Error('Invalid\x20URL:\x20'+_0x3f4283);}if(_0x407799['protocol']!==_0x1bdef9(0x18e)&&_0x407799[_0x1bdef9(0x171)]!==_0x1bdef9(0x17b))throw new Error('Unsupported\x20protocol:\x20'+_0x407799[_0x1bdef9(0x171)]);const _0x7902b2=_0x407799['href'],_0x42e67e=process['platform'];if(_0x42e67e===_0x1bdef9(0x16b))spawn(_0x1bdef9(0x189),['/c',_0x1bdef9(0x160),'',_0x7902b2],{'detached':!![],'stdio':'ignore'})['unref']();else{const _0x4b289e=_0x42e67e===_0x1bdef9(0x172)?_0x1bdef9(0x16a):_0x1bdef9(0x15a);spawn(_0x4b289e,[_0x7902b2],{'detached':!![],'stdio':_0x1bdef9(0x180)})['unref']();}}export function isWindows(){return process['platform']==='win32';}export function getCrossSpawnOptions(_0x314a7c){return{..._0x314a7c??{},'shell':isWindows()};}export function escapeWindowsArg(_0x1a306b){const _0x6b97dd=a206_0x17b7e9;if(!/[ \t"&|<>^%!`\r\n]/[_0x6b97dd(0x17e)](_0x1a306b))return _0x1a306b;const _0x3bc101=_0x1a306b[_0x6b97dd(0x174)](/"/g,'\x22\x22');return'\x22'+_0x3bc101+'\x22';}export function crossSpawn(_0x17c4e8,_0x3fac5c,_0x5e53b7){const _0x1d7c4d=a206_0x17b7e9;if(isWindows()){const _0x369e24=escapeWindowsArg(_0x17c4e8),_0x5a38cd=_0x3fac5c[_0x1d7c4d(0x17f)](escapeWindowsArg),_0x296606=[_0x369e24,..._0x5a38cd][_0x1d7c4d(0x177)]('\x20');return spawn(_0x296606,[],{..._0x5e53b7,'shell':!![]});}return spawn(_0x17c4e8,_0x3fac5c,{..._0x5e53b7,'shell':![]});}export function gracefulExit(_0x16d7e7=0x0){const _0x46657c=a206_0x17b7e9;isWindows()?setTimeout(()=>process[_0x46657c(0x17c)](_0x16d7e7),0x32):process[_0x46657c(0x17c)](_0x16d7e7);}function a206_0x49ec(){const _0x2b825c=['trim','11055513DawvyW','639XNpDMW','protocol','darwin','split','replace','pipe','platform','join','code','electron','xonsh','https:','exit','pid','test','map','ignore','claude','error','ppid','bash','has','2553616ZYnkTU','6mjlJlU','\x22\x20|\x20Select-Object\x20-Property\x20ParentProcessId,Name\x20|\x20ForEach-Object\x20{\x20\x22$($_.ParentProcessId),$($_.Name)\x22\x20}','cmd.exe','data','toLowerCase','423488HRAKYj','ps\x20-p\x20','http:','utf-8','pop','toString','stderr','comm','xdg-open','where.exe','elvish','4161165hsgXVc','ksh','cursor','start','tcsh','\x20-o\x20ppid=,comm=','dash','473909CvDLzA','kill','zsh','isInteger','2167204bSlYCr','treasure\x20studio','open','win32','5084553rcFxYT','stdout'];a206_0x49ec=function(){return _0x2b825c;};return a206_0x49ec();}export function findExecutable(_0x1b5960,_0x178751=0x1388){return new Promise(_0x382603=>{const _0x1ab832=a206_0xa6af,_0x1c60b5=isWindows()?_0x1ab832(0x15b):'which';let _0x385089=![];const _0x21e944=crossSpawn(_0x1c60b5,[_0x1b5960],{'stdio':'pipe','shell':isWindows()}),_0x420ac7=setTimeout(()=>{!_0x385089&&(_0x385089=!![],_0x21e944['kill'](),_0x382603(null));},_0x178751);let _0x3658e6='';_0x21e944[_0x1ab832(0x16d)]?.['on']('data',_0x2cb238=>{const _0x29742b=_0x1ab832;_0x3658e6+=_0x2cb238[_0x29742b(0x157)]();}),_0x21e944[_0x1ab832(0x158)]?.['on'](_0x1ab832(0x18a),()=>{}),_0x21e944['on']('exit',_0xf1d6f7=>{const _0x38e547=_0x1ab832;if(_0x385089)return;_0x385089=!![],clearTimeout(_0x420ac7);if(_0xf1d6f7===0x0&&_0x3658e6[_0x38e547(0x16e)]()){const _0x102e9a=_0x3658e6[_0x38e547(0x16e)]()[_0x38e547(0x173)](/\r?\n/)[0x0];_0x382603(_0x102e9a);}else _0x382603(null);}),_0x21e944['on'](_0x1ab832(0x182),()=>{if(_0x385089)return;_0x385089=!![],clearTimeout(_0x420ac7),_0x382603(null);});});}
@@ -1 +1 @@
1
- (function(_0xe93979,_0x749d77){const _0x3c403f=a207_0x1409,_0x41bba0=_0xe93979();while(!![]){try{const _0x5b2b39=-parseInt(_0x3c403f(0x16d))/0x1*(parseInt(_0x3c403f(0x16a))/0x2)+parseInt(_0x3c403f(0x160))/0x3*(-parseInt(_0x3c403f(0x173))/0x4)+-parseInt(_0x3c403f(0x175))/0x5+-parseInt(_0x3c403f(0x166))/0x6*(-parseInt(_0x3c403f(0x172))/0x7)+parseInt(_0x3c403f(0x163))/0x8*(-parseInt(_0x3c403f(0x16c))/0x9)+parseInt(_0x3c403f(0x174))/0xa+parseInt(_0x3c403f(0x16e))/0xb*(parseInt(_0x3c403f(0x169))/0xc);if(_0x5b2b39===_0x749d77)break;else _0x41bba0['push'](_0x41bba0['shift']());}catch(_0x31e696){_0x41bba0['push'](_0x41bba0['shift']());}}}(a207_0x279f,0x6b83d));import*as a207_0x296e0f from'readline';import{gracefulExit}from'./process.js';export function isInteractive(){const _0x499751=a207_0x1409;return process[_0x499751(0x167)][_0x499751(0x168)]===!![];}function a207_0x1409(_0x14f133,_0x2bc02d){_0x14f133=_0x14f133-0x15b;const _0x279f07=a207_0x279f();let _0x140965=_0x279f07[_0x14f133];return _0x140965;}function a207_0x279f(){const _0x308661=['resume','3FRgeIB','write','createInterface','456gNJIly','\x20(y/N):\x20','setRawMode','93642PNXwyd','stdin','isTTY','30806640ekiSOI','1120uXmLWj','stderr','135414WwSakP','318zzNeeA','11WUkhyB','data','close','setEncoding','56ujythJ','1902232ZLlMKp','660650hkrhJe','4032500nknHbt','question','toLowerCase','stdout','pause'];a207_0x279f=function(){return _0x308661;};return a207_0x279f();}export async function confirm(_0x5461eb){const _0x2f80ef=a207_0x1409,_0x320725=a207_0x296e0f[_0x2f80ef(0x162)]({'input':process[_0x2f80ef(0x167)],'output':process[_0x2f80ef(0x15d)]});return new Promise(_0x2aad44=>{const _0xbfc379=_0x2f80ef;_0x320725[_0xbfc379(0x15b)](_0x5461eb+_0xbfc379(0x164),_0x346eb0=>{const _0x24dbfa=_0xbfc379;_0x320725[_0x24dbfa(0x170)](),_0x2aad44(_0x346eb0[_0x24dbfa(0x15c)]()==='y'||_0x346eb0[_0x24dbfa(0x15c)]()==='yes');});});}export async function confirmKey(_0x31001b){const _0x8dbfe2=a207_0x1409;if(!process['stdin']['isTTY'])return![];return process[_0x8dbfe2(0x16b)][_0x8dbfe2(0x161)](_0x31001b+'\x20[y/N]\x20'),new Promise(_0x3e2a9c=>{const _0x154f91=_0x8dbfe2,_0x281cca=process[_0x154f91(0x167)];_0x281cca['setRawMode'](!![]),_0x281cca[_0x154f91(0x15f)](),_0x281cca[_0x154f91(0x171)]('utf8');const _0x2cc281=_0x3cc179=>{const _0x202c52=_0x154f91;_0x281cca[_0x202c52(0x165)](![]),_0x281cca[_0x202c52(0x15e)](),_0x281cca['removeListener']('data',_0x2cc281);if(_0x3cc179==='\x1b'){process[_0x202c52(0x16b)][_0x202c52(0x161)]('\x0a'),_0x3e2a9c(![]);return;}_0x3cc179==='\x03'&&(process[_0x202c52(0x16b)][_0x202c52(0x161)]('\x0a'),gracefulExit(0x82));if(_0x3cc179['toLowerCase']()==='y'){process['stderr'][_0x202c52(0x161)]('y\x0a'),_0x3e2a9c(!![]);return;}process[_0x202c52(0x16b)]['write']('\x0a'),_0x3e2a9c(![]);};_0x281cca['on'](_0x154f91(0x16f),_0x2cc281);});}
1
+ (function(_0x38c800,_0x4c289e){const _0x535619=a207_0x44bf,_0x4475e2=_0x38c800();while(!![]){try{const _0x58278f=-parseInt(_0x535619(0xb5))/0x1*(parseInt(_0x535619(0xa6))/0x2)+parseInt(_0x535619(0xc2))/0x3+-parseInt(_0x535619(0xb4))/0x4*(-parseInt(_0x535619(0xba))/0x5)+parseInt(_0x535619(0xab))/0x6+parseInt(_0x535619(0xaf))/0x7*(-parseInt(_0x535619(0xb1))/0x8)+-parseInt(_0x535619(0xbb))/0x9+-parseInt(_0x535619(0xae))/0xa*(parseInt(_0x535619(0xc1))/0xb);if(_0x58278f===_0x4c289e)break;else _0x4475e2['push'](_0x4475e2['shift']());}catch(_0x18cbd0){_0x4475e2['push'](_0x4475e2['shift']());}}}(a207_0x560f,0x2a06c));import*as a207_0x16f25e from'readline';import{gracefulExit}from'./process.js';export function isInteractive(){const _0x507ee4=a207_0x44bf;return process[_0x507ee4(0xb9)][_0x507ee4(0xb7)]===!![];}function a207_0x560f(){const _0x25b27f=['isTTY','resume','stdin','1389670uBCJPh','2508327jeDIxF','stdout','setEncoding','stderr','setRawMode','removeListener','438779dzVzfS','835989GKmhNg','pause','4638spKmtE','toLowerCase','createInterface','write','utf8','1859676EOxDFv','data','close','50cWhkNj','126NxJCZu','\x20[y/N]\x20','60040VtJcRS','\x20(y/N):\x20','question','4gTODKo','35HLhgRI','yes'];a207_0x560f=function(){return _0x25b27f;};return a207_0x560f();}function a207_0x44bf(_0x57b2e0,_0x1d6b38){_0x57b2e0=_0x57b2e0-0xa6;const _0x560ff8=a207_0x560f();let _0x44bfb5=_0x560ff8[_0x57b2e0];return _0x44bfb5;}export async function confirm(_0x58f5ea){const _0x45f71c=a207_0x44bf,_0x1474a0=a207_0x16f25e[_0x45f71c(0xa8)]({'input':process[_0x45f71c(0xb9)],'output':process[_0x45f71c(0xbc)]});return new Promise(_0x46958c=>{const _0x446ae8=_0x45f71c;_0x1474a0[_0x446ae8(0xb3)](_0x58f5ea+_0x446ae8(0xb2),_0x57ef5e=>{const _0x2e502b=_0x446ae8;_0x1474a0[_0x2e502b(0xad)](),_0x46958c(_0x57ef5e[_0x2e502b(0xa7)]()==='y'||_0x57ef5e[_0x2e502b(0xa7)]()===_0x2e502b(0xb6));});});}export async function confirmKey(_0x1a73cb){const _0x44baa1=a207_0x44bf;if(!process[_0x44baa1(0xb9)][_0x44baa1(0xb7)])return![];return process['stderr'][_0x44baa1(0xa9)](_0x1a73cb+_0x44baa1(0xb0)),new Promise(_0x449e8b=>{const _0x4a11f6=_0x44baa1,_0x10886c=process[_0x4a11f6(0xb9)];_0x10886c[_0x4a11f6(0xbf)](!![]),_0x10886c[_0x4a11f6(0xb8)](),_0x10886c[_0x4a11f6(0xbd)](_0x4a11f6(0xaa));const _0x272dec=_0xa1c5f1=>{const _0xbc0ade=_0x4a11f6;_0x10886c['setRawMode'](![]),_0x10886c[_0xbc0ade(0xc3)](),_0x10886c[_0xbc0ade(0xc0)](_0xbc0ade(0xac),_0x272dec);if(_0xa1c5f1==='\x1b'){process['stderr'][_0xbc0ade(0xa9)]('\x0a'),_0x449e8b(![]);return;}_0xa1c5f1==='\x03'&&(process[_0xbc0ade(0xbe)][_0xbc0ade(0xa9)]('\x0a'),gracefulExit(0x82));if(_0xa1c5f1[_0xbc0ade(0xa7)]()==='y'){process[_0xbc0ade(0xbe)][_0xbc0ade(0xa9)]('y\x0a'),_0x449e8b(!![]);return;}process[_0xbc0ade(0xbe)][_0xbc0ade(0xa9)]('\x0a'),_0x449e8b(![]);};_0x10886c['on'](_0x4a11f6(0xac),_0x272dec);});}
@@ -1 +1 @@
1
- (function(_0x1865a2,_0x1a79aa){const _0x4f9ef4=a208_0x3ebf,_0x49501c=_0x1865a2();while(!![]){try{const _0x142bb6=parseInt(_0x4f9ef4(0x193))/0x1+parseInt(_0x4f9ef4(0x18d))/0x2*(parseInt(_0x4f9ef4(0x185))/0x3)+parseInt(_0x4f9ef4(0x195))/0x4*(parseInt(_0x4f9ef4(0x194))/0x5)+parseInt(_0x4f9ef4(0x18f))/0x6*(parseInt(_0x4f9ef4(0x19a))/0x7)+-parseInt(_0x4f9ef4(0x199))/0x8*(parseInt(_0x4f9ef4(0x19d))/0x9)+parseInt(_0x4f9ef4(0x198))/0xa+parseInt(_0x4f9ef4(0x196))/0xb*(-parseInt(_0x4f9ef4(0x182))/0xc);if(_0x142bb6===_0x1a79aa)break;else _0x49501c['push'](_0x49501c['shift']());}catch(_0x396748){_0x49501c['push'](_0x49501c['shift']());}}}(a208_0x570d,0x26030));import a208_0x52babe from'ora';import{isWindows}from'./process.js';const windowsSpinner={'interval':0x3e8,'frames':['•']};export function createCommandSpinner(_0x272eeb,_0x169855={}){const _0x52346a=a208_0x3ebf,{verbose:verbose=![],forceEnabled:forceEnabled=![]}=_0x169855;return a208_0x52babe({'text':_0x272eeb,'color':_0x52346a(0x18b),'stream':process[_0x52346a(0x181)],'isEnabled':forceEnabled||process[_0x52346a(0x181)][_0x52346a(0x183)]&&!verbose,...isWindows()&&{'spinner':windowsSpinner}});}export async function withSpinner(_0x51580e,_0x3f6a56,_0xa9ef87={}){const _0x8594cc=a208_0x3ebf,_0x134c76=_0xa9ef87['clock']??(()=>Date[_0x8594cc(0x192)]()),_0x59443d=createCommandSpinner(_0x51580e,_0xa9ef87);_0x59443d[_0x8594cc(0x191)]();const _0x3161be=_0x134c76();try{const _0x28b5d4=await _0x3f6a56(),_0x115b6b=_0x134c76()-_0x3161be;return _0x59443d[_0x8594cc(0x189)](),{'data':_0x28b5d4,'elapsedMs':_0x115b6b};}catch(_0x289a22){_0x59443d[_0x8594cc(0x189)]();throw _0x289a22;}}export async function withProgressSpinner(_0x4bbd51,_0x5fd5bc,_0x3181bb={}){const _0x3d0424=a208_0x3ebf,_0x261c1a=_0x3181bb['clock']??(()=>Date[_0x3d0424(0x192)]()),_0x5173bd=_0x3181bb[_0x3d0424(0x197)]??setInterval,_0x387f38=createCommandSpinner(_0x4bbd51,_0x3181bb);_0x387f38[_0x3d0424(0x191)]();const _0x3fb248=_0x261c1a(),_0x2573c4=_0x4bbd51[_0x3d0424(0x187)](_0x3d0424(0x19c),'')[_0x3d0424(0x184)]()||'Processing',_0x327a5e={};let _0x5c2ce5=_0x4bbd51;const _0x40fc6c=()=>{const _0x4653e9=_0x3d0424;if(!_0x387f38[_0x4653e9(0x18c)])return;const _0xc1a751=_0x261c1a()-_0x3fb248,_0x2c0b1e=formatElapsed(_0xc1a751),_0x483e77=_0x327a5e['phase']?.[_0x4653e9(0x184)]()||_0x2573c4,_0x2fe23f=_0x327a5e[_0x4653e9(0x186)]?_0x4653e9(0x188)+_0x327a5e['jobId']+']':'',_0x51e05e=_0x327a5e[_0x4653e9(0x18a)]?'\x20'+_0x327a5e[_0x4653e9(0x18a)]:'',_0x4d0c52=_0x483e77+'\x20'+_0x2c0b1e+_0x51e05e+_0x2fe23f;_0x4d0c52!==_0x5c2ce5&&_0x4d0c52[_0x4653e9(0x184)]()&&(_0x387f38[_0x4653e9(0x190)]=_0x4d0c52,_0x5c2ce5=_0x4d0c52);},_0x477859=_0x5173bd(()=>{_0x40fc6c();},0x3e8),_0x286739={'setPhase':_0x49f254=>{const _0x3a9d32=_0x3d0424;_0x327a5e['phase']=_0x49f254;const _0x761cfe=_0x49f254?.['trim']()||_0x2573c4,_0x188f9a=_0x261c1a()-_0x3fb248,_0x23abf3=formatElapsed(_0x188f9a),_0x35c954=_0x327a5e[_0x3a9d32(0x186)]?_0x3a9d32(0x188)+_0x327a5e[_0x3a9d32(0x186)]+']':'',_0x4d12f1=_0x327a5e['extra']?'\x20'+_0x327a5e['extra']:'',_0x592cb3=_0x761cfe+'\x20'+_0x23abf3+_0x4d12f1+_0x35c954;_0x387f38[_0x3a9d32(0x18c)]&&_0x592cb3[_0x3a9d32(0x184)]()&&(_0x387f38[_0x3a9d32(0x190)]=_0x592cb3,_0x5c2ce5=_0x592cb3);},'setJobId':_0x16032b=>{_0x327a5e['jobId']=_0x16032b,_0x40fc6c();},'setExtra':_0x2a47a8=>{const _0x16ccb8=_0x3d0424;_0x327a5e[_0x16ccb8(0x18a)]=_0x2a47a8,_0x40fc6c();}};_0x40fc6c();try{const _0x3d1047=await _0x5fd5bc(_0x286739),_0x377386=_0x261c1a()-_0x3fb248;return{'data':_0x3d1047,'elapsedMs':_0x377386};}finally{clearInterval(_0x477859),_0x387f38[_0x3d0424(0x189)]();}}export function formatElapsed(_0xf27d9b){const _0x18e401=a208_0x3ebf,_0x23bd11=Math['floor'](_0xf27d9b/0x3e8);if(_0x23bd11<0x3c)return(_0xf27d9b/0x3e8)[_0x18e401(0x18e)](0x1)+'s';const _0x3c1a6d=Math[_0x18e401(0x19b)](_0x23bd11/0x3c),_0x440fae=_0x23bd11%0x3c;if(_0x3c1a6d<0x3c)return _0x3c1a6d+'m\x20'+_0x440fae+'s';const _0x17215b=Math[_0x18e401(0x19b)](_0x3c1a6d/0x3c),_0x291cee=_0x3c1a6d%0x3c;return _0x17215b+'h\x20'+_0x291cee+'m';}function a208_0x3ebf(_0x5534ff,_0x39a654){_0x5534ff=_0x5534ff-0x181;const _0x570db8=a208_0x570d();let _0x3ebf44=_0x570db8[_0x5534ff];return _0x3ebf44;}function a208_0x570d(){const _0x5a5498=['...','18BryQkY','stderr','24NUQNym','isTTY','trim','33xJkIdn','jobId','replace','\x20[Job\x20ID:\x20','stop','extra','cyan','isSpinning','27034RWSMBB','toFixed','618IiwTIV','text','start','now','191822gsvots','15ORRXPi','171748ByXxiG','2697739USaBIa','intervalFactory','2722900dCrVUu','642872fjxEyo','4438tAzWFO','floor'];a208_0x570d=function(){return _0x5a5498;};return a208_0x570d();}
1
+ (function(_0x26b221,_0x3951bb){const _0x1f4f8d=a208_0x30bd,_0xb0fe8a=_0x26b221();while(!![]){try{const _0x14adbb=parseInt(_0x1f4f8d(0xc5))/0x1+-parseInt(_0x1f4f8d(0xce))/0x2*(parseInt(_0x1f4f8d(0xcc))/0x3)+parseInt(_0x1f4f8d(0xd8))/0x4*(parseInt(_0x1f4f8d(0xc8))/0x5)+-parseInt(_0x1f4f8d(0xbe))/0x6*(parseInt(_0x1f4f8d(0xcb))/0x7)+parseInt(_0x1f4f8d(0xc7))/0x8*(-parseInt(_0x1f4f8d(0xca))/0x9)+parseInt(_0x1f4f8d(0xd1))/0xa*(parseInt(_0x1f4f8d(0xc9))/0xb)+parseInt(_0x1f4f8d(0xda))/0xc*(parseInt(_0x1f4f8d(0xd3))/0xd);if(_0x14adbb===_0x3951bb)break;else _0xb0fe8a['push'](_0xb0fe8a['shift']());}catch(_0x40fe46){_0xb0fe8a['push'](_0xb0fe8a['shift']());}}}(a208_0x5494,0x98019));import a208_0x45a5aa from'ora';import{isWindows}from'./process.js';const windowsSpinner={'interval':0x3e8,'frames':['•']};export function createCommandSpinner(_0x5ebdca,_0x4ff08e={}){const _0x40ad21=a208_0x30bd,{verbose:verbose=![],forceEnabled:forceEnabled=![]}=_0x4ff08e;return a208_0x45a5aa({'text':_0x5ebdca,'color':_0x40ad21(0xc0),'stream':process['stderr'],'isEnabled':forceEnabled||process[_0x40ad21(0xcd)]['isTTY']&&!verbose,...isWindows()&&{'spinner':windowsSpinner}});}function a208_0x5494(){const _0x3c42bd=['33QzmSBm','6925941xSiozF','35Ealoqx','234fhLprV','stderr','4418vjuAlp','Processing','\x20[Job\x20ID:\x20','4008880HRKszk','floor','100061bLfrPU','text','phase','start','trim','428LriUVM','jobId','1812BnPLcw','isSpinning','now','1308282eYCMXH','intervalFactory','cyan','extra','toFixed','clock','stop','30745ZRGobO','...','8XCkgte','12105GFznoJ'];a208_0x5494=function(){return _0x3c42bd;};return a208_0x5494();}function a208_0x30bd(_0x4be2dd,_0x3e00c3){_0x4be2dd=_0x4be2dd-0xbd;const _0x5494e7=a208_0x5494();let _0x30bd41=_0x5494e7[_0x4be2dd];return _0x30bd41;}export async function withSpinner(_0x450d97,_0x294696,_0xe0d6b9={}){const _0x4a6826=a208_0x30bd,_0x25dfae=_0xe0d6b9[_0x4a6826(0xc3)]??(()=>Date['now']()),_0x3168de=createCommandSpinner(_0x450d97,_0xe0d6b9);_0x3168de[_0x4a6826(0xd6)]();const _0x286d4d=_0x25dfae();try{const _0x1e871a=await _0x294696(),_0x3b210c=_0x25dfae()-_0x286d4d;return _0x3168de['stop'](),{'data':_0x1e871a,'elapsedMs':_0x3b210c};}catch(_0x132a92){_0x3168de[_0x4a6826(0xc4)]();throw _0x132a92;}}export async function withProgressSpinner(_0x529e95,_0x115a0e,_0x4671c2={}){const _0x3555aa=a208_0x30bd,_0x588831=_0x4671c2[_0x3555aa(0xc3)]??(()=>Date[_0x3555aa(0xbd)]()),_0x5adfa5=_0x4671c2[_0x3555aa(0xbf)]??setInterval,_0x45ac13=createCommandSpinner(_0x529e95,_0x4671c2);_0x45ac13[_0x3555aa(0xd6)]();const _0xfcc393=_0x588831(),_0x296e74=_0x529e95['replace'](_0x3555aa(0xc6),'')[_0x3555aa(0xd7)]()||_0x3555aa(0xcf),_0x1e3104={};let _0x54955d=_0x529e95;const _0x1a0a25=()=>{const _0x3ce311=_0x3555aa;if(!_0x45ac13[_0x3ce311(0xdb)])return;const _0x46cc9b=_0x588831()-_0xfcc393,_0x59450e=formatElapsed(_0x46cc9b),_0x52410e=_0x1e3104['phase']?.['trim']()||_0x296e74,_0x2f771e=_0x1e3104['jobId']?_0x3ce311(0xd0)+_0x1e3104[_0x3ce311(0xd9)]+']':'',_0x3676c1=_0x1e3104[_0x3ce311(0xc1)]?'\x20'+_0x1e3104[_0x3ce311(0xc1)]:'',_0xc9cce2=_0x52410e+'\x20'+_0x59450e+_0x3676c1+_0x2f771e;_0xc9cce2!==_0x54955d&&_0xc9cce2[_0x3ce311(0xd7)]()&&(_0x45ac13[_0x3ce311(0xd4)]=_0xc9cce2,_0x54955d=_0xc9cce2);},_0x2ce1b2=_0x5adfa5(()=>{_0x1a0a25();},0x3e8),_0x496ffd={'setPhase':_0x5942e9=>{const _0x16a229=_0x3555aa;_0x1e3104[_0x16a229(0xd5)]=_0x5942e9;const _0x53dcd9=_0x5942e9?.[_0x16a229(0xd7)]()||_0x296e74,_0x5885cd=_0x588831()-_0xfcc393,_0x8da487=formatElapsed(_0x5885cd),_0x27023c=_0x1e3104[_0x16a229(0xd9)]?_0x16a229(0xd0)+_0x1e3104[_0x16a229(0xd9)]+']':'',_0x505715=_0x1e3104['extra']?'\x20'+_0x1e3104[_0x16a229(0xc1)]:'',_0x17ddf1=_0x53dcd9+'\x20'+_0x8da487+_0x505715+_0x27023c;_0x45ac13[_0x16a229(0xdb)]&&_0x17ddf1[_0x16a229(0xd7)]()&&(_0x45ac13[_0x16a229(0xd4)]=_0x17ddf1,_0x54955d=_0x17ddf1);},'setJobId':_0x211df0=>{const _0x2a79d9=_0x3555aa;_0x1e3104[_0x2a79d9(0xd9)]=_0x211df0,_0x1a0a25();},'setExtra':_0xf1df31=>{const _0x45f73e=_0x3555aa;_0x1e3104[_0x45f73e(0xc1)]=_0xf1df31,_0x1a0a25();}};_0x1a0a25();try{const _0x12500b=await _0x115a0e(_0x496ffd),_0x5d0a50=_0x588831()-_0xfcc393;return{'data':_0x12500b,'elapsedMs':_0x5d0a50};}finally{clearInterval(_0x2ce1b2),_0x45ac13[_0x3555aa(0xc4)]();}}export function formatElapsed(_0x22810d){const _0x54fe55=a208_0x30bd,_0x11111d=Math[_0x54fe55(0xd2)](_0x22810d/0x3e8);if(_0x11111d<0x3c)return(_0x22810d/0x3e8)[_0x54fe55(0xc2)](0x1)+'s';const _0x1c680a=Math['floor'](_0x11111d/0x3c),_0x34c29f=_0x11111d%0x3c;if(_0x1c680a<0x3c)return _0x1c680a+'m\x20'+_0x34c29f+'s';const _0x44f8b3=Math[_0x54fe55(0xd2)](_0x1c680a/0x3c),_0x12a776=_0x1c680a%0x3c;return _0x44f8b3+'h\x20'+_0x12a776+'m';}
@@ -1 +1 @@
1
- (function(_0x451b16,_0x39afda){const _0x387f06=a209_0x278f,_0x303251=_0x451b16();while(!![]){try{const _0x4e026b=parseInt(_0x387f06(0xb8))/0x1+parseInt(_0x387f06(0xb0))/0x2*(parseInt(_0x387f06(0xb9))/0x3)+-parseInt(_0x387f06(0xaf))/0x4*(-parseInt(_0x387f06(0xc6))/0x5)+-parseInt(_0x387f06(0xc1))/0x6+parseInt(_0x387f06(0xc7))/0x7+-parseInt(_0x387f06(0xbe))/0x8+-parseInt(_0x387f06(0xb4))/0x9;if(_0x4e026b===_0x39afda)break;else _0x303251['push'](_0x303251['shift']());}catch(_0x59e313){_0x303251['push'](_0x303251['shift']());}}}(a209_0x283c,0xacbff));function a209_0x278f(_0x2ce6b2,_0x3c6407){_0x2ce6b2=_0x2ce6b2-0xaf;const _0x283c5f=a209_0x283c();let _0x278f87=_0x283c5f[_0x2ce6b2];return _0x278f87;}function a209_0x283c(){const _0x1681fb=['pop','data','6865020jqwSng','indexOf','event','[LLM\x20API\x20SSE]\x20','445638vDOKZo','9QJeSnB','releaseLock','slice','getReader','body','6584168qeUWzc','Failed\x20to\x20parse\x20SSE\x20data\x20as\x20JSON:\x20','trim','947628lhEWpv','read','split','decode','startsWith','2538185HtCXvZ','659183jIYkmc','8GtteoP','597494XxnmCu','debug'];a209_0x283c=function(){return _0x1681fb;};return a209_0x283c();}export async function*parseSSEStream(_0x3818c7,_0x2790ba){const _0x53148a=a209_0x278f;if(!_0x3818c7[_0x53148a(0xbd)])throw new Error('Response\x20body\x20is\x20null');const _0x1a194e=_0x3818c7[_0x53148a(0xbd)][_0x53148a(0xbc)](),_0xd06da5=new TextDecoder();let _0x55e9aa='',_0x455b2d={};try{while(!![]){const {done:_0x3eb18c,value:_0x49e5b}=await _0x1a194e[_0x53148a(0xc2)]();if(_0x3eb18c){if(_0x455b2d[_0x53148a(0xb3)]){_0x2790ba?.[_0x53148a(0xb1)](_0x53148a(0xb7)+_0x455b2d[_0x53148a(0xb3)]);const _0x342a98=parseSSEData(_0x455b2d['data']);yield _0x342a98;}break;}_0x55e9aa+=_0xd06da5[_0x53148a(0xc4)](_0x49e5b,{'stream':!![]});const _0x4d9b23=_0x55e9aa[_0x53148a(0xc3)]('\x0a');_0x55e9aa=_0x4d9b23[_0x53148a(0xb2)]()||'';for(const _0x3a306a of _0x4d9b23){if(_0x3a306a[_0x53148a(0xc0)]()===''){if(_0x455b2d[_0x53148a(0xb3)]){_0x2790ba?.[_0x53148a(0xb1)](_0x53148a(0xb7)+_0x455b2d[_0x53148a(0xb3)]);const _0x1baf0e=parseSSEData(_0x455b2d[_0x53148a(0xb3)]);yield _0x1baf0e,_0x455b2d={};}continue;}if(_0x3a306a[_0x53148a(0xc5)](':'))continue;const _0x1a3d5f=_0x3a306a[_0x53148a(0xb5)](':');if(_0x1a3d5f===-0x1)continue;const _0x5a3f56=_0x3a306a[_0x53148a(0xbb)](0x0,_0x1a3d5f);let _0x508d41=_0x3a306a[_0x53148a(0xbb)](_0x1a3d5f+0x1);_0x508d41[_0x53148a(0xc5)]('\x20')&&(_0x508d41=_0x508d41[_0x53148a(0xbb)](0x1));switch(_0x5a3f56){case _0x53148a(0xb6):_0x455b2d[_0x53148a(0xb6)]=_0x508d41;break;case _0x53148a(0xb3):_0x455b2d['data']=_0x455b2d['data']?_0x455b2d[_0x53148a(0xb3)]+'\x0a'+_0x508d41:_0x508d41;break;case'id':_0x455b2d['id']=_0x508d41;break;}}}}finally{_0x1a194e[_0x53148a(0xba)]();}}function parseSSEData(_0x1069a3){const _0x542af5=a209_0x278f;try{return JSON['parse'](_0x1069a3);}catch(_0x2b8ad4){throw new Error(_0x542af5(0xbf)+_0x1069a3,{'cause':_0x2b8ad4});}}
1
+ (function(_0x262bf6,_0x49fb44){const _0x1c7608=a209_0x3f81,_0x1c6515=_0x262bf6();while(!![]){try{const _0x100d91=parseInt(_0x1c7608(0x1df))/0x1+-parseInt(_0x1c7608(0x1da))/0x2*(parseInt(_0x1c7608(0x1e6))/0x3)+parseInt(_0x1c7608(0x1e7))/0x4*(parseInt(_0x1c7608(0x1d7))/0x5)+parseInt(_0x1c7608(0x1dc))/0x6+-parseInt(_0x1c7608(0x1e3))/0x7*(parseInt(_0x1c7608(0x1d5))/0x8)+parseInt(_0x1c7608(0x1e2))/0x9+parseInt(_0x1c7608(0x1e9))/0xa;if(_0x100d91===_0x49fb44)break;else _0x1c6515['push'](_0x1c6515['shift']());}catch(_0x6db918){_0x1c6515['push'](_0x1c6515['shift']());}}}(a209_0x3168,0xda8d5));export async function*parseSSEStream(_0x1a76a8,_0x281e4e){const _0x23f1f2=a209_0x3f81;if(!_0x1a76a8[_0x23f1f2(0x1d6)])throw new Error(_0x23f1f2(0x1e0));const _0x55f37f=_0x1a76a8[_0x23f1f2(0x1d6)][_0x23f1f2(0x1e8)](),_0x435075=new TextDecoder();let _0x3d6ac6='',_0x36ce96={};try{while(!![]){const {done:_0x352ec2,value:_0x192358}=await _0x55f37f[_0x23f1f2(0x1d8)]();if(_0x352ec2){if(_0x36ce96['data']){_0x281e4e?.['debug'](_0x23f1f2(0x1e1)+_0x36ce96['data']);const _0x157416=parseSSEData(_0x36ce96[_0x23f1f2(0x1e5)]);yield _0x157416;}break;}_0x3d6ac6+=_0x435075['decode'](_0x192358,{'stream':!![]});const _0x126483=_0x3d6ac6[_0x23f1f2(0x1d9)]('\x0a');_0x3d6ac6=_0x126483['pop']()||'';for(const _0x16c4af of _0x126483){if(_0x16c4af['trim']()===''){if(_0x36ce96[_0x23f1f2(0x1e5)]){_0x281e4e?.[_0x23f1f2(0x1d2)](_0x23f1f2(0x1e1)+_0x36ce96[_0x23f1f2(0x1e5)]);const _0x3e8fef=parseSSEData(_0x36ce96[_0x23f1f2(0x1e5)]);yield _0x3e8fef,_0x36ce96={};}continue;}if(_0x16c4af[_0x23f1f2(0x1e4)](':'))continue;const _0x2eb138=_0x16c4af[_0x23f1f2(0x1d4)](':');if(_0x2eb138===-0x1)continue;const _0x49a10b=_0x16c4af[_0x23f1f2(0x1db)](0x0,_0x2eb138);let _0x229a8b=_0x16c4af['slice'](_0x2eb138+0x1);_0x229a8b[_0x23f1f2(0x1e4)]('\x20')&&(_0x229a8b=_0x229a8b[_0x23f1f2(0x1db)](0x1));switch(_0x49a10b){case _0x23f1f2(0x1d3):_0x36ce96[_0x23f1f2(0x1d3)]=_0x229a8b;break;case _0x23f1f2(0x1e5):_0x36ce96[_0x23f1f2(0x1e5)]=_0x36ce96[_0x23f1f2(0x1e5)]?_0x36ce96['data']+'\x0a'+_0x229a8b:_0x229a8b;break;case'id':_0x36ce96['id']=_0x229a8b;break;}}}}finally{_0x55f37f[_0x23f1f2(0x1dd)]();}}function parseSSEData(_0x13c841){const _0x50445d=a209_0x3f81;try{return JSON[_0x50445d(0x1de)](_0x13c841);}catch(_0x29bf47){throw new Error('Failed\x20to\x20parse\x20SSE\x20data\x20as\x20JSON:\x20'+_0x13c841,{'cause':_0x29bf47});}}function a209_0x3f81(_0x896100,_0x3d2efc){_0x896100=_0x896100-0x1d2;const _0x316856=a209_0x3168();let _0x3f81bb=_0x316856[_0x896100];return _0x3f81bb;}function a209_0x3168(){const _0x321605=['Response\x20body\x20is\x20null','[LLM\x20API\x20SSE]\x20','10610370SuAdIP','745927tPQhOZ','startsWith','data','27PZDYvY','1244wuCPig','getReader','4595800mGRxPD','debug','event','indexOf','96LUAjYn','body','5195ifzlxy','read','split','344184GKgSsI','slice','7702938SXnUSQ','releaseLock','parse','477287ppxzSC'];a209_0x3168=function(){return _0x321605;};return a209_0x3168();}
@@ -1 +1 @@
1
- (function(_0x1328c6,_0x572a54){const _0x8d8ea=a210_0x4517,_0x142d1e=_0x1328c6();while(!![]){try{const _0x47b3f1=-parseInt(_0x8d8ea(0x94))/0x1*(-parseInt(_0x8d8ea(0x8f))/0x2)+-parseInt(_0x8d8ea(0x9e))/0x3+parseInt(_0x8d8ea(0x90))/0x4*(-parseInt(_0x8d8ea(0x9f))/0x5)+parseInt(_0x8d8ea(0xa0))/0x6*(parseInt(_0x8d8ea(0x9d))/0x7)+parseInt(_0x8d8ea(0x9a))/0x8+-parseInt(_0x8d8ea(0x9b))/0x9+parseInt(_0x8d8ea(0x95))/0xa*(-parseInt(_0x8d8ea(0x98))/0xb);if(_0x47b3f1===_0x572a54)break;else _0x142d1e['push'](_0x142d1e['shift']());}catch(_0x215cd8){_0x142d1e['push'](_0x142d1e['shift']());}}}(a210_0x2063,0x2df6f));import a210_0xd1faa7 from'string-width';function a210_0x4517(_0x3d64ff,_0xb8108f){_0x3d64ff=_0x3d64ff-0x8c;const _0x206303=a210_0x2063();let _0x45177e=_0x206303[_0x3d64ff];return _0x45177e;}export function stringWidth(_0x22fdaa){return a210_0xd1faa7(_0x22fdaa);}export function padEnd(_0x2a8835,_0x1b68fa){const _0x4f981c=stringWidth(_0x2a8835);if(_0x4f981c>=_0x1b68fa)return _0x2a8835;return _0x2a8835+'\x20'['repeat'](_0x1b68fa-_0x4f981c);}export function padStart(_0xa95266,_0x59db03){const _0xb233f=a210_0x4517,_0x28ca62=stringWidth(_0xa95266);if(_0x28ca62>=_0x59db03)return _0xa95266;return'\x20'[_0xb233f(0xa1)](_0x59db03-_0x28ca62)+_0xa95266;}export function centerAlign(_0x580372,_0x2a863b){const _0x355c1c=a210_0x4517,_0x5b243b=stringWidth(_0x580372);if(_0x5b243b>_0x2a863b){if(_0x2a863b<=0x1)return'…'['substring'](0x0,_0x2a863b);let _0x34d4f7=_0x580372;while(stringWidth(_0x34d4f7+'…')>_0x2a863b){_0x34d4f7=_0x34d4f7[_0x355c1c(0x91)](0x0,-0x1);}return _0x34d4f7+'…';}if(_0x5b243b===_0x2a863b)return _0x580372;const _0x3be0fe=_0x2a863b-_0x5b243b,_0xee2704=Math[_0x355c1c(0x8d)](_0x3be0fe/0x2),_0x18ef68=_0x3be0fe-_0xee2704;return'\x20'[_0x355c1c(0xa1)](_0xee2704)+_0x580372+'\x20'[_0x355c1c(0xa1)](_0x18ef68);}export function escapeStringLiteral(_0x4c8acb){const _0x26d55a=a210_0x4517;if(!_0x4c8acb||_0x4c8acb[_0x26d55a(0x92)]()['length']===0x0)throw new Error(_0x26d55a(0x9c));const _0x308d64=_0x4c8acb[_0x26d55a(0xa2)](/'/g,'\x27\x27');return'\x27'+_0x308d64+'\x27';}export function globToLike(_0x3a8a31){const _0x41bede=a210_0x4517;let _0x4fdc1c=_0x3a8a31[_0x41bede(0xa2)](/\\/g,'\x5c\x5c')['replace'](/%/g,'\x5c%')[_0x41bede(0xa2)](/_/g,'\x5c_');return _0x4fdc1c=_0x4fdc1c[_0x41bede(0xa2)](/\*/g,'%')[_0x41bede(0xa2)](/\?/g,'_'),_0x4fdc1c;}export function buildLikePattern(_0xb106ae){const _0x4cfbc1=a210_0x4517;if(!_0xb106ae||_0xb106ae[_0x4cfbc1(0x92)]()[_0x4cfbc1(0x99)]===0x0)throw new Error(_0x4cfbc1(0x8c));const _0x17f6de=globToLike(_0xb106ae),_0x63520e=_0x17f6de[_0x4cfbc1(0xa2)](/'/g,'\x27\x27');return'\x27'+_0x63520e+'\x27';}export function matchGlobPattern(_0x3b079f,_0x4dcd28){const _0x1e5163=a210_0x4517,_0x5ce104=_0x4dcd28['replace'](/[.+^${}()|[\]\\]/g,_0x1e5163(0x93))[_0x1e5163(0xa2)](/\*/g,'.*')[_0x1e5163(0xa2)](/\?/g,'.'),_0x39376a=new RegExp('^'+_0x5ce104+'$');return _0x39376a['test'](_0x3b079f);}export function getSanitizedUsername(){const _0x430c00=a210_0x4517,_0x254dcf=process.env.USER||process.env.USERNAME||_0x430c00(0x96);return _0x254dcf[_0x430c00(0xa2)](/[^a-zA-Z0-9]/g,'')[_0x430c00(0x97)]();}export function generateRandomHex(){const _0x3a2634=a210_0x4517,_0x1f894d=Math['floor'](Math['random']()*0xfffff);return _0x1f894d['toString'](0x10)[_0x3a2634(0x8e)](0x5,'0');}function a210_0x2063(){const _0x3d3f13=['padStart','189940uztuIu','23156uuJgTg','slice','trim','\x5c$&','2FwJhHg','229900JhJPPf','unknown','toLowerCase','110BpyIyl','length','2186400bPJUGG','501471FYhyWL','Cannot\x20escape\x20empty\x20string\x20literal','2578562TqtIji','135330YNbKqv','270IRWktL','6UdZpjB','repeat','replace','Cannot\x20build\x20LIKE\x20pattern\x20from\x20empty\x20string','floor'];a210_0x2063=function(){return _0x3d3f13;};return a210_0x2063();}export function sanitizeFileName(_0x4ee2d2){const _0x109e7c=a210_0x4517;return _0x4ee2d2['toLowerCase']()[_0x109e7c(0xa2)](/[/\\:*?"<>|]/g,'-')[_0x109e7c(0xa2)](/\s+/g,'-')[_0x109e7c(0xa2)](/-+/g,'-')[_0x109e7c(0xa2)](/^-|-$/g,'');}
1
+ (function(_0x44f0db,_0x562e52){const _0x45c3c2=a210_0x25f9,_0x458ff2=_0x44f0db();while(!![]){try{const _0x30af5b=parseInt(_0x45c3c2(0x1ef))/0x1+-parseInt(_0x45c3c2(0x1ea))/0x2*(-parseInt(_0x45c3c2(0x1e8))/0x3)+parseInt(_0x45c3c2(0x1e7))/0x4+-parseInt(_0x45c3c2(0x1e9))/0x5*(parseInt(_0x45c3c2(0x1e6))/0x6)+-parseInt(_0x45c3c2(0x1ee))/0x7+parseInt(_0x45c3c2(0x1f4))/0x8*(parseInt(_0x45c3c2(0x1eb))/0x9)+parseInt(_0x45c3c2(0x1f3))/0xa*(-parseInt(_0x45c3c2(0x1e4))/0xb);if(_0x30af5b===_0x562e52)break;else _0x458ff2['push'](_0x458ff2['shift']());}catch(_0x5f30c){_0x458ff2['push'](_0x458ff2['shift']());}}}(a210_0x4dc3,0x8defe));import a210_0x78f686 from'string-width';export function stringWidth(_0x132a19){return a210_0x78f686(_0x132a19);}function a210_0x4dc3(){const _0x20676f=['2627992ACzidY','18Jzvxpl','2072735hjRyOn','306078mnCwdg','240399GDZhpo','length','repeat','6496609dEwjzl','613797XyuvJC','toLowerCase','random','Cannot\x20escape\x20empty\x20string\x20literal','27320DDpOLH','72ugnMeK','padStart','trim','slice','unknown','\x5c$&','substring','replace','2035MLlQob','floor','6bXiGJb'];a210_0x4dc3=function(){return _0x20676f;};return a210_0x4dc3();}export function padEnd(_0x5a877e,_0x50f296){const _0xd89d06=a210_0x25f9,_0xfc8fb6=stringWidth(_0x5a877e);if(_0xfc8fb6>=_0x50f296)return _0x5a877e;return _0x5a877e+'\x20'[_0xd89d06(0x1ed)](_0x50f296-_0xfc8fb6);}export function padStart(_0x4248ba,_0x37593d){const _0x2f72af=a210_0x25f9,_0x5d6a03=stringWidth(_0x4248ba);if(_0x5d6a03>=_0x37593d)return _0x4248ba;return'\x20'[_0x2f72af(0x1ed)](_0x37593d-_0x5d6a03)+_0x4248ba;}export function centerAlign(_0x5c8739,_0x59312b){const _0x182cb7=a210_0x25f9,_0x2a41b7=stringWidth(_0x5c8739);if(_0x2a41b7>_0x59312b){if(_0x59312b<=0x1)return'…'[_0x182cb7(0x1e2)](0x0,_0x59312b);let _0x53f49d=_0x5c8739;while(stringWidth(_0x53f49d+'…')>_0x59312b){_0x53f49d=_0x53f49d[_0x182cb7(0x1f7)](0x0,-0x1);}return _0x53f49d+'…';}if(_0x2a41b7===_0x59312b)return _0x5c8739;const _0x36bb2b=_0x59312b-_0x2a41b7,_0x473a3b=Math[_0x182cb7(0x1e5)](_0x36bb2b/0x2),_0x1cea7d=_0x36bb2b-_0x473a3b;return'\x20'[_0x182cb7(0x1ed)](_0x473a3b)+_0x5c8739+'\x20'[_0x182cb7(0x1ed)](_0x1cea7d);}export function escapeStringLiteral(_0x4ce895){const _0x1d7f4b=a210_0x25f9;if(!_0x4ce895||_0x4ce895['trim']()['length']===0x0)throw new Error(_0x1d7f4b(0x1f2));const _0x571ab2=_0x4ce895['replace'](/'/g,'\x27\x27');return'\x27'+_0x571ab2+'\x27';}export function globToLike(_0x35946b){const _0x36cc99=a210_0x25f9;let _0x4b1497=_0x35946b[_0x36cc99(0x1e3)](/\\/g,'\x5c\x5c')['replace'](/%/g,'\x5c%')[_0x36cc99(0x1e3)](/_/g,'\x5c_');return _0x4b1497=_0x4b1497[_0x36cc99(0x1e3)](/\*/g,'%')[_0x36cc99(0x1e3)](/\?/g,'_'),_0x4b1497;}function a210_0x25f9(_0x48a771,_0x337a1b){_0x48a771=_0x48a771-0x1e0;const _0x4dc3b0=a210_0x4dc3();let _0x25f971=_0x4dc3b0[_0x48a771];return _0x25f971;}export function buildLikePattern(_0x25f6e0){const _0x218439=a210_0x25f9;if(!_0x25f6e0||_0x25f6e0[_0x218439(0x1f6)]()[_0x218439(0x1ec)]===0x0)throw new Error('Cannot\x20build\x20LIKE\x20pattern\x20from\x20empty\x20string');const _0x126c20=globToLike(_0x25f6e0),_0x122aa1=_0x126c20['replace'](/'/g,'\x27\x27');return'\x27'+_0x122aa1+'\x27';}export function matchGlobPattern(_0xd28a61,_0x3302b6){const _0x38b10d=a210_0x25f9,_0x5c9f83=_0x3302b6['replace'](/[.+^${}()|[\]\\]/g,_0x38b10d(0x1e1))[_0x38b10d(0x1e3)](/\*/g,'.*')[_0x38b10d(0x1e3)](/\?/g,'.'),_0x18977d=new RegExp('^'+_0x5c9f83+'$');return _0x18977d['test'](_0xd28a61);}export function getSanitizedUsername(){const _0x42aece=a210_0x25f9,_0x43f484=process.env.USER||process.env.USERNAME||_0x42aece(0x1e0);return _0x43f484[_0x42aece(0x1e3)](/[^a-zA-Z0-9]/g,'')['toLowerCase']();}export function generateRandomHex(){const _0x1602dc=a210_0x25f9,_0x53fc80=Math[_0x1602dc(0x1e5)](Math[_0x1602dc(0x1f1)]()*0xfffff);return _0x53fc80['toString'](0x10)[_0x1602dc(0x1f5)](0x5,'0');}export function sanitizeFileName(_0x4d81ec){const _0xe8a51=a210_0x25f9;return _0x4d81ec[_0xe8a51(0x1f0)]()[_0xe8a51(0x1e3)](/[/\\:*?"<>|]/g,'-')[_0xe8a51(0x1e3)](/\s+/g,'-')[_0xe8a51(0x1e3)](/-+/g,'-')[_0xe8a51(0x1e3)](/^-|-$/g,'');}
@@ -1 +1 @@
1
- (function(_0x3e20ff,_0x44ac5d){const _0x5c2d4f=a211_0x4708,_0x250edc=_0x3e20ff();while(!![]){try{const _0x41923b=-parseInt(_0x5c2d4f(0x1a1))/0x1*(-parseInt(_0x5c2d4f(0x19e))/0x2)+parseInt(_0x5c2d4f(0x18f))/0x3+-parseInt(_0x5c2d4f(0x193))/0x4*(parseInt(_0x5c2d4f(0x18c))/0x5)+-parseInt(_0x5c2d4f(0x198))/0x6*(-parseInt(_0x5c2d4f(0x190))/0x7)+-parseInt(_0x5c2d4f(0x19f))/0x8+-parseInt(_0x5c2d4f(0x196))/0x9*(-parseInt(_0x5c2d4f(0x1a0))/0xa)+-parseInt(_0x5c2d4f(0x18b))/0xb;if(_0x41923b===_0x44ac5d)break;else _0x250edc['push'](_0x250edc['shift']());}catch(_0x853a33){_0x250edc['push'](_0x250edc['shift']());}}}(a211_0x11dc,0xa5a19));function hasWildcard(_0x2df2fb){return _0x2df2fb['includes']('*')||_0x2df2fb['includes']('?');}export function parseTableReference(_0x450c0e){const _0x311e98=a211_0x4708;if(!_0x450c0e||_0x450c0e[_0x311e98(0x192)]()[_0x311e98(0x197)]===0x0)throw new Error(_0x311e98(0x18a));const _0x556009=_0x450c0e[_0x311e98(0x192)](),_0x1c7066={'original':_0x556009},_0x4c3240=_0x556009[_0x311e98(0x18d)]('.');if(_0x4c3240[_0x311e98(0x197)]===0x1){const _0x2b54df=_0x4c3240[0x0];if(!_0x2b54df)throw new Error(_0x311e98(0x199));_0x1c7066[_0x311e98(0x195)]=_0x2b54df;}else{if(_0x4c3240[_0x311e98(0x197)]===0x2){const [_0x3e2325,_0x37c1da]=_0x4c3240;if(!_0x3e2325)throw new Error(_0x311e98(0x191));if(!_0x37c1da)throw new Error(_0x311e98(0x19b));_0x1c7066[_0x311e98(0x1a3)]=_0x3e2325,_0x1c7066['table']=_0x37c1da;}else{if(_0x4c3240[_0x311e98(0x197)]===0x3){const [_0xccb105,_0x7d2ff4,_0x1056ea]=_0x4c3240;if(!_0xccb105||!_0x7d2ff4||!_0x1056ea)throw new Error(_0x311e98(0x19c));_0x1c7066[_0x311e98(0x1a2)]=_0xccb105,_0x1c7066[_0x311e98(0x1a3)]=_0x7d2ff4,_0x1c7066['table']=_0x1056ea;}else throw new Error(_0x311e98(0x19d));}}return _0x1c7066;}function a211_0x4708(_0x29a2d0,_0x1357ff){_0x29a2d0=_0x29a2d0-0x18a;const _0x11dc6b=a211_0x11dc();let _0x4708ac=_0x11dc6b[_0x29a2d0];return _0x4708ac;}export function formatTableReference(_0x344abe){const _0xddda30=a211_0x4708,_0xca824d=[];return _0x344abe['catalog']&&_0xca824d[_0xddda30(0x19a)](_0x344abe[_0xddda30(0x1a2)]),_0x344abe[_0xddda30(0x1a3)]&&_0xca824d[_0xddda30(0x19a)](_0x344abe[_0xddda30(0x1a3)]),_0x344abe[_0xddda30(0x195)]&&_0xca824d[_0xddda30(0x19a)](_0x344abe['table']),_0xca824d[_0xddda30(0x18e)]('.');}export function validateTableListReference(_0x16f742){return undefined;}export function validateTableDescribeReference(_0x35ee6a){const _0x305476=a211_0x4708;if(!_0x35ee6a[_0x305476(0x195)])return _0x305476(0x194);if(_0x35ee6a['database']&&hasWildcard(_0x35ee6a[_0x305476(0x1a3)]))return'Wildcards\x20are\x20not\x20allowed\x20in\x20database\x20name\x20for\x20describe\x20operation';if(hasWildcard(_0x35ee6a[_0x305476(0x195)]))return'Wildcards\x20are\x20not\x20allowed\x20in\x20table\x20name\x20for\x20describe\x20operation';return undefined;}function a211_0x11dc(){const _0x3ef6ac=['Database\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20databases\x20(e.g.,\x20\x22*.mytable\x22)','trim','1192372kieZwK','Table\x20name\x20is\x20required\x20for\x20describe\x20operation','table','1049229WQukoV','length','6Ugxwjs','Pattern\x20cannot\x20be\x20just\x20a\x20dot','push','Table\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20tables\x20(e.g.,\x20\x22mydb.*\x22)','Invalid\x20catalog.database.table\x20format\x20-\x20all\x20parts\x20must\x20be\x20non-empty','Invalid\x20pattern\x20format\x20-\x20too\x20many\x20dots\x20(max:\x20catalog.database.table)','34IpsgIf','3935368BZJVps','110fjiBOE','78343oevHki','catalog','database','Pattern\x20cannot\x20be\x20empty\x20or\x20whitespace-only','18341609yWtFSF','15cbzzoU','split','join','81945DBmktu','7633549gLHnzq'];a211_0x11dc=function(){return _0x3ef6ac;};return a211_0x11dc();}
1
+ (function(_0x599ce0,_0x5b4c74){const _0x36db90=a211_0x4bb3,_0x4b5f2d=_0x599ce0();while(!![]){try{const _0x465d68=-parseInt(_0x36db90(0x1d2))/0x1+-parseInt(_0x36db90(0x1c6))/0x2*(parseInt(_0x36db90(0x1cb))/0x3)+parseInt(_0x36db90(0x1d6))/0x4+parseInt(_0x36db90(0x1d1))/0x5+parseInt(_0x36db90(0x1da))/0x6*(parseInt(_0x36db90(0x1d8))/0x7)+-parseInt(_0x36db90(0x1cf))/0x8+parseInt(_0x36db90(0x1c7))/0x9;if(_0x465d68===_0x5b4c74)break;else _0x4b5f2d['push'](_0x4b5f2d['shift']());}catch(_0x52fa0f){_0x4b5f2d['push'](_0x4b5f2d['shift']());}}}(a211_0xe373,0x747c8));function hasWildcard(_0x337043){const _0x27a5f7=a211_0x4bb3;return _0x337043[_0x27a5f7(0x1cc)]('*')||_0x337043[_0x27a5f7(0x1cc)]('?');}function a211_0xe373(){const _0x1f426=['1928780Ljnvut','5488BlqXfK','push','Pattern\x20cannot\x20be\x20empty\x20or\x20whitespace-only','catalog','225648OCLbKd','Invalid\x20pattern\x20format\x20-\x20too\x20many\x20dots\x20(max:\x20catalog.database.table)','2969309ULfcOW','Pattern\x20cannot\x20be\x20just\x20a\x20dot','6rVcfOU','table','Table\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20tables\x20(e.g.,\x20\x22mydb.*\x22)','length','Database\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20databases\x20(e.g.,\x20\x22*.mytable\x22)','6OrqwAC','4012731jbJnIw','Wildcards\x20are\x20not\x20allowed\x20in\x20database\x20name\x20for\x20describe\x20operation','Invalid\x20catalog.database.table\x20format\x20-\x20all\x20parts\x20must\x20be\x20non-empty','Table\x20name\x20is\x20required\x20for\x20describe\x20operation','571089uJRLPW','includes','split','database','2068072PiMoUe','Wildcards\x20are\x20not\x20allowed\x20in\x20table\x20name\x20for\x20describe\x20operation'];a211_0xe373=function(){return _0x1f426;};return a211_0xe373();}export function parseTableReference(_0x1a1408){const _0x29e969=a211_0x4bb3;if(!_0x1a1408||_0x1a1408['trim']()['length']===0x0)throw new Error(_0x29e969(0x1d4));const _0x3c2f19=_0x1a1408['trim'](),_0x2bf1da={'original':_0x3c2f19},_0x1c9dc3=_0x3c2f19[_0x29e969(0x1cd)]('.');if(_0x1c9dc3['length']===0x1){const _0x5cf9ed=_0x1c9dc3[0x0];if(!_0x5cf9ed)throw new Error(_0x29e969(0x1d9));_0x2bf1da[_0x29e969(0x1db)]=_0x5cf9ed;}else{if(_0x1c9dc3[_0x29e969(0x1dd)]===0x2){const [_0x13589d,_0x96bf9b]=_0x1c9dc3;if(!_0x13589d)throw new Error(_0x29e969(0x1de));if(!_0x96bf9b)throw new Error(_0x29e969(0x1dc));_0x2bf1da[_0x29e969(0x1ce)]=_0x13589d,_0x2bf1da[_0x29e969(0x1db)]=_0x96bf9b;}else{if(_0x1c9dc3[_0x29e969(0x1dd)]===0x3){const [_0xace3b8,_0x5ed260,_0xc8bf7b]=_0x1c9dc3;if(!_0xace3b8||!_0x5ed260||!_0xc8bf7b)throw new Error(_0x29e969(0x1c9));_0x2bf1da[_0x29e969(0x1d5)]=_0xace3b8,_0x2bf1da[_0x29e969(0x1ce)]=_0x5ed260,_0x2bf1da[_0x29e969(0x1db)]=_0xc8bf7b;}else throw new Error(_0x29e969(0x1d7));}}return _0x2bf1da;}function a211_0x4bb3(_0x3db983,_0x13a2ec){_0x3db983=_0x3db983-0x1c6;const _0xe373d8=a211_0xe373();let _0x4bb354=_0xe373d8[_0x3db983];return _0x4bb354;}export function formatTableReference(_0x4684e8){const _0x3e36ef=a211_0x4bb3,_0x23cbe4=[];return _0x4684e8['catalog']&&_0x23cbe4['push'](_0x4684e8[_0x3e36ef(0x1d5)]),_0x4684e8[_0x3e36ef(0x1ce)]&&_0x23cbe4[_0x3e36ef(0x1d3)](_0x4684e8[_0x3e36ef(0x1ce)]),_0x4684e8[_0x3e36ef(0x1db)]&&_0x23cbe4[_0x3e36ef(0x1d3)](_0x4684e8[_0x3e36ef(0x1db)]),_0x23cbe4['join']('.');}export function validateTableListReference(_0x2becee){return undefined;}export function validateTableDescribeReference(_0x12e393){const _0x22b6bb=a211_0x4bb3;if(!_0x12e393['table'])return _0x22b6bb(0x1ca);if(_0x12e393[_0x22b6bb(0x1ce)]&&hasWildcard(_0x12e393['database']))return _0x22b6bb(0x1c8);if(hasWildcard(_0x12e393['table']))return _0x22b6bb(0x1d0);return undefined;}
@@ -1 +1 @@
1
- const a212_0x4e54fc=a212_0x117a;(function(_0xe013b5,_0x122ada){const _0xc68ec8=a212_0x117a,_0x2b96eb=_0xe013b5();while(!![]){try{const _0x29c50f=parseInt(_0xc68ec8(0x13d))/0x1*(-parseInt(_0xc68ec8(0x140))/0x2)+parseInt(_0xc68ec8(0x149))/0x3*(-parseInt(_0xc68ec8(0x137))/0x4)+parseInt(_0xc68ec8(0x13f))/0x5+parseInt(_0xc68ec8(0x131))/0x6+-parseInt(_0xc68ec8(0x133))/0x7*(parseInt(_0xc68ec8(0x141))/0x8)+-parseInt(_0xc68ec8(0x14a))/0x9+parseInt(_0xc68ec8(0x146))/0xa;if(_0x29c50f===_0x122ada)break;else _0x2b96eb['push'](_0x2b96eb['shift']());}catch(_0x47b696){_0x2b96eb['push'](_0x2b96eb['shift']());}}}(a212_0xba27,0xc0a66));import{join}from'path';function a212_0xba27(){const _0x44925f=['97576pZmGZY','init','trace','warn','logs','close','55477xRFvRc','logLevel','6898050dUDYLh','4CKnAJw','824896OSBZpj','debug','consoleHandler','error','logDir','23230380nDClri','logFileName','isInitialized','78FmQffv','13492998hyrHrH','logger','INFO','Session\x20ended','shutdown','3409260hlZPCV','tdx.log','84tGjGMF','fileOnly','fileHandler','info'];a212_0xba27=function(){return _0x44925f;};return a212_0xba27();}import{Logger,LogLevel,FileHandler,ConsoleHandler,DefaultLogFormatter}from'./logger/index.js';function a212_0x117a(_0x2d999c,_0x5958c2){_0x2d999c=_0x2d999c-0x130;const _0xba2766=a212_0xba27();let _0x117a36=_0xba2766[_0x2d999c];return _0x117a36;}import{getGlobalCacheDir}from'./global-cache.js';export{LogLevel}from'./logger/index.js';export class TDXLogger{[a212_0x4e54fc(0x13e)];[a212_0x4e54fc(0x134)];[a212_0x4e54fc(0x145)];[a212_0x4e54fc(0x147)];[a212_0x4e54fc(0x14b)];[a212_0x4e54fc(0x135)]=null;['consoleHandler']=null;constructor(_0x34c56d=LogLevel[a212_0x4e54fc(0x14c)],_0x338020=![],_0x51042f,_0x25875f=a212_0x4e54fc(0x132)){const _0x22dcc2=a212_0x4e54fc;this[_0x22dcc2(0x13e)]=_0x34c56d,this['fileOnly']=_0x338020,this[_0x22dcc2(0x145)]=_0x51042f||join(getGlobalCacheDir(),_0x22dcc2(0x13b)),this['logFileName']=_0x25875f,this[_0x22dcc2(0x14b)]=Logger['of']('tdx');}async[a212_0x4e54fc(0x138)](){const _0x258683=a212_0x4e54fc,_0x2cb4c7=join(this[_0x258683(0x145)],this[_0x258683(0x147)]);if(Logger[_0x258683(0x148)]()){!this[_0x258683(0x134)]&&(this[_0x258683(0x143)]=new ConsoleHandler({'minLevel':LogLevel[_0x258683(0x14c)],'colors':!![]}),Logger['addHandler'](this['consoleHandler']));return;}this[_0x258683(0x135)]=new FileHandler({'filePath':_0x2cb4c7});const _0x5ab1c4=[this['fileHandler']];!this[_0x258683(0x134)]&&(this['consoleHandler']=new ConsoleHandler({'minLevel':LogLevel[_0x258683(0x14c)],'colors':!![]}),_0x5ab1c4['push'](this[_0x258683(0x143)])),await Logger[_0x258683(0x138)]({'defaultLevel':this[_0x258683(0x13e)],'handlers':_0x5ab1c4,'formatter':new DefaultLogFormatter({'colors':!![]})});}[a212_0x4e54fc(0x142)](..._0x5d2595){const _0x29fee4=a212_0x4e54fc;this[_0x29fee4(0x14b)][_0x29fee4(0x142)](..._0x5d2595);}['trace'](..._0x457778){const _0x499e55=a212_0x4e54fc;this[_0x499e55(0x14b)][_0x499e55(0x139)](..._0x457778);}['info'](..._0x2e72ff){this['logger']['info'](..._0x2e72ff);}['warn'](..._0x10a3d0){const _0x17239f=a212_0x4e54fc;this[_0x17239f(0x14b)][_0x17239f(0x13a)](..._0x10a3d0);}[a212_0x4e54fc(0x144)](..._0x1798ef){const _0x1d48ce=a212_0x4e54fc;this[_0x1d48ce(0x14b)][_0x1d48ce(0x144)](..._0x1798ef);}async[a212_0x4e54fc(0x13c)](){const _0x2c7911=a212_0x4e54fc;this[_0x2c7911(0x14b)][_0x2c7911(0x136)](_0x2c7911(0x14d)),await Logger[_0x2c7911(0x130)]();}['getLogPath'](){const _0x544977=a212_0x4e54fc;return join(this[_0x544977(0x145)],this[_0x544977(0x147)]);}}
1
+ const a212_0x9ade5f=a212_0x5d82;(function(_0x36af6d,_0x393d2e){const _0x7b67a=a212_0x5d82,_0x1126e8=_0x36af6d();while(!![]){try{const _0x53ba1c=parseInt(_0x7b67a(0xc0))/0x1*(-parseInt(_0x7b67a(0xae))/0x2)+-parseInt(_0x7b67a(0xbe))/0x3+-parseInt(_0x7b67a(0xbd))/0x4+parseInt(_0x7b67a(0xc7))/0x5*(parseInt(_0x7b67a(0xb9))/0x6)+-parseInt(_0x7b67a(0xc1))/0x7+parseInt(_0x7b67a(0xc4))/0x8+parseInt(_0x7b67a(0xc6))/0x9*(parseInt(_0x7b67a(0xc5))/0xa);if(_0x53ba1c===_0x393d2e)break;else _0x1126e8['push'](_0x1126e8['shift']());}catch(_0x564dc5){_0x1126e8['push'](_0x1126e8['shift']());}}}(a212_0x1e8b,0x84044));import{join}from'path';import{Logger,LogLevel,FileHandler,ConsoleHandler,DefaultLogFormatter}from'./logger/index.js';function a212_0x5d82(_0x350bc5,_0x3c0113){_0x350bc5=_0x350bc5-0xa9;const _0x1e8b08=a212_0x1e8b();let _0x5d826b=_0x1e8b08[_0x350bc5];return _0x5d826b;}import{getGlobalCacheDir}from'./global-cache.js';export{LogLevel}from'./logger/index.js';function a212_0x1e8b(){const _0x2c93f3=['10XGcrWU','12487572ahWykk','1635980vORJsc','close','Session\x20ended','isInitialized','info','init','logger','INFO','2IWIala','getLogPath','logLevel','push','fileOnly','tdx','addHandler','consoleHandler','tdx.log','trace','warn','12iNeRqq','debug','logDir','error','991088hETFIM','2995653pcSHJW','logs','106889CvsoBP','4234923JvgyAp','fileHandler','logFileName','3656328ZDdfgx'];a212_0x1e8b=function(){return _0x2c93f3;};return a212_0x1e8b();}export class TDXLogger{[a212_0x9ade5f(0xb0)];[a212_0x9ade5f(0xb2)];[a212_0x9ade5f(0xbb)];[a212_0x9ade5f(0xc3)];[a212_0x9ade5f(0xac)];['fileHandler']=null;['consoleHandler']=null;constructor(_0x4d6749=LogLevel[a212_0x9ade5f(0xad)],_0x1fe102=![],_0x3651be,_0x3bb5c6=a212_0x9ade5f(0xb6)){const _0x34c8a5=a212_0x9ade5f;this['logLevel']=_0x4d6749,this[_0x34c8a5(0xb2)]=_0x1fe102,this[_0x34c8a5(0xbb)]=_0x3651be||join(getGlobalCacheDir(),_0x34c8a5(0xbf)),this[_0x34c8a5(0xc3)]=_0x3bb5c6,this[_0x34c8a5(0xac)]=Logger['of'](_0x34c8a5(0xb3));}async[a212_0x9ade5f(0xab)](){const _0x62ec69=a212_0x9ade5f,_0x513800=join(this['logDir'],this[_0x62ec69(0xc3)]);if(Logger[_0x62ec69(0xa9)]()){!this['fileOnly']&&(this[_0x62ec69(0xb5)]=new ConsoleHandler({'minLevel':LogLevel[_0x62ec69(0xad)],'colors':!![]}),Logger[_0x62ec69(0xb4)](this['consoleHandler']));return;}this[_0x62ec69(0xc2)]=new FileHandler({'filePath':_0x513800});const _0x132580=[this[_0x62ec69(0xc2)]];!this[_0x62ec69(0xb2)]&&(this[_0x62ec69(0xb5)]=new ConsoleHandler({'minLevel':LogLevel[_0x62ec69(0xad)],'colors':!![]}),_0x132580[_0x62ec69(0xb1)](this['consoleHandler'])),await Logger[_0x62ec69(0xab)]({'defaultLevel':this['logLevel'],'handlers':_0x132580,'formatter':new DefaultLogFormatter({'colors':!![]})});}[a212_0x9ade5f(0xba)](..._0x22c202){const _0x4b5910=a212_0x9ade5f;this[_0x4b5910(0xac)][_0x4b5910(0xba)](..._0x22c202);}[a212_0x9ade5f(0xb7)](..._0x5d44cb){const _0x2156be=a212_0x9ade5f;this[_0x2156be(0xac)]['trace'](..._0x5d44cb);}[a212_0x9ade5f(0xaa)](..._0x2d6d9e){const _0x4f22a9=a212_0x9ade5f;this['logger'][_0x4f22a9(0xaa)](..._0x2d6d9e);}[a212_0x9ade5f(0xb8)](..._0x4fbbd8){const _0x918db9=a212_0x9ade5f;this[_0x918db9(0xac)][_0x918db9(0xb8)](..._0x4fbbd8);}[a212_0x9ade5f(0xbc)](..._0x139b04){const _0x5945ce=a212_0x9ade5f;this[_0x5945ce(0xac)][_0x5945ce(0xbc)](..._0x139b04);}async[a212_0x9ade5f(0xc8)](){const _0x177527=a212_0x9ade5f;this[_0x177527(0xac)][_0x177527(0xaa)](_0x177527(0xc9)),await Logger['shutdown']();}[a212_0x9ade5f(0xaf)](){const _0x2c9b2c=a212_0x9ade5f;return join(this[_0x2c9b2c(0xbb)],this[_0x2c9b2c(0xc3)]);}}
@@ -1 +1 @@
1
- const a213_0x5f2e11=a213_0x4891;(function(_0x25869b,_0x1c0b22){const _0x4b9863=a213_0x4891,_0x50ab91=_0x25869b();while(!![]){try{const _0x3fbec4=-parseInt(_0x4b9863(0x17f))/0x1+-parseInt(_0x4b9863(0x193))/0x2+-parseInt(_0x4b9863(0x176))/0x3*(parseInt(_0x4b9863(0x180))/0x4)+parseInt(_0x4b9863(0x17b))/0x5+parseInt(_0x4b9863(0x179))/0x6+parseInt(_0x4b9863(0x197))/0x7*(parseInt(_0x4b9863(0x18a))/0x8)+-parseInt(_0x4b9863(0x194))/0x9;if(_0x3fbec4===_0x1c0b22)break;else _0x50ab91['push'](_0x50ab91['shift']());}catch(_0x3439e9){_0x50ab91['push'](_0x50ab91['shift']());}}}(a213_0x4ff3,0x57eb5));import{get}from'https';import{gt,valid}from'semver';import a213_0x37ea3a from'chalk';import{createGlobalCache}from'./global-cache.js';const CACHE_DURATION_MS=0x18*0x3c*0x3c*0x3e8,NPM_REGISTRY_BASE='https://registry.npmjs.org/@treasuredata/tdx',TIMEOUT_MS=0x7d0,stableVersionCache=createGlobalCache(a213_0x5f2e11(0x18f),a213_0x5f2e11(0x181)),nextVersionCache=createGlobalCache('last_version_check_next',a213_0x5f2e11(0x173));function getCacheForChannel(_0x534b26){return _0x534b26==='next'?nextVersionCache:stableVersionCache;}function readCache(_0x23f2d2){const _0x1976de=a213_0x5f2e11;return getCacheForChannel(_0x23f2d2)[_0x1976de(0x18e)]()??null;}function writeCache(_0x1fdf07,_0x5ab51d){const _0x57f721=a213_0x5f2e11;try{getCacheForChannel(_0x5ab51d)[_0x57f721(0x183)]({'lastCheck':new Date()['toISOString'](),'latestVersion':_0x1fdf07});}catch{}}function isCacheValid(_0x263e4b){const _0x5d1a0a=a213_0x5f2e11;if(!_0x263e4b)return![];const _0x265bd0=new Date(_0x263e4b[_0x5d1a0a(0x187)])[_0x5d1a0a(0x190)](),_0x2ee822=Date['now']();return _0x2ee822-_0x265bd0<CACHE_DURATION_MS;}function a213_0x4891(_0x2d3b80,_0x337a89){_0x2d3b80=_0x2d3b80-0x170;const _0x4ff3ce=a213_0x4ff3();let _0x48916b=_0x4ff3ce[_0x2d3b80];return _0x48916b;}export function fetchLatestVersion(_0xfd18a9=a213_0x5f2e11(0x182)){const _0x59124c=a213_0x5f2e11,_0x3a9eed=_0xfd18a9===_0x59124c(0x191)?'next':_0x59124c(0x192),_0x30d935=NPM_REGISTRY_BASE+'/'+_0x3a9eed;return new Promise((_0x5cc303,_0x322271)=>{const _0x1ee0e6=_0x59124c,_0x4a15f5=get(_0x30d935,{'timeout':TIMEOUT_MS},_0x3b87fe=>{const _0x49c17b=a213_0x4891;if(_0x3b87fe[_0x49c17b(0x17d)]!==0xc8){clearTimeout(_0x44088e),_0x322271(new Error(_0x49c17b(0x171)+_0x3b87fe[_0x49c17b(0x17d)]));return;}let _0x473680='';_0x3b87fe['on'](_0x49c17b(0x170),_0x158f29=>{_0x473680+=_0x158f29;}),_0x3b87fe['on'](_0x49c17b(0x177),()=>{const _0x3e3325=_0x49c17b;clearTimeout(_0x44088e);try{const _0x2a09d8=JSON[_0x3e3325(0x199)](_0x473680);if(!valid(_0x2a09d8[_0x3e3325(0x172)])){_0x322271(new Error(_0x3e3325(0x184)));return;}_0x5cc303(_0x2a09d8['version']);}catch(_0x32cbdf){_0x322271(_0x32cbdf);}});})['on'](_0x1ee0e6(0x185),_0x40ab7a=>{clearTimeout(_0x44088e),_0x322271(_0x40ab7a);});_0x4a15f5['on']('socket',_0x323f2b=>{_0x323f2b['unref']();});const _0x44088e=setTimeout(()=>{const _0x3887c4=_0x1ee0e6;_0x4a15f5[_0x3887c4(0x18b)](),_0x322271(new Error('Request\x20timeout'));},TIMEOUT_MS);_0x44088e['unref']();});}function a213_0x4ff3(){const _0x55f674=['Invalid\x20version\x20format','error','tdx\x20upgrade\x20--next','lastCheck','\x0aRun:\x20','Run:','1714632fzRvhC','destroy','stderr','latestVersion','read','last_version_check','getTime','next','latest','496228PSOyNc','486459KsbVQN','dim','yellow','14qIwRcg','\x0aUpdate\x20available:\x20','parse','data','HTTP\x20','version','utils/version-check-next','updateAvailable','cyan','591378SQdzea','end','tdx\x20upgrade','3525618bZVvry','channel','1596510hqIbmZ','Update\x20available:','statusCode','currentVersion','279029UCKhTB','8qRvsgx','utils/version-check','stable','write'];a213_0x4ff3=function(){return _0x55f674;};return a213_0x4ff3();}export async function checkForUpdate(_0x369d5f,_0x4646a8=a213_0x5f2e11(0x182)){const _0x3fb136=a213_0x5f2e11;try{const _0x2fa826=readCache(_0x4646a8);if(isCacheValid(_0x2fa826)){const _0x5b9058=gt(_0x2fa826[_0x3fb136(0x18d)],_0x369d5f);return{'updateAvailable':_0x5b9058,'currentVersion':_0x369d5f,'latestVersion':_0x2fa826[_0x3fb136(0x18d)],'channel':_0x4646a8};}const _0x25cba7=await fetchLatestVersion(_0x4646a8);writeCache(_0x25cba7,_0x4646a8);const _0x5f059f=gt(_0x25cba7,_0x369d5f);return{'updateAvailable':_0x5f059f,'currentVersion':_0x369d5f,'latestVersion':_0x25cba7,'channel':_0x4646a8};}catch{return null;}}export function displayUpdateNotification(_0x51a48a){const _0x4a27af=a213_0x5f2e11;if(!_0x51a48a[_0x4a27af(0x174)])return;const _0x2fd6d0=_0x51a48a[_0x4a27af(0x17a)]===_0x4a27af(0x191)?_0x4a27af(0x186):_0x4a27af(0x178),_0x13c9e1=process[_0x4a27af(0x18c)]['isTTY']&&!process.env.NO_COLOR,_0x4d4b4f=_0x13c9e1?a213_0x37ea3a['gray']('→'):'→',_0x4e8583=_0x13c9e1?a213_0x37ea3a[_0x4a27af(0x195)](_0x51a48a[_0x4a27af(0x17e)]):_0x51a48a[_0x4a27af(0x17e)],_0x4889aa=_0x13c9e1?a213_0x37ea3a['green'](_0x51a48a[_0x4a27af(0x18d)]):_0x51a48a['latestVersion'],_0x191887=_0x13c9e1?a213_0x37ea3a[_0x4a27af(0x175)](_0x2fd6d0):_0x2fd6d0,_0x117ae5=_0x13c9e1?'\x0a'+a213_0x37ea3a[_0x4a27af(0x196)](_0x4a27af(0x17c))+'\x20'+_0x4e8583+'\x20'+_0x4d4b4f+'\x20'+_0x4889aa+'\x0a'+a213_0x37ea3a[_0x4a27af(0x195)](_0x4a27af(0x189))+'\x20'+_0x191887+'\x0a':_0x4a27af(0x198)+_0x4e8583+'\x20'+_0x4d4b4f+'\x20'+_0x4889aa+_0x4a27af(0x188)+_0x191887+'\x0a';process['stderr'][_0x4a27af(0x183)](_0x117ae5);}
1
+ const a213_0x168fed=a213_0xe55c;(function(_0x43a7f8,_0xbca257){const _0x3fb87a=a213_0xe55c,_0x5258d1=_0x43a7f8();while(!![]){try{const _0x2ff0d0=-parseInt(_0x3fb87a(0xbb))/0x1+-parseInt(_0x3fb87a(0xac))/0x2*(-parseInt(_0x3fb87a(0xae))/0x3)+-parseInt(_0x3fb87a(0xc2))/0x4+-parseInt(_0x3fb87a(0xaa))/0x5*(parseInt(_0x3fb87a(0xcb))/0x6)+-parseInt(_0x3fb87a(0xa8))/0x7*(parseInt(_0x3fb87a(0xb3))/0x8)+parseInt(_0x3fb87a(0xcd))/0x9+-parseInt(_0x3fb87a(0xc7))/0xa*(-parseInt(_0x3fb87a(0xb7))/0xb);if(_0x2ff0d0===_0xbca257)break;else _0x5258d1['push'](_0x5258d1['shift']());}catch(_0x37a199){_0x5258d1['push'](_0x5258d1['shift']());}}}(a213_0x245f,0x3e83e));import{get}from'https';import{gt,valid}from'semver';import a213_0x216e0c from'chalk';import{createGlobalCache}from'./global-cache.js';function a213_0xe55c(_0x593862,_0x29844e){_0x593862=_0x593862-0xa4;const _0x245f89=a213_0x245f();let _0xe55cfd=_0x245f89[_0x593862];return _0xe55cfd;}const CACHE_DURATION_MS=0x18*0x3c*0x3c*0x3e8,NPM_REGISTRY_BASE=a213_0x168fed(0xab),TIMEOUT_MS=0x7d0,stableVersionCache=createGlobalCache(a213_0x168fed(0xb2),a213_0x168fed(0xba)),nextVersionCache=createGlobalCache(a213_0x168fed(0xca),'utils/version-check-next');function getCacheForChannel(_0x1b03b4){const _0x3951a3=a213_0x168fed;return _0x1b03b4===_0x3951a3(0xad)?nextVersionCache:stableVersionCache;}function readCache(_0x4d3471){const _0x27e4b6=a213_0x168fed;return getCacheForChannel(_0x4d3471)[_0x27e4b6(0xb4)]()??null;}function writeCache(_0x44ba2c,_0x47d1e7){const _0x3c088b=a213_0x168fed;try{getCacheForChannel(_0x47d1e7)[_0x3c088b(0xcc)]({'lastCheck':new Date()[_0x3c088b(0xc1)](),'latestVersion':_0x44ba2c});}catch{}}function a213_0x245f(){const _0x3acbe3=['yellow','socket','last_version_check_next','4542rYMOwJ','write','3260439obrTOM','channel','green','\x0aRun:\x20','Run:','latestVersion','Request\x20timeout','lastCheck','135506uHdjWN','unref','2845UdPkED','https://registry.npmjs.org/@treasuredata/tdx','190JqfNbH','next','13341kaqXuP','Invalid\x20version\x20format','tdx\x20upgrade\x20--next','stderr','last_version_check','40iJJqoD','read','error','version','17545JISFgn','dim','stable','utils/version-check','131791iKIopB','isTTY','parse','tdx\x20upgrade','statusCode','\x0aUpdate\x20available:\x20','toISOString','1257460txIAUi','now','HTTP\x20','currentVersion','cyan','2790wndybQ'];a213_0x245f=function(){return _0x3acbe3;};return a213_0x245f();}function isCacheValid(_0x336002){const _0xc5ccd0=a213_0x168fed;if(!_0x336002)return![];const _0xe8902f=new Date(_0x336002[_0xc5ccd0(0xa7)])['getTime'](),_0x52d524=Date[_0xc5ccd0(0xc3)]();return _0x52d524-_0xe8902f<CACHE_DURATION_MS;}export function fetchLatestVersion(_0xa68cbb=a213_0x168fed(0xb9)){const _0x197c19=a213_0x168fed,_0x56ea67=_0xa68cbb===_0x197c19(0xad)?_0x197c19(0xad):'latest',_0x4e4e7d=NPM_REGISTRY_BASE+'/'+_0x56ea67;return new Promise((_0x3a84ad,_0x93df85)=>{const _0xa5708c=_0x197c19,_0x2ad0b0=get(_0x4e4e7d,{'timeout':TIMEOUT_MS},_0x5b7479=>{const _0x1e1da9=a213_0xe55c;if(_0x5b7479[_0x1e1da9(0xbf)]!==0xc8){clearTimeout(_0x2050fa),_0x93df85(new Error(_0x1e1da9(0xc4)+_0x5b7479[_0x1e1da9(0xbf)]));return;}let _0x1917ff='';_0x5b7479['on']('data',_0x364833=>{_0x1917ff+=_0x364833;}),_0x5b7479['on']('end',()=>{const _0xc7a3e1=_0x1e1da9;clearTimeout(_0x2050fa);try{const _0x2cdc40=JSON[_0xc7a3e1(0xbd)](_0x1917ff);if(!valid(_0x2cdc40['version'])){_0x93df85(new Error(_0xc7a3e1(0xaf)));return;}_0x3a84ad(_0x2cdc40[_0xc7a3e1(0xb6)]);}catch(_0x5d4af7){_0x93df85(_0x5d4af7);}});})['on'](_0xa5708c(0xb5),_0x2db724=>{clearTimeout(_0x2050fa),_0x93df85(_0x2db724);});_0x2ad0b0['on'](_0xa5708c(0xc9),_0xe24a5=>{const _0x56f771=_0xa5708c;_0xe24a5[_0x56f771(0xa9)]();});const _0x2050fa=setTimeout(()=>{const _0x20aa12=_0xa5708c;_0x2ad0b0['destroy'](),_0x93df85(new Error(_0x20aa12(0xa6)));},TIMEOUT_MS);_0x2050fa['unref']();});}export async function checkForUpdate(_0x54f8ac,_0x510854='stable'){const _0x14d85a=a213_0x168fed;try{const _0x37abc1=readCache(_0x510854);if(isCacheValid(_0x37abc1)){const _0x189107=gt(_0x37abc1['latestVersion'],_0x54f8ac);return{'updateAvailable':_0x189107,'currentVersion':_0x54f8ac,'latestVersion':_0x37abc1[_0x14d85a(0xa5)],'channel':_0x510854};}const _0xe59e45=await fetchLatestVersion(_0x510854);writeCache(_0xe59e45,_0x510854);const _0x3afeb8=gt(_0xe59e45,_0x54f8ac);return{'updateAvailable':_0x3afeb8,'currentVersion':_0x54f8ac,'latestVersion':_0xe59e45,'channel':_0x510854};}catch{return null;}}export function displayUpdateNotification(_0x4ee9c0){const _0x44b68c=a213_0x168fed;if(!_0x4ee9c0['updateAvailable'])return;const _0x5c7d51=_0x4ee9c0[_0x44b68c(0xce)]==='next'?_0x44b68c(0xb0):_0x44b68c(0xbe),_0x498c71=process[_0x44b68c(0xb1)][_0x44b68c(0xbc)]&&!process.env.NO_COLOR,_0x10c7ad=_0x498c71?a213_0x216e0c['gray']('→'):'→',_0x3ebb45=_0x498c71?a213_0x216e0c[_0x44b68c(0xb8)](_0x4ee9c0[_0x44b68c(0xc5)]):_0x4ee9c0['currentVersion'],_0x656106=_0x498c71?a213_0x216e0c[_0x44b68c(0xcf)](_0x4ee9c0['latestVersion']):_0x4ee9c0[_0x44b68c(0xa5)],_0x381637=_0x498c71?a213_0x216e0c[_0x44b68c(0xc6)](_0x5c7d51):_0x5c7d51,_0x1c6237=_0x498c71?'\x0a'+a213_0x216e0c[_0x44b68c(0xc8)]('Update\x20available:')+'\x20'+_0x3ebb45+'\x20'+_0x10c7ad+'\x20'+_0x656106+'\x0a'+a213_0x216e0c[_0x44b68c(0xb8)](_0x44b68c(0xa4))+'\x20'+_0x381637+'\x0a':_0x44b68c(0xc0)+_0x3ebb45+'\x20'+_0x10c7ad+'\x20'+_0x656106+_0x44b68c(0xd0)+_0x381637+'\x0a';process[_0x44b68c(0xb1)][_0x44b68c(0xcc)](_0x1c6237);}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@treasuredata/tdx",
3
- "version": "2026.3.16",
3
+ "version": "2026.3.17",
4
4
  "description": "AI-native CLI for Treasure Data - optimized for both human engineers and AI coding assistants",
5
5
  "type": "module",
6
6
  "bin": {
@@ -26,7 +26,7 @@
26
26
  "node": ">=22.12.0"
27
27
  },
28
28
  "scripts": {
29
- "build:info": "bash scripts/generate-build-info.sh",
29
+ "build:info": "node scripts/generate-build-info.mjs",
30
30
  "build:ts": "npm run build:info && tsc && chmod +x dist/bin.js && cp src/build-info.json dist/build-info.json && node -e \"require('fs').copyFileSync('dist/bin.js','dist/tdx')\"",
31
31
  "build:install": "npm run build:ts && npm install -g",
32
32
  "build:obfuscate": "javascript-obfuscator ./dist --output ./dist",