@treasuredata/tdx 2026.3.42 → 2026.3.43

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 (219) 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/cas-command.js +1 -1
  12. package/dist/commands/cas-segment-command.js +1 -1
  13. package/dist/commands/chat-command.js +1 -1
  14. package/dist/commands/claude-command.js +1 -1
  15. package/dist/commands/claude-statusline-command.js +1 -1
  16. package/dist/commands/claude-usage-command.js +1 -1
  17. package/dist/commands/command.js +1 -1
  18. package/dist/commands/connection-command.js +1 -1
  19. package/dist/commands/databases.js +1 -1
  20. package/dist/commands/delivery-command.js +1 -1
  21. package/dist/commands/describe.js +1 -1
  22. package/dist/commands/engage-campaign-pull-command.js +1 -1
  23. package/dist/commands/engage-campaign-push-command.js +1 -1
  24. package/dist/commands/engage-campaign-validate-command.js +1 -1
  25. package/dist/commands/engage-command.js +1 -1
  26. package/dist/commands/engage-template-pull-command.js +1 -1
  27. package/dist/commands/engage-template-push-command.js +1 -1
  28. package/dist/commands/engage-template-validate-command.js +1 -1
  29. package/dist/commands/job-command.js +1 -1
  30. package/dist/commands/journey-command.js +1 -1
  31. package/dist/commands/journey-validate-command.js +1 -1
  32. package/dist/commands/llm-command.js +1 -1
  33. package/dist/commands/mcp-command.js +1 -1
  34. package/dist/commands/parent-segment-command.js +1 -1
  35. package/dist/commands/policy-command.js +1 -1
  36. package/dist/commands/profile-command.js +1 -1
  37. package/dist/commands/profiles-command.js +1 -1
  38. package/dist/commands/query-command.js +1 -1
  39. package/dist/commands/schedule-command.js +1 -1
  40. package/dist/commands/segment-command.js +1 -1
  41. package/dist/commands/segment-create-command.js +1 -1
  42. package/dist/commands/segment-fields-command.js +1 -1
  43. package/dist/commands/segment-pull-command.js +1 -1
  44. package/dist/commands/segment-push-command.js +1 -1
  45. package/dist/commands/segment-update-command.js +1 -1
  46. package/dist/commands/segment-use-command.js +1 -1
  47. package/dist/commands/segment-validate-command.js +1 -1
  48. package/dist/commands/segments.js +1 -1
  49. package/dist/commands/show.js +1 -1
  50. package/dist/commands/status-command.js +1 -1
  51. package/dist/commands/tables.js +1 -1
  52. package/dist/commands/unset-command.js +1 -1
  53. package/dist/commands/upgrade-command.js +1 -1
  54. package/dist/commands/use-command.js +1 -1
  55. package/dist/commands/user-command.js +1 -1
  56. package/dist/commands/work-command.js +1 -1
  57. package/dist/commands/workflow-command.js +1 -1
  58. package/dist/core/auth.js +1 -1
  59. package/dist/core/command-output.js +1 -1
  60. package/dist/core/config.js +1 -1
  61. package/dist/core/connection-cache.js +1 -1
  62. package/dist/core/constants.js +1 -1
  63. package/dist/core/credential-cache.js +1 -1
  64. package/dist/core/global-context.js +1 -1
  65. package/dist/core/keychain.js +1 -1
  66. package/dist/core/oauth-keychain.js +1 -1
  67. package/dist/core/oauth.js +1 -1
  68. package/dist/core/profile.js +1 -1
  69. package/dist/core/project-config.js +1 -1
  70. package/dist/core/session.js +1 -1
  71. package/dist/core/user-cache.js +1 -1
  72. package/dist/core/version.js +1 -1
  73. package/dist/index.js +1 -1
  74. package/dist/mcp/server.js +1 -1
  75. package/dist/mcp/tools/index.js +1 -1
  76. package/dist/mcp/tools/tdx-run.js +1 -1
  77. package/dist/mcp/tools/tdx-search.js +1 -1
  78. package/dist/mcp/utils.js +1 -1
  79. package/dist/proxy/claude-usage-tracker.js +1 -1
  80. package/dist/proxy/passthrough-server.js +1 -1
  81. package/dist/proxy/sse-usage-parser.js +1 -1
  82. package/dist/sdk/agent/agent-config.js +1 -1
  83. package/dist/sdk/agent/agent-ref-parser.js +1 -1
  84. package/dist/sdk/agent/agent-yaml.js +1 -1
  85. package/dist/sdk/agent/test/evaluator.js +1 -1
  86. package/dist/sdk/agent/test/executor.js +1 -1
  87. package/dist/sdk/agent/test/index.js +1 -1
  88. package/dist/sdk/agent/test/output.js +1 -1
  89. package/dist/sdk/agent/test/parser.js +1 -1
  90. package/dist/sdk/agent/tool-target-registry.js +1 -1
  91. package/dist/sdk/api.js +1 -1
  92. package/dist/sdk/cas/cas-api-client.js +1 -1
  93. package/dist/sdk/cas/cas-audience-yaml.js +1 -1
  94. package/dist/sdk/cas/cas-segment-yaml.js +1 -1
  95. package/dist/sdk/cas/index.js +1 -1
  96. package/dist/sdk/cas/pull-workflow.js +1 -1
  97. package/dist/sdk/cas/push-workflow.js +1 -1
  98. package/dist/sdk/client/cdp-api-client.js +1 -1
  99. package/dist/sdk/client/delivery-api-client.js +1 -1
  100. package/dist/sdk/client/endpoints.js +1 -1
  101. package/dist/sdk/client/engage-api-client.js +1 -1
  102. package/dist/sdk/client/http-client.js +1 -1
  103. package/dist/sdk/client/llm-api-client.js +1 -1
  104. package/dist/sdk/client/oauth-refresh.js +1 -1
  105. package/dist/sdk/client/rate-limiter.js +1 -1
  106. package/dist/sdk/client/td-api-client.js +1 -1
  107. package/dist/sdk/client/trino-api-client.js +1 -1
  108. package/dist/sdk/client/workflow-client.js +1 -1
  109. package/dist/sdk/connection-validator.js +1 -1
  110. package/dist/sdk/connection.js +1 -1
  111. package/dist/sdk/delivery.js +1 -1
  112. package/dist/sdk/engage/campaign-pull.js +1 -1
  113. package/dist/sdk/engage/campaign-push.js +1 -1
  114. package/dist/sdk/engage/campaign-validator.js +1 -1
  115. package/dist/sdk/engage/campaign-yaml.js +1 -1
  116. package/dist/sdk/engage/template-pull.js +1 -1
  117. package/dist/sdk/engage/template-push.js +1 -1
  118. package/dist/sdk/engage/template-validator.js +1 -1
  119. package/dist/sdk/engage/template-yaml.js +1 -1
  120. package/dist/sdk/engage/types/campaign-def.js +1 -1
  121. package/dist/sdk/engage/types/campaign-schema.js +1 -1
  122. package/dist/sdk/engage/types/template-schema.js +1 -1
  123. package/dist/sdk/engage.js +1 -1
  124. package/dist/sdk/errors.js +1 -1
  125. package/dist/sdk/index.js +1 -1
  126. package/dist/sdk/io/index.js +1 -1
  127. package/dist/sdk/io/node-filesystem.js +1 -1
  128. package/dist/sdk/job.js +1 -1
  129. package/dist/sdk/journey.js +1 -1
  130. package/dist/sdk/llm/chat-cache.js +1 -1
  131. package/dist/sdk/llm/index.js +1 -1
  132. package/dist/sdk/llm/llm-backup-utils.js +1 -1
  133. package/dist/sdk/llm/model-factors.js +1 -1
  134. package/dist/sdk/personalization.js +1 -1
  135. package/dist/sdk/policy.js +1 -1
  136. package/dist/sdk/query/index.js +1 -1
  137. package/dist/sdk/query/sql-parser.js +1 -1
  138. package/dist/sdk/realtime.js +1 -1
  139. package/dist/sdk/schedule.js +1 -1
  140. package/dist/sdk/segment/child-segment-yaml.js +1 -1
  141. package/dist/sdk/segment/fields-display.js +1 -1
  142. package/dist/sdk/segment/file-discovery.js +1 -1
  143. package/dist/sdk/segment/journey-utils.js +1 -1
  144. package/dist/sdk/segment/journey-validator.js +1 -1
  145. package/dist/sdk/segment/journey-yaml.js +1 -1
  146. package/dist/sdk/segment/parent-segment-preview.js +1 -1
  147. package/dist/sdk/segment/parent-segment-yaml.js +1 -1
  148. package/dist/sdk/segment/pull-workflow.js +1 -1
  149. package/dist/sdk/segment/push-recovery.js +1 -1
  150. package/dist/sdk/segment/push-workflow.js +1 -1
  151. package/dist/sdk/segment/resolution-context.js +1 -1
  152. package/dist/sdk/segment/segment-path-parser.js +1 -1
  153. package/dist/sdk/segment/segment-ref-parser.js +1 -1
  154. package/dist/sdk/segment/segment-validator.js +1 -1
  155. package/dist/sdk/segment/target-resolution.js +1 -1
  156. package/dist/sdk/segment/tdx-config.js +1 -1
  157. package/dist/sdk/segment/types/activation-schema.js +1 -1
  158. package/dist/sdk/segment/types/journey-def.js +1 -1
  159. package/dist/sdk/segment/types/journey-schema.js +1 -1
  160. package/dist/sdk/segment/types/segment-def.js +1 -1
  161. package/dist/sdk/segment/types/segment-schema.js +1 -1
  162. package/dist/sdk/segment/validate-files.js +1 -1
  163. package/dist/sdk/segment/yaml-validator.js +1 -1
  164. package/dist/sdk/segment.js +1 -1
  165. package/dist/sdk/types/index.js +1 -1
  166. package/dist/sdk/types/progress.js +1 -1
  167. package/dist/sdk/types/workspace.js +1 -1
  168. package/dist/sdk/user.js +1 -1
  169. package/dist/sdk/util/format-detector.js +1 -1
  170. package/dist/sdk/util/formatters.js +1 -1
  171. package/dist/sdk/util/index.js +1 -1
  172. package/dist/sdk/util/paginate.js +1 -1
  173. package/dist/sdk/util/tree-formatter.js +1 -1
  174. package/dist/sdk/workflow/archive-validation.js +1 -1
  175. package/dist/sdk/workflow/clone-workflow.js +1 -1
  176. package/dist/sdk/workflow/index.js +1 -1
  177. package/dist/sdk/workflow/pull-workflow.js +1 -1
  178. package/dist/sdk/workflow/push-workflow.js +1 -1
  179. package/dist/sdk/workflow/tdx-config.js +1 -1
  180. package/dist/sdk/workflow/workflow-utils.js +1 -1
  181. package/dist/sdk/workspace/frontmatter.js +1 -1
  182. package/dist/sdk/workspace/git.js +1 -1
  183. package/dist/sdk/workspace/index.js +1 -1
  184. package/dist/sdk/workspace/templates.js +1 -1
  185. package/dist/sdk/workspace/weekly.js +1 -1
  186. package/dist/sdk/workspace/wikilinks.js +1 -1
  187. package/dist/test-utils/command-runner.js +1 -1
  188. package/dist/test-utils/factories.js +1 -1
  189. package/dist/test-utils/fixtures.js +1 -1
  190. package/dist/test-utils/http-mock.js +1 -1
  191. package/dist/test-utils/index.js +1 -1
  192. package/dist/utils/async.js +1 -1
  193. package/dist/utils/colors.js +1 -1
  194. package/dist/utils/diff.js +1 -1
  195. package/dist/utils/file-permissions.js +1 -1
  196. package/dist/utils/file-reader.js +1 -1
  197. package/dist/utils/github-releases.js +1 -1
  198. package/dist/utils/global-cache.js +1 -1
  199. package/dist/utils/json-loader.js +1 -1
  200. package/dist/utils/local-cache.js +1 -1
  201. package/dist/utils/logger/formatters/default-formatter.js +1 -1
  202. package/dist/utils/logger/formatters/index.js +1 -1
  203. package/dist/utils/logger/handlers/console-handler.js +1 -1
  204. package/dist/utils/logger/handlers/file-handler.js +1 -1
  205. package/dist/utils/logger/handlers/index.js +1 -1
  206. package/dist/utils/logger/handlers/null-handler.js +1 -1
  207. package/dist/utils/logger/index.js +1 -1
  208. package/dist/utils/logger/logger.js +1 -1
  209. package/dist/utils/logger/types.js +1 -1
  210. package/dist/utils/option-validation.js +1 -1
  211. package/dist/utils/process.js +1 -1
  212. package/dist/utils/prompt.js +1 -1
  213. package/dist/utils/spinner.js +1 -1
  214. package/dist/utils/sse-parser.js +1 -1
  215. package/dist/utils/string-utils.js +1 -1
  216. package/dist/utils/table-ref-parser.js +1 -1
  217. package/dist/utils/tdx-logger.js +1 -1
  218. package/dist/utils/version-check.js +1 -1
  219. package/package.json +1 -1
