@treasuredata/tdx 0.8.6 → 0.8.8

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 (116) hide show
  1. package/dist/bin.js +1 -1
  2. package/dist/build-info.json +2 -2
  3. package/dist/cli-categories.js +1 -1
  4. package/dist/cli.js +1 -1
  5. package/dist/client/cdp-api-client.js +1 -1
  6. package/dist/client/engage-api-client.js +1 -1
  7. package/dist/client/http-client.js +1 -1
  8. package/dist/client/llm-api-client.js +1 -1
  9. package/dist/client/rate-limiter.js +1 -1
  10. package/dist/client/td-api-client.js +1 -1
  11. package/dist/client/trino-api-client.js +1 -1
  12. package/dist/client/workflow-client.js +1 -1
  13. package/dist/commands/activations.js +1 -1
  14. package/dist/commands/api-command.js +1 -1
  15. package/dist/commands/auth-command.js +1 -1
  16. package/dist/commands/chat-command.js +1 -1
  17. package/dist/commands/claude-command.d.ts.map +1 -1
  18. package/dist/commands/claude-command.js +1 -1
  19. package/dist/commands/claude-command.js.map +1 -1
  20. package/dist/commands/claude-statusline-command.js +1 -1
  21. package/dist/commands/claude-usage-command.js +1 -1
  22. package/dist/commands/command.js +1 -1
  23. package/dist/commands/connection-command.js +1 -1
  24. package/dist/commands/context-command.js +1 -1
  25. package/dist/commands/databases.js +1 -1
  26. package/dist/commands/describe.js +1 -1
  27. package/dist/commands/engage-command.js +1 -1
  28. package/dist/commands/job-command.js +1 -1
  29. package/dist/commands/journey-command.js +1 -1
  30. package/dist/commands/llm-command.js +1 -1
  31. package/dist/commands/llm-proxy.js +1 -1
  32. package/dist/commands/parent-segment-command.js +1 -1
  33. package/dist/commands/profiles-command.js +1 -1
  34. package/dist/commands/query-command.js +1 -1
  35. package/dist/commands/segment-command.js +1 -1
  36. package/dist/commands/segment-create-command.js +1 -1
  37. package/dist/commands/segment-fields-command.js +1 -1
  38. package/dist/commands/segment-pull-command.js +1 -1
  39. package/dist/commands/segment-push-command.js +1 -1
  40. package/dist/commands/segment-update-command.js +1 -1
  41. package/dist/commands/segment-use-command.js +1 -1
  42. package/dist/commands/segments.js +1 -1
  43. package/dist/commands/show.js +1 -1
  44. package/dist/commands/tables.js +1 -1
  45. package/dist/commands/use-command.js +1 -1
  46. package/dist/commands/user-command.js +1 -1
  47. package/dist/commands/workflow-command.js +1 -1
  48. package/dist/core/auth.js +1 -1
  49. package/dist/core/config.js +1 -1
  50. package/dist/core/connection-cache.js +1 -1
  51. package/dist/core/credential-cache.js +1 -1
  52. package/dist/core/global-context.js +1 -1
  53. package/dist/core/keychain.js +1 -1
  54. package/dist/core/profile.js +1 -1
  55. package/dist/core/project-config.js +1 -1
  56. package/dist/core/session.js +1 -1
  57. package/dist/core/user-cache.js +1 -1
  58. package/dist/index.js +1 -1
  59. package/dist/proxy/anthropic-adapter.js +1 -1
  60. package/dist/proxy/claude-usage-tracker.js +1 -1
  61. package/dist/proxy/context-signature.js +1 -1
  62. package/dist/proxy/conversation-utils.js +1 -1
  63. package/dist/proxy/server.js +1 -1
  64. package/dist/proxy/session-cache.js +1 -1
  65. package/dist/sdk/api.js +1 -1
  66. package/dist/sdk/connection.js +1 -1
  67. package/dist/sdk/engage.js +1 -1
  68. package/dist/sdk/errors.js +1 -1
  69. package/dist/sdk/index.js +1 -1
  70. package/dist/sdk/job.js +1 -1
  71. package/dist/sdk/journey.js +1 -1
  72. package/dist/sdk/llm.js +1 -1
  73. package/dist/sdk/query.js +1 -1
  74. package/dist/sdk/segment/child-segment-yaml.js +1 -1
  75. package/dist/sdk/segment/journey-yaml.js +1 -1
  76. package/dist/sdk/segment/parent-segment-preview.js +1 -1
  77. package/dist/sdk/segment/parent-segment-yaml.js +1 -1
  78. package/dist/sdk/segment.js +1 -1
  79. package/dist/sdk/user.js +1 -1
  80. package/dist/sdk/workflow.js +1 -1
  81. package/dist/types/endpoints.js +1 -1
  82. package/dist/types/index.js +1 -1
  83. package/dist/utils/agent-ref-parser.js +1 -1
  84. package/dist/utils/async.js +1 -1
  85. package/dist/utils/chat-cache.js +1 -1
  86. package/dist/utils/colors.js +1 -1
  87. package/dist/utils/command-output.js +1 -1
  88. package/dist/utils/constants.js +1 -1
  89. package/dist/utils/diff.js +1 -1
  90. package/dist/utils/fields-display.js +1 -1
  91. package/dist/utils/file-permissions.js +1 -1
  92. package/dist/utils/format-detector.js +1 -1
  93. package/dist/utils/formatters.js +1 -1
  94. package/dist/utils/json-loader.js +1 -1
  95. package/dist/utils/llm-backup-utils.js +1 -1
  96. package/dist/utils/model-aliases.js +1 -1
  97. package/dist/utils/model-factors.js +1 -1
  98. package/dist/utils/option-validation.js +1 -1
  99. package/dist/utils/port.js +1 -1
  100. package/dist/utils/process.d.ts.map +1 -1
  101. package/dist/utils/process.js +1 -1
  102. package/dist/utils/process.js.map +1 -1
  103. package/dist/utils/prompt.js +1 -1
  104. package/dist/utils/segment-path-parser.js +1 -1
  105. package/dist/utils/segment-ref-parser.js +1 -1
  106. package/dist/utils/spinner.js +1 -1
  107. package/dist/utils/sql-parser.js +1 -1
  108. package/dist/utils/sse-parser.js +1 -1
  109. package/dist/utils/string-utils.js +1 -1
  110. package/dist/utils/table-ref-parser.js +1 -1
  111. package/dist/utils/tdx-config.js +1 -1
  112. package/dist/utils/tdx-logger.js +1 -1
  113. package/dist/utils/tree-formatter.js +1 -1
  114. package/dist/utils/version-check.js +1 -1
  115. package/dist/utils/workflow-utils.js +1 -1
  116. package/package.json +1 -1