@@ -1 +1 @@
1
- const a227_0x3a3afa=a227_0x4889;(function(_0x5eacc7,_0x448e31){const _0x24e168=a227_0x4889,_0x2f6204=_0x5eacc7();while(!![]){try{const _0x36d883=-parseInt(_0x24e168(0xc0))/0x1*(-parseInt(_0x24e168(0xcb))/0x2)+-parseInt(_0x24e168(0xe2))/0x3+-parseInt(_0x24e168(0xce))/0x4+-parseInt(_0x24e168(0xc9))/0x5*(parseInt(_0x24e168(0xec))/0x6)+-parseInt(_0x24e168(0xbc))/0x7*(parseInt(_0x24e168(0xc7))/0x8)+parseInt(_0x24e168(0xe9))/0x9*(parseInt(_0x24e168(0xdc))/0xa)+parseInt(_0x24e168(0xd5))/0xb*(parseInt(_0x24e168(0xcc))/0xc);if(_0x36d883===_0x448e31)break;else _0x2f6204['push'](_0x2f6204['shift']());}catch(_0x44452a){_0x2f6204['push'](_0x2f6204['shift']());}}}(a227_0xf9bd,0x97511));import{execSync,spawn}from'node:child_process';const SHELL_NAMES=new Set([a227_0x3a3afa(0xef),a227_0x3a3afa(0xe8),'sh',a227_0x3a3afa(0xe3),'ksh',a227_0x3a3afa(0xdf),'csh','dash','pwsh','powershell','nu',a227_0x3a3afa(0xd0),a227_0x3a3afa(0xea),'xonsh']),EPHEMERAL_SHELL_SPAWNERS=new Set([a227_0x3a3afa(0xf0),a227_0x3a3afa(0xdb),a227_0x3a3afa(0xdd),'electron','treasure\x20studio']);function getProcessInfoWindows(_0x41e3cc){const _0x67cce9=a227_0x3a3afa;try{if(!Number[_0x67cce9(0xd1)](_0x41e3cc)||_0x41e3cc<=0x0)return null;const _0x383d62=_0x67cce9(0xe7)+_0x41e3cc+_0x67cce9(0xbe),_0x485570=execSync('powershell.exe\x20-NoProfile\x20-NonInteractive\x20-Command\x20\x22'+_0x383d62+'\x22',{'encoding':_0x67cce9(0xd9),'windowsHide':!![],'stdio':[_0x67cce9(0xc8),_0x67cce9(0xc8),_0x67cce9(0xc8)]})['trim']();if(!_0x485570)return null;const [_0x17f69c,..._0x515cb5]=_0x485570[_0x67cce9(0xcf)](','),_0x41cf80=parseInt(_0x17f69c,0xa),_0x396c63=_0x515cb5[_0x67cce9(0xe0)](',')[_0x67cce9(0xd6)]();if(isNaN(_0x41cf80)||!_0x396c63)return null;return{'pid':_0x41e3cc,'ppid':_0x41cf80,'comm':_0x396c63[_0x67cce9(0xeb)](/\.exe$/i,'')};}catch{return null;}}function getProcessInfoPosix(_0x4b0931){const _0x5a537c=a227_0x3a3afa;try{const _0x2740d3=0x400000;if(!Number['isInteger'](_0x4b0931)||_0x4b0931<=0x0||_0x4b0931>_0x2740d3)return null;const _0x305f70=execSync('ps\x20-p\x20'+_0x4b0931+'\x20-o\x20ppid=,comm=',{'encoding':_0x5a537c(0xd9),'stdio':_0x5a537c(0xc8)})[_0x5a537c(0xd6)](),[_0x13b00d,..._0x22c647]=_0x305f70[_0x5a537c(0xcf)](/\s+/),_0x320eb0=parseInt(_0x13b00d,0xa),_0x5660c8=_0x22c647[_0x5a537c(0xe0)]('\x20');if(isNaN(_0x320eb0))return null;return{'pid':_0x4b0931,'ppid':_0x320eb0,'comm':_0x5660c8};}catch{return null;}}function getProcessInfo(_0x3b89f3){const _0x406a0c=a227_0x3a3afa;if(process['platform']===_0x406a0c(0xd8))return getProcessInfoWindows(_0x3b89f3);return getProcessInfoPosix(_0x3b89f3);}function getBasename(_0x55b6e2){const _0x262c85=a227_0x3a3afa;return _0x55b6e2['replace'](/^-/,'')[_0x262c85(0xcf)]('/')[_0x262c85(0xe4)]()?.[_0x262c85(0xe6)]()||'';}function a227_0x4889(_0x5a8a09,_0x5c2d12){_0x5a8a09=_0x5a8a09-0xbc;const _0xf9bd20=a227_0xf9bd();let _0x4889fd=_0xf9bd20[_0x5a8a09];return _0x4889fd;}function isShell(_0x1e1a49){const _0x3124bd=a227_0x3a3afa;return SHELL_NAMES[_0x3124bd(0xe5)](getBasename(_0x1e1a49));}function isEphemeralShellSpawner(_0x24ec52){const _0x2bd308=a227_0x3a3afa;return EPHEMERAL_SHELL_SPAWNERS[_0x2bd308(0xe5)](getBasename(_0x24ec52));}let cachedShellPID;function findShellPID(){const _0x381487=a227_0x3a3afa;if(process['ppid']===undefined)return process['pid'];let _0x5c40db=process[_0x381487(0xe1)];const _0x1a3043=0xa;let _0x3b1916=0x0;while(_0x3b1916<_0x1a3043){const _0xc21e91=getProcessInfo(_0x5c40db);if(!_0xc21e91)break;if(isShell(_0xc21e91[_0x381487(0xc2)])){const _0x57a43b=getProcessInfo(_0xc21e91[_0x381487(0xe1)]);if(_0x57a43b&&isEphemeralShellSpawner(_0x57a43b[_0x381487(0xc2)])){_0x5c40db=_0xc21e91['ppid'],_0x3b1916++;continue;}return _0xc21e91[_0x381487(0xcd)];}if(_0xc21e91[_0x381487(0xe1)]===0x0||_0xc21e91[_0x381487(0xe1)]===0x1){if(isShell(_0xc21e91[_0x381487(0xc2)]))return _0xc21e91[_0x381487(0xcd)];break;}_0x5c40db=_0xc21e91[_0x381487(0xe1)],_0x3b1916++;}return process[_0x381487(0xe1)]!==undefined?process[_0x381487(0xe1)]:process[_0x381487(0xcd)];}export function getPPID(){return cachedShellPID===undefined&&(cachedShellPID=findShellPID()),cachedShellPID;}export function clearPPIDCache(){cachedShellPID=undefined;}export function isProcessRunning(_0x38c635){const _0x4dfa9a=a227_0x3a3afa;if(!Number[_0x4dfa9a(0xd1)](_0x38c635)||_0x38c635<=0x0)return![];try{return process[_0x4dfa9a(0xbf)](_0x38c635,0x0),!![];}catch{return![];}}export function openBrowser(_0x1d357e){const _0x309e70=a227_0x3a3afa;let _0x31bc19;try{_0x31bc19=new URL(_0x1d357e);}catch{throw new Error(_0x309e70(0xf2)+_0x1d357e);}if(_0x31bc19['protocol']!==_0x309e70(0xd2)&&_0x31bc19[_0x309e70(0xd7)]!==_0x309e70(0xd3))throw new Error('Unsupported\x20protocol:\x20'+_0x31bc19[_0x309e70(0xd7)]);const _0x32c605=_0x31bc19[_0x309e70(0xc6)],_0x4b75fa=process[_0x309e70(0xc5)];if(_0x4b75fa===_0x309e70(0xd8))spawn('cmd.exe',['/c','start','',_0x32c605],{'detached':!![],'stdio':'ignore'})[_0x309e70(0xde)]();else{const _0x5877ae=_0x4b75fa===_0x309e70(0xf4)?_0x309e70(0xee):_0x309e70(0xc4);spawn(_0x5877ae,[_0x32c605],{'detached':!![],'stdio':_0x309e70(0xd4)})['unref']();}}export function isWindows(){const _0x28c91e=a227_0x3a3afa;return process[_0x28c91e(0xc5)]===_0x28c91e(0xd8);}export function getCrossSpawnOptions(_0x18c089){return{..._0x18c089??{},'shell':isWindows()};}function a227_0xf9bd(){const _0x29ee41=['ppid','2186136eldddD','fish','pop','has','toLowerCase','Get-CimInstance\x20Win32_Process\x20-Filter\x20\x22ProcessId=','zsh','5922ygAhum','elvish','replace','6qKqNgb','which','open','bash','claude','stderr','Invalid\x20URL:\x20','exit','darwin','69307eTsMZT','map','\x22\x20|\x20Select-Object\x20-Property\x20ParentProcessId,Name\x20|\x20ForEach-Object\x20{\x20\x22$($_.ParentProcessId),$($_.Name)\x22\x20}','kill','537dfNyTH','data','comm','toString','xdg-open','platform','href','776qPmttn','pipe','3476035accCDK','error','3602NKrDrX','12Cwlhss','pid','459764cYChYL','split','ion','isInteger','http:','https:','ignore','17714169lLpVDH','trim','protocol','win32','utf-8','test','code','8230liCucF','cursor','unref','tcsh','join'];a227_0xf9bd=function(){return _0x29ee41;};return a227_0xf9bd();}export function escapeWindowsArg(_0x2810a2){const _0xb6a4b4=a227_0x3a3afa;if(!/[ \t"&|<>^%!`\r\n]/[_0xb6a4b4(0xda)](_0x2810a2))return _0x2810a2;const _0x3fa24c=_0x2810a2[_0xb6a4b4(0xeb)](/"/g,'\x22\x22');return'\x22'+_0x3fa24c+'\x22';}export function crossSpawn(_0x5ec92c,_0xa615f2,_0x8dca6){const _0x48fb88=a227_0x3a3afa;if(isWindows()){const _0x5f2a1e=escapeWindowsArg(_0x5ec92c),_0x220b59=_0xa615f2[_0x48fb88(0xbd)](escapeWindowsArg),_0x44d096=[_0x5f2a1e,..._0x220b59][_0x48fb88(0xe0)]('\x20');return spawn(_0x44d096,[],{..._0x8dca6,'shell':!![]});}return spawn(_0x5ec92c,_0xa615f2,{..._0x8dca6,'shell':![]});}export function gracefulExit(_0x135883=0x0){isWindows()?setTimeout(()=>process['exit'](_0x135883),0x32):process['exit'](_0x135883);}export function findExecutable(_0x130ad0,_0x438051=0x1388){return new Promise(_0x768cfb=>{const _0x428585=a227_0x4889,_0x2201b6=isWindows()?'where.exe':_0x428585(0xed);let _0x2fee4b=![];const _0x479f70=crossSpawn(_0x2201b6,[_0x130ad0],{'stdio':_0x428585(0xc8),'shell':isWindows()}),_0x521a14=setTimeout(()=>{!_0x2fee4b&&(_0x2fee4b=!![],_0x479f70['kill'](),_0x768cfb(null));},_0x438051);let _0x29fc1b='';_0x479f70['stdout']?.['on'](_0x428585(0xc1),_0x5121ba=>{const _0x51ae12=_0x428585;_0x29fc1b+=_0x5121ba[_0x51ae12(0xc3)]();}),_0x479f70[_0x428585(0xf1)]?.['on']('data',()=>{}),_0x479f70['on'](_0x428585(0xf3),_0x5b98f1=>{const _0x2b7336=_0x428585;if(_0x2fee4b)return;_0x2fee4b=!![],clearTimeout(_0x521a14);if(_0x5b98f1===0x0&&_0x29fc1b[_0x2b7336(0xd6)]()){const _0x31d368=_0x29fc1b[_0x2b7336(0xd6)]()[_0x2b7336(0xcf)](/\r?\n/)[0x0];_0x768cfb(_0x31d368);}else _0x768cfb(null);}),_0x479f70['on'](_0x428585(0xca),()=>{if(_0x2fee4b)return;_0x2fee4b=!![],clearTimeout(_0x521a14),_0x768cfb(null);});});}
1
+ const a227_0x449eca=a227_0x15e7;(function(_0x367732,_0x42854c){const _0x847cb=a227_0x15e7,_0x4003c6=_0x367732();while(!![]){try{const _0x3ee3b6=-parseInt(_0x847cb(0x1c7))/0x1+parseInt(_0x847cb(0x1e4))/0x2+parseInt(_0x847cb(0x1de))/0x3+-parseInt(_0x847cb(0x1e1))/0x4+-parseInt(_0x847cb(0x1c9))/0x5*(parseInt(_0x847cb(0x1d8))/0x6)+-parseInt(_0x847cb(0x1f5))/0x7+parseInt(_0x847cb(0x1cb))/0x8;if(_0x3ee3b6===_0x42854c)break;else _0x4003c6['push'](_0x4003c6['shift']());}catch(_0x9f0c21){_0x4003c6['push'](_0x4003c6['shift']());}}}(a227_0x1872,0x5f887));import{execSync,spawn}from'node:child_process';const SHELL_NAMES=new Set([a227_0x449eca(0x1ca),a227_0x449eca(0x1c1),'sh',a227_0x449eca(0x1cc),a227_0x449eca(0x1e6),a227_0x449eca(0x1cd),a227_0x449eca(0x1d4),a227_0x449eca(0x1f2),a227_0x449eca(0x1d7),'powershell','nu',a227_0x449eca(0x1eb),a227_0x449eca(0x1d1),a227_0x449eca(0x1e2)]),EPHEMERAL_SHELL_SPAWNERS=new Set([a227_0x449eca(0x1e7),'code',a227_0x449eca(0x1d0),'electron',a227_0x449eca(0x1e8)]);function getProcessInfoWindows(_0x2197bb){const _0x55bc4a=a227_0x449eca;try{if(!Number['isInteger'](_0x2197bb)||_0x2197bb<=0x0)return null;const _0x24f675='Get-CimInstance\x20Win32_Process\x20-Filter\x20\x22ProcessId='+_0x2197bb+'\x22\x20|\x20Select-Object\x20-Property\x20ParentProcessId,Name\x20|\x20ForEach-Object\x20{\x20\x22$($_.ParentProcessId),$($_.Name)\x22\x20}',_0x37b134=execSync(_0x55bc4a(0x1db)+_0x24f675+'\x22',{'encoding':_0x55bc4a(0x1d6),'windowsHide':!![],'stdio':['pipe','pipe','pipe']})[_0x55bc4a(0x1d5)]();if(!_0x37b134)return null;const [_0x28da8e,..._0x2bd6ab]=_0x37b134[_0x55bc4a(0x1cf)](','),_0x100a2c=parseInt(_0x28da8e,0xa),_0x32c68a=_0x2bd6ab[_0x55bc4a(0x1e9)](',')[_0x55bc4a(0x1d5)]();if(isNaN(_0x100a2c)||!_0x32c68a)return null;return{'pid':_0x2197bb,'ppid':_0x100a2c,'comm':_0x32c68a['replace'](/\.exe$/i,'')};}catch{return null;}}function getProcessInfoPosix(_0x1b7baf){const _0x46ce62=a227_0x449eca;try{const _0x191275=0x400000;if(!Number['isInteger'](_0x1b7baf)||_0x1b7baf<=0x0||_0x1b7baf>_0x191275)return null;const _0x465cde=execSync(_0x46ce62(0x1da)+_0x1b7baf+'\x20-o\x20ppid=,comm=',{'encoding':_0x46ce62(0x1d6),'stdio':_0x46ce62(0x1e3)})['trim'](),[_0x2fd7a6,..._0xf4afcb]=_0x465cde['split'](/\s+/),_0x1ad597=parseInt(_0x2fd7a6,0xa),_0x372e35=_0xf4afcb['join']('\x20');if(isNaN(_0x1ad597))return null;return{'pid':_0x1b7baf,'ppid':_0x1ad597,'comm':_0x372e35};}catch{return null;}}function getProcessInfo(_0x5c11cb){const _0x378fc3=a227_0x449eca;if(process[_0x378fc3(0x1ea)]==='win32')return getProcessInfoWindows(_0x5c11cb);return getProcessInfoPosix(_0x5c11cb);}function getBasename(_0x1c5b43){const _0x498828=a227_0x449eca;return _0x1c5b43[_0x498828(0x1c2)](/^-/,'')[_0x498828(0x1cf)]('/')[_0x498828(0x1d3)]()?.[_0x498828(0x1ee)]()||'';}function isShell(_0x4328be){return SHELL_NAMES['has'](getBasename(_0x4328be));}function isEphemeralShellSpawner(_0x341a2a){return EPHEMERAL_SHELL_SPAWNERS['has'](getBasename(_0x341a2a));}let cachedShellPID;function findShellPID(){const _0x13c7a5=a227_0x449eca;if(process[_0x13c7a5(0x1f6)]===undefined)return process[_0x13c7a5(0x1f0)];let _0x48a1ba=process['ppid'];const _0x597cb8=0xa;let _0x249122=0x0;while(_0x249122<_0x597cb8){const _0x10f714=getProcessInfo(_0x48a1ba);if(!_0x10f714)break;if(isShell(_0x10f714[_0x13c7a5(0x1c5)])){const _0x1eedbe=getProcessInfo(_0x10f714['ppid']);if(_0x1eedbe&&isEphemeralShellSpawner(_0x1eedbe[_0x13c7a5(0x1c5)])){_0x48a1ba=_0x10f714[_0x13c7a5(0x1f6)],_0x249122++;continue;}return _0x10f714[_0x13c7a5(0x1f0)];}if(_0x10f714['ppid']===0x0||_0x10f714[_0x13c7a5(0x1f6)]===0x1){if(isShell(_0x10f714[_0x13c7a5(0x1c5)]))return _0x10f714[_0x13c7a5(0x1f0)];break;}_0x48a1ba=_0x10f714['ppid'],_0x249122++;}return process[_0x13c7a5(0x1f6)]!==undefined?process['ppid']:process[_0x13c7a5(0x1f0)];}function a227_0x1872(){const _0x20877d=['693970lDfRra','unref','370eUvozq','bash','6080968GxyCoS','fish','tcsh','test','split','cursor','elvish','xdg-open','pop','csh','trim','utf-8','pwsh','26358ytgLzh','exit','ps\x20-p\x20','powershell.exe\x20-NoProfile\x20-NonInteractive\x20-Command\x20\x22','data','isInteger','917829BGybjI','win32','kill','423192nfVMgN','xonsh','pipe','1369462gTIzYl','which','ksh','claude','treasure\x20studio','join','platform','ion','map','stdout','toLowerCase','toString','pid','error','dash','cmd.exe','protocol','1642494BmwIZs','ppid','zsh','replace','start','stderr','comm','open'];a227_0x1872=function(){return _0x20877d;};return a227_0x1872();}export function getPPID(){return cachedShellPID===undefined&&(cachedShellPID=findShellPID()),cachedShellPID;}function a227_0x15e7(_0x373428,_0x213abb){_0x373428=_0x373428-0x1c1;const _0x187256=a227_0x1872();let _0x15e74e=_0x187256[_0x373428];return _0x15e74e;}export function clearPPIDCache(){cachedShellPID=undefined;}export function isProcessRunning(_0x1e3482){const _0x5b0478=a227_0x449eca;if(!Number[_0x5b0478(0x1dd)](_0x1e3482)||_0x1e3482<=0x0)return![];try{return process[_0x5b0478(0x1e0)](_0x1e3482,0x0),!![];}catch{return![];}}export function openBrowser(_0x23ed14){const _0x2e0c90=a227_0x449eca;let _0x526e73;try{_0x526e73=new URL(_0x23ed14);}catch{throw new Error('Invalid\x20URL:\x20'+_0x23ed14);}if(_0x526e73[_0x2e0c90(0x1f4)]!=='http:'&&_0x526e73[_0x2e0c90(0x1f4)]!=='https:')throw new Error('Unsupported\x20protocol:\x20'+_0x526e73[_0x2e0c90(0x1f4)]);const _0x248327=_0x526e73['href'],_0x4a6da0=process['platform'];if(_0x4a6da0===_0x2e0c90(0x1df))spawn(_0x2e0c90(0x1f3),['/c',_0x2e0c90(0x1c3),'',_0x248327],{'detached':!![],'stdio':'ignore'})[_0x2e0c90(0x1c8)]();else{const _0x28f43b=_0x4a6da0==='darwin'?_0x2e0c90(0x1c6):_0x2e0c90(0x1d2);spawn(_0x28f43b,[_0x248327],{'detached':!![],'stdio':'ignore'})[_0x2e0c90(0x1c8)]();}}export function isWindows(){const _0x3977a9=a227_0x449eca;return process[_0x3977a9(0x1ea)]==='win32';}export function getCrossSpawnOptions(_0x259f05){return{..._0x259f05??{},'shell':isWindows()};}export function escapeWindowsArg(_0x1f480f){const _0x598de5=a227_0x449eca;if(!/[ \t"&|<>^%!`\r\n]/[_0x598de5(0x1ce)](_0x1f480f))return _0x1f480f;const _0x12abe4=_0x1f480f['replace'](/"/g,'\x22\x22');return'\x22'+_0x12abe4+'\x22';}export function crossSpawn(_0x4302f7,_0x3889a8,_0x2f9fe6){const _0x59bff4=a227_0x449eca;if(isWindows()){const _0x2aa22a=escapeWindowsArg(_0x4302f7),_0xb65482=_0x3889a8[_0x59bff4(0x1ec)](escapeWindowsArg),_0x2fc317=[_0x2aa22a,..._0xb65482][_0x59bff4(0x1e9)]('\x20');return spawn(_0x2fc317,[],{..._0x2f9fe6,'shell':!![]});}return spawn(_0x4302f7,_0x3889a8,{..._0x2f9fe6,'shell':![]});}export function gracefulExit(_0x3b8f0a=0x0){const _0x2c3473=a227_0x449eca;isWindows()?setTimeout(()=>process[_0x2c3473(0x1d9)](_0x3b8f0a),0x32):process[_0x2c3473(0x1d9)](_0x3b8f0a);}export function findExecutable(_0xc9c9b9,_0x565700=0x1388){return new Promise(_0x4c9237=>{const _0x778e3a=a227_0x15e7,_0x2dff4f=isWindows()?'where.exe':_0x778e3a(0x1e5);let _0x1798a7=![];const _0x4a57e3=crossSpawn(_0x2dff4f,[_0xc9c9b9],{'stdio':_0x778e3a(0x1e3),'shell':isWindows()}),_0x453265=setTimeout(()=>{const _0xb5a69=_0x778e3a;!_0x1798a7&&(_0x1798a7=!![],_0x4a57e3[_0xb5a69(0x1e0)](),_0x4c9237(null));},_0x565700);let _0x297a1a='';_0x4a57e3[_0x778e3a(0x1ed)]?.['on'](_0x778e3a(0x1dc),_0x45e6a0=>{const _0xe6fa44=_0x778e3a;_0x297a1a+=_0x45e6a0[_0xe6fa44(0x1ef)]();}),_0x4a57e3[_0x778e3a(0x1c4)]?.['on'](_0x778e3a(0x1dc),()=>{}),_0x4a57e3['on'](_0x778e3a(0x1d9),_0x3930bc=>{const _0x43010b=_0x778e3a;if(_0x1798a7)return;_0x1798a7=!![],clearTimeout(_0x453265);if(_0x3930bc===0x0&&_0x297a1a['trim']()){const _0xba681c=_0x297a1a['trim']()[_0x43010b(0x1cf)](/\r?\n/)[0x0];_0x4c9237(_0xba681c);}else _0x4c9237(null);}),_0x4a57e3['on'](_0x778e3a(0x1f1),()=>{if(_0x1798a7)return;_0x1798a7=!![],clearTimeout(_0x453265),_0x4c9237(null);});});}
@@ -1 +1 @@
1
- (function(_0x2f726e,_0x56738d){const _0x1da98d=a228_0x33c3,_0x421bb4=_0x2f726e();while(!![]){try{const _0x484fe5=-parseInt(_0x1da98d(0xd7))/0x1+-parseInt(_0x1da98d(0xd8))/0x2+-parseInt(_0x1da98d(0xdb))/0x3+-parseInt(_0x1da98d(0xcb))/0x4+-parseInt(_0x1da98d(0xdc))/0x5*(-parseInt(_0x1da98d(0xdd))/0x6)+-parseInt(_0x1da98d(0xd0))/0x7+-parseInt(_0x1da98d(0xd6))/0x8*(-parseInt(_0x1da98d(0xe0))/0x9);if(_0x484fe5===_0x56738d)break;else _0x421bb4['push'](_0x421bb4['shift']());}catch(_0x5be6d7){_0x421bb4['push'](_0x421bb4['shift']());}}}(a228_0x269a,0x1f1f2));import*as a228_0x86156e from'readline';function a228_0x33c3(_0x425d54,_0x3ac682){_0x425d54=_0x425d54-0xca;const _0x269add=a228_0x269a();let _0x33c355=_0x269add[_0x425d54];return _0x33c355;}import{gracefulExit}from'./process.js';function a228_0x269a(){const _0x54d231=['question','stdout','9kKfdTA','data','setEncoding','createInterface','668600WQUgFq','stderr','close','toLowerCase','write','144669wriSOK','yes','pause','setRawMode','resume','\x20(y/N):\x20','6347760YREHTj','86312xxAWbP','429632nnGrrY','isTTY','stdin','639840ydGJab','5qJEKPt','217374KdfSgb'];a228_0x269a=function(){return _0x54d231;};return a228_0x269a();}export function isInteractive(){const _0x4805c6=a228_0x33c3;return process[_0x4805c6(0xda)][_0x4805c6(0xd9)]===!![];}export async function confirm(_0x3c97dc){const _0x2d4603=a228_0x33c3,_0x54e01a=a228_0x86156e[_0x2d4603(0xca)]({'input':process['stdin'],'output':process[_0x2d4603(0xdf)]});return new Promise(_0x2e0d1c=>{const _0x3fe1ad=_0x2d4603;_0x54e01a[_0x3fe1ad(0xde)](_0x3c97dc+_0x3fe1ad(0xd5),_0x10284c=>{const _0x138b29=_0x3fe1ad;_0x54e01a[_0x138b29(0xcd)](),_0x2e0d1c(_0x10284c[_0x138b29(0xce)]()==='y'||_0x10284c[_0x138b29(0xce)]()===_0x138b29(0xd1));});});}export async function confirmKey(_0x3c3ee0){const _0x544d0=a228_0x33c3;if(!process['stdin'][_0x544d0(0xd9)])return![];return process['stderr']['write'](_0x3c3ee0+'\x20[y/N]\x20'),new Promise(_0x41c1af=>{const _0x1cf97a=_0x544d0,_0x133546=process[_0x1cf97a(0xda)];_0x133546[_0x1cf97a(0xd3)](!![]),_0x133546[_0x1cf97a(0xd4)](),_0x133546[_0x1cf97a(0xe2)]('utf8');const _0x2c3568=_0x37c59e=>{const _0xba16d8=_0x1cf97a;_0x133546[_0xba16d8(0xd3)](![]),_0x133546[_0xba16d8(0xd2)](),_0x133546['removeListener'](_0xba16d8(0xe1),_0x2c3568);if(_0x37c59e==='\x1b'){process['stderr']['write']('\x0a'),_0x41c1af(![]);return;}_0x37c59e==='\x03'&&(process[_0xba16d8(0xcc)][_0xba16d8(0xcf)]('\x0a'),gracefulExit(0x82));if(_0x37c59e[_0xba16d8(0xce)]()==='y'){process['stderr'][_0xba16d8(0xcf)]('y\x0a'),_0x41c1af(!![]);return;}process[_0xba16d8(0xcc)]['write']('\x0a'),_0x41c1af(![]);};_0x133546['on'](_0x1cf97a(0xe1),_0x2c3568);});}
1
+ (function(_0x2ee3a0,_0x24a227){const _0xcb3f5f=a228_0x7abd,_0x523ed0=_0x2ee3a0();while(!![]){try{const _0x4120bb=-parseInt(_0xcb3f5f(0x101))/0x1*(parseInt(_0xcb3f5f(0xff))/0x2)+-parseInt(_0xcb3f5f(0x106))/0x3*(-parseInt(_0xcb3f5f(0x10f))/0x4)+parseInt(_0xcb3f5f(0x119))/0x5*(parseInt(_0xcb3f5f(0x110))/0x6)+-parseInt(_0xcb3f5f(0x112))/0x7+-parseInt(_0xcb3f5f(0x116))/0x8*(-parseInt(_0xcb3f5f(0x118))/0x9)+parseInt(_0xcb3f5f(0x111))/0xa+parseInt(_0xcb3f5f(0x11a))/0xb*(-parseInt(_0xcb3f5f(0x108))/0xc);if(_0x4120bb===_0x24a227)break;else _0x523ed0['push'](_0x523ed0['shift']());}catch(_0x45c548){_0x523ed0['push'](_0x523ed0['shift']());}}}(a228_0x4d78,0xec451));import*as a228_0x1742d2 from'readline';import{gracefulExit}from'./process.js';function a228_0x7abd(_0x5d4cc8,_0x3f23fa){_0x5d4cc8=_0x5d4cc8-0xff;const _0x4d7865=a228_0x4d78();let _0x7abdee=_0x4d7865[_0x5d4cc8];return _0x7abdee;}function a228_0x4d78(){const _0x21895a=['\x20[y/N]\x20','5416EoZMFK','stderr','25092kNtOQF','5TgHIyH','3014TkuDXS','2MajZsH','setRawMode','1523849pjgpUc','data','removeListener','resume','close','3OYeoMY','toLowerCase','66648AJihST','question','\x20(y/N):\x20','write','stdin','setEncoding','stdout','3072428wutrOZ','9378240BqEoUI','7818520AGkzeD','6909483pLdEMN','pause','isTTY'];a228_0x4d78=function(){return _0x21895a;};return a228_0x4d78();}export function isInteractive(){const _0x947dca=a228_0x7abd;return process[_0x947dca(0x10c)][_0x947dca(0x114)]===!![];}export async function confirm(_0x1b78d1){const _0x147e9c=a228_0x7abd,_0x5b3a5f=a228_0x1742d2['createInterface']({'input':process[_0x147e9c(0x10c)],'output':process[_0x147e9c(0x10e)]});return new Promise(_0x471315=>{const _0x3d37be=_0x147e9c;_0x5b3a5f[_0x3d37be(0x109)](_0x1b78d1+_0x3d37be(0x10a),_0x24c524=>{const _0x538c23=_0x3d37be;_0x5b3a5f[_0x538c23(0x105)](),_0x471315(_0x24c524[_0x538c23(0x107)]()==='y'||_0x24c524[_0x538c23(0x107)]()==='yes');});});}export async function confirmKey(_0x50cc33){const _0x539016=a228_0x7abd;if(!process[_0x539016(0x10c)][_0x539016(0x114)])return![];return process[_0x539016(0x117)][_0x539016(0x10b)](_0x50cc33+_0x539016(0x115)),new Promise(_0x4f9f9e=>{const _0x456ce4=_0x539016,_0x58fb1c=process[_0x456ce4(0x10c)];_0x58fb1c['setRawMode'](!![]),_0x58fb1c[_0x456ce4(0x104)](),_0x58fb1c[_0x456ce4(0x10d)]('utf8');const _0x4f7383=_0x112bd4=>{const _0x4721e8=_0x456ce4;_0x58fb1c[_0x4721e8(0x100)](![]),_0x58fb1c[_0x4721e8(0x113)](),_0x58fb1c[_0x4721e8(0x103)](_0x4721e8(0x102),_0x4f7383);if(_0x112bd4==='\x1b'){process['stderr']['write']('\x0a'),_0x4f9f9e(![]);return;}_0x112bd4==='\x03'&&(process[_0x4721e8(0x117)][_0x4721e8(0x10b)]('\x0a'),gracefulExit(0x82));if(_0x112bd4['toLowerCase']()==='y'){process['stderr']['write']('y\x0a'),_0x4f9f9e(!![]);return;}process[_0x4721e8(0x117)]['write']('\x0a'),_0x4f9f9e(![]);};_0x58fb1c['on'](_0x456ce4(0x102),_0x4f7383);});}
@@ -1 +1 @@
1
- (function(_0x8b0039,_0x235832){const _0xa16ffb=a229_0x69d0,_0x20a761=_0x8b0039();while(!![]){try{const _0x4667f1=-parseInt(_0xa16ffb(0x76))/0x1*(-parseInt(_0xa16ffb(0x79))/0x2)+parseInt(_0xa16ffb(0x80))/0x3+parseInt(_0xa16ffb(0x78))/0x4+parseInt(_0xa16ffb(0x6d))/0x5+-parseInt(_0xa16ffb(0x7c))/0x6+parseInt(_0xa16ffb(0x6a))/0x7*(parseInt(_0xa16ffb(0x6c))/0x8)+-parseInt(_0xa16ffb(0x6b))/0x9;if(_0x4667f1===_0x235832)break;else _0x20a761['push'](_0x20a761['shift']());}catch(_0x2ffd26){_0x20a761['push'](_0x20a761['shift']());}}}(a229_0x2449,0xee7e8));import a229_0x2b1b0 from'ora';import{isWindows}from'./process.js';const windowsSpinner={'interval':0x3e8,'frames':['•']};export function createCommandSpinner(_0x23a925,_0x155d71={}){const _0x38b4db=a229_0x69d0,{verbose:verbose=![],forceEnabled:forceEnabled=![]}=_0x155d71;return a229_0x2b1b0({'text':_0x23a925,'color':_0x38b4db(0x7e),'stream':process[_0x38b4db(0x82)],'isEnabled':forceEnabled||process[_0x38b4db(0x82)][_0x38b4db(0x71)]&&!verbose,...isWindows()&&{'spinner':windowsSpinner}});}export async function withSpinner(_0x58660a,_0xdf23c3,_0x3391ff={}){const _0x14be63=a229_0x69d0,_0x3da097=_0x3391ff[_0x14be63(0x77)]??(()=>Date['now']()),_0x52c4aa=createCommandSpinner(_0x58660a,_0x3391ff);_0x52c4aa[_0x14be63(0x81)]();const _0x4fb0b7=_0x3da097();try{const _0x2dc27c=await _0xdf23c3(),_0x43a506=_0x3da097()-_0x4fb0b7;return _0x52c4aa[_0x14be63(0x7f)](),{'data':_0x2dc27c,'elapsedMs':_0x43a506};}catch(_0x3e8ba2){_0x52c4aa[_0x14be63(0x7f)]();throw _0x3e8ba2;}}export async function withProgressSpinner(_0x2da33a,_0x3e38f0,_0x23f875={}){const _0x53dc82=a229_0x69d0,_0x59b86c=_0x23f875[_0x53dc82(0x77)]??(()=>Date['now']()),_0x2212d7=_0x23f875['intervalFactory']??setInterval,_0x5ecfa3=createCommandSpinner(_0x2da33a,_0x23f875);_0x5ecfa3[_0x53dc82(0x81)]();const _0x7c384a=_0x59b86c(),_0x11bec8=_0x2da33a[_0x53dc82(0x69)](_0x53dc82(0x7b),'')[_0x53dc82(0x6f)]()||_0x53dc82(0x72),_0x3110c6={};let _0x51d0a0=_0x2da33a;const _0x14f74e=()=>{const _0x5ac2e1=_0x53dc82;if(!_0x5ecfa3[_0x5ac2e1(0x68)])return;const _0x55fd36=_0x59b86c()-_0x7c384a,_0x495587=formatElapsed(_0x55fd36),_0x4e3701=_0x3110c6['phase']?.[_0x5ac2e1(0x6f)]()||_0x11bec8,_0x222e5d=_0x3110c6['jobId']?_0x5ac2e1(0x7d)+_0x3110c6[_0x5ac2e1(0x70)]+']':'',_0x134038=_0x3110c6[_0x5ac2e1(0x75)]?'\x20'+_0x3110c6['extra']:'',_0x3cd0f5=_0x4e3701+'\x20'+_0x495587+_0x134038+_0x222e5d;_0x3cd0f5!==_0x51d0a0&&_0x3cd0f5[_0x5ac2e1(0x6f)]()&&(_0x5ecfa3[_0x5ac2e1(0x73)]=_0x3cd0f5,_0x51d0a0=_0x3cd0f5);},_0x56bcf1=_0x2212d7(()=>{_0x14f74e();},0x3e8),_0x16f72c={'setPhase':_0x4262d6=>{const _0x309adc=_0x53dc82;_0x3110c6[_0x309adc(0x6e)]=_0x4262d6;const _0x450590=_0x4262d6?.[_0x309adc(0x6f)]()||_0x11bec8,_0x369110=_0x59b86c()-_0x7c384a,_0x358d6d=formatElapsed(_0x369110),_0x5bbf9a=_0x3110c6[_0x309adc(0x70)]?'\x20[Job\x20ID:\x20'+_0x3110c6[_0x309adc(0x70)]+']':'',_0x1d36f6=_0x3110c6['extra']?'\x20'+_0x3110c6['extra']:'',_0x3996e4=_0x450590+'\x20'+_0x358d6d+_0x1d36f6+_0x5bbf9a;_0x5ecfa3['isSpinning']&&_0x3996e4[_0x309adc(0x6f)]()&&(_0x5ecfa3['text']=_0x3996e4,_0x51d0a0=_0x3996e4);},'setJobId':_0x53b79c=>{const _0x5f58d6=_0x53dc82;_0x3110c6[_0x5f58d6(0x70)]=_0x53b79c,_0x14f74e();},'setExtra':_0x55ad4a=>{const _0x48cbef=_0x53dc82;_0x3110c6[_0x48cbef(0x75)]=_0x55ad4a,_0x14f74e();}};_0x14f74e();try{const _0x2079c2=await _0x3e38f0(_0x16f72c),_0xc76fc=_0x59b86c()-_0x7c384a;return{'data':_0x2079c2,'elapsedMs':_0xc76fc};}finally{clearInterval(_0x56bcf1),_0x5ecfa3[_0x53dc82(0x7f)]();}}export function formatElapsed(_0x3dce3c){const _0x1aed38=a229_0x69d0,_0x26ce79=Math[_0x1aed38(0x74)](_0x3dce3c/0x3e8);if(_0x26ce79<0x3c)return(_0x3dce3c/0x3e8)[_0x1aed38(0x7a)](0x1)+'s';const _0x5e7390=Math[_0x1aed38(0x74)](_0x26ce79/0x3c),_0x1fbea7=_0x26ce79%0x3c;if(_0x5e7390<0x3c)return _0x5e7390+'m\x20'+_0x1fbea7+'s';const _0x575ffc=Math['floor'](_0x5e7390/0x3c),_0x4dd650=_0x5e7390%0x3c;return _0x575ffc+'h\x20'+_0x4dd650+'m';}function a229_0x69d0(_0x45c66a,_0xc34634){_0x45c66a=_0x45c66a-0x68;const _0x244938=a229_0x2449();let _0x69d0b1=_0x244938[_0x45c66a];return _0x69d0b1;}function a229_0x2449(){const _0x13d834=['553FGyjjA','32174739AQHfLH','152968zRZyNw','7843290lxDIHL','phase','trim','jobId','isTTY','Processing','text','floor','extra','16649vtiKMH','clock','1934620FFytww','194bqDLlJ','toFixed','...','6337188HCBPsE','\x20[Job\x20ID:\x20','cyan','stop','1290648LZMqJT','start','stderr','isSpinning','replace'];a229_0x2449=function(){return _0x13d834;};return a229_0x2449();}
1
+ (function(_0x9942f0,_0x4ec915){const _0x2abd82=a229_0x3d4f,_0x36addd=_0x9942f0();while(!![]){try{const _0x22b460=-parseInt(_0x2abd82(0x84))/0x1*(-parseInt(_0x2abd82(0x9b))/0x2)+parseInt(_0x2abd82(0x88))/0x3*(parseInt(_0x2abd82(0x94))/0x4)+parseInt(_0x2abd82(0x91))/0x5+parseInt(_0x2abd82(0x98))/0x6+parseInt(_0x2abd82(0x87))/0x7+-parseInt(_0x2abd82(0x8d))/0x8+-parseInt(_0x2abd82(0x93))/0x9;if(_0x22b460===_0x4ec915)break;else _0x36addd['push'](_0x36addd['shift']());}catch(_0xfb29a5){_0x36addd['push'](_0x36addd['shift']());}}}(a229_0x1427,0xc0ed6));function a229_0x1427(){const _0x16ce00=['now','jobId','trim','2010535Hmbrxv','extra','23105079KxTMzJ','8nJmtkp','floor','start','clock','8517912sfcGLD','intervalFactory','phase','1810rdqoEe','stderr','Processing','toFixed','1459ysdkds','isSpinning','\x20[Job\x20ID:\x20','1548008uBUvTx','2027769AZzQqa','text','stop','replace','isTTY','10861464RrbruJ'];a229_0x1427=function(){return _0x16ce00;};return a229_0x1427();}import a229_0x5bd1f9 from'ora';import{isWindows}from'./process.js';const windowsSpinner={'interval':0x3e8,'frames':['•']};export function createCommandSpinner(_0x217e69,_0x5b96a5={}){const _0x54d504=a229_0x3d4f,{verbose:verbose=![],forceEnabled:forceEnabled=![]}=_0x5b96a5;return a229_0x5bd1f9({'text':_0x217e69,'color':'cyan','stream':process[_0x54d504(0x9c)],'isEnabled':forceEnabled||process[_0x54d504(0x9c)][_0x54d504(0x8c)]&&!verbose,...isWindows()&&{'spinner':windowsSpinner}});}export async function withSpinner(_0x32fb86,_0x5d12a2,_0x5a1e72={}){const _0x653986=a229_0x3d4f,_0x171936=_0x5a1e72[_0x653986(0x97)]??(()=>Date[_0x653986(0x8e)]()),_0xae984c=createCommandSpinner(_0x32fb86,_0x5a1e72);_0xae984c['start']();const _0x386881=_0x171936();try{const _0x2da73e=await _0x5d12a2(),_0x4c1361=_0x171936()-_0x386881;return _0xae984c[_0x653986(0x8a)](),{'data':_0x2da73e,'elapsedMs':_0x4c1361};}catch(_0x24a2d0){_0xae984c[_0x653986(0x8a)]();throw _0x24a2d0;}}function a229_0x3d4f(_0x25ce50,_0x3674fd){_0x25ce50=_0x25ce50-0x84;const _0x142779=a229_0x1427();let _0x3d4f9e=_0x142779[_0x25ce50];return _0x3d4f9e;}export async function withProgressSpinner(_0x4b48b4,_0x422daf,_0x275ed1={}){const _0x3314a8=a229_0x3d4f,_0x2d1c0a=_0x275ed1['clock']??(()=>Date[_0x3314a8(0x8e)]()),_0x291b55=_0x275ed1[_0x3314a8(0x99)]??setInterval,_0x30297c=createCommandSpinner(_0x4b48b4,_0x275ed1);_0x30297c[_0x3314a8(0x96)]();const _0x2d0238=_0x2d1c0a(),_0x2c4aae=_0x4b48b4[_0x3314a8(0x8b)]('...','')['trim']()||_0x3314a8(0x9d),_0x2f3113={};let _0x19ac6c=_0x4b48b4;const _0x40a998=()=>{const _0x18dda5=_0x3314a8;if(!_0x30297c['isSpinning'])return;const _0x5af9f1=_0x2d1c0a()-_0x2d0238,_0x4adddd=formatElapsed(_0x5af9f1),_0x9736e3=_0x2f3113[_0x18dda5(0x9a)]?.['trim']()||_0x2c4aae,_0x5e4a7c=_0x2f3113[_0x18dda5(0x8f)]?_0x18dda5(0x86)+_0x2f3113['jobId']+']':'',_0x672629=_0x2f3113['extra']?'\x20'+_0x2f3113['extra']:'',_0x1d6c3e=_0x9736e3+'\x20'+_0x4adddd+_0x672629+_0x5e4a7c;_0x1d6c3e!==_0x19ac6c&&_0x1d6c3e[_0x18dda5(0x90)]()&&(_0x30297c['text']=_0x1d6c3e,_0x19ac6c=_0x1d6c3e);},_0x55d8e=_0x291b55(()=>{_0x40a998();},0x3e8),_0x4f547c={'setPhase':_0x432ae5=>{const _0x108392=_0x3314a8;_0x2f3113['phase']=_0x432ae5;const _0x2373e1=_0x432ae5?.[_0x108392(0x90)]()||_0x2c4aae,_0x53f799=_0x2d1c0a()-_0x2d0238,_0x498106=formatElapsed(_0x53f799),_0x2faa66=_0x2f3113[_0x108392(0x8f)]?_0x108392(0x86)+_0x2f3113[_0x108392(0x8f)]+']':'',_0x24fba5=_0x2f3113[_0x108392(0x92)]?'\x20'+_0x2f3113['extra']:'',_0x28d0e0=_0x2373e1+'\x20'+_0x498106+_0x24fba5+_0x2faa66;_0x30297c[_0x108392(0x85)]&&_0x28d0e0['trim']()&&(_0x30297c[_0x108392(0x89)]=_0x28d0e0,_0x19ac6c=_0x28d0e0);},'setJobId':_0x1a6551=>{const _0x567b1a=_0x3314a8;_0x2f3113[_0x567b1a(0x8f)]=_0x1a6551,_0x40a998();},'setExtra':_0x4d388d=>{const _0x5b39d4=_0x3314a8;_0x2f3113[_0x5b39d4(0x92)]=_0x4d388d,_0x40a998();}};_0x40a998();try{const _0x4a5a24=await _0x422daf(_0x4f547c),_0x236a31=_0x2d1c0a()-_0x2d0238;return{'data':_0x4a5a24,'elapsedMs':_0x236a31};}finally{clearInterval(_0x55d8e),_0x30297c[_0x3314a8(0x8a)]();}}export function formatElapsed(_0x48d7f2){const _0x59bd46=a229_0x3d4f,_0x1da7ec=Math[_0x59bd46(0x95)](_0x48d7f2/0x3e8);if(_0x1da7ec<0x3c)return(_0x48d7f2/0x3e8)[_0x59bd46(0x9e)](0x1)+'s';const _0xaef87e=Math['floor'](_0x1da7ec/0x3c),_0x5586bc=_0x1da7ec%0x3c;if(_0xaef87e<0x3c)return _0xaef87e+'m\x20'+_0x5586bc+'s';const _0x3f552f=Math[_0x59bd46(0x95)](_0xaef87e/0x3c),_0x139cff=_0xaef87e%0x3c;return _0x3f552f+'h\x20'+_0x139cff+'m';}
@@ -1 +1 @@
1
- (function(_0xc6f135,_0x26ee3c){const _0x6c8e1=a230_0x4f2c,_0x26307e=_0xc6f135();while(!![]){try{const _0x4480a9=-parseInt(_0x6c8e1(0x121))/0x1*(-parseInt(_0x6c8e1(0x11e))/0x2)+-parseInt(_0x6c8e1(0x12d))/0x3+parseInt(_0x6c8e1(0x11d))/0x4+parseInt(_0x6c8e1(0x130))/0x5+parseInt(_0x6c8e1(0x125))/0x6+-parseInt(_0x6c8e1(0x12b))/0x7+-parseInt(_0x6c8e1(0x11b))/0x8*(-parseInt(_0x6c8e1(0x129))/0x9);if(_0x4480a9===_0x26ee3c)break;else _0x26307e['push'](_0x26307e['shift']());}catch(_0x55a161){_0x26307e['push'](_0x26307e['shift']());}}}(a230_0xbb99,0x30d9d));export async function*parseSSEStream(_0x189c4e,_0x566884){const _0x1b6ed2=a230_0x4f2c;if(!_0x189c4e[_0x1b6ed2(0x131)])throw new Error(_0x1b6ed2(0x120));const _0x86f7b8=_0x189c4e['body'][_0x1b6ed2(0x126)](),_0x28359d=new TextDecoder();let _0x43be5b='',_0x3649b1={};try{while(!![]){const {done:_0x31fcab,value:_0x1dfc73}=await _0x86f7b8[_0x1b6ed2(0x123)]();if(_0x31fcab){if(_0x3649b1[_0x1b6ed2(0x127)]){_0x566884?.[_0x1b6ed2(0x12c)](_0x1b6ed2(0x11c)+_0x3649b1[_0x1b6ed2(0x127)]);const _0x24eb4d=parseSSEData(_0x3649b1['data']);yield _0x24eb4d;}break;}_0x43be5b+=_0x28359d['decode'](_0x1dfc73,{'stream':!![]});const _0x34e6c4=_0x43be5b[_0x1b6ed2(0x12e)]('\x0a');_0x43be5b=_0x34e6c4[_0x1b6ed2(0x11f)]()||'';for(const _0x5e17d1 of _0x34e6c4){if(_0x5e17d1['trim']()===''){if(_0x3649b1['data']){_0x566884?.['debug'](_0x1b6ed2(0x11c)+_0x3649b1['data']);const _0x4dbc8e=parseSSEData(_0x3649b1[_0x1b6ed2(0x127)]);yield _0x4dbc8e,_0x3649b1={};}continue;}if(_0x5e17d1[_0x1b6ed2(0x128)](':'))continue;const _0x43096b=_0x5e17d1['indexOf'](':');if(_0x43096b===-0x1)continue;const _0x508feb=_0x5e17d1[_0x1b6ed2(0x12a)](0x0,_0x43096b);let _0x3fbbb5=_0x5e17d1['slice'](_0x43096b+0x1);_0x3fbbb5[_0x1b6ed2(0x128)]('\x20')&&(_0x3fbbb5=_0x3fbbb5['slice'](0x1));switch(_0x508feb){case _0x1b6ed2(0x124):_0x3649b1[_0x1b6ed2(0x124)]=_0x3fbbb5;break;case _0x1b6ed2(0x127):_0x3649b1[_0x1b6ed2(0x127)]=_0x3649b1[_0x1b6ed2(0x127)]?_0x3649b1[_0x1b6ed2(0x127)]+'\x0a'+_0x3fbbb5:_0x3fbbb5;break;case'id':_0x3649b1['id']=_0x3fbbb5;break;}}}}finally{_0x86f7b8[_0x1b6ed2(0x122)]();}}function a230_0xbb99(){const _0x45ab0a=['split','Failed\x20to\x20parse\x20SSE\x20data\x20as\x20JSON:\x20','1003965YZXfGU','body','2265224AGmzjc','[LLM\x20API\x20SSE]\x20','925592MkGnev','698XzYXfC','pop','Response\x20body\x20is\x20null','79PfrOfk','releaseLock','read','event','1329264iKvAZS','getReader','data','startsWith','9ellFIM','slice','2750188ZxHBdD','debug','1114446OSkDwF'];a230_0xbb99=function(){return _0x45ab0a;};return a230_0xbb99();}function a230_0x4f2c(_0x461bb9,_0x232704){_0x461bb9=_0x461bb9-0x11b;const _0xbb99da=a230_0xbb99();let _0x4f2c8e=_0xbb99da[_0x461bb9];return _0x4f2c8e;}function parseSSEData(_0x4d6b34){const _0x339d81=a230_0x4f2c;try{return JSON['parse'](_0x4d6b34);}catch(_0x87573c){throw new Error(_0x339d81(0x12f)+_0x4d6b34,{'cause':_0x87573c});}}
1
+ (function(_0x5443c1,_0x54353b){const _0x2c5dff=a230_0x128d,_0x520eef=_0x5443c1();while(!![]){try{const _0xe56f2a=parseInt(_0x2c5dff(0x1fd))/0x1+parseInt(_0x2c5dff(0x1f3))/0x2+parseInt(_0x2c5dff(0x203))/0x3+parseInt(_0x2c5dff(0x205))/0x4*(-parseInt(_0x2c5dff(0x1ff))/0x5)+-parseInt(_0x2c5dff(0x1f8))/0x6+parseInt(_0x2c5dff(0x1fc))/0x7+-parseInt(_0x2c5dff(0x1fb))/0x8*(-parseInt(_0x2c5dff(0x201))/0x9);if(_0xe56f2a===_0x54353b)break;else _0x520eef['push'](_0x520eef['shift']());}catch(_0x27c728){_0x520eef['push'](_0x520eef['shift']());}}}(a230_0x565d,0x8556a));export async function*parseSSEStream(_0x10b24b,_0x299980){const _0x41d3d1=a230_0x128d;if(!_0x10b24b[_0x41d3d1(0x1f2)])throw new Error(_0x41d3d1(0x1f7));const _0x230f76=_0x10b24b[_0x41d3d1(0x1f2)]['getReader'](),_0x4ea35e=new TextDecoder();let _0xf75326='',_0x19b729={};try{while(!![]){const {done:_0x3f2486,value:_0x24844a}=await _0x230f76['read']();if(_0x3f2486){if(_0x19b729['data']){_0x299980?.['debug'](_0x41d3d1(0x206)+_0x19b729[_0x41d3d1(0x1f9)]);const _0x532e29=parseSSEData(_0x19b729[_0x41d3d1(0x1f9)]);yield _0x532e29;}break;}_0xf75326+=_0x4ea35e[_0x41d3d1(0x1f4)](_0x24844a,{'stream':!![]});const _0xb84ab5=_0xf75326[_0x41d3d1(0x207)]('\x0a');_0xf75326=_0xb84ab5[_0x41d3d1(0x1f6)]()||'';for(const _0x1d6238 of _0xb84ab5){if(_0x1d6238[_0x41d3d1(0x204)]()===''){if(_0x19b729[_0x41d3d1(0x1f9)]){_0x299980?.['debug'](_0x41d3d1(0x206)+_0x19b729[_0x41d3d1(0x1f9)]);const _0x31ccf7=parseSSEData(_0x19b729[_0x41d3d1(0x1f9)]);yield _0x31ccf7,_0x19b729={};}continue;}if(_0x1d6238[_0x41d3d1(0x1fe)](':'))continue;const _0xd50b92=_0x1d6238[_0x41d3d1(0x200)](':');if(_0xd50b92===-0x1)continue;const _0xb06c61=_0x1d6238[_0x41d3d1(0x1f5)](0x0,_0xd50b92);let _0x1dc959=_0x1d6238['slice'](_0xd50b92+0x1);_0x1dc959[_0x41d3d1(0x1fe)]('\x20')&&(_0x1dc959=_0x1dc959[_0x41d3d1(0x1f5)](0x1));switch(_0xb06c61){case'event':_0x19b729['event']=_0x1dc959;break;case _0x41d3d1(0x1f9):_0x19b729[_0x41d3d1(0x1f9)]=_0x19b729[_0x41d3d1(0x1f9)]?_0x19b729[_0x41d3d1(0x1f9)]+'\x0a'+_0x1dc959:_0x1dc959;break;case'id':_0x19b729['id']=_0x1dc959;break;}}}}finally{_0x230f76[_0x41d3d1(0x1fa)]();}}function a230_0x128d(_0x137b84,_0x17e234){_0x137b84=_0x137b84-0x1f2;const _0x565dbf=a230_0x565d();let _0x128df0=_0x565dbf[_0x137b84];return _0x128df0;}function parseSSEData(_0x1afde6){const _0x5ec3c8=a230_0x128d;try{return JSON['parse'](_0x1afde6);}catch(_0x1ee4e6){throw new Error(_0x5ec3c8(0x202)+_0x1afde6,{'cause':_0x1ee4e6});}}function a230_0x565d(){const _0x320016=['3848024TnGKfH','2229717ACZMES','244877dClQcA','startsWith','4735sULwZy','indexOf','9TzetGb','Failed\x20to\x20parse\x20SSE\x20data\x20as\x20JSON:\x20','551520ZDwRmR','trim','2748eVmGwh','[LLM\x20API\x20SSE]\x20','split','body','915600qsFDzm','decode','slice','pop','Response\x20body\x20is\x20null','2935848PdhGKQ','data','releaseLock'];a230_0x565d=function(){return _0x320016;};return a230_0x565d();}
@@ -1 +1 @@
1
- (function(_0x25968d,_0x3f028a){const _0xb4200d=a231_0x3014,_0xcc812d=_0x25968d();while(!![]){try{const _0x551751=parseInt(_0xb4200d(0x1a0))/0x1+parseInt(_0xb4200d(0x19c))/0x2*(parseInt(_0xb4200d(0x1a4))/0x3)+-parseInt(_0xb4200d(0x1a3))/0x4*(parseInt(_0xb4200d(0x197))/0x5)+-parseInt(_0xb4200d(0x1a9))/0x6+-parseInt(_0xb4200d(0x1a8))/0x7+parseInt(_0xb4200d(0x1a2))/0x8+parseInt(_0xb4200d(0x1a6))/0x9;if(_0x551751===_0x3f028a)break;else _0xcc812d['push'](_0xcc812d['shift']());}catch(_0x4da3d8){_0xcc812d['push'](_0xcc812d['shift']());}}}(a231_0x4213,0x791f1));import a231_0x304158 from'string-width';function a231_0x3014(_0x5549f1,_0x56197f){_0x5549f1=_0x5549f1-0x197;const _0x421375=a231_0x4213();let _0x301432=_0x421375[_0x5549f1];return _0x301432;}export function stringWidth(_0xac49c0){return a231_0x304158(_0xac49c0);}export function padEnd(_0x4e65d2,_0x1eccf2){const _0x140029=a231_0x3014,_0x448b5c=stringWidth(_0x4e65d2);if(_0x448b5c>=_0x1eccf2)return _0x4e65d2;return _0x4e65d2+'\x20'[_0x140029(0x1ad)](_0x1eccf2-_0x448b5c);}export function padStart(_0x12e82e,_0x1a02a5){const _0x400c7c=a231_0x3014,_0x11cd14=stringWidth(_0x12e82e);if(_0x11cd14>=_0x1a02a5)return _0x12e82e;return'\x20'[_0x400c7c(0x1ad)](_0x1a02a5-_0x11cd14)+_0x12e82e;}export function centerAlign(_0xe1c415,_0x402db1){const _0x4e07dc=a231_0x3014,_0x48f4cc=stringWidth(_0xe1c415);if(_0x48f4cc>_0x402db1){if(_0x402db1<=0x1)return'…'[_0x4e07dc(0x1a7)](0x0,_0x402db1);let _0x3b2362=_0xe1c415;while(stringWidth(_0x3b2362+'…')>_0x402db1){_0x3b2362=_0x3b2362[_0x4e07dc(0x198)](0x0,-0x1);}return _0x3b2362+'…';}if(_0x48f4cc===_0x402db1)return _0xe1c415;const _0x236eb9=_0x402db1-_0x48f4cc,_0x25207e=Math[_0x4e07dc(0x1ab)](_0x236eb9/0x2),_0x498762=_0x236eb9-_0x25207e;return'\x20'[_0x4e07dc(0x1ad)](_0x25207e)+_0xe1c415+'\x20'['repeat'](_0x498762);}export function escapeStringLiteral(_0x1a4de9){const _0x42ebb5=a231_0x3014;if(!_0x1a4de9||_0x1a4de9['trim']()['length']===0x0)throw new Error(_0x42ebb5(0x199));const _0x3069a8=_0x1a4de9[_0x42ebb5(0x19a)](/'/g,'\x27\x27');return'\x27'+_0x3069a8+'\x27';}export function globToLike(_0x20dc51){const _0x233d65=a231_0x3014;let _0x48fe5d=_0x20dc51[_0x233d65(0x19a)](/\\/g,'\x5c\x5c')[_0x233d65(0x19a)](/%/g,'\x5c%')[_0x233d65(0x19a)](/_/g,'\x5c_');return _0x48fe5d=_0x48fe5d[_0x233d65(0x19a)](/\*/g,'%')[_0x233d65(0x19a)](/\?/g,'_'),_0x48fe5d;}function a231_0x4213(){const _0x334e01=['test','474398afbZvK','toLowerCase','3594416OEFzvu','8YTfnvc','3RKdWwE','trim','11078811YQwrfs','substring','5485179SUSMEv','3477804tcoJTA','padStart','floor','length','repeat','2120620KZmUYW','slice','Cannot\x20escape\x20empty\x20string\x20literal','replace','Cannot\x20build\x20LIKE\x20pattern\x20from\x20empty\x20string','1105826WRWeyV','unknown','\x5c$&'];a231_0x4213=function(){return _0x334e01;};return a231_0x4213();}export function buildLikePattern(_0x5c435c){const _0x24de3b=a231_0x3014;if(!_0x5c435c||_0x5c435c[_0x24de3b(0x1a5)]()[_0x24de3b(0x1ac)]===0x0)throw new Error(_0x24de3b(0x19b));const _0x32d144=globToLike(_0x5c435c),_0x14942a=_0x32d144[_0x24de3b(0x19a)](/'/g,'\x27\x27');return'\x27'+_0x14942a+'\x27';}export function matchGlobPattern(_0x468703,_0x541c5e){const _0x3f6dd1=a231_0x3014,_0x24f78f=_0x541c5e[_0x3f6dd1(0x19a)](/[.+^${}()|[\]\\]/g,_0x3f6dd1(0x19e))[_0x3f6dd1(0x19a)](/\*/g,'.*')[_0x3f6dd1(0x19a)](/\?/g,'.'),_0x51045f=new RegExp('^'+_0x24f78f+'$');return _0x51045f[_0x3f6dd1(0x19f)](_0x468703);}export function getSanitizedUsername(){const _0x246689=a231_0x3014,_0x17ee4c=process.env.USER||process.env.USERNAME||_0x246689(0x19d);return _0x17ee4c[_0x246689(0x19a)](/[^a-zA-Z0-9]/g,'')[_0x246689(0x1a1)]();}export function generateRandomHex(){const _0x1f998a=a231_0x3014,_0xa0e778=Math[_0x1f998a(0x1ab)](Math['random']()*0xfffff);return _0xa0e778['toString'](0x10)[_0x1f998a(0x1aa)](0x5,'0');}export function sanitizeFileName(_0x38fb2e){const _0xf7fac7=a231_0x3014;return _0x38fb2e[_0xf7fac7(0x1a1)]()['replace'](/[/\\:*?"<>|]/g,'-')['replace'](/\s+/g,'-')[_0xf7fac7(0x19a)](/-+/g,'-')[_0xf7fac7(0x19a)](/^-|-$/g,'');}
1
+ (function(_0x42702c,_0x32a927){const _0x2d6206=a231_0x1773,_0xc64ca2=_0x42702c();while(!![]){try{const _0x5573a9=parseInt(_0x2d6206(0x192))/0x1*(parseInt(_0x2d6206(0x18e))/0x2)+-parseInt(_0x2d6206(0x190))/0x3+-parseInt(_0x2d6206(0x198))/0x4*(parseInt(_0x2d6206(0x1a1))/0x5)+parseInt(_0x2d6206(0x19f))/0x6*(-parseInt(_0x2d6206(0x196))/0x7)+parseInt(_0x2d6206(0x18f))/0x8+-parseInt(_0x2d6206(0x19e))/0x9*(parseInt(_0x2d6206(0x1a0))/0xa)+parseInt(_0x2d6206(0x191))/0xb;if(_0x5573a9===_0x32a927)break;else _0xc64ca2['push'](_0xc64ca2['shift']());}catch(_0x279722){_0xc64ca2['push'](_0xc64ca2['shift']());}}}(a231_0x1b73,0xca67b));function a231_0x1b73(){const _0x59da68=['12982152slDlOC','4617270DhfybI','20489139ptXyHB','2MORJIA','replace','unknown','repeat','178934twEKdF','Cannot\x20escape\x20empty\x20string\x20literal','4EHovNi','random','substring','trim','toLowerCase','\x5c$&','45rgVEUd','78Mjsqrv','714390kphJil','5477410lbRFNr','toString','slice','floor','667706zHVkFu'];a231_0x1b73=function(){return _0x59da68;};return a231_0x1b73();}import a231_0x1b08a1 from'string-width';export function stringWidth(_0x3fb3c){return a231_0x1b08a1(_0x3fb3c);}export function padEnd(_0x27787e,_0x5e72ed){const _0x47e10b=a231_0x1773,_0x543ad2=stringWidth(_0x27787e);if(_0x543ad2>=_0x5e72ed)return _0x27787e;return _0x27787e+'\x20'[_0x47e10b(0x195)](_0x5e72ed-_0x543ad2);}export function padStart(_0x18e30a,_0x2be981){const _0x33f863=stringWidth(_0x18e30a);if(_0x33f863>=_0x2be981)return _0x18e30a;return'\x20'['repeat'](_0x2be981-_0x33f863)+_0x18e30a;}export function centerAlign(_0x1b10b0,_0x5224f8){const _0x3c6596=a231_0x1773,_0x5953c9=stringWidth(_0x1b10b0);if(_0x5953c9>_0x5224f8){if(_0x5224f8<=0x1)return'…'[_0x3c6596(0x19a)](0x0,_0x5224f8);let _0x243fa1=_0x1b10b0;while(stringWidth(_0x243fa1+'…')>_0x5224f8){_0x243fa1=_0x243fa1[_0x3c6596(0x18c)](0x0,-0x1);}return _0x243fa1+'…';}if(_0x5953c9===_0x5224f8)return _0x1b10b0;const _0x219b0d=_0x5224f8-_0x5953c9,_0x42e3f2=Math[_0x3c6596(0x18d)](_0x219b0d/0x2),_0x2e3e91=_0x219b0d-_0x42e3f2;return'\x20'[_0x3c6596(0x195)](_0x42e3f2)+_0x1b10b0+'\x20'[_0x3c6596(0x195)](_0x2e3e91);}export function escapeStringLiteral(_0x245c88){const _0x2a936b=a231_0x1773;if(!_0x245c88||_0x245c88['trim']()['length']===0x0)throw new Error(_0x2a936b(0x197));const _0xb8e679=_0x245c88[_0x2a936b(0x193)](/'/g,'\x27\x27');return'\x27'+_0xb8e679+'\x27';}function a231_0x1773(_0x1b3762,_0x504a7a){_0x1b3762=_0x1b3762-0x18b;const _0x1b73e4=a231_0x1b73();let _0x1773e9=_0x1b73e4[_0x1b3762];return _0x1773e9;}export function globToLike(_0x5a52c6){const _0x4293c6=a231_0x1773;let _0x4d5358=_0x5a52c6[_0x4293c6(0x193)](/\\/g,'\x5c\x5c')[_0x4293c6(0x193)](/%/g,'\x5c%')[_0x4293c6(0x193)](/_/g,'\x5c_');return _0x4d5358=_0x4d5358['replace'](/\*/g,'%')[_0x4293c6(0x193)](/\?/g,'_'),_0x4d5358;}export function buildLikePattern(_0x52758d){const _0x1d3202=a231_0x1773;if(!_0x52758d||_0x52758d[_0x1d3202(0x19b)]()['length']===0x0)throw new Error('Cannot\x20build\x20LIKE\x20pattern\x20from\x20empty\x20string');const _0x2a03ac=globToLike(_0x52758d),_0x5d5fb7=_0x2a03ac[_0x1d3202(0x193)](/'/g,'\x27\x27');return'\x27'+_0x5d5fb7+'\x27';}export function matchGlobPattern(_0x2c96c3,_0x10e1ca){const _0x1e144b=a231_0x1773,_0x557956=_0x10e1ca['replace'](/[.+^${}()|[\]\\]/g,_0x1e144b(0x19d))[_0x1e144b(0x193)](/\*/g,'.*')[_0x1e144b(0x193)](/\?/g,'.'),_0x253791=new RegExp('^'+_0x557956+'$');return _0x253791['test'](_0x2c96c3);}export function getSanitizedUsername(){const _0x2d1029=a231_0x1773,_0x583cd6=process.env.USER||process.env.USERNAME||_0x2d1029(0x194);return _0x583cd6[_0x2d1029(0x193)](/[^a-zA-Z0-9]/g,'')[_0x2d1029(0x19c)]();}export function generateRandomHex(){const _0x5c6b38=a231_0x1773,_0x4b9345=Math[_0x5c6b38(0x18d)](Math[_0x5c6b38(0x199)]()*0xfffff);return _0x4b9345[_0x5c6b38(0x18b)](0x10)['padStart'](0x5,'0');}export function sanitizeFileName(_0x5e5a05){const _0x372f35=a231_0x1773;return _0x5e5a05[_0x372f35(0x19c)]()[_0x372f35(0x193)](/[/\\:*?"<>|]/g,'-')[_0x372f35(0x193)](/\s+/g,'-')[_0x372f35(0x193)](/-+/g,'-')['replace'](/^-|-$/g,'');}
@@ -1 +1 @@
1
- (function(_0x4698d9,_0x58d32e){const _0x4858a4=a232_0x6d44,_0x420bb8=_0x4698d9();while(!![]){try{const _0x3cbbd6=-parseInt(_0x4858a4(0xe6))/0x1+parseInt(_0x4858a4(0xdf))/0x2+-parseInt(_0x4858a4(0xeb))/0x3*(-parseInt(_0x4858a4(0xd7))/0x4)+-parseInt(_0x4858a4(0xde))/0x5*(-parseInt(_0x4858a4(0xdb))/0x6)+-parseInt(_0x4858a4(0xe5))/0x7*(parseInt(_0x4858a4(0xe3))/0x8)+-parseInt(_0x4858a4(0xe1))/0x9*(parseInt(_0x4858a4(0xd5))/0xa)+parseInt(_0x4858a4(0xe4))/0xb*(parseInt(_0x4858a4(0xd8))/0xc);if(_0x3cbbd6===_0x58d32e)break;else _0x420bb8['push'](_0x420bb8['shift']());}catch(_0x56d11d){_0x420bb8['push'](_0x420bb8['shift']());}}}(a232_0x39b7,0xdb161));function hasWildcard(_0x4e3636){const _0xc3f7b5=a232_0x6d44;return _0x4e3636[_0xc3f7b5(0xe8)]('*')||_0x4e3636['includes']('?');}function a232_0x39b7(){const _0x327cb0=['catalog','Invalid\x20pattern\x20format\x20-\x20too\x20many\x20dots\x20(max:\x20catalog.database.table)','59810fMzLdz','2618122jBBHrY','database','31554MiOsnH','table','6975536SOeUAA','18057083imnUxg','14LLSyPM','1643413THqiTf','trim','includes','Table\x20name\x20is\x20required\x20for\x20describe\x20operation','Wildcards\x20are\x20not\x20allowed\x20in\x20table\x20name\x20for\x20describe\x20operation','216dbvDYR','Wildcards\x20are\x20not\x20allowed\x20in\x20database\x20name\x20for\x20describe\x20operation','split','1230vjNYTn','join','7028THqXBD','12NFwGWS','push','length','822ULHTRj'];a232_0x39b7=function(){return _0x327cb0;};return a232_0x39b7();}export function parseTableReference(_0x32fece){const _0x546d8f=a232_0x6d44;if(!_0x32fece||_0x32fece['trim']()[_0x546d8f(0xda)]===0x0)throw new Error('Pattern\x20cannot\x20be\x20empty\x20or\x20whitespace-only');const _0x3da84e=_0x32fece[_0x546d8f(0xe7)](),_0x161352={'original':_0x3da84e},_0x3529b4=_0x3da84e[_0x546d8f(0xd4)]('.');if(_0x3529b4[_0x546d8f(0xda)]===0x1){const _0x5a67b2=_0x3529b4[0x0];if(!_0x5a67b2)throw new Error('Pattern\x20cannot\x20be\x20just\x20a\x20dot');_0x161352['table']=_0x5a67b2;}else{if(_0x3529b4['length']===0x2){const [_0x10c3ee,_0x760966]=_0x3529b4;if(!_0x10c3ee)throw new Error('Database\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20databases\x20(e.g.,\x20\x22*.mytable\x22)');if(!_0x760966)throw new Error('Table\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20tables\x20(e.g.,\x20\x22mydb.*\x22)');_0x161352[_0x546d8f(0xe0)]=_0x10c3ee,_0x161352[_0x546d8f(0xe2)]=_0x760966;}else{if(_0x3529b4['length']===0x3){const [_0x3ff39a,_0x2fa76f,_0x1d3cfa]=_0x3529b4;if(!_0x3ff39a||!_0x2fa76f||!_0x1d3cfa)throw new Error('Invalid\x20catalog.database.table\x20format\x20-\x20all\x20parts\x20must\x20be\x20non-empty');_0x161352[_0x546d8f(0xdc)]=_0x3ff39a,_0x161352['database']=_0x2fa76f,_0x161352[_0x546d8f(0xe2)]=_0x1d3cfa;}else throw new Error(_0x546d8f(0xdd));}}return _0x161352;}function a232_0x6d44(_0x48fead,_0x18e4a2){_0x48fead=_0x48fead-0xd4;const _0x39b78a=a232_0x39b7();let _0x6d444e=_0x39b78a[_0x48fead];return _0x6d444e;}export function formatTableReference(_0x36a970){const _0x48e194=a232_0x6d44,_0x4e3643=[];return _0x36a970['catalog']&&_0x4e3643[_0x48e194(0xd9)](_0x36a970['catalog']),_0x36a970[_0x48e194(0xe0)]&&_0x4e3643[_0x48e194(0xd9)](_0x36a970['database']),_0x36a970[_0x48e194(0xe2)]&&_0x4e3643[_0x48e194(0xd9)](_0x36a970[_0x48e194(0xe2)]),_0x4e3643[_0x48e194(0xd6)]('.');}export function validateTableListReference(_0x18e065){return undefined;}export function validateTableDescribeReference(_0x317950){const _0x22df0b=a232_0x6d44;if(!_0x317950[_0x22df0b(0xe2)])return _0x22df0b(0xe9);if(_0x317950[_0x22df0b(0xe0)]&&hasWildcard(_0x317950['database']))return _0x22df0b(0xec);if(hasWildcard(_0x317950['table']))return _0x22df0b(0xea);return undefined;}
1
+ (function(_0x4c5e75,_0x2ce5b6){const _0xb51ff9=a232_0x2c08,_0x156ad7=_0x4c5e75();while(!![]){try{const _0x240053=parseInt(_0xb51ff9(0x16c))/0x1+parseInt(_0xb51ff9(0x172))/0x2+parseInt(_0xb51ff9(0x161))/0x3*(-parseInt(_0xb51ff9(0x170))/0x4)+-parseInt(_0xb51ff9(0x15e))/0x5+-parseInt(_0xb51ff9(0x164))/0x6*(-parseInt(_0xb51ff9(0x169))/0x7)+parseInt(_0xb51ff9(0x16d))/0x8*(parseInt(_0xb51ff9(0x175))/0x9)+parseInt(_0xb51ff9(0x162))/0xa*(-parseInt(_0xb51ff9(0x167))/0xb);if(_0x240053===_0x2ce5b6)break;else _0x156ad7['push'](_0x156ad7['shift']());}catch(_0x57400b){_0x156ad7['push'](_0x156ad7['shift']());}}}(a232_0x35b5,0xc7438));function hasWildcard(_0xa3f8ca){const _0x2b9f58=a232_0x2c08;return _0xa3f8ca[_0x2b9f58(0x174)]('*')||_0xa3f8ca[_0x2b9f58(0x174)]('?');}export function parseTableReference(_0xab2abc){const _0x6837b3=a232_0x2c08;if(!_0xab2abc||_0xab2abc['trim']()[_0x6837b3(0x171)]===0x0)throw new Error(_0x6837b3(0x178));const _0x4d85fd=_0xab2abc[_0x6837b3(0x177)](),_0x4f4a6c={'original':_0x4d85fd},_0x41ba3c=_0x4d85fd[_0x6837b3(0x160)]('.');if(_0x41ba3c[_0x6837b3(0x171)]===0x1){const _0x5f44c6=_0x41ba3c[0x0];if(!_0x5f44c6)throw new Error(_0x6837b3(0x16e));_0x4f4a6c[_0x6837b3(0x168)]=_0x5f44c6;}else{if(_0x41ba3c['length']===0x2){const [_0x2811d8,_0x253d3c]=_0x41ba3c;if(!_0x2811d8)throw new Error(_0x6837b3(0x16b));if(!_0x253d3c)throw new Error(_0x6837b3(0x15d));_0x4f4a6c[_0x6837b3(0x176)]=_0x2811d8,_0x4f4a6c[_0x6837b3(0x168)]=_0x253d3c;}else{if(_0x41ba3c[_0x6837b3(0x171)]===0x3){const [_0x466579,_0x3fc5ee,_0x5a4988]=_0x41ba3c;if(!_0x466579||!_0x3fc5ee||!_0x5a4988)throw new Error(_0x6837b3(0x163));_0x4f4a6c[_0x6837b3(0x166)]=_0x466579,_0x4f4a6c[_0x6837b3(0x176)]=_0x3fc5ee,_0x4f4a6c[_0x6837b3(0x168)]=_0x5a4988;}else throw new Error(_0x6837b3(0x16a));}}return _0x4f4a6c;}export function formatTableReference(_0x22b4c6){const _0x1d03f1=a232_0x2c08,_0x1a598e=[];return _0x22b4c6[_0x1d03f1(0x166)]&&_0x1a598e[_0x1d03f1(0x173)](_0x22b4c6[_0x1d03f1(0x166)]),_0x22b4c6['database']&&_0x1a598e[_0x1d03f1(0x173)](_0x22b4c6[_0x1d03f1(0x176)]),_0x22b4c6['table']&&_0x1a598e['push'](_0x22b4c6['table']),_0x1a598e[_0x1d03f1(0x165)]('.');}function a232_0x35b5(){const _0x2b83eb=['1504593FEoNvW','database','trim','Pattern\x20cannot\x20be\x20empty\x20or\x20whitespace-only','Table\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20tables\x20(e.g.,\x20\x22mydb.*\x22)','1092220UYFAbD','Wildcards\x20are\x20not\x20allowed\x20in\x20table\x20name\x20for\x20describe\x20operation','split','99OlfSIl','9747820pGuCxh','Invalid\x20catalog.database.table\x20format\x20-\x20all\x20parts\x20must\x20be\x20non-empty','999720BfSlLW','join','catalog','11tVmXFo','table','56jjcKko','Invalid\x20pattern\x20format\x20-\x20too\x20many\x20dots\x20(max:\x20catalog.database.table)','Database\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20databases\x20(e.g.,\x20\x22*.mytable\x22)','513582hOUpHF','24AglOga','Pattern\x20cannot\x20be\x20just\x20a\x20dot','Table\x20name\x20is\x20required\x20for\x20describe\x20operation','93724CrEKwL','length','869120whUrqi','push','includes'];a232_0x35b5=function(){return _0x2b83eb;};return a232_0x35b5();}function a232_0x2c08(_0x52e25d,_0xf8718a){_0x52e25d=_0x52e25d-0x15d;const _0x35b579=a232_0x35b5();let _0x2c08fd=_0x35b579[_0x52e25d];return _0x2c08fd;}export function validateTableListReference(_0x4fbe2c){return undefined;}export function validateTableDescribeReference(_0x55ee76){const _0x2bc943=a232_0x2c08;if(!_0x55ee76[_0x2bc943(0x168)])return _0x2bc943(0x16f);if(_0x55ee76['database']&&hasWildcard(_0x55ee76['database']))return'Wildcards\x20are\x20not\x20allowed\x20in\x20database\x20name\x20for\x20describe\x20operation';if(hasWildcard(_0x55ee76[_0x2bc943(0x168)]))return _0x2bc943(0x15f);return undefined;}
@@ -1 +1 @@
1
- const a233_0x200621=a233_0x4be4;function a233_0x4f85(){const _0x328e67=['Session\x20ended','logger','1278495gwutSB','tdx.log','trace','logs','debug','8dXvJld','isInitialized','logLevel','246462VWFkBN','548210NkwiPA','16gcXhEN','getLogPath','fileHandler','info','close','2NSIPUk','2277012fxLBEa','addHandler','21999HlhBvl','230630DRdTEN','consoleHandler','fileOnly','98WIucZZ','logFileName','INFO','5368419oMoztP','77RGNMjS','warn','tdx','logDir'];a233_0x4f85=function(){return _0x328e67;};return a233_0x4f85();}(function(_0x31d075,_0x2662a6){const _0x388d0a=a233_0x4be4,_0x502852=_0x31d075();while(!![]){try{const _0x5bef30=parseInt(_0x388d0a(0x133))/0x1*(-parseInt(_0x388d0a(0x130))/0x2)+-parseInt(_0x388d0a(0x141))/0x3+-parseInt(_0x388d0a(0x12b))/0x4*(-parseInt(_0x388d0a(0x14a))/0x5)+-parseInt(_0x388d0a(0x149))/0x6*(-parseInt(_0x388d0a(0x137))/0x7)+parseInt(_0x388d0a(0x146))/0x8*(-parseInt(_0x388d0a(0x13a))/0x9)+parseInt(_0x388d0a(0x134))/0xa*(parseInt(_0x388d0a(0x13b))/0xb)+parseInt(_0x388d0a(0x131))/0xc;if(_0x5bef30===_0x2662a6)break;else _0x502852['push'](_0x502852['shift']());}catch(_0x12c167){_0x502852['push'](_0x502852['shift']());}}}(a233_0x4f85,0x4e2b7));function a233_0x4be4(_0x4965a1,_0x51d103){_0x4965a1=_0x4965a1-0x12b;const _0x4f85dd=a233_0x4f85();let _0x4be40a=_0x4f85dd[_0x4965a1];return _0x4be40a;}import{join}from'path';import{Logger,LogLevel,FileHandler,ConsoleHandler,DefaultLogFormatter}from'./logger/index.js';import{getGlobalCacheDir}from'./global-cache.js';export{LogLevel}from'./logger/index.js';export class TDXLogger{[a233_0x200621(0x148)];[a233_0x200621(0x136)];[a233_0x200621(0x13e)];[a233_0x200621(0x138)];[a233_0x200621(0x140)];[a233_0x200621(0x12d)]=null;[a233_0x200621(0x135)]=null;constructor(_0x10bc3e=LogLevel[a233_0x200621(0x139)],_0x47a419=![],_0x14dbc5,_0x28b6ef=a233_0x200621(0x142)){const _0x535d5c=a233_0x200621;this[_0x535d5c(0x148)]=_0x10bc3e,this[_0x535d5c(0x136)]=_0x47a419,this[_0x535d5c(0x13e)]=_0x14dbc5||join(getGlobalCacheDir(),_0x535d5c(0x144)),this[_0x535d5c(0x138)]=_0x28b6ef,this['logger']=Logger['of'](_0x535d5c(0x13d));}async['init'](){const _0x40a481=a233_0x200621,_0x44b3d8=join(this[_0x40a481(0x13e)],this['logFileName']);if(Logger[_0x40a481(0x147)]()){!this[_0x40a481(0x136)]&&(this['consoleHandler']=new ConsoleHandler({'minLevel':LogLevel[_0x40a481(0x139)],'colors':!![]}),Logger[_0x40a481(0x132)](this['consoleHandler']));return;}this[_0x40a481(0x12d)]=new FileHandler({'filePath':_0x44b3d8});const _0x355287=[this['fileHandler']];!this[_0x40a481(0x136)]&&(this[_0x40a481(0x135)]=new ConsoleHandler({'minLevel':LogLevel[_0x40a481(0x139)],'colors':!![]}),_0x355287['push'](this[_0x40a481(0x135)])),await Logger['init']({'defaultLevel':this[_0x40a481(0x148)],'handlers':_0x355287,'formatter':new DefaultLogFormatter({'colors':!![]})});}[a233_0x200621(0x145)](..._0x2f17e0){const _0x228610=a233_0x200621;this['logger'][_0x228610(0x145)](..._0x2f17e0);}[a233_0x200621(0x143)](..._0x169341){const _0x3ae713=a233_0x200621;this[_0x3ae713(0x140)][_0x3ae713(0x143)](..._0x169341);}[a233_0x200621(0x12e)](..._0x104a4f){const _0x48e048=a233_0x200621;this[_0x48e048(0x140)][_0x48e048(0x12e)](..._0x104a4f);}['warn'](..._0x6f8be2){const _0x1db5a4=a233_0x200621;this[_0x1db5a4(0x140)][_0x1db5a4(0x13c)](..._0x6f8be2);}['error'](..._0x4db025){const _0x108a02=a233_0x200621;this[_0x108a02(0x140)]['error'](..._0x4db025);}async[a233_0x200621(0x12f)](){const _0x552cc6=a233_0x200621;this['logger'][_0x552cc6(0x12e)](_0x552cc6(0x13f)),await Logger['shutdown']();}[a233_0x200621(0x12c)](){const _0x2fd98f=a233_0x200621;return join(this['logDir'],this[_0x2fd98f(0x138)]);}}
1
+ const a233_0x573e4b=a233_0x3f93;(function(_0x4a6677,_0x48d884){const _0x2b5810=a233_0x3f93,_0x1f9b5a=_0x4a6677();while(!![]){try{const _0x2ed843=parseInt(_0x2b5810(0x137))/0x1*(parseInt(_0x2b5810(0x13b))/0x2)+parseInt(_0x2b5810(0x14d))/0x3+-parseInt(_0x2b5810(0x143))/0x4*(-parseInt(_0x2b5810(0x13f))/0x5)+parseInt(_0x2b5810(0x136))/0x6+-parseInt(_0x2b5810(0x145))/0x7+parseInt(_0x2b5810(0x148))/0x8*(-parseInt(_0x2b5810(0x135))/0x9)+parseInt(_0x2b5810(0x13d))/0xa*(parseInt(_0x2b5810(0x14b))/0xb);if(_0x2ed843===_0x48d884)break;else _0x1f9b5a['push'](_0x1f9b5a['shift']());}catch(_0x1677f2){_0x1f9b5a['push'](_0x1f9b5a['shift']());}}}(a233_0x4c02,0xb5b9c));import{join}from'path';import{Logger,LogLevel,FileHandler,ConsoleHandler,DefaultLogFormatter}from'./logger/index.js';function a233_0x4c02(){const _0x471be8=['fileHandler','tdx.log','error','4gIBLmx','close','90IfHEne','isInitialized','5czLAqb','info','Session\x20ended','push','2852936okAuXT','logFileName','7260344OAyrMT','INFO','warn','1393176uKlxPA','consoleHandler','debug','1429241XwewVK','logger','335556LUXTmx','logDir','trace','logLevel','fileOnly','init','72ZBJXYQ','6255858nBKWsw','68804oSKmVW'];a233_0x4c02=function(){return _0x471be8;};return a233_0x4c02();}import{getGlobalCacheDir}from'./global-cache.js';function a233_0x3f93(_0x3347ad,_0x4beee6){_0x3347ad=_0x3347ad-0x135;const _0x4c02e7=a233_0x4c02();let _0x3f93d0=_0x4c02e7[_0x3347ad];return _0x3f93d0;}export{LogLevel}from'./logger/index.js';export class TDXLogger{[a233_0x573e4b(0x150)];['fileOnly'];[a233_0x573e4b(0x14e)];[a233_0x573e4b(0x144)];[a233_0x573e4b(0x14c)];[a233_0x573e4b(0x138)]=null;[a233_0x573e4b(0x149)]=null;constructor(_0x44a12f=LogLevel[a233_0x573e4b(0x146)],_0x3b584c=![],_0x599e21,_0x2844b1=a233_0x573e4b(0x139)){const _0x4c229b=a233_0x573e4b;this[_0x4c229b(0x150)]=_0x44a12f,this['fileOnly']=_0x3b584c,this[_0x4c229b(0x14e)]=_0x599e21||join(getGlobalCacheDir(),'logs'),this[_0x4c229b(0x144)]=_0x2844b1,this[_0x4c229b(0x14c)]=Logger['of']('tdx');}async[a233_0x573e4b(0x152)](){const _0x1da1ee=a233_0x573e4b,_0x36dbe3=join(this[_0x1da1ee(0x14e)],this[_0x1da1ee(0x144)]);if(Logger[_0x1da1ee(0x13e)]()){!this[_0x1da1ee(0x151)]&&(this[_0x1da1ee(0x149)]=new ConsoleHandler({'minLevel':LogLevel[_0x1da1ee(0x146)],'colors':!![]}),Logger['addHandler'](this[_0x1da1ee(0x149)]));return;}this[_0x1da1ee(0x138)]=new FileHandler({'filePath':_0x36dbe3});const _0x1f83d6=[this[_0x1da1ee(0x138)]];!this[_0x1da1ee(0x151)]&&(this[_0x1da1ee(0x149)]=new ConsoleHandler({'minLevel':LogLevel[_0x1da1ee(0x146)],'colors':!![]}),_0x1f83d6[_0x1da1ee(0x142)](this['consoleHandler'])),await Logger[_0x1da1ee(0x152)]({'defaultLevel':this['logLevel'],'handlers':_0x1f83d6,'formatter':new DefaultLogFormatter({'colors':!![]})});}[a233_0x573e4b(0x14a)](..._0x1cc75b){this['logger']['debug'](..._0x1cc75b);}[a233_0x573e4b(0x14f)](..._0x14e3f3){const _0x389f8a=a233_0x573e4b;this[_0x389f8a(0x14c)][_0x389f8a(0x14f)](..._0x14e3f3);}[a233_0x573e4b(0x140)](..._0x1cdea8){const _0x21e3a6=a233_0x573e4b;this['logger'][_0x21e3a6(0x140)](..._0x1cdea8);}[a233_0x573e4b(0x147)](..._0x3f21ba){const _0x2afda3=a233_0x573e4b;this[_0x2afda3(0x14c)]['warn'](..._0x3f21ba);}[a233_0x573e4b(0x13a)](..._0x1896d2){const _0x4676a6=a233_0x573e4b;this[_0x4676a6(0x14c)][_0x4676a6(0x13a)](..._0x1896d2);}async[a233_0x573e4b(0x13c)](){const _0x3ad38e=a233_0x573e4b;this[_0x3ad38e(0x14c)][_0x3ad38e(0x140)](_0x3ad38e(0x141)),await Logger['shutdown']();}['getLogPath'](){const _0x42b75a=a233_0x573e4b;return join(this[_0x42b75a(0x14e)],this[_0x42b75a(0x144)]);}}
@@ -1 +1 @@
1
- const a234_0x26e36d=a234_0x5e81;function a234_0x18e2(){const _0x451906=['channel','Invalid\x20version\x20format','isTTY','version','HTTP\x20','now','\x0aRun:\x20','destroy','1127168Vyraoe','lastCheck','Run:','776aPjevi','dim','gray','write','cyan','read','error','3561488WaNszB','green','last_version_check','tdx\x20upgrade\x20--next','110855vwiwPf','updateAvailable','toISOString','latestVersion','currentVersion','stable','12035961VaaDHe','247392PuesCI','unref','222imPodu','parse','Update\x20available:','latest','next','https://registry.npmjs.org/@treasuredata/tdx','1261632gIIiPX','yellow','\x0aUpdate\x20available:\x20','utils/version-check-next','stderr','data','2143FBOzIM'];a234_0x18e2=function(){return _0x451906;};return a234_0x18e2();}(function(_0x4c5dcd,_0x1936a1){const _0x4e9c6e=a234_0x5e81,_0x4a02d7=_0x4c5dcd();while(!![]){try{const _0x214c64=parseInt(_0x4e9c6e(0x111))/0x1*(-parseInt(_0x4e9c6e(0xf1))/0x2)+parseInt(_0x4e9c6e(0x103))/0x3+-parseInt(_0x4e9c6e(0x10b))/0x4+parseInt(_0x4e9c6e(0xfc))/0x5*(parseInt(_0x4e9c6e(0x105))/0x6)+-parseInt(_0x4e9c6e(0xf8))/0x7+-parseInt(_0x4e9c6e(0xee))/0x8+parseInt(_0x4e9c6e(0x102))/0x9;if(_0x214c64===_0x1936a1)break;else _0x4a02d7['push'](_0x4a02d7['shift']());}catch(_0x399222){_0x4a02d7['push'](_0x4a02d7['shift']());}}}(a234_0x18e2,0x6c49c));import{get}from'https';function a234_0x5e81(_0xd1cda7,_0x444af0){_0xd1cda7=_0xd1cda7-0xee;const _0x18e244=a234_0x18e2();let _0x5e811e=_0x18e244[_0xd1cda7];return _0x5e811e;}import{gt,valid}from'semver';import a234_0x8cfaa3 from'chalk';import{createGlobalCache}from'./global-cache.js';const CACHE_DURATION_MS=0x18*0x3c*0x3c*0x3e8,NPM_REGISTRY_BASE=a234_0x26e36d(0x10a),TIMEOUT_MS=0x7d0,stableVersionCache=createGlobalCache(a234_0x26e36d(0xfa),'utils/version-check'),nextVersionCache=createGlobalCache('last_version_check_next',a234_0x26e36d(0x10e));function getCacheForChannel(_0x1769a6){const _0x532279=a234_0x26e36d;return _0x1769a6===_0x532279(0x109)?nextVersionCache:stableVersionCache;}function readCache(_0x131f7e){const _0x236b4c=a234_0x26e36d;return getCacheForChannel(_0x131f7e)[_0x236b4c(0xf6)]()??null;}function writeCache(_0x5babe6,_0x30cd98){const _0x1565a3=a234_0x26e36d;try{getCacheForChannel(_0x30cd98)['write']({'lastCheck':new Date()[_0x1565a3(0xfe)](),'latestVersion':_0x5babe6});}catch{}}function isCacheValid(_0x59a529){const _0xe6b481=a234_0x26e36d;if(!_0x59a529)return![];const _0x5d4dc9=new Date(_0x59a529[_0xe6b481(0xef)])['getTime'](),_0x12fbc9=Date[_0xe6b481(0x117)]();return _0x12fbc9-_0x5d4dc9<CACHE_DURATION_MS;}export function fetchLatestVersion(_0x930088=a234_0x26e36d(0x101)){const _0x55dbbf=a234_0x26e36d,_0x4d4f82=_0x930088===_0x55dbbf(0x109)?'next':_0x55dbbf(0x108),_0x361085=NPM_REGISTRY_BASE+'/'+_0x4d4f82;return new Promise((_0x538ef9,_0x55193c)=>{const _0x5ac750=_0x55dbbf,_0xbbfbdd=get(_0x361085,{'timeout':TIMEOUT_MS},_0x32feae=>{const _0x3778e3=a234_0x5e81;if(_0x32feae['statusCode']!==0xc8){clearTimeout(_0x426da6),_0x55193c(new Error(_0x3778e3(0x116)+_0x32feae['statusCode']));return;}let _0x19f569='';_0x32feae['on'](_0x3778e3(0x110),_0x6bc1a0=>{_0x19f569+=_0x6bc1a0;}),_0x32feae['on']('end',()=>{const _0xbdbc4a=_0x3778e3;clearTimeout(_0x426da6);try{const _0x7b2926=JSON[_0xbdbc4a(0x106)](_0x19f569);if(!valid(_0x7b2926[_0xbdbc4a(0x115)])){_0x55193c(new Error(_0xbdbc4a(0x113)));return;}_0x538ef9(_0x7b2926[_0xbdbc4a(0x115)]);}catch(_0x3d344e){_0x55193c(_0x3d344e);}});})['on'](_0x5ac750(0xf7),_0x4778ec=>{clearTimeout(_0x426da6),_0x55193c(_0x4778ec);});_0xbbfbdd['on']('socket',_0x66ff6c=>{_0x66ff6c['unref']();});const _0x426da6=setTimeout(()=>{const _0x501bb5=_0x5ac750;_0xbbfbdd[_0x501bb5(0x119)](),_0x55193c(new Error('Request\x20timeout'));},TIMEOUT_MS);_0x426da6[_0x5ac750(0x104)]();});}export async function checkForUpdate(_0xf8fbba,_0x5d8fad=a234_0x26e36d(0x101)){const _0x4c24c2=a234_0x26e36d;try{const _0x56bca7=readCache(_0x5d8fad);if(isCacheValid(_0x56bca7)){const _0x2f447d=gt(_0x56bca7[_0x4c24c2(0xff)],_0xf8fbba);return{'updateAvailable':_0x2f447d,'currentVersion':_0xf8fbba,'latestVersion':_0x56bca7['latestVersion'],'channel':_0x5d8fad};}const _0x36c021=await fetchLatestVersion(_0x5d8fad);writeCache(_0x36c021,_0x5d8fad);const _0x49a01d=gt(_0x36c021,_0xf8fbba);return{'updateAvailable':_0x49a01d,'currentVersion':_0xf8fbba,'latestVersion':_0x36c021,'channel':_0x5d8fad};}catch{return null;}}export function displayUpdateNotification(_0x380ae9){const _0x379366=a234_0x26e36d;if(!_0x380ae9[_0x379366(0xfd)])return;const _0x1a9c50=_0x380ae9[_0x379366(0x112)]===_0x379366(0x109)?_0x379366(0xfb):'tdx\x20upgrade',_0x20531f=process[_0x379366(0x10f)][_0x379366(0x114)]&&!process.env.NO_COLOR,_0x7a27c4=_0x20531f?a234_0x8cfaa3[_0x379366(0xf3)]('→'):'→',_0x4340e9=_0x20531f?a234_0x8cfaa3['dim'](_0x380ae9[_0x379366(0x100)]):_0x380ae9[_0x379366(0x100)],_0x1591a8=_0x20531f?a234_0x8cfaa3[_0x379366(0xf9)](_0x380ae9[_0x379366(0xff)]):_0x380ae9[_0x379366(0xff)],_0x5ac87d=_0x20531f?a234_0x8cfaa3[_0x379366(0xf5)](_0x1a9c50):_0x1a9c50,_0x3de240=_0x20531f?'\x0a'+a234_0x8cfaa3[_0x379366(0x10c)](_0x379366(0x107))+'\x20'+_0x4340e9+'\x20'+_0x7a27c4+'\x20'+_0x1591a8+'\x0a'+a234_0x8cfaa3[_0x379366(0xf2)](_0x379366(0xf0))+'\x20'+_0x5ac87d+'\x0a':_0x379366(0x10d)+_0x4340e9+'\x20'+_0x7a27c4+'\x20'+_0x1591a8+_0x379366(0x118)+_0x5ac87d+'\x0a';process[_0x379366(0x10f)][_0x379366(0xf4)](_0x3de240);}
1
+ const a234_0x2d2e53=a234_0x15a8;function a234_0x4b3a(){const _0x300eb8=['end','10LEfjzc','5468733hMTEgO','read','version','HTTP\x20','dim','yellow','6945776VACerT','latest','statusCode','gray','10fpYHME','Invalid\x20version\x20format','last_version_check_next','data','next','write','6642163BcqarU','now','Run:','parse','utils/version-check-next','tdx\x20upgrade\x20--next','isTTY','7olxliR','1391802PFNMaK','green','latestVersion','145294jgEXJl','toISOString','socket','stable','currentVersion','stderr','unref','https://registry.npmjs.org/@treasuredata/tdx','updateAvailable','channel','46102IqvDNF','Update\x20available:','lastCheck','cyan','tdx\x20upgrade','\x0aUpdate\x20available:\x20','3aFJogX','2910500XpzqJJ'];a234_0x4b3a=function(){return _0x300eb8;};return a234_0x4b3a();}(function(_0x23cdaa,_0xf00675){const _0x491e50=a234_0x15a8,_0x2b1c60=_0x23cdaa();while(!![]){try{const _0x4e5848=parseInt(_0x491e50(0x14c))/0x1+parseInt(_0x491e50(0x171))/0x2*(parseInt(_0x491e50(0x152))/0x3)+parseInt(_0x491e50(0x153))/0x4+parseInt(_0x491e50(0x160))/0x5*(parseInt(_0x491e50(0x16e))/0x6)+-parseInt(_0x491e50(0x16d))/0x7*(parseInt(_0x491e50(0x15c))/0x8)+parseInt(_0x491e50(0x156))/0x9+-parseInt(_0x491e50(0x155))/0xa*(parseInt(_0x491e50(0x166))/0xb);if(_0x4e5848===_0xf00675)break;else _0x2b1c60['push'](_0x2b1c60['shift']());}catch(_0x33c72d){_0x2b1c60['push'](_0x2b1c60['shift']());}}}(a234_0x4b3a,0x6cdc2));function a234_0x15a8(_0x5102b1,_0x5cdc63){_0x5102b1=_0x5102b1-0x145;const _0x4b3a9e=a234_0x4b3a();let _0x15a8e1=_0x4b3a9e[_0x5102b1];return _0x15a8e1;}import{get}from'https';import{gt,valid}from'semver';import a234_0x4e5d29 from'chalk';import{createGlobalCache}from'./global-cache.js';const CACHE_DURATION_MS=0x18*0x3c*0x3c*0x3e8,NPM_REGISTRY_BASE=a234_0x2d2e53(0x149),TIMEOUT_MS=0x7d0,stableVersionCache=createGlobalCache('last_version_check','utils/version-check'),nextVersionCache=createGlobalCache(a234_0x2d2e53(0x162),a234_0x2d2e53(0x16a));function getCacheForChannel(_0x2197d8){return _0x2197d8==='next'?nextVersionCache:stableVersionCache;}function readCache(_0x4bf9ec){const _0x221249=a234_0x2d2e53;return getCacheForChannel(_0x4bf9ec)[_0x221249(0x157)]()??null;}function writeCache(_0x5b6705,_0x49d85d){const _0x504650=a234_0x2d2e53;try{getCacheForChannel(_0x49d85d)[_0x504650(0x165)]({'lastCheck':new Date()[_0x504650(0x172)](),'latestVersion':_0x5b6705});}catch{}}function isCacheValid(_0x198c58){const _0x2a1ba2=a234_0x2d2e53;if(!_0x198c58)return![];const _0x3d0926=new Date(_0x198c58[_0x2a1ba2(0x14e)])['getTime'](),_0x19c734=Date[_0x2a1ba2(0x167)]();return _0x19c734-_0x3d0926<CACHE_DURATION_MS;}export function fetchLatestVersion(_0x56c165=a234_0x2d2e53(0x145)){const _0x5f5b31=a234_0x2d2e53,_0x1a84f3=_0x56c165==='next'?_0x5f5b31(0x164):_0x5f5b31(0x15d),_0x5da445=NPM_REGISTRY_BASE+'/'+_0x1a84f3;return new Promise((_0x29b748,_0x31e262)=>{const _0x512626=_0x5f5b31,_0x5e254e=get(_0x5da445,{'timeout':TIMEOUT_MS},_0x51b818=>{const _0x499e28=a234_0x15a8;if(_0x51b818[_0x499e28(0x15e)]!==0xc8){clearTimeout(_0x11a82d),_0x31e262(new Error(_0x499e28(0x159)+_0x51b818[_0x499e28(0x15e)]));return;}let _0x57539e='';_0x51b818['on'](_0x499e28(0x163),_0x537222=>{_0x57539e+=_0x537222;}),_0x51b818['on'](_0x499e28(0x154),()=>{const _0x17d55=_0x499e28;clearTimeout(_0x11a82d);try{const _0x33062e=JSON[_0x17d55(0x169)](_0x57539e);if(!valid(_0x33062e[_0x17d55(0x158)])){_0x31e262(new Error(_0x17d55(0x161)));return;}_0x29b748(_0x33062e[_0x17d55(0x158)]);}catch(_0x4aefb0){_0x31e262(_0x4aefb0);}});})['on']('error',_0x4d3046=>{clearTimeout(_0x11a82d),_0x31e262(_0x4d3046);});_0x5e254e['on'](_0x512626(0x173),_0x46c3f3=>{const _0x292e23=_0x512626;_0x46c3f3[_0x292e23(0x148)]();});const _0x11a82d=setTimeout(()=>{_0x5e254e['destroy'](),_0x31e262(new Error('Request\x20timeout'));},TIMEOUT_MS);_0x11a82d[_0x512626(0x148)]();});}export async function checkForUpdate(_0x3bdf72,_0x4ff222=a234_0x2d2e53(0x145)){const _0x29fdac=a234_0x2d2e53;try{const _0x5ee349=readCache(_0x4ff222);if(isCacheValid(_0x5ee349)){const _0x22bf59=gt(_0x5ee349['latestVersion'],_0x3bdf72);return{'updateAvailable':_0x22bf59,'currentVersion':_0x3bdf72,'latestVersion':_0x5ee349[_0x29fdac(0x170)],'channel':_0x4ff222};}const _0x567c40=await fetchLatestVersion(_0x4ff222);writeCache(_0x567c40,_0x4ff222);const _0x2d8658=gt(_0x567c40,_0x3bdf72);return{'updateAvailable':_0x2d8658,'currentVersion':_0x3bdf72,'latestVersion':_0x567c40,'channel':_0x4ff222};}catch{return null;}}export function displayUpdateNotification(_0x449e6c){const _0x2a97ab=a234_0x2d2e53;if(!_0x449e6c[_0x2a97ab(0x14a)])return;const _0x4af885=_0x449e6c[_0x2a97ab(0x14b)]===_0x2a97ab(0x164)?_0x2a97ab(0x16b):_0x2a97ab(0x150),_0x48fa44=process[_0x2a97ab(0x147)][_0x2a97ab(0x16c)]&&!process.env.NO_COLOR,_0x552ecc=_0x48fa44?a234_0x4e5d29[_0x2a97ab(0x15f)]('→'):'→',_0x54a535=_0x48fa44?a234_0x4e5d29[_0x2a97ab(0x15a)](_0x449e6c[_0x2a97ab(0x146)]):_0x449e6c[_0x2a97ab(0x146)],_0x374ea8=_0x48fa44?a234_0x4e5d29[_0x2a97ab(0x16f)](_0x449e6c[_0x2a97ab(0x170)]):_0x449e6c[_0x2a97ab(0x170)],_0x36e967=_0x48fa44?a234_0x4e5d29[_0x2a97ab(0x14f)](_0x4af885):_0x4af885,_0x4c0915=_0x48fa44?'\x0a'+a234_0x4e5d29[_0x2a97ab(0x15b)](_0x2a97ab(0x14d))+'\x20'+_0x54a535+'\x20'+_0x552ecc+'\x20'+_0x374ea8+'\x0a'+a234_0x4e5d29[_0x2a97ab(0x15a)](_0x2a97ab(0x168))+'\x20'+_0x36e967+'\x0a':_0x2a97ab(0x151)+_0x54a535+'\x20'+_0x552ecc+'\x20'+_0x374ea8+'\x0aRun:\x20'+_0x36e967+'\x0a';process['stderr']['write'](_0x4c0915);}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@treasuredata/tdx",
3
- "version": "2026.3.42",
3
+ "version": "2026.3.43",
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": {