@@ -1 +1 @@
1
- (function(_0x11da75,_0x14b9d6){const _0x428bb0=a107_0x41d7,_0x4785cf=_0x11da75();while(!![]){try{const _0x54f909=parseInt(_0x428bb0(0x1f3))/0x1*(-parseInt(_0x428bb0(0x1f1))/0x2)+parseInt(_0x428bb0(0x1d1))/0x3+-parseInt(_0x428bb0(0x1d9))/0x4*(parseInt(_0x428bb0(0x1cb))/0x5)+-parseInt(_0x428bb0(0x1e2))/0x6*(-parseInt(_0x428bb0(0x1d6))/0x7)+parseInt(_0x428bb0(0x1d7))/0x8*(parseInt(_0x428bb0(0x1e5))/0x9)+-parseInt(_0x428bb0(0x1d3))/0xa+-parseInt(_0x428bb0(0x1c8))/0xb*(parseInt(_0x428bb0(0x1cd))/0xc);if(_0x54f909===_0x14b9d6)break;else _0x4785cf['push'](_0x4785cf['shift']());}catch(_0x5d75a8){_0x4785cf['push'](_0x4785cf['shift']());}}}(a107_0x35b5,0xd02b8));function a107_0x35b5(){const _0x50acf0=['slice','resolve','length','utf-8','Path\x20attempts\x20to\x20navigate\x20above\x20root','File\x20not\x20found:\x20','relative','9891114vvUaFA','startsWith','root','81YdueoA','Path\x20segment\x20cannot\x20be\x20empty','Relative\x20path\x20cannot\x20be\x20empty','isAbsolute','parse','Absolute\x20path\x20cannot\x20start\x20with\x20\x22..\x22','name','filter','raw','trim','Cannot\x20navigate\x20above\x20root','join','2wLLRFO','segment','414964dKUAPU','dirname','Cannot\x20split\x20empty\x20path','11RszxOx','Path\x20cannot\x20be\x20empty','Path\x20segment\x20contains\x20invalid\x20control\x20characters:\x20','11295MsoARa','endsWith','13038684ZbAIMB','Invalid\x20YAML:\x20missing\x20name\x20field\x20in\x20','segments','push','4078902JvGOzB','parent_segment','4592260hAEMPg','replace','pop','7LwlbZs','210424LISnYL','type','764ByoUCT','split'];a107_0x35b5=function(){return _0x50acf0;};return a107_0x35b5();}import{existsSync,readFileSync}from'fs';import a107_0x24d99a from'path';function a107_0x41d7(_0x1e805f,_0x36c8ec){_0x1e805f=_0x1e805f-0x1c7;const _0x35b5ef=a107_0x35b5();let _0x41d709=_0x35b5ef[_0x1e805f];return _0x41d709;}import{parse as a107_0x664778}from'yaml';export function parsePath(_0x29a3b7){const _0x5ec175=a107_0x41d7;if(!_0x29a3b7||_0x29a3b7[_0x5ec175(0x1ee)]()==='')throw new Error(_0x5ec175(0x1c9));const _0x1849bf=_0x29a3b7[_0x5ec175(0x1ee)]();if(_0x1849bf==='/')return{'segments':[],'isAbsolute':!![],'raw':_0x29a3b7};const _0x2832c9=_0x1849bf[_0x5ec175(0x1e3)]('/')?_0x1849bf['substring'](0x1):_0x1849bf,_0x3e3010=_0x2832c9[_0x5ec175(0x1da)]('/')[_0x5ec175(0x1ec)](_0x20a1f3=>_0x20a1f3!=='');if(_0x3e3010[_0x5ec175(0x1dd)]===0x0)throw new Error('Path\x20must\x20contain\x20at\x20least\x20one\x20segment');const _0x323b69=_0x1849bf['startsWith']('/')||!isRelativePathSegment(_0x3e3010[0x0]);for(const _0xa64702 of _0x3e3010){validatePathSegment(_0xa64702);}return{'segments':_0x3e3010,'isAbsolute':_0x323b69,'raw':_0x29a3b7};}function isRelativePathSegment(_0x3ef814){return _0x3ef814==='.'||_0x3ef814==='..';}function validatePathSegment(_0x25ff2c){const _0x243959=a107_0x41d7;if(_0x25ff2c==='')throw new Error(_0x243959(0x1e6));if(_0x25ff2c==='.'||_0x25ff2c==='..')return;if(/[\x00-\x1F\x7F]/['test'](_0x25ff2c))throw new Error(_0x243959(0x1ca)+_0x25ff2c);if(_0x25ff2c!==_0x25ff2c['trim']()){}}export function validatePath(_0x5ae36b){const _0xad331c=a107_0x41d7;if(_0x5ae36b[_0xad331c(0x1cf)][_0xad331c(0x1dd)]===0x0&&!_0x5ae36b[_0xad331c(0x1e8)])throw new Error(_0xad331c(0x1e7));if(_0x5ae36b['isAbsolute']){if(_0x5ae36b[_0xad331c(0x1cf)][0x0]==='..')throw new Error(_0xad331c(0x1ea));let _0x4bbcd2=0x0;for(const _0x5a9bd2 of _0x5ae36b[_0xad331c(0x1cf)]){if(_0x5a9bd2==='..'){if(_0x4bbcd2===0x0)throw new Error(_0xad331c(0x1df));_0x4bbcd2--;}else _0x5a9bd2!=='.'&&_0x4bbcd2++;}}}export function joinPaths(_0x79b7af,_0x3469c0){const _0x2dfddd=a107_0x41d7;if(!_0x79b7af||_0x79b7af==='/')return _0x3469c0;if(!_0x3469c0||_0x3469c0==='.')return _0x79b7af;if(_0x3469c0[_0x2dfddd(0x1e3)]('/'))return _0x3469c0;const _0x4112b0=parsePath(_0x79b7af),_0x311689=parsePath(_0x3469c0),_0x5a8c5b=[..._0x4112b0[_0x2dfddd(0x1cf)]];for(const _0x24d1b8 of _0x311689['segments']){if(_0x24d1b8==='.')continue;else{if(_0x24d1b8==='..'){if(_0x5a8c5b['length']===0x0)throw new Error('Cannot\x20navigate\x20above\x20root');_0x5a8c5b[_0x2dfddd(0x1d5)]();}else _0x5a8c5b[_0x2dfddd(0x1d0)](_0x24d1b8);}}const _0x33d595=_0x5a8c5b[_0x2dfddd(0x1f0)]('/');return _0x4112b0[_0x2dfddd(0x1ed)][_0x2dfddd(0x1e3)]('/')?'/'+_0x33d595:_0x33d595;}export function normalizePath(_0x833c9f){const _0x2764c6=a107_0x41d7,_0x5a9195=parsePath(_0x833c9f),_0x1f9d28=[];for(const _0x35c918 of _0x5a9195[_0x2764c6(0x1cf)]){if(_0x35c918==='.')continue;else{if(_0x35c918==='..'){if(_0x1f9d28[_0x2764c6(0x1dd)]===0x0){if(_0x5a9195['isAbsolute'])throw new Error(_0x2764c6(0x1ef));_0x1f9d28[_0x2764c6(0x1d0)]('..');}else _0x1f9d28[_0x1f9d28[_0x2764c6(0x1dd)]-0x1]==='..'?_0x1f9d28[_0x2764c6(0x1d0)]('..'):_0x1f9d28['pop']();}else _0x1f9d28['push'](_0x35c918);}}if(_0x1f9d28[_0x2764c6(0x1dd)]===0x0)return _0x5a9195['isAbsolute']?'/':'.';const _0x3b52ae=_0x1f9d28[_0x2764c6(0x1f0)]('/');return _0x5a9195[_0x2764c6(0x1ed)][_0x2764c6(0x1e3)]('/')?'/'+_0x3b52ae:_0x3b52ae;}export function getParentPath(_0x28a8e2){const _0x955f83=a107_0x41d7,_0x3138d3=parsePath(_0x28a8e2);if(_0x3138d3[_0x955f83(0x1cf)][_0x955f83(0x1dd)]<=0x1)return'/';const _0x261b44=_0x3138d3[_0x955f83(0x1cf)][_0x955f83(0x1db)](0x0,-0x1)[_0x955f83(0x1f0)]('/');return _0x3138d3[_0x955f83(0x1ed)][_0x955f83(0x1e3)]('/')?'/'+_0x261b44:_0x261b44;}export function getBaseName(_0x13afd6){const _0x1aec02=a107_0x41d7,_0x1e64f5=parsePath(_0x13afd6);return _0x1e64f5[_0x1aec02(0x1cf)][_0x1e64f5[_0x1aec02(0x1cf)][_0x1aec02(0x1dd)]-0x1]||'';}export function isChildPath(_0x277d10,_0x101175){const _0x5832bb=a107_0x41d7,_0x35c2a2=parsePath(_0x277d10),_0x394129=parsePath(_0x101175);if(_0x35c2a2['segments'][_0x5832bb(0x1dd)]<=_0x394129[_0x5832bb(0x1cf)][_0x5832bb(0x1dd)])return![];for(let _0x3e3dd6=0x0;_0x3e3dd6<_0x394129[_0x5832bb(0x1cf)][_0x5832bb(0x1dd)];_0x3e3dd6++){if(_0x35c2a2[_0x5832bb(0x1cf)][_0x3e3dd6]!==_0x394129[_0x5832bb(0x1cf)][_0x3e3dd6])return![];}return!![];}export function splitPath(_0x1c4cbe){const _0xb7ccdf=a107_0x41d7,_0x2ce8f4=parsePath(_0x1c4cbe);if(_0x2ce8f4['segments'][_0xb7ccdf(0x1dd)]===0x0)throw new Error(_0xb7ccdf(0x1c7));if(_0x2ce8f4['segments'][_0xb7ccdf(0x1dd)]===0x1)return{'parent':_0x2ce8f4['segments'][0x0]};return{'parent':_0x2ce8f4[_0xb7ccdf(0x1cf)][0x0],'child':_0x2ce8f4['segments'][_0xb7ccdf(0x1db)](0x1)[_0xb7ccdf(0x1f0)]('/')};}export function isYamlFilePath(_0x43e1ef){const _0x1f5ec0=a107_0x41d7;return _0x43e1ef[_0x1f5ec0(0x1cc)]('.yml')||_0x43e1ef['endsWith']('.yaml');}export function resolveYamlFilePath(_0x2d9c2c){const _0x82af5c=a107_0x41d7,_0x203f48=a107_0x24d99a[_0x82af5c(0x1dc)](_0x2d9c2c);if(!existsSync(_0x203f48))throw new Error(_0x82af5c(0x1e0)+_0x2d9c2c);let _0x5d69f6=a107_0x24d99a[_0x82af5c(0x1f4)](_0x203f48),_0x1b9daa=null,_0x318afe=null;const _0x511f60=a107_0x24d99a[_0x82af5c(0x1e9)](_0x5d69f6)[_0x82af5c(0x1e4)];while(_0x5d69f6!==_0x511f60){const _0x4aa8e7=a107_0x24d99a[_0x82af5c(0x1f0)](_0x5d69f6,'tdx.json');if(existsSync(_0x4aa8e7)){_0x1b9daa=_0x4aa8e7,_0x318afe=_0x5d69f6;break;}_0x5d69f6=a107_0x24d99a[_0x82af5c(0x1f4)](_0x5d69f6);}if(!_0x1b9daa||!_0x318afe)throw new Error('No\x20tdx.json\x20found\x20for\x20file:\x20'+_0x2d9c2c);const _0x576807=readFileSync(_0x1b9daa,_0x82af5c(0x1de)),_0x213d4f=JSON[_0x82af5c(0x1e9)](_0x576807),_0x3e9b86=_0x213d4f[_0x82af5c(0x1d2)];if(!_0x3e9b86)throw new Error('Invalid\x20tdx.json:\x20missing\x20parent_segment\x20field');const _0x265bd3=readFileSync(_0x203f48,_0x82af5c(0x1de)),_0x5b5ea7=a107_0x664778(_0x265bd3),_0x5ad62f=_0x5b5ea7[_0x82af5c(0x1eb)];if(!_0x5ad62f)throw new Error(_0x82af5c(0x1ce)+_0x2d9c2c);const _0x458529=_0x5b5ea7[_0x82af5c(0x1d8)]==='journey'?'journey':_0x82af5c(0x1f2),_0x34f588=a107_0x24d99a[_0x82af5c(0x1e1)](_0x318afe,_0x203f48),_0x3fdb07=a107_0x24d99a[_0x82af5c(0x1f4)](_0x34f588),_0x3c8825=_0x3fdb07==='.'?'':_0x3fdb07[_0x82af5c(0x1d4)](/\\/g,'/'),_0x4fe4e7=_0x3c8825?_0x3e9b86+'/'+_0x3c8825+'/'+_0x5ad62f:_0x3e9b86+'/'+_0x5ad62f;return{'parentSegment':_0x3e9b86,'segmentName':_0x5ad62f,'folderPath':_0x3c8825,'fullPath':_0x4fe4e7,'resourceType':_0x458529};}
1
+ (function(_0x82eeb6,_0x2948f7){const _0x4c2610=a107_0x4802,_0x451051=_0x82eeb6();while(!![]){try{const _0x29fc5f=parseInt(_0x4c2610(0xbb))/0x1*(-parseInt(_0x4c2610(0xa0))/0x2)+-parseInt(_0x4c2610(0xb3))/0x3+-parseInt(_0x4c2610(0xc0))/0x4+-parseInt(_0x4c2610(0xa7))/0x5+-parseInt(_0x4c2610(0xaf))/0x6*(parseInt(_0x4c2610(0xb2))/0x7)+-parseInt(_0x4c2610(0xa9))/0x8+parseInt(_0x4c2610(0xb1))/0x9;if(_0x29fc5f===_0x2948f7)break;else _0x451051['push'](_0x451051['shift']());}catch(_0x128e91){_0x451051['push'](_0x451051['shift']());}}}(a107_0x7b2f,0x5f59f));import{existsSync,readFileSync}from'fs';import a107_0x4498f4 from'path';import{parse as a107_0x56b9c2}from'yaml';function a107_0x4802(_0xa3a8fe,_0x3947fa){_0xa3a8fe=_0xa3a8fe-0x96;const _0x7b2f0c=a107_0x7b2f();let _0x48026e=_0x7b2f0c[_0xa3a8fe];return _0x48026e;}export function parsePath(_0x44965a){const _0x19c3a0=a107_0x4802;if(!_0x44965a||_0x44965a['trim']()==='')throw new Error('Path\x20cannot\x20be\x20empty');const _0x139bd6=_0x44965a[_0x19c3a0(0x99)]();if(_0x139bd6==='/')return{'segments':[],'isAbsolute':!![],'raw':_0x44965a};const _0x2bb87d=_0x139bd6[_0x19c3a0(0xb5)]('/')?_0x139bd6['substring'](0x1):_0x139bd6,_0x707297=_0x2bb87d['split']('/')[_0x19c3a0(0x98)](_0x594199=>_0x594199!=='');if(_0x707297[_0x19c3a0(0xa8)]===0x0)throw new Error(_0x19c3a0(0xa1));const _0x1b13a2=_0x139bd6[_0x19c3a0(0xb5)]('/')||!isRelativePathSegment(_0x707297[0x0]);for(const _0x2132b3 of _0x707297){validatePathSegment(_0x2132b3);}return{'segments':_0x707297,'isAbsolute':_0x1b13a2,'raw':_0x44965a};}function isRelativePathSegment(_0x21b862){return _0x21b862==='.'||_0x21b862==='..';}function validatePathSegment(_0x1914df){const _0x5e4001=a107_0x4802;if(_0x1914df==='')throw new Error(_0x5e4001(0xac));if(_0x1914df==='.'||_0x1914df==='..')return;if(/[\x00-\x1F\x7F]/[_0x5e4001(0xb0)](_0x1914df))throw new Error('Path\x20segment\x20contains\x20invalid\x20control\x20characters:\x20'+_0x1914df);if(_0x1914df!==_0x1914df[_0x5e4001(0x99)]()){}}export function validatePath(_0x175366){const _0x2c2af5=a107_0x4802;if(_0x175366['segments'][_0x2c2af5(0xa8)]===0x0&&!_0x175366[_0x2c2af5(0x9a)])throw new Error(_0x2c2af5(0xb8));if(_0x175366[_0x2c2af5(0x9a)]){if(_0x175366['segments'][0x0]==='..')throw new Error(_0x2c2af5(0xa3));let _0x4d2391=0x0;for(const _0x3d9b74 of _0x175366[_0x2c2af5(0x97)]){if(_0x3d9b74==='..'){if(_0x4d2391===0x0)throw new Error(_0x2c2af5(0xb4));_0x4d2391--;}else _0x3d9b74!=='.'&&_0x4d2391++;}}}function a107_0x7b2f(){const _0x5365fc=['filter','trim','isAbsolute','utf-8','slice','endsWith','Cannot\x20navigate\x20above\x20root','raw','32914otvOLb','Path\x20must\x20contain\x20at\x20least\x20one\x20segment','pop','Absolute\x20path\x20cannot\x20start\x20with\x20\x22..\x22','type','name','dirname','2650345NyDaId','length','174936LtvRDy','join','parent_segment','Path\x20segment\x20cannot\x20be\x20empty','Invalid\x20tdx.json:\x20missing\x20parent_segment\x20field','parse','6BKrqkf','test','21159540loGHXQ','974407UonADP','1544907jLCaeQ','Path\x20attempts\x20to\x20navigate\x20above\x20root','startsWith','push','.yml','Relative\x20path\x20cannot\x20be\x20empty','journey','File\x20not\x20found:\x20','20KsGVIi','.yaml','Cannot\x20split\x20empty\x20path','relative','resolve','1701020LaWTpy','No\x20tdx.json\x20found\x20for\x20file:\x20','segments'];a107_0x7b2f=function(){return _0x5365fc;};return a107_0x7b2f();}export function joinPaths(_0x58d766,_0x1dd62b){const _0x1e54ed=a107_0x4802;if(!_0x58d766||_0x58d766==='/')return _0x1dd62b;if(!_0x1dd62b||_0x1dd62b==='.')return _0x58d766;if(_0x1dd62b[_0x1e54ed(0xb5)]('/'))return _0x1dd62b;const _0xafb765=parsePath(_0x58d766),_0x182a2e=parsePath(_0x1dd62b),_0x318d3c=[..._0xafb765[_0x1e54ed(0x97)]];for(const _0x596f98 of _0x182a2e[_0x1e54ed(0x97)]){if(_0x596f98==='.')continue;else{if(_0x596f98==='..'){if(_0x318d3c[_0x1e54ed(0xa8)]===0x0)throw new Error(_0x1e54ed(0x9e));_0x318d3c[_0x1e54ed(0xa2)]();}else _0x318d3c[_0x1e54ed(0xb6)](_0x596f98);}}const _0x3b20fe=_0x318d3c[_0x1e54ed(0xaa)]('/');return _0xafb765[_0x1e54ed(0x9f)][_0x1e54ed(0xb5)]('/')?'/'+_0x3b20fe:_0x3b20fe;}export function normalizePath(_0x380405){const _0x3b3c15=a107_0x4802,_0x5c80be=parsePath(_0x380405),_0x43b117=[];for(const _0x1a67e2 of _0x5c80be['segments']){if(_0x1a67e2==='.')continue;else{if(_0x1a67e2==='..'){if(_0x43b117['length']===0x0){if(_0x5c80be[_0x3b3c15(0x9a)])throw new Error(_0x3b3c15(0x9e));_0x43b117[_0x3b3c15(0xb6)]('..');}else _0x43b117[_0x43b117[_0x3b3c15(0xa8)]-0x1]==='..'?_0x43b117[_0x3b3c15(0xb6)]('..'):_0x43b117[_0x3b3c15(0xa2)]();}else _0x43b117[_0x3b3c15(0xb6)](_0x1a67e2);}}if(_0x43b117[_0x3b3c15(0xa8)]===0x0)return _0x5c80be[_0x3b3c15(0x9a)]?'/':'.';const _0x598a87=_0x43b117['join']('/');return _0x5c80be['raw'][_0x3b3c15(0xb5)]('/')?'/'+_0x598a87:_0x598a87;}export function getParentPath(_0x178851){const _0x1664b6=a107_0x4802,_0x2331e5=parsePath(_0x178851);if(_0x2331e5[_0x1664b6(0x97)][_0x1664b6(0xa8)]<=0x1)return'/';const _0xd0992c=_0x2331e5['segments'][_0x1664b6(0x9c)](0x0,-0x1)[_0x1664b6(0xaa)]('/');return _0x2331e5[_0x1664b6(0x9f)][_0x1664b6(0xb5)]('/')?'/'+_0xd0992c:_0xd0992c;}export function getBaseName(_0x2d7008){const _0x3a3628=a107_0x4802,_0x1e83fa=parsePath(_0x2d7008);return _0x1e83fa[_0x3a3628(0x97)][_0x1e83fa[_0x3a3628(0x97)][_0x3a3628(0xa8)]-0x1]||'';}export function isChildPath(_0x2fa493,_0x8d94bb){const _0x3be7cb=a107_0x4802,_0x51f54c=parsePath(_0x2fa493),_0x4b030f=parsePath(_0x8d94bb);if(_0x51f54c['segments'][_0x3be7cb(0xa8)]<=_0x4b030f[_0x3be7cb(0x97)][_0x3be7cb(0xa8)])return![];for(let _0x92c0ea=0x0;_0x92c0ea<_0x4b030f['segments']['length'];_0x92c0ea++){if(_0x51f54c[_0x3be7cb(0x97)][_0x92c0ea]!==_0x4b030f[_0x3be7cb(0x97)][_0x92c0ea])return![];}return!![];}export function splitPath(_0x139ec3){const _0x131e3c=a107_0x4802,_0x11e5a7=parsePath(_0x139ec3);if(_0x11e5a7['segments'][_0x131e3c(0xa8)]===0x0)throw new Error(_0x131e3c(0xbd));if(_0x11e5a7['segments']['length']===0x1)return{'parent':_0x11e5a7[_0x131e3c(0x97)][0x0]};return{'parent':_0x11e5a7[_0x131e3c(0x97)][0x0],'child':_0x11e5a7[_0x131e3c(0x97)][_0x131e3c(0x9c)](0x1)['join']('/')};}export function isYamlFilePath(_0x227799){const _0x5434ef=a107_0x4802;return _0x227799[_0x5434ef(0x9d)](_0x5434ef(0xb7))||_0x227799['endsWith'](_0x5434ef(0xbc));}export function resolveYamlFilePath(_0x4b9f90){const _0x28e155=a107_0x4802,_0x57d297=a107_0x4498f4[_0x28e155(0xbf)](_0x4b9f90);if(!existsSync(_0x57d297))throw new Error(_0x28e155(0xba)+_0x4b9f90);let _0x14093b=a107_0x4498f4['dirname'](_0x57d297),_0x428c56=null,_0x1b0b35=null;const _0xb7e765=a107_0x4498f4[_0x28e155(0xae)](_0x14093b)['root'];while(_0x14093b!==_0xb7e765){const _0xc8f4c2=a107_0x4498f4['join'](_0x14093b,'tdx.json');if(existsSync(_0xc8f4c2)){_0x428c56=_0xc8f4c2,_0x1b0b35=_0x14093b;break;}_0x14093b=a107_0x4498f4[_0x28e155(0xa6)](_0x14093b);}if(!_0x428c56||!_0x1b0b35)throw new Error(_0x28e155(0x96)+_0x4b9f90);const _0x112cda=readFileSync(_0x428c56,_0x28e155(0x9b)),_0x58eca1=JSON[_0x28e155(0xae)](_0x112cda),_0x30dcc9=_0x58eca1[_0x28e155(0xab)];if(!_0x30dcc9)throw new Error(_0x28e155(0xad));const _0x26ed34=readFileSync(_0x57d297,'utf-8'),_0x191d45=a107_0x56b9c2(_0x26ed34),_0x259916=_0x191d45[_0x28e155(0xa5)];if(!_0x259916)throw new Error('Invalid\x20YAML:\x20missing\x20name\x20field\x20in\x20'+_0x4b9f90);const _0x47679c=_0x191d45[_0x28e155(0xa4)]===_0x28e155(0xb9)?_0x28e155(0xb9):'segment',_0x114d3d=a107_0x4498f4[_0x28e155(0xbe)](_0x1b0b35,_0x57d297),_0x331b9e=a107_0x4498f4['dirname'](_0x114d3d),_0x3f1ed4=_0x331b9e==='.'?'':_0x331b9e['replace'](/\\/g,'/'),_0x261719=_0x3f1ed4?_0x30dcc9+'/'+_0x3f1ed4+'/'+_0x259916:_0x30dcc9+'/'+_0x259916;return{'parentSegment':_0x30dcc9,'segmentName':_0x259916,'folderPath':_0x3f1ed4,'fullPath':_0x261719,'resourceType':_0x47679c};}
@@ -1 +1 @@
1
- function a108_0x2cc7(_0x2b2652,_0x71c457){_0x2b2652=_0x2b2652-0x9b;const _0x318137=a108_0x3181();let _0x2cc73f=_0x318137[_0x2b2652];return _0x2cc73f;}(function(_0x246c92,_0x4c7137){const _0x29d5a6=a108_0x2cc7,_0x5c268a=_0x246c92();while(!![]){try{const _0x3aa8fe=-parseInt(_0x29d5a6(0xa9))/0x1+-parseInt(_0x29d5a6(0x9b))/0x2+-parseInt(_0x29d5a6(0xa8))/0x3*(-parseInt(_0x29d5a6(0xa5))/0x4)+-parseInt(_0x29d5a6(0x9d))/0x5*(parseInt(_0x29d5a6(0xa6))/0x6)+-parseInt(_0x29d5a6(0xa1))/0x7+-parseInt(_0x29d5a6(0xa0))/0x8*(parseInt(_0x29d5a6(0xa2))/0x9)+parseInt(_0x29d5a6(0xa7))/0xa;if(_0x3aa8fe===_0x4c7137)break;else _0x5c268a['push'](_0x5c268a['shift']());}catch(_0x19dd88){_0x5c268a['push'](_0x5c268a['shift']());}}}(a108_0x3181,0xb56e1));export function parseSegmentRef(_0x4eba43){const _0x199e65=a108_0x2cc7,_0x2f5fcc=_0x4eba43[_0x199e65(0xa3)]('/');if(_0x2f5fcc===-0x1)return{'parentId':_0x4eba43};if(_0x2f5fcc===0x0)throw new Error('Invalid\x20segment\x20reference\x20format:\x20'+_0x4eba43+_0x199e65(0x9c));const _0x2f13ef=_0x4eba43[_0x199e65(0x9f)](0x0,_0x2f5fcc),_0x511614=_0x4eba43[_0x199e65(0x9f)](_0x2f5fcc+0x1);if(_0x511614==='')throw new Error(_0x199e65(0xa4)+_0x4eba43+_0x199e65(0x9e));return{'parentId':_0x2f13ef,'childId':_0x511614};}function a108_0x3181(){const _0x30a181=['914754uoFyyD','47687880cgSziN','17610RYQIad','645511bOxyha','2344072tKZkzx','.\x20Parent\x20name\x20cannot\x20be\x20empty','30uCYoRh','.\x20Child\x20name\x20cannot\x20be\x20empty','substring','72yiaXPg','8322363XnlpXi','1225611CcRGQa','indexOf','Invalid\x20segment\x20reference\x20format:\x20','764vQrYLo'];a108_0x3181=function(){return _0x30a181;};return a108_0x3181();}
1
+ (function(_0x16f3b8,_0x592534){const _0x24ad7b=a108_0x3c30,_0x20fa27=_0x16f3b8();while(!![]){try{const _0x29c215=-parseInt(_0x24ad7b(0x17a))/0x1+parseInt(_0x24ad7b(0x17e))/0x2*(parseInt(_0x24ad7b(0x181))/0x3)+parseInt(_0x24ad7b(0x17b))/0x4*(parseInt(_0x24ad7b(0x183))/0x5)+-parseInt(_0x24ad7b(0x185))/0x6+-parseInt(_0x24ad7b(0x184))/0x7*(parseInt(_0x24ad7b(0x17c))/0x8)+-parseInt(_0x24ad7b(0x17f))/0x9+parseInt(_0x24ad7b(0x182))/0xa;if(_0x29c215===_0x592534)break;else _0x20fa27['push'](_0x20fa27['shift']());}catch(_0x2b02a7){_0x20fa27['push'](_0x20fa27['shift']());}}}(a108_0x5aa7,0xa96f9));function a108_0x3c30(_0x12b443,_0x21c11a){_0x12b443=_0x12b443-0x17a;const _0x5aa7d6=a108_0x5aa7();let _0x3c304e=_0x5aa7d6[_0x12b443];return _0x3c304e;}export function parseSegmentRef(_0x1e26b5){const _0x1eb14a=a108_0x3c30,_0x3097d1=_0x1e26b5['indexOf']('/');if(_0x3097d1===-0x1)return{'parentId':_0x1e26b5};if(_0x3097d1===0x0)throw new Error(_0x1eb14a(0x17d)+_0x1e26b5+'.\x20Parent\x20name\x20cannot\x20be\x20empty');const _0x50d270=_0x1e26b5[_0x1eb14a(0x180)](0x0,_0x3097d1),_0x5bc3e4=_0x1e26b5[_0x1eb14a(0x180)](_0x3097d1+0x1);if(_0x5bc3e4==='')throw new Error('Invalid\x20segment\x20reference\x20format:\x20'+_0x1e26b5+'.\x20Child\x20name\x20cannot\x20be\x20empty');return{'parentId':_0x50d270,'childId':_0x5bc3e4};}function a108_0x5aa7(){const _0x3c1083=['6556FoNaZv','8riRJER','Invalid\x20segment\x20reference\x20format:\x20','1343330pNAYDx','5236551DZiGqs','substring','3syGwpg','25738450Feuubg','1915mHMKrI','6634873ZPmnlF','2334912TjScSi','1260408TRptGV'];a108_0x5aa7=function(){return _0x3c1083;};return a108_0x5aa7();}
@@ -1 +1 @@
1
- (function(_0x54dfd6,_0x34972d){const _0x11b04e=a109_0x4f05,_0x1a0bf5=_0x54dfd6();while(!![]){try{const _0x3fb567=-parseInt(_0x11b04e(0x18e))/0x1+-parseInt(_0x11b04e(0x18f))/0x2*(-parseInt(_0x11b04e(0x17e))/0x3)+-parseInt(_0x11b04e(0x17d))/0x4+parseInt(_0x11b04e(0x189))/0x5+-parseInt(_0x11b04e(0x187))/0x6+-parseInt(_0x11b04e(0x186))/0x7+parseInt(_0x11b04e(0x185))/0x8;if(_0x3fb567===_0x34972d)break;else _0x1a0bf5['push'](_0x1a0bf5['shift']());}catch(_0x31bf86){_0x1a0bf5['push'](_0x1a0bf5['shift']());}}}(a109_0x1cc9,0x67269));import a109_0x55d5df from'ora';function a109_0x4f05(_0x47fa31,_0x3f728a){_0x47fa31=_0x47fa31-0x179;const _0x1cc9a0=a109_0x1cc9();let _0x4f0561=_0x1cc9a0[_0x47fa31];return _0x4f0561;}export function createCommandSpinner(_0x57a4f8,_0x502c1d={}){const _0x560b2f=a109_0x4f05,{verbose:verbose=![],forceEnabled:forceEnabled=![]}=_0x502c1d;return a109_0x55d5df({'text':_0x57a4f8,'color':_0x560b2f(0x17c),'isEnabled':forceEnabled||process['stdout'][_0x560b2f(0x180)]&&!verbose});}function a109_0x1cc9(){const _0xcd391f=['toFixed','start','jobId','phase','17203672npbeev','2899575tSMCHK','3018762VlEIsV','clock','833175fXfrzj','floor','...','text','extra','426247jSYSyj','2XZvyva','now','stop','\x20[Job\x20ID:\x20','cyan','2850532BtziRl','484929wqKUkM','replace','isTTY'];a109_0x1cc9=function(){return _0xcd391f;};return a109_0x1cc9();}export async function withSpinner(_0x47e3f0,_0x1a3d31,_0x19f886={}){const _0x198946=a109_0x4f05,_0x5c6488=_0x19f886[_0x198946(0x188)]??(()=>Date['now']()),_0x407dbe=createCommandSpinner(_0x47e3f0,_0x19f886);_0x407dbe['start']();const _0x279202=_0x5c6488();try{const _0xa00278=await _0x1a3d31(),_0x3747ad=_0x5c6488()-_0x279202;return _0x407dbe[_0x198946(0x17a)](),{'data':_0xa00278,'elapsedMs':_0x3747ad};}catch(_0xa12cb1){_0x407dbe[_0x198946(0x17a)]();throw _0xa12cb1;}}export async function withQuerySpinner(_0xd1dcaf,_0x13dd5b,_0xe02efa={}){const _0x5d669a=a109_0x4f05,_0x885b3a=_0xe02efa[_0x5d669a(0x188)]??(()=>Date[_0x5d669a(0x179)]()),_0xbd3ee5=_0xe02efa['intervalFactory']??setInterval,_0x53e827=createCommandSpinner(_0xd1dcaf,_0xe02efa);_0x53e827[_0x5d669a(0x182)]();const _0x594dd5=_0x885b3a(),_0x2db958=_0xd1dcaf[_0x5d669a(0x17f)](_0x5d669a(0x18b),''),_0x4e1874={},_0x2fe9d8=()=>{const _0x5b6632=_0x5d669a;if(!_0x53e827['isSpinning'])return;const _0xe4339=_0x885b3a()-_0x594dd5,_0x5f3e7c=formatElapsed(_0xe4339),_0x4f6ad8=_0x4e1874['phase']??_0x2db958,_0x4531b9=_0x4e1874[_0x5b6632(0x183)]?_0x5b6632(0x17b)+_0x4e1874[_0x5b6632(0x183)]+']':'',_0x3efee3=_0x4e1874[_0x5b6632(0x18d)]?'\x20'+_0x4e1874[_0x5b6632(0x18d)]:'';_0x53e827[_0x5b6632(0x18c)]=_0x4f6ad8+'\x20'+_0x5f3e7c+_0x3efee3+_0x4531b9;},_0x245bcb=_0xbd3ee5(()=>{_0x2fe9d8();},0x3e8),_0xfa065b={'setPhase':_0x1980ea=>{const _0x748a5a=_0x5d669a;_0x4e1874[_0x748a5a(0x184)]=_0x1980ea,_0x2fe9d8();},'setJobId':_0x5a5489=>{const _0x2bfc67=_0x5d669a;_0x4e1874[_0x2bfc67(0x183)]=_0x5a5489,_0x2fe9d8();},'setExtra':_0x1f3414=>{const _0x4d4b8d=_0x5d669a;_0x4e1874[_0x4d4b8d(0x18d)]=_0x1f3414,_0x2fe9d8();}};_0x2fe9d8();try{const _0x2f7388=await _0x13dd5b(_0xfa065b),_0x123849=_0x885b3a()-_0x594dd5;return{'data':_0x2f7388,'elapsedMs':_0x123849};}finally{clearInterval(_0x245bcb),_0x53e827[_0x5d669a(0x17a)]();}}export function formatElapsed(_0x4fb21a){const _0xd1f654=a109_0x4f05,_0x1b4640=Math['floor'](_0x4fb21a/0x3e8);if(_0x1b4640<0x3c)return(_0x4fb21a/0x3e8)[_0xd1f654(0x181)](0x1)+'s';const _0x4aefc0=Math[_0xd1f654(0x18a)](_0x1b4640/0x3c),_0x7e07fc=_0x1b4640%0x3c;if(_0x4aefc0<0x3c)return _0x4aefc0+'m\x20'+_0x7e07fc+'s';const _0x5324b4=Math[_0xd1f654(0x18a)](_0x4aefc0/0x3c),_0x536da1=_0x4aefc0%0x3c;return _0x5324b4+'h\x20'+_0x536da1+'m';}
1
+ (function(_0x51d9bb,_0x4a5a74){const _0x2db4c3=a109_0x583b,_0x225061=_0x51d9bb();while(!![]){try{const _0x53cc48=parseInt(_0x2db4c3(0x189))/0x1*(parseInt(_0x2db4c3(0x184))/0x2)+parseInt(_0x2db4c3(0x180))/0x3+-parseInt(_0x2db4c3(0x17c))/0x4*(parseInt(_0x2db4c3(0x178))/0x5)+parseInt(_0x2db4c3(0x185))/0x6+-parseInt(_0x2db4c3(0x17e))/0x7*(parseInt(_0x2db4c3(0x179))/0x8)+parseInt(_0x2db4c3(0x182))/0x9+-parseInt(_0x2db4c3(0x177))/0xa;if(_0x53cc48===_0x4a5a74)break;else _0x225061['push'](_0x225061['shift']());}catch(_0x59f8ad){_0x225061['push'](_0x225061['shift']());}}}(a109_0x11e1,0x3d183));import a109_0x58666e from'ora';function a109_0x583b(_0x238368,_0x140f7a){_0x238368=_0x238368-0x171;const _0x11e1d9=a109_0x11e1();let _0x583b7d=_0x11e1d9[_0x238368];return _0x583b7d;}export function createCommandSpinner(_0x13d59e,_0x57c0d0={}){const _0x84660f=a109_0x583b,{verbose:verbose=![],forceEnabled:forceEnabled=![]}=_0x57c0d0;return a109_0x58666e({'text':_0x13d59e,'color':_0x84660f(0x174),'isEnabled':forceEnabled||process[_0x84660f(0x188)]['isTTY']&&!verbose});}function a109_0x11e1(){const _0x498be8=['1810854NtqtGG','stop','isSpinning','stdout','16941QSezhN','...','jobId','\x20[Job\x20ID:\x20','cyan','now','floor','6474380boNEjk','5fnvSXA','235760uUiEDG','clock','replace','1114400rcVVDI','extra','49fBmZuo','text','878271aSaBtL','intervalFactory','3585258yZGQSq','start','46qnfcXD'];a109_0x11e1=function(){return _0x498be8;};return a109_0x11e1();}export async function withSpinner(_0x3636f4,_0x2c0f8f,_0x25111e={}){const _0x13d89f=a109_0x583b,_0x3dec2e=_0x25111e[_0x13d89f(0x17a)]??(()=>Date[_0x13d89f(0x175)]()),_0x3eeb93=createCommandSpinner(_0x3636f4,_0x25111e);_0x3eeb93[_0x13d89f(0x183)]();const _0x5c5ec0=_0x3dec2e();try{const _0x11b2ce=await _0x2c0f8f(),_0x3dec87=_0x3dec2e()-_0x5c5ec0;return _0x3eeb93[_0x13d89f(0x186)](),{'data':_0x11b2ce,'elapsedMs':_0x3dec87};}catch(_0x1cb630){_0x3eeb93['stop']();throw _0x1cb630;}}export async function withQuerySpinner(_0x3fccb8,_0x1846d9,_0x4a0785={}){const _0x229098=a109_0x583b,_0x3187c1=_0x4a0785['clock']??(()=>Date[_0x229098(0x175)]()),_0x5c21ab=_0x4a0785[_0x229098(0x181)]??setInterval,_0x1cead7=createCommandSpinner(_0x3fccb8,_0x4a0785);_0x1cead7[_0x229098(0x183)]();const _0x138ccc=_0x3187c1(),_0x3ced04=_0x3fccb8[_0x229098(0x17b)](_0x229098(0x171),''),_0x6be52a={},_0x4c7830=()=>{const _0xc2b3c0=_0x229098;if(!_0x1cead7[_0xc2b3c0(0x187)])return;const _0x3f30b2=_0x3187c1()-_0x138ccc,_0x217b67=formatElapsed(_0x3f30b2),_0x3de4b8=_0x6be52a['phase']??_0x3ced04,_0x26141f=_0x6be52a[_0xc2b3c0(0x172)]?_0xc2b3c0(0x173)+_0x6be52a[_0xc2b3c0(0x172)]+']':'',_0x53e819=_0x6be52a[_0xc2b3c0(0x17d)]?'\x20'+_0x6be52a['extra']:'';_0x1cead7[_0xc2b3c0(0x17f)]=_0x3de4b8+'\x20'+_0x217b67+_0x53e819+_0x26141f;},_0x3bf291=_0x5c21ab(()=>{_0x4c7830();},0x3e8),_0x133dc3={'setPhase':_0x1f9afd=>{_0x6be52a['phase']=_0x1f9afd,_0x4c7830();},'setJobId':_0xfc388d=>{const _0x111f26=_0x229098;_0x6be52a[_0x111f26(0x172)]=_0xfc388d,_0x4c7830();},'setExtra':_0x280c2c=>{const _0x32f7b3=_0x229098;_0x6be52a[_0x32f7b3(0x17d)]=_0x280c2c,_0x4c7830();}};_0x4c7830();try{const _0x4dbef1=await _0x1846d9(_0x133dc3),_0x212586=_0x3187c1()-_0x138ccc;return{'data':_0x4dbef1,'elapsedMs':_0x212586};}finally{clearInterval(_0x3bf291),_0x1cead7[_0x229098(0x186)]();}}export function formatElapsed(_0x16a386){const _0x13c22a=a109_0x583b,_0x1bc376=Math[_0x13c22a(0x176)](_0x16a386/0x3e8);if(_0x1bc376<0x3c)return(_0x16a386/0x3e8)['toFixed'](0x1)+'s';const _0x2ab484=Math[_0x13c22a(0x176)](_0x1bc376/0x3c),_0x328989=_0x1bc376%0x3c;if(_0x2ab484<0x3c)return _0x2ab484+'m\x20'+_0x328989+'s';const _0x3e9d6e=Math[_0x13c22a(0x176)](_0x2ab484/0x3c),_0x2bde8c=_0x2ab484%0x3c;return _0x3e9d6e+'h\x20'+_0x2bde8c+'m';}
@@ -1 +1 @@
1
- (function(_0x3b6273,_0x3cfe7f){const _0x1b9fe9=a110_0x49f2,_0x47d78c=_0x3b6273();while(!![]){try{const _0x14cd0d=-parseInt(_0x1b9fe9(0x201))/0x1*(parseInt(_0x1b9fe9(0x1ef))/0x2)+parseInt(_0x1b9fe9(0x20b))/0x3+-parseInt(_0x1b9fe9(0x20a))/0x4*(parseInt(_0x1b9fe9(0x1f1))/0x5)+parseInt(_0x1b9fe9(0x207))/0x6*(parseInt(_0x1b9fe9(0x1fa))/0x7)+-parseInt(_0x1b9fe9(0x205))/0x8*(parseInt(_0x1b9fe9(0x1f0))/0x9)+-parseInt(_0x1b9fe9(0x1f9))/0xa*(parseInt(_0x1b9fe9(0x1f7))/0xb)+parseInt(_0x1b9fe9(0x20c))/0xc;if(_0x14cd0d===_0x3cfe7f)break;else _0x47d78c['push'](_0x47d78c['shift']());}catch(_0x47778c){_0x47d78c['push'](_0x47d78c['shift']());}}}(a110_0x559e,0xcacbd));import{readFileSync}from'fs';import{createInterface}from'readline';function a110_0x559e(){const _0x5ecb2b=['push','test','2GyakxW','error','stdin\x20','message','72pwkdmt','stdin','18HdDMpj','Permission\x20denied\x20reading\x20file\x20\x27','length','4290140oyOwte','1769052yPWPAt','51470916GTFgqo','isTTY','Error\x20reading\x20from\x20stdin:\x20','EACCES','1406626mhaCBU','872811flzOvI','5CZSJhi','map','replace','utf-8','filter','trim','11XpLqbk','\x27:\x20','13690010gjIOdL','1569631LaFZPD','Content\x20contains\x20no\x20SQL\x20statements','File\x20\x27','toLowerCase','ENOENT'];a110_0x559e=function(){return _0x5ecb2b;};return a110_0x559e();}function a110_0x49f2(_0x22a468,_0x11910c){_0x22a468=_0x22a468-0x1ec;const _0x559e84=a110_0x559e();let _0x49f22f=_0x559e84[_0x22a468];return _0x49f22f;}export function stripSqlComments(_0x20ba9e){const _0x3c75f7=a110_0x49f2;let _0x276455=_0x20ba9e[_0x3c75f7(0x1f3)](/\/\*(?:[^*]|\*(?!\/))*\*\//g,'');return _0x276455=_0x276455['replace'](/--.*$/gm,''),_0x276455['trim']();}function isEscaped(_0x513b56,_0x47ad30){let _0x393a2e=0x0;for(let _0x1bb77a=_0x47ad30-0x1;_0x1bb77a>=0x0&&_0x513b56[_0x1bb77a]==='\x5c';_0x1bb77a--){_0x393a2e++;}return _0x393a2e%0x2===0x1;}export function splitSqlStatements(_0x594e66){const _0x153199=a110_0x49f2,_0x53f63a=stripSqlComments(_0x594e66);if(!_0x53f63a)throw new Error(_0x153199(0x1fb));const _0x10157d=[];let _0x408352='',_0x3ebbda=![],_0x821d2b=![],_0x335464=![];for(let _0x21aa5a=0x0;_0x21aa5a<_0x594e66['length'];_0x21aa5a++){const _0x1c70d4=_0x594e66[_0x21aa5a];if(_0x1c70d4==='\x27'&&!isEscaped(_0x594e66,_0x21aa5a)&&!_0x821d2b&&!_0x335464)_0x3ebbda=!_0x3ebbda;else{if(_0x1c70d4==='\x22'&&!isEscaped(_0x594e66,_0x21aa5a)&&!_0x3ebbda&&!_0x335464)_0x821d2b=!_0x821d2b;else _0x1c70d4==='`'&&!isEscaped(_0x594e66,_0x21aa5a)&&!_0x3ebbda&&!_0x821d2b&&(_0x335464=!_0x335464);}if(_0x1c70d4===';'&&!_0x3ebbda&&!_0x821d2b&&!_0x335464){const _0x290526=_0x408352[_0x153199(0x1f6)]();_0x290526&&_0x10157d[_0x153199(0x1ff)](_0x290526),_0x408352='';}else _0x408352+=_0x1c70d4;}const _0x89fbd6=_0x408352['trim']();_0x89fbd6&&_0x10157d[_0x153199(0x1ff)](_0x89fbd6);const _0x48a62b=_0x10157d[_0x153199(0x1f2)](_0x53bc21=>_0x53bc21[_0x153199(0x1f6)]())[_0x153199(0x1f5)](_0x3ed7aa=>{const _0x3530f2=_0x153199,_0x199ae0=stripSqlComments(_0x3ed7aa);return _0x199ae0[_0x3530f2(0x209)]>0x0;});if(_0x48a62b[_0x153199(0x209)]===0x0)throw new Error(_0x153199(0x1fb));return _0x48a62b;}export function readFileContent(_0x2a703f){const _0x4e51aa=a110_0x49f2;try{return readFileSync(_0x2a703f,_0x4e51aa(0x1f4));}catch(_0x2c0a8e){const _0x19b43b=_0x2c0a8e['code'];if(_0x19b43b===_0x4e51aa(0x1fe))throw new Error(_0x4e51aa(0x1fc)+_0x2a703f+'\x27\x20not\x20found');else{if(_0x19b43b===_0x4e51aa(0x1ee))throw new Error(_0x4e51aa(0x208)+_0x2a703f+'\x27');else throw new Error('Error\x20reading\x20file\x20\x27'+_0x2a703f+_0x4e51aa(0x1f8)+_0x2c0a8e['message']);}}}export function readSqlStatementsFromFile(_0x46b466){const _0x550409=a110_0x49f2,_0x2acd71=readFileContent(_0x46b466);try{return splitSqlStatements(_0x2acd71);}catch(_0x285f16){throw new Error(_0x550409(0x1fc)+_0x46b466+'\x27\x20'+_0x285f16[_0x550409(0x204)][_0x550409(0x1fd)]());}}export async function readStdinContent(){const _0x1f8e0f=a110_0x49f2;if(process[_0x1f8e0f(0x206)][_0x1f8e0f(0x1ec)])throw new Error('No\x20input\x20provided.\x20Pipe\x20SQL\x20to\x20stdin\x20or\x20use\x20a\x20file.\x0aExample:\x20echo\x20\x22SELECT\x201\x22\x20|\x20tdx\x20query\x20-');return new Promise((_0x1e88e1,_0x1613c8)=>{const _0x40bc8c=_0x1f8e0f,_0x39ddde=[],_0x5740d3=createInterface({'input':process[_0x40bc8c(0x206)],'terminal':![]});_0x5740d3['on']('line',_0x1b27e9=>{const _0x59f27f=_0x40bc8c;_0x39ddde[_0x59f27f(0x1ff)](_0x1b27e9);}),_0x5740d3['on']('close',()=>{_0x1e88e1(_0x39ddde['join']('\x0a'));}),_0x5740d3['on'](_0x40bc8c(0x202),_0x720a4e=>{const _0x9e1b23=_0x40bc8c;_0x5740d3['close'](),_0x1613c8(new Error(_0x9e1b23(0x1ed)+_0x720a4e[_0x9e1b23(0x204)]));});});}export async function readSqlStatementsFromStdin(){const _0x4adc10=a110_0x49f2,_0x5c44f6=await readStdinContent();try{return splitSqlStatements(_0x5c44f6);}catch(_0x13a81d){throw new Error(_0x4adc10(0x203)+_0x13a81d[_0x4adc10(0x204)][_0x4adc10(0x1fd)]());}}export function isSqlFilePath(_0x16621c){const _0x43aa6f=a110_0x49f2;return/\w\.sql$/[_0x43aa6f(0x200)](_0x16621c);}
1
+ (function(_0x454694,_0x15e0ee){const _0x4aca93=a110_0x286c,_0x4795d9=_0x454694();while(!![]){try{const _0x295d32=-parseInt(_0x4aca93(0xef))/0x1+-parseInt(_0x4aca93(0xfb))/0x2+-parseInt(_0x4aca93(0xf3))/0x3+-parseInt(_0x4aca93(0x102))/0x4+parseInt(_0x4aca93(0xf9))/0x5+parseInt(_0x4aca93(0xf4))/0x6+-parseInt(_0x4aca93(0xec))/0x7*(-parseInt(_0x4aca93(0xf0))/0x8);if(_0x295d32===_0x15e0ee)break;else _0x4795d9['push'](_0x4795d9['shift']());}catch(_0x33fca8){_0x4795d9['push'](_0x4795d9['shift']());}}}(a110_0x48bc,0x5a163));import{readFileSync}from'fs';import{createInterface}from'readline';function a110_0x48bc(){const _0x1360bf=['filter','670450UDjsKe','\x27:\x20','604924hKuLJj','error','File\x20\x27','length','\x27\x20not\x20found','stdin\x20','Error\x20reading\x20from\x20stdin:\x20','2127552xgtLmO','toLowerCase','message','code','isTTY','replace','Content\x20contains\x20no\x20SQL\x20statements','stdin','map','test','924567OwTBNg','close','Permission\x20denied\x20reading\x20file\x20\x27','728340luZYBL','120hbUOWO','line','No\x20input\x20provided.\x20Pipe\x20SQL\x20to\x20stdin\x20or\x20use\x20a\x20file.\x0aExample:\x20echo\x20\x22SELECT\x201\x22\x20|\x20tdx\x20query\x20-','1095579OFrIui','1089438IQhAKs','push','join','trim'];a110_0x48bc=function(){return _0x1360bf;};return a110_0x48bc();}function a110_0x286c(_0x6ca37d,_0xd87df5){_0x6ca37d=_0x6ca37d-0xea;const _0x48bc8a=a110_0x48bc();let _0x286c38=_0x48bc8a[_0x6ca37d];return _0x286c38;}export function stripSqlComments(_0x459aee){const _0x4be0b4=a110_0x286c;let _0x2ad981=_0x459aee[_0x4be0b4(0x107)](/\/\*(?:[^*]|\*(?!\/))*\*\//g,'');return _0x2ad981=_0x2ad981[_0x4be0b4(0x107)](/--.*$/gm,''),_0x2ad981['trim']();}function isEscaped(_0x265a24,_0x390c74){let _0x19319d=0x0;for(let _0x538464=_0x390c74-0x1;_0x538464>=0x0&&_0x265a24[_0x538464]==='\x5c';_0x538464--){_0x19319d++;}return _0x19319d%0x2===0x1;}export function splitSqlStatements(_0x680cb1){const _0x10ea95=a110_0x286c,_0xd54447=stripSqlComments(_0x680cb1);if(!_0xd54447)throw new Error(_0x10ea95(0x108));const _0x423af9=[];let _0x3aef29='',_0x1431a2=![],_0x3a155f=![],_0x347a9b=![];for(let _0x358035=0x0;_0x358035<_0x680cb1[_0x10ea95(0xfe)];_0x358035++){const _0x17297f=_0x680cb1[_0x358035];if(_0x17297f==='\x27'&&!isEscaped(_0x680cb1,_0x358035)&&!_0x3a155f&&!_0x347a9b)_0x1431a2=!_0x1431a2;else{if(_0x17297f==='\x22'&&!isEscaped(_0x680cb1,_0x358035)&&!_0x1431a2&&!_0x347a9b)_0x3a155f=!_0x3a155f;else _0x17297f==='`'&&!isEscaped(_0x680cb1,_0x358035)&&!_0x1431a2&&!_0x3a155f&&(_0x347a9b=!_0x347a9b);}if(_0x17297f===';'&&!_0x1431a2&&!_0x3a155f&&!_0x347a9b){const _0x32a302=_0x3aef29[_0x10ea95(0xf7)]();_0x32a302&&_0x423af9[_0x10ea95(0xf5)](_0x32a302),_0x3aef29='';}else _0x3aef29+=_0x17297f;}const _0x5952e7=_0x3aef29[_0x10ea95(0xf7)]();_0x5952e7&&_0x423af9['push'](_0x5952e7);const _0x20bbcd=_0x423af9[_0x10ea95(0xea)](_0x115b72=>_0x115b72[_0x10ea95(0xf7)]())[_0x10ea95(0xf8)](_0x58b7f5=>{const _0x231c3b=stripSqlComments(_0x58b7f5);return _0x231c3b['length']>0x0;});if(_0x20bbcd[_0x10ea95(0xfe)]===0x0)throw new Error('Content\x20contains\x20no\x20SQL\x20statements');return _0x20bbcd;}export function readFileContent(_0x299b45){const _0x1d2d13=a110_0x286c;try{return readFileSync(_0x299b45,'utf-8');}catch(_0x19413d){const _0x350c53=_0x19413d[_0x1d2d13(0x105)];if(_0x350c53==='ENOENT')throw new Error(_0x1d2d13(0xfd)+_0x299b45+_0x1d2d13(0xff));else{if(_0x350c53==='EACCES')throw new Error(_0x1d2d13(0xee)+_0x299b45+'\x27');else throw new Error('Error\x20reading\x20file\x20\x27'+_0x299b45+_0x1d2d13(0xfa)+_0x19413d[_0x1d2d13(0x104)]);}}}export function readSqlStatementsFromFile(_0x3b8a90){const _0x27d061=a110_0x286c,_0xd7042f=readFileContent(_0x3b8a90);try{return splitSqlStatements(_0xd7042f);}catch(_0x290e1c){throw new Error(_0x27d061(0xfd)+_0x3b8a90+'\x27\x20'+_0x290e1c['message'][_0x27d061(0x103)]());}}export async function readStdinContent(){const _0x2e5a38=a110_0x286c;if(process[_0x2e5a38(0x109)][_0x2e5a38(0x106)])throw new Error(_0x2e5a38(0xf2));return new Promise((_0xe331a2,_0x15ae73)=>{const _0x528e4d=_0x2e5a38,_0x45d5f1=[],_0x816e1f=createInterface({'input':process[_0x528e4d(0x109)],'terminal':![]});_0x816e1f['on'](_0x528e4d(0xf1),_0x2f999d=>{const _0x32a46c=_0x528e4d;_0x45d5f1[_0x32a46c(0xf5)](_0x2f999d);}),_0x816e1f['on']('close',()=>{const _0x461822=_0x528e4d;_0xe331a2(_0x45d5f1[_0x461822(0xf6)]('\x0a'));}),_0x816e1f['on'](_0x528e4d(0xfc),_0x5b9666=>{const _0x31edd0=_0x528e4d;_0x816e1f[_0x31edd0(0xed)](),_0x15ae73(new Error(_0x31edd0(0x101)+_0x5b9666[_0x31edd0(0x104)]));});});}export async function readSqlStatementsFromStdin(){const _0x3b976b=a110_0x286c,_0x1329b1=await readStdinContent();try{return splitSqlStatements(_0x1329b1);}catch(_0xeefd6f){throw new Error(_0x3b976b(0x100)+_0xeefd6f[_0x3b976b(0x104)][_0x3b976b(0x103)]());}}export function isSqlFilePath(_0xdcad98){const _0x581826=a110_0x286c;return/\w\.sql$/[_0x581826(0xeb)](_0xdcad98);}
@@ -1 +1 @@
1
- function a111_0x1da6(_0x12829f,_0x33bc5d){_0x12829f=_0x12829f-0x1f3;const _0x260ceb=a111_0x260c();let _0x1da614=_0x260ceb[_0x12829f];return _0x1da614;}function a111_0x260c(){const _0x5acbef=['getReader','startsWith','[LLM\x20API\x20SSE]\x20','slice','259EjDFnh','Response\x20body\x20is\x20null','debug','1639932PPPzFP','11646aiSMYr','body','1942560YrPRsP','trim','read','123088wnNvQG','pop','releaseLock','data','parse','event','213134rTTVbd','2349972PdxQTb','146088gjYyln'];a111_0x260c=function(){return _0x5acbef;};return a111_0x260c();}(function(_0x36659b,_0x423ec8){const _0x356075=a111_0x1da6,_0x476c12=_0x36659b();while(!![]){try{const _0x18f80a=-parseInt(_0x356075(0x1f9))/0x1+-parseInt(_0x356075(0x1f3))/0x2+-parseInt(_0x356075(0x204))/0x3+parseInt(_0x356075(0x203))/0x4+parseInt(_0x356075(0x206))/0x5+parseInt(_0x356075(0x1fa))/0x6+-parseInt(_0x356075(0x200))/0x7*(parseInt(_0x356075(0x1fb))/0x8);if(_0x18f80a===_0x423ec8)break;else _0x476c12['push'](_0x476c12['shift']());}catch(_0x3b253d){_0x476c12['push'](_0x476c12['shift']());}}}(a111_0x260c,0x399a4));export async function*parseSSEStream(_0x5bda6e,_0x1f9899){const _0x12c8d6=a111_0x1da6;if(!_0x5bda6e[_0x12c8d6(0x205)])throw new Error(_0x12c8d6(0x201));const _0x5b6e43=_0x5bda6e[_0x12c8d6(0x205)][_0x12c8d6(0x1fc)](),_0x240838=new TextDecoder();let _0x42a3dc='',_0x444f96={};try{while(!![]){const {done:_0xc568c7,value:_0x556c6d}=await _0x5b6e43[_0x12c8d6(0x208)]();if(_0xc568c7){if(_0x444f96[_0x12c8d6(0x1f6)]){_0x1f9899?.[_0x12c8d6(0x202)](_0x12c8d6(0x1fe)+_0x444f96[_0x12c8d6(0x1f6)]);const _0x532952=parseSSEData(_0x444f96[_0x12c8d6(0x1f6)]);yield _0x532952;}break;}_0x42a3dc+=_0x240838['decode'](_0x556c6d,{'stream':!![]});const _0x382596=_0x42a3dc['split']('\x0a');_0x42a3dc=_0x382596[_0x12c8d6(0x1f4)]()||'';for(const _0x24f5b7 of _0x382596){if(_0x24f5b7[_0x12c8d6(0x207)]()===''){if(_0x444f96[_0x12c8d6(0x1f6)]){_0x1f9899?.[_0x12c8d6(0x202)](_0x12c8d6(0x1fe)+_0x444f96[_0x12c8d6(0x1f6)]);const _0x7ecb73=parseSSEData(_0x444f96['data']);yield _0x7ecb73,_0x444f96={};}continue;}if(_0x24f5b7['startsWith'](':'))continue;const _0x5edb05=_0x24f5b7['indexOf'](':');if(_0x5edb05===-0x1)continue;const _0x5dffa0=_0x24f5b7[_0x12c8d6(0x1ff)](0x0,_0x5edb05);let _0x568b50=_0x24f5b7['slice'](_0x5edb05+0x1);_0x568b50[_0x12c8d6(0x1fd)]('\x20')&&(_0x568b50=_0x568b50['slice'](0x1));switch(_0x5dffa0){case _0x12c8d6(0x1f8):_0x444f96['event']=_0x568b50;break;case _0x12c8d6(0x1f6):_0x444f96[_0x12c8d6(0x1f6)]=_0x444f96[_0x12c8d6(0x1f6)]?_0x444f96[_0x12c8d6(0x1f6)]+'\x0a'+_0x568b50:_0x568b50;break;case'id':_0x444f96['id']=_0x568b50;break;}}}}finally{_0x5b6e43[_0x12c8d6(0x1f5)]();}}function parseSSEData(_0x49bcec){const _0x40b6b3=a111_0x1da6;try{return JSON[_0x40b6b3(0x1f7)](_0x49bcec);}catch(_0x565ca7){throw new Error('Failed\x20to\x20parse\x20SSE\x20data\x20as\x20JSON:\x20'+_0x49bcec,{'cause':_0x565ca7});}}
1
+ (function(_0x512267,_0x164e19){const _0x5d6cdf=a111_0x34bd,_0xfe4bc7=_0x512267();while(!![]){try{const _0x111b61=-parseInt(_0x5d6cdf(0x129))/0x1+-parseInt(_0x5d6cdf(0x131))/0x2+parseInt(_0x5d6cdf(0x12f))/0x3+parseInt(_0x5d6cdf(0x12b))/0x4*(parseInt(_0x5d6cdf(0x12c))/0x5)+-parseInt(_0x5d6cdf(0x137))/0x6+parseInt(_0x5d6cdf(0x139))/0x7*(-parseInt(_0x5d6cdf(0x135))/0x8)+parseInt(_0x5d6cdf(0x133))/0x9;if(_0x111b61===_0x164e19)break;else _0xfe4bc7['push'](_0xfe4bc7['shift']());}catch(_0x3eb39b){_0xfe4bc7['push'](_0xfe4bc7['shift']());}}}(a111_0x4a6e,0xabb0c));export async function*parseSSEStream(_0x3ae79c,_0x5180da){const _0x47a711=a111_0x34bd;if(!_0x3ae79c[_0x47a711(0x136)])throw new Error(_0x47a711(0x12e));const _0x3d77c0=_0x3ae79c[_0x47a711(0x136)]['getReader'](),_0x13f29f=new TextDecoder();let _0x2508c5='',_0xd014b1={};try{while(!![]){const {done:_0x84b023,value:_0x5b2e19}=await _0x3d77c0[_0x47a711(0x13d)]();if(_0x84b023){if(_0xd014b1[_0x47a711(0x132)]){_0x5180da?.['debug'](_0x47a711(0x12d)+_0xd014b1['data']);const _0xd99dc3=parseSSEData(_0xd014b1[_0x47a711(0x132)]);yield _0xd99dc3;}break;}_0x2508c5+=_0x13f29f['decode'](_0x5b2e19,{'stream':!![]});const _0x129bdb=_0x2508c5['split']('\x0a');_0x2508c5=_0x129bdb[_0x47a711(0x13a)]()||'';for(const _0x2f4ce2 of _0x129bdb){if(_0x2f4ce2[_0x47a711(0x13c)]()===''){if(_0xd014b1[_0x47a711(0x132)]){_0x5180da?.[_0x47a711(0x138)](_0x47a711(0x12d)+_0xd014b1[_0x47a711(0x132)]);const _0x561891=parseSSEData(_0xd014b1[_0x47a711(0x132)]);yield _0x561891,_0xd014b1={};}continue;}if(_0x2f4ce2['startsWith'](':'))continue;const _0x5967df=_0x2f4ce2['indexOf'](':');if(_0x5967df===-0x1)continue;const _0x529451=_0x2f4ce2[_0x47a711(0x130)](0x0,_0x5967df);let _0x55b987=_0x2f4ce2[_0x47a711(0x130)](_0x5967df+0x1);_0x55b987['startsWith']('\x20')&&(_0x55b987=_0x55b987['slice'](0x1));switch(_0x529451){case _0x47a711(0x13b):_0xd014b1[_0x47a711(0x13b)]=_0x55b987;break;case'data':_0xd014b1[_0x47a711(0x132)]=_0xd014b1[_0x47a711(0x132)]?_0xd014b1[_0x47a711(0x132)]+'\x0a'+_0x55b987:_0x55b987;break;case'id':_0xd014b1['id']=_0x55b987;break;}}}}finally{_0x3d77c0['releaseLock']();}}function a111_0x34bd(_0x1e09da,_0x1b9f02){_0x1e09da=_0x1e09da-0x129;const _0x4a6ebe=a111_0x4a6e();let _0x34bdd6=_0x4a6ebe[_0x1e09da];return _0x34bdd6;}function parseSSEData(_0x21e188){const _0x920e43=a111_0x34bd;try{return JSON[_0x920e43(0x12a)](_0x21e188);}catch(_0x49d6d0){throw new Error(_0x920e43(0x134)+_0x21e188,{'cause':_0x49d6d0});}}function a111_0x4a6e(){const _0x109f43=['1298976UDoGdP','debug','509817MtxruU','pop','event','trim','read','911258XBaVgt','parse','628EmRNiS','14585POxMPZ','[LLM\x20API\x20SSE]\x20','Response\x20body\x20is\x20null','2049522NolQyI','slice','1237868MleEYr','data','20300328TpZoFT','Failed\x20to\x20parse\x20SSE\x20data\x20as\x20JSON:\x20','104XjmZUY','body'];a111_0x4a6e=function(){return _0x109f43;};return a111_0x4a6e();}
@@ -1 +1 @@
1
- (function(_0x3922f4,_0x2605de){const _0x481fa6=a112_0x2861,_0x3d9d7d=_0x3922f4();while(!![]){try{const _0x413cc3=parseInt(_0x481fa6(0x162))/0x1+-parseInt(_0x481fa6(0x15c))/0x2+-parseInt(_0x481fa6(0x15a))/0x3+-parseInt(_0x481fa6(0x15b))/0x4+parseInt(_0x481fa6(0x152))/0x5*(-parseInt(_0x481fa6(0x167))/0x6)+parseInt(_0x481fa6(0x163))/0x7+parseInt(_0x481fa6(0x161))/0x8;if(_0x413cc3===_0x2605de)break;else _0x3d9d7d['push'](_0x3d9d7d['shift']());}catch(_0x250e2b){_0x3d9d7d['push'](_0x3d9d7d['shift']());}}}(a112_0x403a,0xde887));import a112_0xd115df from'string-width';function a112_0x403a(){const _0x2c992b=['env','680292KfigTY','7146688fUpxut','1026124MBCwik','unknown','test','floor','USER','23890608VnrJWG','511088LLFJEd','8324855SokCMm','toString','length','repeat','12KqAWxr','3121715xoJIZn','replace','Cannot\x20escape\x20empty\x20string\x20literal','slice','padStart','trim','toLowerCase'];a112_0x403a=function(){return _0x2c992b;};return a112_0x403a();}export function stringWidth(_0x51e681){return a112_0xd115df(_0x51e681);}export function padEnd(_0x365e12,_0x169450){const _0x1fcb84=stringWidth(_0x365e12);if(_0x1fcb84>=_0x169450)return _0x365e12;return _0x365e12+'\x20'['repeat'](_0x169450-_0x1fcb84);}export function padStart(_0x147654,_0x318a5c){const _0x2d9f48=a112_0x2861,_0xe1c237=stringWidth(_0x147654);if(_0xe1c237>=_0x318a5c)return _0x147654;return'\x20'[_0x2d9f48(0x166)](_0x318a5c-_0xe1c237)+_0x147654;}export function centerAlign(_0x1128db,_0x30d07c){const _0x18dfa3=a112_0x2861,_0x243d2c=stringWidth(_0x1128db);if(_0x243d2c>_0x30d07c){if(_0x30d07c<=0x1)return'…'['substring'](0x0,_0x30d07c);let _0x589103=_0x1128db;while(stringWidth(_0x589103+'…')>_0x30d07c){_0x589103=_0x589103[_0x18dfa3(0x155)](0x0,-0x1);}return _0x589103+'…';}if(_0x243d2c===_0x30d07c)return _0x1128db;const _0x37a7be=_0x30d07c-_0x243d2c,_0x528b12=Math[_0x18dfa3(0x15f)](_0x37a7be/0x2),_0x316ad6=_0x37a7be-_0x528b12;return'\x20'['repeat'](_0x528b12)+_0x1128db+'\x20'[_0x18dfa3(0x166)](_0x316ad6);}function a112_0x2861(_0x4bfae0,_0x14e3c3){_0x4bfae0=_0x4bfae0-0x152;const _0x403ade=a112_0x403a();let _0x2861ad=_0x403ade[_0x4bfae0];return _0x2861ad;}export function escapeStringLiteral(_0x3ddad5){const _0x41e5ca=a112_0x2861;if(!_0x3ddad5||_0x3ddad5[_0x41e5ca(0x157)]()[_0x41e5ca(0x165)]===0x0)throw new Error(_0x41e5ca(0x154));const _0x471d3d=_0x3ddad5['replace'](/'/g,'\x27\x27');return'\x27'+_0x471d3d+'\x27';}export function globToLike(_0x480791){const _0x124fa1=a112_0x2861;let _0x2a4902=_0x480791['replace'](/\\/g,'\x5c\x5c')[_0x124fa1(0x153)](/%/g,'\x5c%')[_0x124fa1(0x153)](/_/g,'\x5c_');return _0x2a4902=_0x2a4902[_0x124fa1(0x153)](/\*/g,'%')['replace'](/\?/g,'_'),_0x2a4902;}export function buildLikePattern(_0x23ef0b){const _0x5f0ee0=a112_0x2861;if(!_0x23ef0b||_0x23ef0b[_0x5f0ee0(0x157)]()[_0x5f0ee0(0x165)]===0x0)throw new Error('Cannot\x20build\x20LIKE\x20pattern\x20from\x20empty\x20string');const _0x513e0d=globToLike(_0x23ef0b),_0x4f906a=_0x513e0d['replace'](/'/g,'\x27\x27');return'\x27'+_0x4f906a+'\x27';}export function matchGlobPattern(_0x43da95,_0x52f5af){const _0x193444=a112_0x2861,_0x311031=_0x52f5af[_0x193444(0x153)](/[.+^${}()|[\]\\]/g,'\x5c$&')[_0x193444(0x153)](/\*/g,'.*')[_0x193444(0x153)](/\?/g,'.'),_0x3c65d2=new RegExp('^'+_0x311031+'$');return _0x3c65d2[_0x193444(0x15e)](_0x43da95);}export function getSanitizedUsername(){const _0x26435f=a112_0x2861,_0x28621a=process['env'][_0x26435f(0x160)]||process[_0x26435f(0x159)]['USERNAME']||_0x26435f(0x15d);return _0x28621a[_0x26435f(0x153)](/[^a-zA-Z0-9]/g,'')[_0x26435f(0x158)]();}export function generateRandomHex(){const _0x41b1fc=a112_0x2861,_0x484d07=Math['floor'](Math['random']()*0xfffff);return _0x484d07[_0x41b1fc(0x164)](0x10)[_0x41b1fc(0x156)](0x5,'0');}export function sanitizeFileName(_0x3a215b){const _0x56c4e8=a112_0x2861;return _0x3a215b[_0x56c4e8(0x158)]()['replace'](/[/\\:*?"<>|]/g,'-')[_0x56c4e8(0x153)](/\s+/g,'-')[_0x56c4e8(0x153)](/-+/g,'-')[_0x56c4e8(0x153)](/^-|-$/g,'');}
1
+ (function(_0x26e859,_0x6880f7){const _0x263488=a112_0x1ba7,_0xe741d=_0x26e859();while(!![]){try{const _0x1f53da=parseInt(_0x263488(0x10d))/0x1*(-parseInt(_0x263488(0x10e))/0x2)+-parseInt(_0x263488(0x11a))/0x3*(parseInt(_0x263488(0x117))/0x4)+parseInt(_0x263488(0x116))/0x5*(parseInt(_0x263488(0x10c))/0x6)+parseInt(_0x263488(0x110))/0x7+parseInt(_0x263488(0x10a))/0x8+-parseInt(_0x263488(0x109))/0x9*(-parseInt(_0x263488(0x114))/0xa)+-parseInt(_0x263488(0x113))/0xb;if(_0x1f53da===_0x6880f7)break;else _0xe741d['push'](_0xe741d['shift']());}catch(_0x271050){_0xe741d['push'](_0xe741d['shift']());}}}(a112_0x4f14,0x33de8));import a112_0x38be36 from'string-width';export function stringWidth(_0x3b393c){return a112_0x38be36(_0x3b393c);}export function padEnd(_0x3c0c43,_0x1344ec){const _0x29973a=a112_0x1ba7,_0x2e8d91=stringWidth(_0x3c0c43);if(_0x2e8d91>=_0x1344ec)return _0x3c0c43;return _0x3c0c43+'\x20'[_0x29973a(0x11b)](_0x1344ec-_0x2e8d91);}export function padStart(_0x384ec7,_0x47c01c){const _0x5dbbdb=a112_0x1ba7,_0x1e5884=stringWidth(_0x384ec7);if(_0x1e5884>=_0x47c01c)return _0x384ec7;return'\x20'[_0x5dbbdb(0x11b)](_0x47c01c-_0x1e5884)+_0x384ec7;}function a112_0x4f14(){const _0x27ca8b=['4264FJORxS','slice','toString','1173QAUSmY','repeat','unknown','trim','Cannot\x20build\x20LIKE\x20pattern\x20from\x20empty\x20string','replace','substring','toLowerCase','floor','1577196lREFkY','3302952YxDviP','length','165786fhKHUc','373019XlOJfK','2NFmnmD','Cannot\x20escape\x20empty\x20string\x20literal','2866122YinUku','\x5c$&','env','4507173FPziOT','10knYEAi','USERNAME','75srrBfg'];a112_0x4f14=function(){return _0x27ca8b;};return a112_0x4f14();}export function centerAlign(_0x294a5a,_0xee0040){const _0xdc1046=a112_0x1ba7,_0x2e6eea=stringWidth(_0x294a5a);if(_0x2e6eea>_0xee0040){if(_0xee0040<=0x1)return'…'[_0xdc1046(0x106)](0x0,_0xee0040);let _0x1d3e07=_0x294a5a;while(stringWidth(_0x1d3e07+'…')>_0xee0040){_0x1d3e07=_0x1d3e07[_0xdc1046(0x118)](0x0,-0x1);}return _0x1d3e07+'…';}if(_0x2e6eea===_0xee0040)return _0x294a5a;const _0x44ec9a=_0xee0040-_0x2e6eea,_0x1fb271=Math[_0xdc1046(0x108)](_0x44ec9a/0x2),_0x25e115=_0x44ec9a-_0x1fb271;return'\x20'[_0xdc1046(0x11b)](_0x1fb271)+_0x294a5a+'\x20'['repeat'](_0x25e115);}export function escapeStringLiteral(_0x559f9c){const _0x3c3c63=a112_0x1ba7;if(!_0x559f9c||_0x559f9c['trim']()[_0x3c3c63(0x10b)]===0x0)throw new Error(_0x3c3c63(0x10f));const _0x168fce=_0x559f9c[_0x3c3c63(0x11f)](/'/g,'\x27\x27');return'\x27'+_0x168fce+'\x27';}export function globToLike(_0x484947){const _0x5cc079=a112_0x1ba7;let _0x40cb9f=_0x484947[_0x5cc079(0x11f)](/\\/g,'\x5c\x5c')[_0x5cc079(0x11f)](/%/g,'\x5c%')['replace'](/_/g,'\x5c_');return _0x40cb9f=_0x40cb9f['replace'](/\*/g,'%')[_0x5cc079(0x11f)](/\?/g,'_'),_0x40cb9f;}export function buildLikePattern(_0x25e836){const _0x589aa5=a112_0x1ba7;if(!_0x25e836||_0x25e836[_0x589aa5(0x11d)]()[_0x589aa5(0x10b)]===0x0)throw new Error(_0x589aa5(0x11e));const _0x330ba8=globToLike(_0x25e836),_0x59a6ed=_0x330ba8[_0x589aa5(0x11f)](/'/g,'\x27\x27');return'\x27'+_0x59a6ed+'\x27';}export function matchGlobPattern(_0x21152a,_0x4f316f){const _0x3be881=a112_0x1ba7,_0xb21d6b=_0x4f316f[_0x3be881(0x11f)](/[.+^${}()|[\]\\]/g,_0x3be881(0x111))[_0x3be881(0x11f)](/\*/g,'.*')[_0x3be881(0x11f)](/\?/g,'.'),_0x358af0=new RegExp('^'+_0xb21d6b+'$');return _0x358af0['test'](_0x21152a);}function a112_0x1ba7(_0x251a92,_0x205256){_0x251a92=_0x251a92-0x106;const _0x4f14bf=a112_0x4f14();let _0x1ba7cf=_0x4f14bf[_0x251a92];return _0x1ba7cf;}export function getSanitizedUsername(){const _0x8776d2=a112_0x1ba7,_0x6501fb=process['env']['USER']||process[_0x8776d2(0x112)][_0x8776d2(0x115)]||_0x8776d2(0x11c);return _0x6501fb[_0x8776d2(0x11f)](/[^a-zA-Z0-9]/g,'')[_0x8776d2(0x107)]();}export function generateRandomHex(){const _0x4994ac=a112_0x1ba7,_0x258045=Math[_0x4994ac(0x108)](Math['random']()*0xfffff);return _0x258045[_0x4994ac(0x119)](0x10)['padStart'](0x5,'0');}export function sanitizeFileName(_0x5596b9){const _0x32a495=a112_0x1ba7;return _0x5596b9[_0x32a495(0x107)]()[_0x32a495(0x11f)](/[/\\:*?"<>|]/g,'-')['replace'](/\s+/g,'-')[_0x32a495(0x11f)](/-+/g,'-')[_0x32a495(0x11f)](/^-|-$/g,'');}
@@ -1 +1 @@
1
- (function(_0x267dd8,_0x5dff5d){const _0x431086=a113_0x5277,_0x2972e2=_0x267dd8();while(!![]){try{const _0x380180=-parseInt(_0x431086(0x1cb))/0x1*(parseInt(_0x431086(0x1c4))/0x2)+-parseInt(_0x431086(0x1c0))/0x3*(parseInt(_0x431086(0x1ba))/0x4)+-parseInt(_0x431086(0x1c9))/0x5+-parseInt(_0x431086(0x1b4))/0x6+parseInt(_0x431086(0x1c3))/0x7*(-parseInt(_0x431086(0x1b8))/0x8)+-parseInt(_0x431086(0x1c1))/0x9*(parseInt(_0x431086(0x1bb))/0xa)+parseInt(_0x431086(0x1be))/0xb;if(_0x380180===_0x5dff5d)break;else _0x2972e2['push'](_0x2972e2['shift']());}catch(_0x1a3e89){_0x2972e2['push'](_0x2972e2['shift']());}}}(a113_0x241c,0xbdde2));function hasWildcard(_0x477c35){const _0x1b17ad=a113_0x5277;return _0x477c35[_0x1b17ad(0x1b9)]('*')||_0x477c35[_0x1b17ad(0x1b9)]('?');}function a113_0x5277(_0x29f209,_0x43b7af){_0x29f209=_0x29f209-0x1b3;const _0x241cfe=a113_0x241c();let _0x5277a9=_0x241cfe[_0x29f209];return _0x5277a9;}export function parseTableReference(_0x3393c6){const _0x21dfbf=a113_0x5277;if(!_0x3393c6||_0x3393c6[_0x21dfbf(0x1c8)]()[_0x21dfbf(0x1c7)]===0x0)throw new Error(_0x21dfbf(0x1b3));const _0x53ec5f=_0x3393c6[_0x21dfbf(0x1c8)](),_0x35d424={'original':_0x53ec5f},_0x37e770=_0x53ec5f[_0x21dfbf(0x1b5)]('.');if(_0x37e770[_0x21dfbf(0x1c7)]===0x1){const _0x5bda9c=_0x37e770[0x0];if(!_0x5bda9c)throw new Error(_0x21dfbf(0x1bd));_0x35d424['table']=_0x5bda9c;}else{if(_0x37e770[_0x21dfbf(0x1c7)]===0x2){const [_0x453b57,_0x2ba61a]=_0x37e770;if(!_0x453b57)throw new Error(_0x21dfbf(0x1c2));if(!_0x2ba61a)throw new Error(_0x21dfbf(0x1bf));_0x35d424[_0x21dfbf(0x1ca)]=_0x453b57,_0x35d424[_0x21dfbf(0x1b6)]=_0x2ba61a;}else{if(_0x37e770['length']===0x3){const [_0x3bdd72,_0x2f03b7,_0x1e830f]=_0x37e770;if(!_0x3bdd72||!_0x2f03b7||!_0x1e830f)throw new Error('Invalid\x20catalog.database.table\x20format\x20-\x20all\x20parts\x20must\x20be\x20non-empty');_0x35d424[_0x21dfbf(0x1b7)]=_0x3bdd72,_0x35d424['database']=_0x2f03b7,_0x35d424[_0x21dfbf(0x1b6)]=_0x1e830f;}else throw new Error(_0x21dfbf(0x1cc));}}return _0x35d424;}export function formatTableReference(_0x58fff4){const _0x123356=a113_0x5277,_0x2df2d1=[];return _0x58fff4[_0x123356(0x1b7)]&&_0x2df2d1[_0x123356(0x1c6)](_0x58fff4[_0x123356(0x1b7)]),_0x58fff4[_0x123356(0x1ca)]&&_0x2df2d1[_0x123356(0x1c6)](_0x58fff4['database']),_0x58fff4[_0x123356(0x1b6)]&&_0x2df2d1['push'](_0x58fff4[_0x123356(0x1b6)]),_0x2df2d1['join']('.');}function a113_0x241c(){const _0x1c3361=['Pattern\x20cannot\x20be\x20empty\x20or\x20whitespace-only','2546280ArBhrj','split','table','catalog','144paLayY','includes','42188iJxqQu','10240750yRjbIC','Wildcards\x20are\x20not\x20allowed\x20in\x20table\x20name\x20for\x20describe\x20operation','Pattern\x20cannot\x20be\x20just\x20a\x20dot','45918191MYcYLR','Table\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20tables\x20(e.g.,\x20\x22mydb.*\x22)','45zucAHk','9UZRuqJ','Database\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20databases\x20(e.g.,\x20\x22*.mytable\x22)','317142sLuuUJ','4GQexcb','Wildcards\x20are\x20not\x20allowed\x20in\x20database\x20name\x20for\x20describe\x20operation','push','length','trim','3438385GjTFQT','database','143419tYgGPt','Invalid\x20pattern\x20format\x20-\x20too\x20many\x20dots\x20(max:\x20catalog.database.table)'];a113_0x241c=function(){return _0x1c3361;};return a113_0x241c();}export function validateTableListReference(_0x35fc4c){return undefined;}export function validateTableDescribeReference(_0xa4da73){const _0x5ee646=a113_0x5277;if(!_0xa4da73[_0x5ee646(0x1b6)])return'Table\x20name\x20is\x20required\x20for\x20describe\x20operation';if(_0xa4da73['database']&&hasWildcard(_0xa4da73[_0x5ee646(0x1ca)]))return _0x5ee646(0x1c5);if(hasWildcard(_0xa4da73[_0x5ee646(0x1b6)]))return _0x5ee646(0x1bc);return undefined;}
1
+ function a113_0x2ca9(){const _0x20adc2=['includes','8BjAJow','Table\x20name\x20is\x20required\x20for\x20describe\x20operation','push','Pattern\x20cannot\x20be\x20just\x20a\x20dot','table','database','3958934QvHFJa','Invalid\x20pattern\x20format\x20-\x20too\x20many\x20dots\x20(max:\x20catalog.database.table)','58EPmKXj','Table\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20tables\x20(e.g.,\x20\x22mydb.*\x22)','40938IZsfUi','length','Wildcards\x20are\x20not\x20allowed\x20in\x20database\x20name\x20for\x20describe\x20operation','30IgulON','1106442ceJbMG','8313206GLnmDG','10135JAEbjh','catalog','1503576ecjhvU','split','445MOkuqN','Invalid\x20catalog.database.table\x20format\x20-\x20all\x20parts\x20must\x20be\x20non-empty','Wildcards\x20are\x20not\x20allowed\x20in\x20table\x20name\x20for\x20describe\x20operation','1003944WiiLKX','trim','Pattern\x20cannot\x20be\x20empty\x20or\x20whitespace-only'];a113_0x2ca9=function(){return _0x20adc2;};return a113_0x2ca9();}(function(_0x7b29c4,_0x276e21){const _0x3b1056=a113_0x3ef1,_0x1580d0=_0x7b29c4();while(!![]){try{const _0x390392=parseInt(_0x3b1056(0x135))/0x1*(-parseInt(_0x3b1056(0x148))/0x2)+parseInt(_0x3b1056(0x137))/0x3+parseInt(_0x3b1056(0x13c))/0x4+-parseInt(_0x3b1056(0x139))/0x5*(-parseInt(_0x3b1056(0x12f))/0x6)+parseInt(_0x3b1056(0x146))/0x7*(parseInt(_0x3b1056(0x140))/0x8)+parseInt(_0x3b1056(0x133))/0x9*(-parseInt(_0x3b1056(0x132))/0xa)+-parseInt(_0x3b1056(0x134))/0xb;if(_0x390392===_0x276e21)break;else _0x1580d0['push'](_0x1580d0['shift']());}catch(_0x4a48aa){_0x1580d0['push'](_0x1580d0['shift']());}}}(a113_0x2ca9,0x7ba90));function hasWildcard(_0x3e7097){const _0x55ed19=a113_0x3ef1;return _0x3e7097['includes']('*')||_0x3e7097[_0x55ed19(0x13f)]('?');}export function parseTableReference(_0x14733b){const _0x13cc7e=a113_0x3ef1;if(!_0x14733b||_0x14733b[_0x13cc7e(0x13d)]()[_0x13cc7e(0x130)]===0x0)throw new Error(_0x13cc7e(0x13e));const _0x8ba33e=_0x14733b[_0x13cc7e(0x13d)](),_0x162245={'original':_0x8ba33e},_0x2b530d=_0x8ba33e[_0x13cc7e(0x138)]('.');if(_0x2b530d['length']===0x1){const _0x303cf4=_0x2b530d[0x0];if(!_0x303cf4)throw new Error(_0x13cc7e(0x143));_0x162245[_0x13cc7e(0x144)]=_0x303cf4;}else{if(_0x2b530d[_0x13cc7e(0x130)]===0x2){const [_0x41cf0a,_0x3553eb]=_0x2b530d;if(!_0x41cf0a)throw new Error('Database\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20databases\x20(e.g.,\x20\x22*.mytable\x22)');if(!_0x3553eb)throw new Error(_0x13cc7e(0x149));_0x162245[_0x13cc7e(0x145)]=_0x41cf0a,_0x162245['table']=_0x3553eb;}else{if(_0x2b530d['length']===0x3){const [_0x15e902,_0x128168,_0x2ef5c0]=_0x2b530d;if(!_0x15e902||!_0x128168||!_0x2ef5c0)throw new Error(_0x13cc7e(0x13a));_0x162245[_0x13cc7e(0x136)]=_0x15e902,_0x162245['database']=_0x128168,_0x162245[_0x13cc7e(0x144)]=_0x2ef5c0;}else throw new Error(_0x13cc7e(0x147));}}return _0x162245;}export function formatTableReference(_0x488420){const _0x239565=a113_0x3ef1,_0x276b25=[];return _0x488420['catalog']&&_0x276b25[_0x239565(0x142)](_0x488420[_0x239565(0x136)]),_0x488420[_0x239565(0x145)]&&_0x276b25[_0x239565(0x142)](_0x488420['database']),_0x488420[_0x239565(0x144)]&&_0x276b25[_0x239565(0x142)](_0x488420[_0x239565(0x144)]),_0x276b25['join']('.');}function a113_0x3ef1(_0x413260,_0x1ba553){_0x413260=_0x413260-0x12f;const _0x2ca9e8=a113_0x2ca9();let _0x3ef1da=_0x2ca9e8[_0x413260];return _0x3ef1da;}export function validateTableListReference(_0x233088){return undefined;}export function validateTableDescribeReference(_0x10a5bd){const _0x58b50b=a113_0x3ef1;if(!_0x10a5bd[_0x58b50b(0x144)])return _0x58b50b(0x141);if(_0x10a5bd[_0x58b50b(0x145)]&&hasWildcard(_0x10a5bd[_0x58b50b(0x145)]))return _0x58b50b(0x131);if(hasWildcard(_0x10a5bd[_0x58b50b(0x144)]))return _0x58b50b(0x13b);return undefined;}
@@ -1 +1 @@
1
- const a114_0x59e712=a114_0x1a11;(function(_0x2b5f4a,_0x4e7d8b){const _0x59994f=a114_0x1a11,_0x17ae88=_0x2b5f4a();while(!![]){try{const _0x107ebc=-parseInt(_0x59994f(0x1ec))/0x1*(parseInt(_0x59994f(0x1fc))/0x2)+-parseInt(_0x59994f(0x204))/0x3*(parseInt(_0x59994f(0x1ed))/0x4)+-parseInt(_0x59994f(0x1f8))/0x5+-parseInt(_0x59994f(0x203))/0x6*(parseInt(_0x59994f(0x1fd))/0x7)+-parseInt(_0x59994f(0x1f4))/0x8+parseInt(_0x59994f(0x1f9))/0x9+-parseInt(_0x59994f(0x200))/0xa*(-parseInt(_0x59994f(0x1fe))/0xb);if(_0x107ebc===_0x4e7d8b)break;else _0x17ae88['push'](_0x17ae88['shift']());}catch(_0x1cea56){_0x17ae88['push'](_0x17ae88['shift']());}}}(a114_0x2578,0x3966e));import{existsSync,readFileSync}from'fs';import a114_0x26bd6d from'path';const TDX_CONFIG_FILE=a114_0x59e712(0x1fa),SEGMENTS_DIR='segments';export function findTdxConfigPath(_0x5b94e7=process[a114_0x59e712(0x1f0)]()){const _0x10136c=a114_0x59e712;let _0x3228b2=a114_0x26bd6d[_0x10136c(0x1f2)](_0x5b94e7);const _0x14f90e=a114_0x26bd6d['parse'](_0x3228b2)['root'];while(_0x3228b2!==_0x14f90e){const _0x468b85=a114_0x26bd6d[_0x10136c(0x1f5)](_0x3228b2,TDX_CONFIG_FILE);if(existsSync(_0x468b85))return _0x468b85;_0x3228b2=a114_0x26bd6d['dirname'](_0x3228b2);}return null;}export function loadTdxConfig(_0x3c2bd7){const _0x102808=a114_0x59e712,_0x4c05a0=readFileSync(_0x3c2bd7,'utf-8');let _0x15b767;try{_0x15b767=JSON[_0x102808(0x1f7)](_0x4c05a0);}catch{throw new Error(_0x102808(0x202)+_0x3c2bd7);}if(!_0x15b767||typeof _0x15b767!=='object')throw new Error(_0x102808(0x201));const _0x2819c6=_0x15b767;if(!_0x2819c6[_0x102808(0x1fb)]||typeof _0x2819c6['parent_segment']!=='string')throw new Error(_0x102808(0x1ee));return{'parent_segment':_0x2819c6[_0x102808(0x1fb)]};}function a114_0x1a11(_0x5dac86,_0x1bea42){_0x5dac86=_0x5dac86-0x1ec;const _0x25784b=a114_0x2578();let _0x1a1171=_0x25784b[_0x5dac86];return _0x1a1171;}function a114_0x2578(){const _0x538ea0=['1892210yOvnzU','2412225XJHCPK','tdx.json','parent_segment','2tKREmq','7QTTAgm','253JMWXXE','No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.','523870oekLxd','Invalid\x20tdx.json:\x20expected\x20object','Invalid\x20JSON\x20in\x20','2577006jEdgaX','3681zwVyce','34513nCUSrD','316RxUNWy','Invalid\x20tdx.json:\x20missing\x20or\x20invalid\x20\x27parent_segment\x27\x20field','relative','cwd','dirname','resolve','stringify','2387352dGlSUD','join','replace','parse'];a114_0x2578=function(){return _0x538ea0;};return a114_0x2578();}export function findTdxConfig(_0x2a6c9c=process[a114_0x59e712(0x1f0)]()){const _0x59b9f4=a114_0x59e712,_0x36c4fd=findTdxConfigPath(_0x2a6c9c);if(!_0x36c4fd)throw new Error(_0x59b9f4(0x1ff));const _0x1b395a=loadTdxConfig(_0x36c4fd),_0x56d189=a114_0x26bd6d[_0x59b9f4(0x1f1)](_0x36c4fd);return{'config':_0x1b395a,'configPath':_0x36c4fd,'configDir':_0x56d189};}export function getSegmentRootDir(_0x5abb05,_0x2deb0c=process['cwd']()){const _0x2ef477=a114_0x59e712;return a114_0x26bd6d[_0x2ef477(0x1f5)](_0x2deb0c,SEGMENTS_DIR,_0x5abb05);}export function getTdxConfigPath(_0x487127,_0x1e780d=process[a114_0x59e712(0x1f0)]()){return a114_0x26bd6d['join'](getSegmentRootDir(_0x487127,_0x1e780d),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0x1ede89,_0xf08ff){const _0x5422ff=a114_0x59e712,_0x27ba76=a114_0x26bd6d[_0x5422ff(0x1f2)](_0x1ede89),_0x204681=a114_0x26bd6d[_0x5422ff(0x1ef)](_0xf08ff,_0x27ba76);if(_0x204681['startsWith']('..'))return'';return _0x204681;}export function localPathToTdFolderPath(_0x481729){const _0x3c2964=a114_0x59e712,_0x217f26=a114_0x26bd6d[_0x3c2964(0x1f1)](_0x481729);if(_0x217f26==='.'||_0x217f26==='')return'';return _0x217f26[_0x3c2964(0x1f6)](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x3fa4cb,_0x3aa593){const _0x373718=a114_0x59e712;if(!_0x3fa4cb)return _0x3aa593;return a114_0x26bd6d[_0x373718(0x1f5)](_0x3aa593,_0x3fa4cb);}export function createTdxConfigContent(_0x10c6a7){const _0x4af6f9=a114_0x59e712,_0x1ba877={'parent_segment':_0x10c6a7};return JSON[_0x4af6f9(0x1f3)](_0x1ba877,null,0x2)+'\x0a';}
1
+ const a114_0x254218=a114_0x3dc8;(function(_0x241fef,_0x217cfc){const _0x45168d=a114_0x3dc8,_0x465d07=_0x241fef();while(!![]){try{const _0x20ecd3=-parseInt(_0x45168d(0x18d))/0x1*(parseInt(_0x45168d(0x18b))/0x2)+-parseInt(_0x45168d(0x193))/0x3+-parseInt(_0x45168d(0x1a3))/0x4+-parseInt(_0x45168d(0x19d))/0x5*(parseInt(_0x45168d(0x1a0))/0x6)+parseInt(_0x45168d(0x1a5))/0x7*(parseInt(_0x45168d(0x19b))/0x8)+parseInt(_0x45168d(0x190))/0x9+parseInt(_0x45168d(0x199))/0xa*(-parseInt(_0x45168d(0x191))/0xb);if(_0x20ecd3===_0x217cfc)break;else _0x465d07['push'](_0x465d07['shift']());}catch(_0x43eaab){_0x465d07['push'](_0x465d07['shift']());}}}(a114_0x4fa5,0x9b671));import{existsSync,readFileSync}from'fs';import a114_0x4d9d00 from'path';const TDX_CONFIG_FILE=a114_0x254218(0x19c),SEGMENTS_DIR='segments';export function findTdxConfigPath(_0x2f44ed=process[a114_0x254218(0x196)]()){const _0xbe8a36=a114_0x254218;let _0x53c2d1=a114_0x4d9d00['resolve'](_0x2f44ed);const _0x1c66b8=a114_0x4d9d00[_0xbe8a36(0x1a4)](_0x53c2d1)[_0xbe8a36(0x195)];while(_0x53c2d1!==_0x1c66b8){const _0x211190=a114_0x4d9d00[_0xbe8a36(0x198)](_0x53c2d1,TDX_CONFIG_FILE);if(existsSync(_0x211190))return _0x211190;_0x53c2d1=a114_0x4d9d00[_0xbe8a36(0x197)](_0x53c2d1);}return null;}export function loadTdxConfig(_0x42548e){const _0x4e2cd6=a114_0x254218,_0x5baefd=readFileSync(_0x42548e,_0x4e2cd6(0x18e));let _0x5d1aea;try{_0x5d1aea=JSON[_0x4e2cd6(0x1a4)](_0x5baefd);}catch{throw new Error(_0x4e2cd6(0x19f)+_0x42548e);}if(!_0x5d1aea||typeof _0x5d1aea!==_0x4e2cd6(0x1a2))throw new Error(_0x4e2cd6(0x18c));const _0x4ac019=_0x5d1aea;if(!_0x4ac019[_0x4e2cd6(0x19e)]||typeof _0x4ac019[_0x4e2cd6(0x19e)]!=='string')throw new Error(_0x4e2cd6(0x1a1));return{'parent_segment':_0x4ac019[_0x4e2cd6(0x19e)]};}export function findTdxConfig(_0xd9b5f0=process[a114_0x254218(0x196)]()){const _0x49e3d4=a114_0x254218,_0x17b6eb=findTdxConfigPath(_0xd9b5f0);if(!_0x17b6eb)throw new Error(_0x49e3d4(0x18f));const _0x45f690=loadTdxConfig(_0x17b6eb),_0x2e3530=a114_0x4d9d00[_0x49e3d4(0x197)](_0x17b6eb);return{'config':_0x45f690,'configPath':_0x17b6eb,'configDir':_0x2e3530};}export function getSegmentRootDir(_0x42d93f,_0x17dd36=process[a114_0x254218(0x196)]()){const _0x41c169=a114_0x254218;return a114_0x4d9d00[_0x41c169(0x198)](_0x17dd36,SEGMENTS_DIR,_0x42d93f);}function a114_0x3dc8(_0x40073e,_0x2a3fce){_0x40073e=_0x40073e-0x18b;const _0x4fa56a=a114_0x4fa5();let _0x3dc89d=_0x4fa56a[_0x40073e];return _0x3dc89d;}export function getTdxConfigPath(_0x329b18,_0x41fba2=process[a114_0x254218(0x196)]()){return a114_0x4d9d00['join'](getSegmentRootDir(_0x329b18,_0x41fba2),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0x17da5f,_0x18f6cb){const _0x491be7=a114_0x254218,_0x2922dc=a114_0x4d9d00[_0x491be7(0x192)](_0x17da5f),_0x5556e5=a114_0x4d9d00[_0x491be7(0x19a)](_0x18f6cb,_0x2922dc);if(_0x5556e5['startsWith']('..'))return'';return _0x5556e5;}export function localPathToTdFolderPath(_0x7028db){const _0x4243cc=a114_0x254218,_0x27c528=a114_0x4d9d00[_0x4243cc(0x197)](_0x7028db);if(_0x27c528==='.'||_0x27c528==='')return'';return _0x27c528[_0x4243cc(0x194)](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x3fb7d8,_0x3787c4){const _0x3c3029=a114_0x254218;if(!_0x3fb7d8)return _0x3787c4;return a114_0x4d9d00[_0x3c3029(0x198)](_0x3787c4,_0x3fb7d8);}export function createTdxConfigContent(_0x56cf7c){const _0x518476={'parent_segment':_0x56cf7c};return JSON['stringify'](_0x518476,null,0x2)+'\x0a';}function a114_0x4fa5(){const _0x34077d=['10381131gmTlEO','11XHAcQo','resolve','1100124MARKOG','replace','root','cwd','dirname','join','1566520PptYsP','relative','10067592JfphDl','tdx.json','5OovoWu','parent_segment','Invalid\x20JSON\x20in\x20','3969558Hjgaxn','Invalid\x20tdx.json:\x20missing\x20or\x20invalid\x20\x27parent_segment\x27\x20field','object','2129028CSNEIY','parse','7wGGyzd','116338wXrMKs','Invalid\x20tdx.json:\x20expected\x20object','1tBIobX','utf-8','No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.'];a114_0x4fa5=function(){return _0x34077d;};return a114_0x4fa5();}
@@ -1 +1 @@
1
- const a115_0x4b917e=a115_0x56eb;(function(_0x24db13,_0x38a0d8){const _0xc8c239=a115_0x56eb,_0xb725c3=_0x24db13();while(!![]){try{const _0xc6aa60=parseInt(_0xc8c239(0xca))/0x1*(-parseInt(_0xc8c239(0xde))/0x2)+-parseInt(_0xc8c239(0xc2))/0x3+-parseInt(_0xc8c239(0xcb))/0x4+parseInt(_0xc8c239(0xc8))/0x5+parseInt(_0xc8c239(0xb3))/0x6*(parseInt(_0xc8c239(0xcc))/0x7)+parseInt(_0xc8c239(0xbe))/0x8+parseInt(_0xc8c239(0xb4))/0x9;if(_0xc6aa60===_0x38a0d8)break;else _0xb725c3['push'](_0xb725c3['shift']());}catch(_0x125b7d){_0xb725c3['push'](_0xb725c3['shift']());}}}(a115_0xd925,0xbd1f3));import{createWriteStream,createReadStream}from'fs';import{mkdir,readdir,unlink,stat,rename}from'fs/promises';import{join}from'path';import{homedir}from'os';import{createGzip}from'zlib';import{pipeline}from'stream/promises';import a115_0x3bb11b from'chalk';function safeStringify(_0x23db2c){const _0x196349=a115_0x56eb;if(typeof _0x23db2c===_0x196349(0xe6))return _0x23db2c;if(_0x23db2c instanceof Error)return _0x23db2c[_0x196349(0xdb)]||_0x23db2c[_0x196349(0xd8)]+':\x20'+_0x23db2c[_0x196349(0xd4)];try{return JSON[_0x196349(0xb5)](_0x23db2c,(_0x5be9b4,_0x4771b9)=>{const _0x5db1a0=_0x196349;if(_0x4771b9 instanceof Error)return{'name':_0x4771b9[_0x5db1a0(0xd8)],'message':_0x4771b9[_0x5db1a0(0xd4)],'stack':_0x4771b9[_0x5db1a0(0xdb)],'cause':_0x4771b9[_0x5db1a0(0xb2)]};return _0x4771b9;});}catch{return String(_0x23db2c);}}function getTimezoneOffset(){const _0x9208f4=a115_0x56eb,_0x3e3cbc=-new Date()['getTimezoneOffset'](),_0xfdaf72=Math[_0x9208f4(0xbf)](Math[_0x9208f4(0xc6)](_0x3e3cbc)/0x3c),_0x4c4c5e=Math[_0x9208f4(0xc6)](_0x3e3cbc)%0x3c,_0x46eaf4=_0x3e3cbc>=0x0?'+':'-';return''+_0x46eaf4+_0xfdaf72['toString']()[_0x9208f4(0xb0)](0x2,'0')+_0x4c4c5e[_0x9208f4(0xe5)]()['padStart'](0x2,'0');}function formatTimestamp(){const _0x3981f9=a115_0x56eb,_0x472fe0=new Date(),_0x318ca9=_0x472fe0['getFullYear'](),_0xcf66a=(_0x472fe0['getMonth']()+0x1)[_0x3981f9(0xe5)]()[_0x3981f9(0xb0)](0x2,'0'),_0xf90144=_0x472fe0[_0x3981f9(0xd2)]()[_0x3981f9(0xe5)]()[_0x3981f9(0xb0)](0x2,'0'),_0x12b3cf=_0x472fe0['getHours']()[_0x3981f9(0xe5)]()[_0x3981f9(0xb0)](0x2,'0'),_0x33f3a2=_0x472fe0[_0x3981f9(0xe3)]()[_0x3981f9(0xe5)]()['padStart'](0x2,'0'),_0x52aca2=_0x472fe0[_0x3981f9(0xd5)]()['toString']()[_0x3981f9(0xb0)](0x2,'0'),_0x356064=_0x472fe0['getMilliseconds']()['toString']()[_0x3981f9(0xb0)](0x3,'0'),_0x30bcc0=getTimezoneOffset();return _0x318ca9+'-'+_0xcf66a+'-'+_0xf90144+'\x20'+_0x12b3cf+':'+_0x33f3a2+':'+_0x52aca2+'.'+_0x356064+_0x30bcc0;}function formatColoredLogEntry(_0x376283,_0xcb766c){const _0x5ae15e=a115_0x56eb,_0x75bb52=formatTimestamp(),_0x33c780=_0xcb766c['map'](safeStringify)[_0x5ae15e(0xda)]('\x20'),_0x4383b3=a115_0x3bb11b[_0x5ae15e(0xc3)](_0x75bb52);let _0x2a8352;switch(_0x376283){case _0x5ae15e(0xce):_0x2a8352=a115_0x3bb11b[_0x5ae15e(0xc1)]('['+_0x376283+']\x20');break;case _0x5ae15e(0xe2):_0x2a8352=a115_0x3bb11b['yellow']('['+_0x376283+']\x20');break;case'error':_0x2a8352=a115_0x3bb11b[_0x5ae15e(0xdd)]('['+_0x376283+']');break;case _0x5ae15e(0xb7):_0x2a8352=a115_0x3bb11b['gray']('['+_0x376283+']');break;default:_0x2a8352='['+_0x376283+']';}return _0x4383b3+'\x20'+_0x2a8352+'\x20'+_0x33c780;}function a115_0x56eb(_0x5ba664,_0x12ced4){_0x5ba664=_0x5ba664-0xaf;const _0xd925ac=a115_0xd925();let _0x56ebb6=_0xd925ac[_0x5ba664];return _0x56ebb6;}export var LogLevel;(function(_0x4b77e5){const _0x5b32cd=a115_0x56eb;_0x4b77e5[_0x4b77e5[_0x5b32cd(0xbc)]=-0x2]=_0x5b32cd(0xbc),_0x4b77e5[_0x4b77e5[_0x5b32cd(0xe0)]=-0x1]=_0x5b32cd(0xe0),_0x4b77e5[_0x4b77e5[_0x5b32cd(0xd7)]=0x0]=_0x5b32cd(0xd7),_0x4b77e5[_0x4b77e5['WARN']=0x1]='WARN',_0x4b77e5[_0x4b77e5[_0x5b32cd(0xe9)]=0x2]=_0x5b32cd(0xe9);}(LogLevel||(LogLevel={})));function a115_0xd925(){const _0x235828=['getDate','includes','message','getSeconds','logDir','INFO','name','write','join','stack','Warning:\x20Failed\x20to\x20compress\x20','red','2EEQYvA','logLevel','DEBUG','WARN','warn','getMinutes','error','toString','string','.cache','tdx.log','ERROR','close','.gz','padStart','logStream','cause','168vEPUTX','6769071oqbNgT','stringify','Proxy\x20session\x20ended','debug','mtime','logs','rotateOldLogs','test','TRACE','end','3142064OJwAcH','floor','tdx','cyan','1082673NdWvel','gray','fileOnly','log','abs','filter','579270Upjwii','trace','981818mQVamE','2597100GiFCuS','376474kYfpLC','Warning:\x20Failed\x20to\x20initialize\x20log\x20files:','info','getLogPath','split','toISOString'];a115_0xd925=function(){return _0x235828;};return a115_0xd925();}export class TDXLogger{[a115_0x4b917e(0xb1)];[a115_0x4b917e(0xd6)];[a115_0x4b917e(0xdf)];[a115_0x4b917e(0xc4)];constructor(_0x417a23=LogLevel[a115_0x4b917e(0xd7)],_0xdb662c=![]){const _0x327412=a115_0x4b917e;this[_0x327412(0xd6)]=join(homedir(),_0x327412(0xe7),_0x327412(0xc0),_0x327412(0xb9)),this[_0x327412(0xdf)]=_0x417a23,this[_0x327412(0xc4)]=_0xdb662c;}async['init'](){const _0x56be8c=a115_0x4b917e;try{await mkdir(this[_0x56be8c(0xd6)],{'recursive':!![]}),await this[_0x56be8c(0xba)]();const _0x5d704d=join(this['logDir'],_0x56be8c(0xe8));this[_0x56be8c(0xb1)]=createWriteStream(_0x5d704d,{'flags':'a'}),this[_0x56be8c(0xb1)]['on']('error',_0x240d44=>{const _0x3d859e=_0x56be8c;console['error']('Warning:\x20Error\x20writing\x20to\x20tdx.log:',_0x240d44[_0x3d859e(0xd4)]);});}catch(_0x390196){console[_0x56be8c(0xe4)](_0x56be8c(0xcd),_0x390196);}}async[a115_0x4b917e(0xba)](){const _0x55ce19=a115_0x4b917e;try{const _0x18a987=await readdir(this[_0x55ce19(0xd6)]),_0x49addc=new Date()[_0x55ce19(0xd1)]()[_0x55ce19(0xd0)]('T')[0x0];if(_0x18a987[_0x55ce19(0xd3)](_0x55ce19(0xe8))){const _0xccc5d4=join(this[_0x55ce19(0xd6)],_0x55ce19(0xe8)),_0x268a2f=await stat(_0xccc5d4),_0x3c542f=new Date(_0x268a2f[_0x55ce19(0xb8)])[_0x55ce19(0xd1)]()['split']('T')[0x0];if(_0x3c542f<_0x49addc){const _0x15d9c6=join(this['logDir'],'tdx-'+_0x3c542f+'.log');await rename(_0xccc5d4,_0x15d9c6);}}const _0x564528=await readdir(this[_0x55ce19(0xd6)]),_0x2caa9b=/^tdx-(\d{4}-\d{2}-\d{2})\.log$/,_0x48b2d5=_0x564528[_0x55ce19(0xc7)](_0x50bb9f=>_0x2caa9b[_0x55ce19(0xbb)](_0x50bb9f));for(const _0x5392bb of _0x48b2d5){const _0x37732e=join(this[_0x55ce19(0xd6)],_0x5392bb),_0x272890=join(this[_0x55ce19(0xd6)],_0x5392bb+_0x55ce19(0xaf));try{await pipeline(createReadStream(_0x37732e),createGzip(),createWriteStream(_0x272890)),await unlink(_0x37732e);}catch(_0xc82771){console[_0x55ce19(0xe4)](_0x55ce19(0xdc)+_0x5392bb+':',_0xc82771);}}}catch{}}[a115_0x4b917e(0xb7)](..._0x22fa84){const _0x5b6b32=a115_0x4b917e;if(this['logLevel']>LogLevel[_0x5b6b32(0xe0)])return;const _0x8fd425=formatColoredLogEntry(_0x5b6b32(0xb7),_0x22fa84);this['logStream']?.[_0x5b6b32(0xd9)](_0x8fd425+'\x0a');}[a115_0x4b917e(0xc9)](..._0x4961b3){const _0x2a020b=a115_0x4b917e;if(this['logLevel']>LogLevel[_0x2a020b(0xbc)])return;const _0x154bf3=formatColoredLogEntry(_0x2a020b(0xc9),_0x4961b3);this[_0x2a020b(0xb1)]?.[_0x2a020b(0xd9)](_0x154bf3+'\x0a');}['info'](..._0x123374){const _0x19cdd9=a115_0x4b917e;if(this[_0x19cdd9(0xdf)]>LogLevel[_0x19cdd9(0xd7)])return;const _0x1ed8bf=formatColoredLogEntry(_0x19cdd9(0xce),_0x123374);!this['fileOnly']&&console[_0x19cdd9(0xc5)](_0x1ed8bf),this[_0x19cdd9(0xb1)]?.[_0x19cdd9(0xd9)](_0x1ed8bf+'\x0a');}[a115_0x4b917e(0xe2)](..._0x489ed8){const _0x5e28cb=a115_0x4b917e;if(this['logLevel']>LogLevel[_0x5e28cb(0xe1)])return;const _0x2f63c8=formatColoredLogEntry(_0x5e28cb(0xe2),_0x489ed8);!this[_0x5e28cb(0xc4)]&&console[_0x5e28cb(0xe4)](_0x2f63c8),this[_0x5e28cb(0xb1)]?.[_0x5e28cb(0xd9)](_0x2f63c8+'\x0a');}[a115_0x4b917e(0xe4)](..._0x1ba427){const _0x3da21c=a115_0x4b917e,_0x25511f=formatColoredLogEntry(_0x3da21c(0xe4),_0x1ba427);!this[_0x3da21c(0xc4)]&&console[_0x3da21c(0xe4)](_0x25511f),this['logStream']?.[_0x3da21c(0xd9)](_0x25511f+'\x0a');}async[a115_0x4b917e(0xea)](){const _0x4f155b=a115_0x4b917e;return this[_0x4f155b(0xce)](_0x4f155b(0xb6)),new Promise(_0x350f29=>{const _0x5aa341=_0x4f155b;this[_0x5aa341(0xb1)]?this['logStream'][_0x5aa341(0xbd)](()=>{_0x350f29();}):_0x350f29();});}[a115_0x4b917e(0xcf)](){const _0x75c3ba=a115_0x4b917e;return join(this[_0x75c3ba(0xd6)],_0x75c3ba(0xe8));}}
1
+ const a115_0x3fa86d=a115_0x5a28;function a115_0x5a28(_0x16e98b,_0xe1ee67){_0x16e98b=_0x16e98b-0xa9;const _0x918468=a115_0x9184();let _0x5a2849=_0x918468[_0x16e98b];return _0x5a2849;}(function(_0x494a7b,_0x149c5b){const _0x382ba7=a115_0x5a28,_0x213f9e=_0x494a7b();while(!![]){try{const _0x2191d5=parseInt(_0x382ba7(0xcf))/0x1*(parseInt(_0x382ba7(0xb8))/0x2)+parseInt(_0x382ba7(0xe4))/0x3+parseInt(_0x382ba7(0xaf))/0x4*(parseInt(_0x382ba7(0xca))/0x5)+parseInt(_0x382ba7(0xe0))/0x6*(-parseInt(_0x382ba7(0xd4))/0x7)+parseInt(_0x382ba7(0xd5))/0x8*(-parseInt(_0x382ba7(0xe1))/0x9)+-parseInt(_0x382ba7(0xdc))/0xa*(parseInt(_0x382ba7(0xc0))/0xb)+parseInt(_0x382ba7(0xbb))/0xc*(parseInt(_0x382ba7(0xe9))/0xd);if(_0x2191d5===_0x149c5b)break;else _0x213f9e['push'](_0x213f9e['shift']());}catch(_0x5ae356){_0x213f9e['push'](_0x213f9e['shift']());}}}(a115_0x9184,0x64ea6));import{createWriteStream,createReadStream}from'fs';function a115_0x9184(){const _0x3a9c4d=['warn','11573159EXRfkA','map','getMinutes','toISOString','message','gray','WARN','Warning:\x20Failed\x20to\x20initialize\x20log\x20files:','4mIOhYk','error','logLevel','split','rotateOldLogs','log','close','write','getSeconds','8204bORrPM','getTimezoneOffset','getFullYear','12lZaaOx','INFO','debug','getHours','getLogPath','11MxTUDp','ERROR','toString','Warning:\x20Failed\x20to\x20compress\x20','logDir','filter','DEBUG','Warning:\x20Error\x20writing\x20to\x20tdx.log:','logStream','init','623325oHceKp','TRACE','stack','.log','mtime','7gvnHaY','name','getDate','tdx.log','tdx-','7fsozfl','1488iVYgsi','.cache','Proxy\x20session\x20ended','join','info','.gz','end','292350FIZLzu','logs','floor','stringify','3542442rrDxNa','17019ZRTdRj','abs','cause','1023288YmpWbw','padStart','fileOnly','trace'];a115_0x9184=function(){return _0x3a9c4d;};return a115_0x9184();}import{mkdir,readdir,unlink,stat,rename}from'fs/promises';import{join}from'path';import{homedir}from'os';import{createGzip}from'zlib';import{pipeline}from'stream/promises';import a115_0x276465 from'chalk';function safeStringify(_0x20a6ba){const _0x5cff7e=a115_0x5a28;if(typeof _0x20a6ba==='string')return _0x20a6ba;if(_0x20a6ba instanceof Error)return _0x20a6ba[_0x5cff7e(0xcc)]||_0x20a6ba[_0x5cff7e(0xd0)]+':\x20'+_0x20a6ba[_0x5cff7e(0xab)];try{return JSON[_0x5cff7e(0xdf)](_0x20a6ba,(_0x3242c6,_0x53eb2c)=>{const _0xc29ba3=_0x5cff7e;if(_0x53eb2c instanceof Error)return{'name':_0x53eb2c['name'],'message':_0x53eb2c['message'],'stack':_0x53eb2c[_0xc29ba3(0xcc)],'cause':_0x53eb2c[_0xc29ba3(0xe3)]};return _0x53eb2c;});}catch{return String(_0x20a6ba);}}function getTimezoneOffset(){const _0x67837=a115_0x5a28,_0x3dc05c=-new Date()[_0x67837(0xb9)](),_0x1c77eb=Math[_0x67837(0xde)](Math[_0x67837(0xe2)](_0x3dc05c)/0x3c),_0x3c39dc=Math['abs'](_0x3dc05c)%0x3c,_0x5194b3=_0x3dc05c>=0x0?'+':'-';return''+_0x5194b3+_0x1c77eb[_0x67837(0xc2)]()[_0x67837(0xe5)](0x2,'0')+_0x3c39dc[_0x67837(0xc2)]()['padStart'](0x2,'0');}function formatTimestamp(){const _0x234ec0=a115_0x5a28,_0x237c8d=new Date(),_0x58ff9e=_0x237c8d[_0x234ec0(0xba)](),_0x335bfd=(_0x237c8d['getMonth']()+0x1)['toString']()[_0x234ec0(0xe5)](0x2,'0'),_0x5caf79=_0x237c8d[_0x234ec0(0xd1)]()[_0x234ec0(0xc2)]()[_0x234ec0(0xe5)](0x2,'0'),_0x55eb6f=_0x237c8d[_0x234ec0(0xbe)]()['toString']()['padStart'](0x2,'0'),_0x2250fd=_0x237c8d[_0x234ec0(0xa9)]()['toString']()[_0x234ec0(0xe5)](0x2,'0'),_0x59e063=_0x237c8d[_0x234ec0(0xb7)]()[_0x234ec0(0xc2)]()[_0x234ec0(0xe5)](0x2,'0'),_0x113c6e=_0x237c8d['getMilliseconds']()[_0x234ec0(0xc2)]()[_0x234ec0(0xe5)](0x3,'0'),_0x539445=getTimezoneOffset();return _0x58ff9e+'-'+_0x335bfd+'-'+_0x5caf79+'\x20'+_0x55eb6f+':'+_0x2250fd+':'+_0x59e063+'.'+_0x113c6e+_0x539445;}function formatColoredLogEntry(_0x203581,_0x4fc2d8){const _0x394aca=a115_0x5a28,_0x16f1f7=formatTimestamp(),_0x83bc7a=_0x4fc2d8[_0x394aca(0xea)](safeStringify)[_0x394aca(0xd8)]('\x20'),_0x3d38c3=a115_0x276465[_0x394aca(0xac)](_0x16f1f7);let _0x1e6798;switch(_0x203581){case _0x394aca(0xd9):_0x1e6798=a115_0x276465['cyan']('['+_0x203581+']\x20');break;case'warn':_0x1e6798=a115_0x276465['yellow']('['+_0x203581+']\x20');break;case _0x394aca(0xb0):_0x1e6798=a115_0x276465['red']('['+_0x203581+']');break;case _0x394aca(0xbd):_0x1e6798=a115_0x276465[_0x394aca(0xac)]('['+_0x203581+']');break;default:_0x1e6798='['+_0x203581+']';}return _0x3d38c3+'\x20'+_0x1e6798+'\x20'+_0x83bc7a;}export var LogLevel;(function(_0x472f22){const _0xeadc36=a115_0x5a28;_0x472f22[_0x472f22['TRACE']=-0x2]=_0xeadc36(0xcb),_0x472f22[_0x472f22['DEBUG']=-0x1]=_0xeadc36(0xc6),_0x472f22[_0x472f22['INFO']=0x0]='INFO',_0x472f22[_0x472f22[_0xeadc36(0xad)]=0x1]='WARN',_0x472f22[_0x472f22['ERROR']=0x2]=_0xeadc36(0xc1);}(LogLevel||(LogLevel={})));export class TDXLogger{[a115_0x3fa86d(0xc8)];[a115_0x3fa86d(0xc4)];['logLevel'];[a115_0x3fa86d(0xe6)];constructor(_0x447a4e=LogLevel[a115_0x3fa86d(0xbc)],_0x59a928=![]){const _0x56e355=a115_0x3fa86d;this[_0x56e355(0xc4)]=join(homedir(),_0x56e355(0xd6),'tdx',_0x56e355(0xdd)),this[_0x56e355(0xb1)]=_0x447a4e,this[_0x56e355(0xe6)]=_0x59a928;}async[a115_0x3fa86d(0xc9)](){const _0x26ff67=a115_0x3fa86d;try{await mkdir(this['logDir'],{'recursive':!![]}),await this[_0x26ff67(0xb3)]();const _0x602d52=join(this[_0x26ff67(0xc4)],_0x26ff67(0xd2));this[_0x26ff67(0xc8)]=createWriteStream(_0x602d52,{'flags':'a'}),this[_0x26ff67(0xc8)]['on'](_0x26ff67(0xb0),_0x1c9dca=>{const _0x4bc1c9=_0x26ff67;console[_0x4bc1c9(0xb0)](_0x4bc1c9(0xc7),_0x1c9dca['message']);});}catch(_0x1f8c57){console['error'](_0x26ff67(0xae),_0x1f8c57);}}async['rotateOldLogs'](){const _0x261ec3=a115_0x3fa86d;try{const _0x13bc19=await readdir(this[_0x261ec3(0xc4)]),_0x23a16b=new Date()[_0x261ec3(0xaa)]()['split']('T')[0x0];if(_0x13bc19['includes'](_0x261ec3(0xd2))){const _0x1b6d11=join(this[_0x261ec3(0xc4)],_0x261ec3(0xd2)),_0x51d0c2=await stat(_0x1b6d11),_0x1e47be=new Date(_0x51d0c2[_0x261ec3(0xce)])['toISOString']()[_0x261ec3(0xb2)]('T')[0x0];if(_0x1e47be<_0x23a16b){const _0x430d6d=join(this[_0x261ec3(0xc4)],_0x261ec3(0xd3)+_0x1e47be+_0x261ec3(0xcd));await rename(_0x1b6d11,_0x430d6d);}}const _0x2970f0=await readdir(this[_0x261ec3(0xc4)]),_0x5ed1e8=/^tdx-(\d{4}-\d{2}-\d{2})\.log$/,_0x4e8c4d=_0x2970f0[_0x261ec3(0xc5)](_0x28c7a7=>_0x5ed1e8['test'](_0x28c7a7));for(const _0x288107 of _0x4e8c4d){const _0x46d8d2=join(this[_0x261ec3(0xc4)],_0x288107),_0x588df4=join(this[_0x261ec3(0xc4)],_0x288107+_0x261ec3(0xda));try{await pipeline(createReadStream(_0x46d8d2),createGzip(),createWriteStream(_0x588df4)),await unlink(_0x46d8d2);}catch(_0x1d64c6){console[_0x261ec3(0xb0)](_0x261ec3(0xc3)+_0x288107+':',_0x1d64c6);}}}catch{}}[a115_0x3fa86d(0xbd)](..._0x2c516a){const _0x387454=a115_0x3fa86d;if(this['logLevel']>LogLevel['DEBUG'])return;const _0x45b25d=formatColoredLogEntry(_0x387454(0xbd),_0x2c516a);this['logStream']?.[_0x387454(0xb6)](_0x45b25d+'\x0a');}[a115_0x3fa86d(0xe7)](..._0xb9a224){const _0x118161=a115_0x3fa86d;if(this['logLevel']>LogLevel[_0x118161(0xcb)])return;const _0x2715fb=formatColoredLogEntry(_0x118161(0xe7),_0xb9a224);this[_0x118161(0xc8)]?.[_0x118161(0xb6)](_0x2715fb+'\x0a');}['info'](..._0xb9fadd){const _0x113149=a115_0x3fa86d;if(this[_0x113149(0xb1)]>LogLevel[_0x113149(0xbc)])return;const _0x2cd2b7=formatColoredLogEntry(_0x113149(0xd9),_0xb9fadd);!this[_0x113149(0xe6)]&&console[_0x113149(0xb4)](_0x2cd2b7),this[_0x113149(0xc8)]?.['write'](_0x2cd2b7+'\x0a');}[a115_0x3fa86d(0xe8)](..._0xac2791){const _0x26bc75=a115_0x3fa86d;if(this['logLevel']>LogLevel[_0x26bc75(0xad)])return;const _0x1fab17=formatColoredLogEntry(_0x26bc75(0xe8),_0xac2791);!this[_0x26bc75(0xe6)]&&console[_0x26bc75(0xb0)](_0x1fab17),this['logStream']?.[_0x26bc75(0xb6)](_0x1fab17+'\x0a');}['error'](..._0x134732){const _0x105661=a115_0x3fa86d,_0x24db17=formatColoredLogEntry(_0x105661(0xb0),_0x134732);!this['fileOnly']&&console[_0x105661(0xb0)](_0x24db17),this[_0x105661(0xc8)]?.[_0x105661(0xb6)](_0x24db17+'\x0a');}async[a115_0x3fa86d(0xb5)](){const _0x5e857f=a115_0x3fa86d;return this[_0x5e857f(0xd9)](_0x5e857f(0xd7)),new Promise(_0x3d59c7=>{const _0x522242=_0x5e857f;this[_0x522242(0xc8)]?this['logStream'][_0x522242(0xdb)](()=>{_0x3d59c7();}):_0x3d59c7();});}[a115_0x3fa86d(0xbf)](){const _0x21a7f6=a115_0x3fa86d;return join(this[_0x21a7f6(0xc4)],_0x21a7f6(0xd2));}}
@@ -1 +1 @@
1
- (function(_0x1e9d38,_0x2fbd89){const _0x18a367=a116_0x59a7,_0x51719e=_0x1e9d38();while(!![]){try{const _0x46bbda=parseInt(_0x18a367(0x1f1))/0x1*(parseInt(_0x18a367(0x1df))/0x2)+-parseInt(_0x18a367(0x1d2))/0x3*(parseInt(_0x18a367(0x1e5))/0x4)+-parseInt(_0x18a367(0x1eb))/0x5*(-parseInt(_0x18a367(0x1e8))/0x6)+-parseInt(_0x18a367(0x1ea))/0x7+parseInt(_0x18a367(0x1da))/0x8+-parseInt(_0x18a367(0x1d6))/0x9*(parseInt(_0x18a367(0x1f3))/0xa)+-parseInt(_0x18a367(0x1dd))/0xb*(-parseInt(_0x18a367(0x1ec))/0xc);if(_0x46bbda===_0x2fbd89)break;else _0x51719e['push'](_0x51719e['shift']());}catch(_0xfeb3d5){_0x51719e['push'](_0x51719e['shift']());}}}(a116_0x21e9,0x810f7));import{formatRows}from'./formatters.js';import a116_0x1bb8b3 from'chalk';const DEFAULT_OPTIONS={'showTreeLines':!![],'showIcons':!![],'showMetadata':!![],'indent':'\x20\x20','showUrl':![],'getSegmentUrl':undefined};function a116_0x21e9(){const _0x5731e5=['\x20segment','3763165QLrZdQ','25llhXUW','13645284MBHqcm','type','\x20\x20\x20\x20','showIcons','name','146YgQJUV','map','330QiBLnI','length','dim','segment','showUrl','folder','showMetadata','24222iwffls','join','push','└──\x20','173223GGyocq','metadata','sort','showTreeLines','3807136gHlUbs','population','segmentCount','11tasbMN','\x20\x20\x20','1758MVHfaX','icon','\x20folder','folderCount','indent','📁\x20','76cCVmKy','├──\x20','getSegmentUrl','136140DqWoLK'];a116_0x21e9=function(){return _0x5731e5;};return a116_0x21e9();}export function formatTree(_0x5bf19b,_0x260212={},_0x33e1dd=0x0,_0x5dc7ce=''){const _0x250e84=a116_0x59a7,_0x372fd1={...DEFAULT_OPTIONS,..._0x260212},_0x4713f8=[],_0x18f12b=[..._0x5bf19b][_0x250e84(0x1d8)]((_0x2f0029,_0x2dfe1d)=>_0x2f0029[_0x250e84(0x1f0)]['localeCompare'](_0x2dfe1d[_0x250e84(0x1f0)]));for(let _0x1ebb0d=0x0;_0x1ebb0d<_0x18f12b['length'];_0x1ebb0d++){const _0x38e1ca=_0x18f12b[_0x1ebb0d],_0x265ecd=_0x1ebb0d===_0x18f12b['length']-0x1;let _0x21509f='';_0x33e1dd>0x0&&(_0x21509f+=_0x5dc7ce);_0x372fd1[_0x250e84(0x1d9)]&&_0x33e1dd>0x0&&(_0x21509f+=a116_0x1bb8b3[_0x250e84(0x1f5)](_0x265ecd?_0x250e84(0x1d5):_0x250e84(0x1e6)));_0x372fd1[_0x250e84(0x1ef)]&&(_0x21509f+=_0x38e1ca[_0x250e84(0x1ed)]===_0x250e84(0x1d0)?_0x250e84(0x1e4):'🎯\x20');_0x21509f+=_0x38e1ca['name'];if(_0x372fd1['showMetadata']){if(_0x38e1ca[_0x250e84(0x1ed)]===_0x250e84(0x1d0)){const _0x49c9d2=[];_0x38e1ca[_0x250e84(0x1d7)][_0x250e84(0x1dc)]&&_0x49c9d2['push'](_0x38e1ca['metadata'][_0x250e84(0x1dc)]+_0x250e84(0x1e9)+(_0x38e1ca['metadata'][_0x250e84(0x1dc)]!==0x1?'s':'')),_0x38e1ca[_0x250e84(0x1d7)]['folderCount']&&_0x49c9d2[_0x250e84(0x1d4)](_0x38e1ca[_0x250e84(0x1d7)][_0x250e84(0x1e2)]+_0x250e84(0x1e1)+(_0x38e1ca[_0x250e84(0x1d7)]['folderCount']!==0x1?'s':'')),_0x49c9d2[_0x250e84(0x1f4)]>0x0&&(_0x21509f+=a116_0x1bb8b3[_0x250e84(0x1f5)]('\x20('+_0x49c9d2[_0x250e84(0x1d3)](',\x20')+')'));}else _0x38e1ca['type']==='segment'&&_0x38e1ca[_0x250e84(0x1db)]!==undefined&&(_0x21509f+=a116_0x1bb8b3[_0x250e84(0x1f5)]('\x20('+formatRows(_0x38e1ca[_0x250e84(0x1db)])+')'));}_0x372fd1[_0x250e84(0x1f7)]&&_0x372fd1[_0x250e84(0x1e7)]&&_0x38e1ca[_0x250e84(0x1ed)]===_0x250e84(0x1f6)&&(_0x21509f+='\x20'+a116_0x1bb8b3['cyan'](_0x372fd1['getSegmentUrl'](_0x38e1ca['id'])));_0x4713f8[_0x250e84(0x1d4)](_0x21509f);if(_0x38e1ca['children']&&_0x38e1ca['children'][_0x250e84(0x1f4)]>0x0){let _0x5db1df;if(_0x33e1dd===0x0)_0x5db1df='';else _0x372fd1['showTreeLines']?_0x5db1df=_0x5dc7ce+(_0x265ecd?_0x250e84(0x1ee):a116_0x1bb8b3['dim']('│')+_0x250e84(0x1de)):_0x5db1df=_0x5dc7ce+_0x372fd1[_0x250e84(0x1e3)];const _0xf2990b=formatTree(_0x38e1ca['children'],_0x372fd1,_0x33e1dd+0x1,_0x5db1df);_0x4713f8[_0x250e84(0x1d4)](_0xf2990b);}}return _0x4713f8['join']('\x0a');}function a116_0x59a7(_0x12b20c,_0x399fca){_0x12b20c=_0x12b20c-0x1d0;const _0x21e9c7=a116_0x21e9();let _0x59a711=_0x21e9c7[_0x12b20c];return _0x59a711;}export function formatFlatList(_0x2307e7,_0x1af6a8,_0x1d587d={}){const _0x5201d7=a116_0x59a7,_0x27945c={...DEFAULT_OPTIONS,..._0x1d587d},_0x4d3ab4=[];for(const _0x27d379 of _0x2307e7){_0x4d3ab4[_0x5201d7(0x1d4)]({'name':_0x27d379['name'],'icon':_0x27945c[_0x5201d7(0x1ef)]?'📁':'','metadata':undefined});}for(const _0xe6e9c1 of _0x1af6a8){const _0x5b9718=_0x27945c[_0x5201d7(0x1d1)]&&_0xe6e9c1[_0x5201d7(0x1db)]!==undefined?a116_0x1bb8b3[_0x5201d7(0x1f5)]('\x20('+formatRows(_0xe6e9c1[_0x5201d7(0x1db)])+')'):'',_0x54f7bf=_0x27945c[_0x5201d7(0x1f7)]&&_0x27945c['getSegmentUrl']?_0x27945c[_0x5201d7(0x1e7)](_0xe6e9c1['id']):undefined;_0x4d3ab4[_0x5201d7(0x1d4)]({'name':_0xe6e9c1[_0x5201d7(0x1f0)],'icon':_0x27945c[_0x5201d7(0x1ef)]?'🎯':'','metadata':_0x5b9718,'url':_0x54f7bf});}_0x4d3ab4[_0x5201d7(0x1d8)]((_0x384091,_0x2de1f3)=>_0x384091[_0x5201d7(0x1f0)]['localeCompare'](_0x2de1f3[_0x5201d7(0x1f0)]));if(_0x4d3ab4[_0x5201d7(0x1f4)]===0x0)return'(empty)';const _0x5a78cc=_0x4d3ab4[_0x5201d7(0x1f2)](_0xab3c6e=>{const _0x170a96=_0x5201d7,_0x4af7ac=_0xab3c6e[_0x170a96(0x1e0)]?_0xab3c6e[_0x170a96(0x1e0)]+'\x20':'',_0x87d4a7=_0xab3c6e[_0x170a96(0x1d7)]||'',_0x30369=_0xab3c6e['url']?'\x20'+a116_0x1bb8b3['cyan'](_0xab3c6e['url']):'';return''+_0x4af7ac+_0xab3c6e['name']+_0x87d4a7+_0x30369;});return _0x5a78cc['join']('\x0a');}
1
+ (function(_0x59a2d6,_0x113abc){const _0x4e2894=a116_0x4057,_0x308eea=_0x59a2d6();while(!![]){try{const _0x1b4ece=parseInt(_0x4e2894(0x14c))/0x1+-parseInt(_0x4e2894(0x14d))/0x2*(-parseInt(_0x4e2894(0x151))/0x3)+-parseInt(_0x4e2894(0x161))/0x4*(-parseInt(_0x4e2894(0x16e))/0x5)+-parseInt(_0x4e2894(0x153))/0x6+parseInt(_0x4e2894(0x16b))/0x7+-parseInt(_0x4e2894(0x157))/0x8+-parseInt(_0x4e2894(0x163))/0x9*(parseInt(_0x4e2894(0x165))/0xa);if(_0x1b4ece===_0x113abc)break;else _0x308eea['push'](_0x308eea['shift']());}catch(_0x439156){_0x308eea['push'](_0x308eea['shift']());}}}(a116_0x3766,0xb6410));import{formatRows}from'./formatters.js';import a116_0x4d199f from'chalk';function a116_0x4057(_0x41dbb4,_0x36b672){_0x41dbb4=_0x41dbb4-0x147;const _0x3766b4=a116_0x3766();let _0x405708=_0x3766b4[_0x41dbb4];return _0x405708;}const DEFAULT_OPTIONS={'showTreeLines':!![],'showIcons':!![],'showMetadata':!![],'indent':'\x20\x20','showUrl':![],'getSegmentUrl':undefined};function a116_0x3766(){const _0x11c24d=['(empty)','├──\x20','cyan','\x20\x20\x20','showIcons','indent','segment','3914876pWVmIc','getSegmentUrl','9qpehPp','population','8196950rBffGV','children','\x20\x20\x20\x20','name','length','📁\x20','2749299TbtpNN','icon','map','5wmYrFn','push','🎯\x20','showUrl','url','metadata','segmentCount','folderCount','695819HTfogF','22ajBsTK','localeCompare','\x20folder','sort','204234aPWpAI','\x20segment','1731396NLTcmk','join','type','dim','7691040DfhayR','folder','showMetadata'];a116_0x3766=function(){return _0x11c24d;};return a116_0x3766();}export function formatTree(_0x844f4a,_0x324036={},_0x2f4bf7=0x0,_0x2a31fe=''){const _0x58ac5f=a116_0x4057,_0x4b5b87={...DEFAULT_OPTIONS,..._0x324036},_0x4b01d1=[],_0x9d156c=[..._0x844f4a][_0x58ac5f(0x150)]((_0x33c372,_0xd5fdce)=>_0x33c372['name'][_0x58ac5f(0x14e)](_0xd5fdce[_0x58ac5f(0x168)]));for(let _0x2e7374=0x0;_0x2e7374<_0x9d156c[_0x58ac5f(0x169)];_0x2e7374++){const _0x5b722e=_0x9d156c[_0x2e7374],_0x5b7ec3=_0x2e7374===_0x9d156c['length']-0x1;let _0x21a6e6='';_0x2f4bf7>0x0&&(_0x21a6e6+=_0x2a31fe);_0x4b5b87['showTreeLines']&&_0x2f4bf7>0x0&&(_0x21a6e6+=a116_0x4d199f[_0x58ac5f(0x156)](_0x5b7ec3?'└──\x20':_0x58ac5f(0x15b)));_0x4b5b87['showIcons']&&(_0x21a6e6+=_0x5b722e[_0x58ac5f(0x155)]==='folder'?_0x58ac5f(0x16a):_0x58ac5f(0x170));_0x21a6e6+=_0x5b722e[_0x58ac5f(0x168)];if(_0x4b5b87[_0x58ac5f(0x159)]){if(_0x5b722e['type']===_0x58ac5f(0x158)){const _0x510bfd=[];_0x5b722e[_0x58ac5f(0x149)][_0x58ac5f(0x14a)]&&_0x510bfd['push'](_0x5b722e[_0x58ac5f(0x149)][_0x58ac5f(0x14a)]+_0x58ac5f(0x152)+(_0x5b722e[_0x58ac5f(0x149)]['segmentCount']!==0x1?'s':'')),_0x5b722e['metadata']['folderCount']&&_0x510bfd[_0x58ac5f(0x16f)](_0x5b722e['metadata']['folderCount']+_0x58ac5f(0x14f)+(_0x5b722e['metadata'][_0x58ac5f(0x14b)]!==0x1?'s':'')),_0x510bfd['length']>0x0&&(_0x21a6e6+=a116_0x4d199f[_0x58ac5f(0x156)]('\x20('+_0x510bfd[_0x58ac5f(0x154)](',\x20')+')'));}else _0x5b722e[_0x58ac5f(0x155)]===_0x58ac5f(0x160)&&_0x5b722e['population']!==undefined&&(_0x21a6e6+=a116_0x4d199f[_0x58ac5f(0x156)]('\x20('+formatRows(_0x5b722e[_0x58ac5f(0x164)])+')'));}_0x4b5b87['showUrl']&&_0x4b5b87[_0x58ac5f(0x162)]&&_0x5b722e['type']===_0x58ac5f(0x160)&&(_0x21a6e6+='\x20'+a116_0x4d199f[_0x58ac5f(0x15c)](_0x4b5b87[_0x58ac5f(0x162)](_0x5b722e['id'])));_0x4b01d1[_0x58ac5f(0x16f)](_0x21a6e6);if(_0x5b722e[_0x58ac5f(0x166)]&&_0x5b722e['children'][_0x58ac5f(0x169)]>0x0){let _0x3b2f07;if(_0x2f4bf7===0x0)_0x3b2f07='';else _0x4b5b87['showTreeLines']?_0x3b2f07=_0x2a31fe+(_0x5b7ec3?_0x58ac5f(0x167):a116_0x4d199f[_0x58ac5f(0x156)]('│')+_0x58ac5f(0x15d)):_0x3b2f07=_0x2a31fe+_0x4b5b87[_0x58ac5f(0x15f)];const _0xbbe9ef=formatTree(_0x5b722e['children'],_0x4b5b87,_0x2f4bf7+0x1,_0x3b2f07);_0x4b01d1['push'](_0xbbe9ef);}}return _0x4b01d1[_0x58ac5f(0x154)]('\x0a');}export function formatFlatList(_0x29bbde,_0x500d92,_0x4287cf={}){const _0x536e42=a116_0x4057,_0x310b90={...DEFAULT_OPTIONS,..._0x4287cf},_0x39ffc6=[];for(const _0x5b3e6f of _0x29bbde){_0x39ffc6['push']({'name':_0x5b3e6f['name'],'icon':_0x310b90[_0x536e42(0x15e)]?'📁':'','metadata':undefined});}for(const _0x4c5d17 of _0x500d92){const _0x2ce91c=_0x310b90['showMetadata']&&_0x4c5d17[_0x536e42(0x164)]!==undefined?a116_0x4d199f[_0x536e42(0x156)]('\x20('+formatRows(_0x4c5d17['population'])+')'):'',_0x23b1fd=_0x310b90[_0x536e42(0x147)]&&_0x310b90[_0x536e42(0x162)]?_0x310b90[_0x536e42(0x162)](_0x4c5d17['id']):undefined;_0x39ffc6[_0x536e42(0x16f)]({'name':_0x4c5d17[_0x536e42(0x168)],'icon':_0x310b90['showIcons']?'🎯':'','metadata':_0x2ce91c,'url':_0x23b1fd});}_0x39ffc6[_0x536e42(0x150)]((_0x327fba,_0x520c22)=>_0x327fba[_0x536e42(0x168)][_0x536e42(0x14e)](_0x520c22[_0x536e42(0x168)]));if(_0x39ffc6[_0x536e42(0x169)]===0x0)return _0x536e42(0x15a);const _0x38d261=_0x39ffc6[_0x536e42(0x16d)](_0x2f549a=>{const _0x47bf0a=_0x536e42,_0x2cf5b0=_0x2f549a[_0x47bf0a(0x16c)]?_0x2f549a[_0x47bf0a(0x16c)]+'\x20':'',_0x508e5a=_0x2f549a[_0x47bf0a(0x149)]||'',_0xd9842f=_0x2f549a['url']?'\x20'+a116_0x4d199f[_0x47bf0a(0x15c)](_0x2f549a[_0x47bf0a(0x148)]):'';return''+_0x2cf5b0+_0x2f549a['name']+_0x508e5a+_0xd9842f;});return _0x38d261[_0x536e42(0x154)]('\x0a');}
@@ -1 +1 @@
1
- const a117_0x121096=a117_0x440b;(function(_0x2b596d,_0x2b548a){const _0x5a316e=a117_0x440b,_0x294a47=_0x2b596d();while(!![]){try{const _0x430b51=parseInt(_0x5a316e(0x1a6))/0x1+-parseInt(_0x5a316e(0x199))/0x2+-parseInt(_0x5a316e(0x192))/0x3+-parseInt(_0x5a316e(0x186))/0x4+parseInt(_0x5a316e(0x187))/0x5+-parseInt(_0x5a316e(0x191))/0x6*(-parseInt(_0x5a316e(0x1a7))/0x7)+parseInt(_0x5a316e(0x184))/0x8;if(_0x430b51===_0x2b548a)break;else _0x294a47['push'](_0x294a47['shift']());}catch(_0xf0b72b){_0x294a47['push'](_0x294a47['shift']());}}}(a117_0x20ac,0xa13ff));import{get}from'https';import{readFileSync,writeFileSync,mkdirSync}from'fs';import{join}from'path';function a117_0x20ac(){const _0x4b8fe7=['848296aLyyAb','isTTY','595252tEzDkH','2974420cxITJp','utf-8','green','toISOString','currentVersion','destroy','stderr','npm\x20install\x20-g\x20@treasuredata/tdx@latest','env','data','3138bTrySW','521805qCYJmF','getTime','statusCode','yellow','\x0aUpdate\x20available:\x20','Run:','HTTP\x20','1648948lErjMG','error','Request\x20timeout','stringify','Invalid\x20version\x20format','now','version','write','gray','latestVersion','NO_COLOR','https://registry.npmjs.org/@treasuredata/tdx/latest','\x0aRun:\x20','628235caQTuZ','6405pjcQQk','lastCheck','last_version_check'];a117_0x20ac=function(){return _0x4b8fe7;};return a117_0x20ac();}import{gt,valid}from'semver';import a117_0x486b4f from'chalk';import{getCacheDir}from'../core/config.js';const CACHE_DURATION_MS=0x18*0x3c*0x3c*0x3e8,NPM_REGISTRY_URL=a117_0x121096(0x1a4),TIMEOUT_MS=0x7d0;function getCacheFilePath(){const _0x7ad6f9=a117_0x121096,_0x3809e4=getCacheDir();return join(_0x3809e4,_0x7ad6f9(0x1a9));}function readCache(){const _0x53c009=a117_0x121096;try{const _0x236b2d=getCacheFilePath(),_0x39b877=readFileSync(_0x236b2d,_0x53c009(0x188));return JSON['parse'](_0x39b877);}catch{return null;}}function writeCache(_0x1714bf){const _0x2048db=a117_0x121096;try{const _0x148578=getCacheDir();mkdirSync(_0x148578,{'recursive':!![]});const _0xde74ff={'lastCheck':new Date()[_0x2048db(0x18a)](),'latestVersion':_0x1714bf},_0x45c79f=getCacheFilePath();writeFileSync(_0x45c79f,JSON[_0x2048db(0x19c)](_0xde74ff,null,0x2),_0x2048db(0x188));}catch{}}function isCacheValid(_0x3424e5){const _0x334c65=a117_0x121096;if(!_0x3424e5)return![];const _0x58356b=new Date(_0x3424e5[_0x334c65(0x1a8)])[_0x334c65(0x193)](),_0xd71576=Date[_0x334c65(0x19e)]();return _0xd71576-_0x58356b<CACHE_DURATION_MS;}function fetchLatestVersion(){return new Promise((_0x40014d,_0x327642)=>{const _0x5c69da=a117_0x440b,_0x5df290=get(NPM_REGISTRY_URL,_0x49e24f=>{const _0x5d267f=a117_0x440b;if(_0x49e24f[_0x5d267f(0x194)]!==0xc8){clearTimeout(_0x32138f),_0x327642(new Error(_0x5d267f(0x198)+_0x49e24f['statusCode']));return;}let _0x1045ea='';_0x49e24f['on'](_0x5d267f(0x190),_0x53a6b1=>{_0x1045ea+=_0x53a6b1;}),_0x49e24f['on']('end',()=>{const _0x51af28=_0x5d267f;clearTimeout(_0x32138f);try{const _0x1822cc=JSON['parse'](_0x1045ea);if(!valid(_0x1822cc['version'])){_0x327642(new Error(_0x51af28(0x19d)));return;}_0x40014d(_0x1822cc[_0x51af28(0x19f)]);}catch(_0x17a0f7){_0x327642(_0x17a0f7);}});})['on'](_0x5c69da(0x19a),_0x42dd1c=>{clearTimeout(_0x32138f),_0x327642(_0x42dd1c);}),_0x32138f=setTimeout(()=>{const _0x5059c6=_0x5c69da;_0x5df290[_0x5059c6(0x18c)](),_0x327642(new Error(_0x5059c6(0x19b)));},TIMEOUT_MS);});}export async function checkForUpdate(_0x277d25){const _0x56e5d9=a117_0x121096;try{const _0x3f009a=readCache();if(isCacheValid(_0x3f009a)){const _0x64077a=gt(_0x3f009a[_0x56e5d9(0x1a2)],_0x277d25);return{'updateAvailable':_0x64077a,'currentVersion':_0x277d25,'latestVersion':_0x3f009a[_0x56e5d9(0x1a2)]};}const _0x330f79=await fetchLatestVersion();writeCache(_0x330f79);const _0xd0975b=gt(_0x330f79,_0x277d25);return{'updateAvailable':_0xd0975b,'currentVersion':_0x277d25,'latestVersion':_0x330f79};}catch{return null;}}function a117_0x440b(_0x23c5f0,_0x69ca56){_0x23c5f0=_0x23c5f0-0x184;const _0x20acdf=a117_0x20ac();let _0x440bf5=_0x20acdf[_0x23c5f0];return _0x440bf5;}export function displayUpdateNotification(_0x1909f9){const _0x19071f=a117_0x121096;if(!_0x1909f9['updateAvailable'])return;const _0x557229=process[_0x19071f(0x18d)][_0x19071f(0x185)]&&!process[_0x19071f(0x18f)][_0x19071f(0x1a3)],_0x5ddb16=_0x557229?a117_0x486b4f[_0x19071f(0x1a1)]('→'):'→',_0x814954=_0x557229?a117_0x486b4f['dim'](_0x1909f9[_0x19071f(0x18b)]):_0x1909f9[_0x19071f(0x18b)],_0xb5e34e=_0x557229?a117_0x486b4f[_0x19071f(0x189)](_0x1909f9[_0x19071f(0x1a2)]):_0x1909f9[_0x19071f(0x1a2)],_0x389e5e=_0x557229?a117_0x486b4f['cyan']('npm\x20install\x20-g\x20@treasuredata/tdx@latest'):_0x19071f(0x18e),_0x1a273c=_0x557229?'\x0a'+a117_0x486b4f[_0x19071f(0x195)]('Update\x20available:')+'\x20'+_0x814954+'\x20'+_0x5ddb16+'\x20'+_0xb5e34e+'\x0a'+a117_0x486b4f['dim'](_0x19071f(0x197))+'\x20'+_0x389e5e+'\x0a':_0x19071f(0x196)+_0x814954+'\x20'+_0x5ddb16+'\x20'+_0xb5e34e+_0x19071f(0x1a5)+_0x389e5e+'\x0a';process[_0x19071f(0x18d)][_0x19071f(0x1a0)](_0x1a273c);}
1
+ const a117_0x209b48=a117_0x48eb;(function(_0x130ee4,_0x4fe8a5){const _0x998370=a117_0x48eb,_0xecbee5=_0x130ee4();while(!![]){try{const _0x501b3d=-parseInt(_0x998370(0x201))/0x1+-parseInt(_0x998370(0x1f5))/0x2+-parseInt(_0x998370(0x205))/0x3+parseInt(_0x998370(0x1f4))/0x4+parseInt(_0x998370(0x1f6))/0x5+parseInt(_0x998370(0x20d))/0x6*(-parseInt(_0x998370(0x206))/0x7)+parseInt(_0x998370(0x20b))/0x8;if(_0x501b3d===_0x4fe8a5)break;else _0xecbee5['push'](_0xecbee5['shift']());}catch(_0x5ed9c5){_0xecbee5['push'](_0xecbee5['shift']());}}}(a117_0x16f6,0x5afd6));import{get}from'https';import{readFileSync,writeFileSync,mkdirSync}from'fs';import{join}from'path';function a117_0x48eb(_0x4ade18,_0x3d5b7a){_0x4ade18=_0x4ade18-0x1f1;const _0x16f6d3=a117_0x16f6();let _0x48eb32=_0x16f6d3[_0x4ade18];return _0x48eb32;}import{gt,valid}from'semver';import a117_0x502938 from'chalk';import{getCacheDir}from'../core/config.js';const CACHE_DURATION_MS=0x18*0x3c*0x3c*0x3e8,NPM_REGISTRY_URL=a117_0x209b48(0x20c),TIMEOUT_MS=0x7d0;function getCacheFilePath(){const _0x13ad91=getCacheDir();return join(_0x13ad91,'last_version_check');}function readCache(){const _0x2a38f2=a117_0x209b48;try{const _0x44c00c=getCacheFilePath(),_0x5a8dca=readFileSync(_0x44c00c,'utf-8');return JSON[_0x2a38f2(0x1f9)](_0x5a8dca);}catch{return null;}}function writeCache(_0x1a4c1a){const _0x18ec6e=a117_0x209b48;try{const _0x583b43=getCacheDir();mkdirSync(_0x583b43,{'recursive':!![]});const _0x546a6c={'lastCheck':new Date()[_0x18ec6e(0x208)](),'latestVersion':_0x1a4c1a},_0x122556=getCacheFilePath();writeFileSync(_0x122556,JSON['stringify'](_0x546a6c,null,0x2),'utf-8');}catch{}}function isCacheValid(_0x223bd3){const _0x1d4b09=a117_0x209b48;if(!_0x223bd3)return![];const _0x45ec17=new Date(_0x223bd3[_0x1d4b09(0x1f8)])['getTime'](),_0x1280cd=Date[_0x1d4b09(0x203)]();return _0x1280cd-_0x45ec17<CACHE_DURATION_MS;}function fetchLatestVersion(){return new Promise((_0x1696dc,_0x167822)=>{const _0x2f3f2b=a117_0x48eb,_0x543a49=get(NPM_REGISTRY_URL,_0x28f1f=>{const _0x41895a=a117_0x48eb;if(_0x28f1f[_0x41895a(0x202)]!==0xc8){clearTimeout(_0x252d0f),_0x167822(new Error(_0x41895a(0x211)+_0x28f1f[_0x41895a(0x202)]));return;}let _0x12418e='';_0x28f1f['on']('data',_0x4c3e5e=>{_0x12418e+=_0x4c3e5e;}),_0x28f1f['on'](_0x41895a(0x1f7),()=>{const _0x44b11a=_0x41895a;clearTimeout(_0x252d0f);try{const _0x497dc1=JSON[_0x44b11a(0x1f9)](_0x12418e);if(!valid(_0x497dc1[_0x44b11a(0x1f3)])){_0x167822(new Error(_0x44b11a(0x1fc)));return;}_0x1696dc(_0x497dc1[_0x44b11a(0x1f3)]);}catch(_0x2f6890){_0x167822(_0x2f6890);}});})['on'](_0x2f3f2b(0x1fa),_0x460f57=>{clearTimeout(_0x252d0f),_0x167822(_0x460f57);}),_0x252d0f=setTimeout(()=>{const _0x580c97=_0x2f3f2b;_0x543a49[_0x580c97(0x204)](),_0x167822(new Error('Request\x20timeout'));},TIMEOUT_MS);});}function a117_0x16f6(){const _0x50a7f9=['parse','error','gray','Invalid\x20version\x20format','yellow','write','latestVersion','NO_COLOR','55487udLPAF','statusCode','now','destroy','794412FxkWHE','2540587GNbJrZ','\x0aUpdate\x20available:\x20','toISOString','dim','green','9069952ooZxwf','https://registry.npmjs.org/@treasuredata/tdx/latest','12aMCrIl','updateAvailable','\x0aRun:\x20','stderr','HTTP\x20','npm\x20install\x20-g\x20@treasuredata/tdx@latest','currentVersion','version','1202252JfwcdB','528212TizYBv','1243330xZMuZX','end','lastCheck'];a117_0x16f6=function(){return _0x50a7f9;};return a117_0x16f6();}export async function checkForUpdate(_0x5cd2d3){const _0x5df03c=a117_0x209b48;try{const _0xc1922f=readCache();if(isCacheValid(_0xc1922f)){const _0x389709=gt(_0xc1922f[_0x5df03c(0x1ff)],_0x5cd2d3);return{'updateAvailable':_0x389709,'currentVersion':_0x5cd2d3,'latestVersion':_0xc1922f[_0x5df03c(0x1ff)]};}const _0x58458a=await fetchLatestVersion();writeCache(_0x58458a);const _0x54c4ab=gt(_0x58458a,_0x5cd2d3);return{'updateAvailable':_0x54c4ab,'currentVersion':_0x5cd2d3,'latestVersion':_0x58458a};}catch{return null;}}export function displayUpdateNotification(_0x2ed958){const _0x548cdf=a117_0x209b48;if(!_0x2ed958[_0x548cdf(0x20e)])return;const _0x41c56a=process[_0x548cdf(0x210)]['isTTY']&&!process['env'][_0x548cdf(0x200)],_0x40ed1d=_0x41c56a?a117_0x502938[_0x548cdf(0x1fb)]('→'):'→',_0x598369=_0x41c56a?a117_0x502938[_0x548cdf(0x209)](_0x2ed958[_0x548cdf(0x1f2)]):_0x2ed958['currentVersion'],_0x5a0a7e=_0x41c56a?a117_0x502938[_0x548cdf(0x20a)](_0x2ed958[_0x548cdf(0x1ff)]):_0x2ed958[_0x548cdf(0x1ff)],_0xa3c317=_0x41c56a?a117_0x502938['cyan'](_0x548cdf(0x1f1)):_0x548cdf(0x1f1),_0x46eed2=_0x41c56a?'\x0a'+a117_0x502938[_0x548cdf(0x1fd)]('Update\x20available:')+'\x20'+_0x598369+'\x20'+_0x40ed1d+'\x20'+_0x5a0a7e+'\x0a'+a117_0x502938[_0x548cdf(0x209)]('Run:')+'\x20'+_0xa3c317+'\x0a':_0x548cdf(0x207)+_0x598369+'\x20'+_0x40ed1d+'\x20'+_0x5a0a7e+_0x548cdf(0x20f)+_0xa3c317+'\x0a';process[_0x548cdf(0x210)][_0x548cdf(0x1fe)](_0x46eed2);}
@@ -1 +1 @@
1
- const a118_0xb69b3b=a118_0x1bdc;(function(_0xcf72c3,_0x186851){const _0x68a644=a118_0x1bdc,_0x57459b=_0xcf72c3();while(!![]){try{const _0x97b277=-parseInt(_0x68a644(0x8a))/0x1+-parseInt(_0x68a644(0x8d))/0x2+parseInt(_0x68a644(0x93))/0x3*(parseInt(_0x68a644(0x8e))/0x4)+parseInt(_0x68a644(0x89))/0x5+-parseInt(_0x68a644(0x87))/0x6*(parseInt(_0x68a644(0x91))/0x7)+parseInt(_0x68a644(0x94))/0x8*(parseInt(_0x68a644(0x8b))/0x9)+parseInt(_0x68a644(0x90))/0xa*(parseInt(_0x68a644(0x88))/0xb);if(_0x97b277===_0x186851)break;else _0x57459b['push'](_0x57459b['shift']());}catch(_0x2027f5){_0x57459b['push'](_0x57459b['shift']());}}}(a118_0x41d5,0x397e9));function a118_0x41d5(){const _0x3beae3=['150gzEzxS','2750293RyrhQY','startsWith','3BWMAXG','8NvORwg','6VtBoku','119086uNPzLP','2253940TDsxmk','143890IVFuMy','1683693XMtHkG','.dig','878670MsuvsY','1645464hSAQMO','.digdag'];a118_0x41d5=function(){return _0x3beae3;};return a118_0x41d5();}export const WORKFLOW_FILE_EXTENSION=a118_0xb69b3b(0x8c);function a118_0x1bdc(_0x195d7d,_0x3e8905){_0x195d7d=_0x195d7d-0x87;const _0x41d5f3=a118_0x41d5();let _0x1bdc67=_0x41d5f3[_0x195d7d];return _0x1bdc67;}export function shouldIncludeInArchive(_0x1c8848){const _0x54d865=a118_0xb69b3b;if(_0x1c8848===_0x54d865(0x8f))return!![];if(_0x1c8848[_0x54d865(0x92)]('.'))return![];return!![];}
1
+ const a118_0x40e047=a118_0x1485;(function(_0x23aa80,_0x2ebd74){const _0x14a81e=a118_0x1485,_0x3b49a9=_0x23aa80();while(!![]){try{const _0x52cbb1=parseInt(_0x14a81e(0x9d))/0x1+-parseInt(_0x14a81e(0x9c))/0x2+parseInt(_0x14a81e(0x99))/0x3+-parseInt(_0x14a81e(0x9b))/0x4*(parseInt(_0x14a81e(0x95))/0x5)+-parseInt(_0x14a81e(0x98))/0x6+-parseInt(_0x14a81e(0xa0))/0x7+-parseInt(_0x14a81e(0x9a))/0x8*(-parseInt(_0x14a81e(0x9f))/0x9);if(_0x52cbb1===_0x2ebd74)break;else _0x3b49a9['push'](_0x3b49a9['shift']());}catch(_0x494902){_0x3b49a9['push'](_0x3b49a9['shift']());}}}(a118_0x2e1b,0x67fc5));function a118_0x1485(_0x504fa5,_0x91d13){_0x504fa5=_0x504fa5-0x95;const _0x2e1bfd=a118_0x2e1b();let _0x1485d4=_0x2e1bfd[_0x504fa5];return _0x1485d4;}export const WORKFLOW_FILE_EXTENSION=a118_0x40e047(0x96);export function shouldIncludeInArchive(_0x4f438a){const _0x215c35=a118_0x40e047;if(_0x4f438a===_0x215c35(0x9e))return!![];if(_0x4f438a[_0x215c35(0x97)]('.'))return![];return!![];}function a118_0x2e1b(){const _0x535721=['4719024FASGsu','917007bFcaNw','8COjWjy','69316GvHfeA','846834eOWFhc','557803SJjokp','.digdag','15601887JBprWx','5879062LBDKaM','35zyvUmj','.dig','startsWith'];a118_0x2e1b=function(){return _0x535721;};return a118_0x2e1b();}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@treasuredata/tdx",
3
- "version": "0.8.6",
3
+ "version": "0.8.8",
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": {