@typescape-ai/cli 1.8.9 → 1.9.1

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 (2) hide show
  1. package/dist/cli.js +1 -1
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -138,7 +138,7 @@ ${n.comment}`:n.comment}this.doc.range[2]=n.offset;break}default:this.errors.pus
138
138
  `)+1;while(n!==0)this.onNewLine(this.offset+n),n=this.source.indexOf(`
139
139
  `,n)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let n=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,n.value){let t="end"in n.value?n.value.end:void 0;if((Array.isArray(t)?t[t.length-1]:void 0)?.type==="comment")t?.push(this.sourceToken);else e.items.push({start:[this.sourceToken]})}else if(n.sep)n.sep.push(this.sourceToken);else n.start.push(this.sourceToken);return;case"space":case"comment":if(n.value)e.items.push({start:[this.sourceToken]});else if(n.sep)n.sep.push(this.sourceToken);else{if(this.atIndentedComment(n.start,e.indent)){let a=e.items[e.items.length-2]?.value?.end;if(Array.isArray(a)){Array.prototype.push.apply(a,n.start),a.push(this.sourceToken),e.items.pop();return}}n.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let t=!this.onKeyLine&&this.indent===e.indent,a=t&&(n.sep||n.explicitKey)&&this.type!=="seq-item-ind",r=[];if(a&&n.sep&&!n.value){let i=[];for(let o=0;o<n.sep.length;++o){let s=n.sep[o];switch(s.type){case"newline":i.push(o);break;case"space":break;case"comment":if(s.indent>e.indent)i.length=0;break;default:i.length=0}}if(i.length>=2)r=n.sep.splice(i[1])}switch(this.type){case"anchor":case"tag":if(a||n.value)r.push(this.sourceToken),e.items.push({start:r}),this.onKeyLine=!0;else if(n.sep)n.sep.push(this.sourceToken);else n.start.push(this.sourceToken);return;case"explicit-key-ind":if(!n.sep&&!n.explicitKey)n.start.push(this.sourceToken),n.explicitKey=!0;else if(a||n.value)r.push(this.sourceToken),e.items.push({start:r,explicitKey:!0});else this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]});this.onKeyLine=!0;return;case"map-value-ind":if(n.explicitKey)if(!n.sep)if(Fr(n.start,"newline"))Object.assign(n,{key:null,sep:[this.sourceToken]});else{let i=Po(n.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:i,key:null,sep:[this.sourceToken]}]})}else if(n.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Fr(n.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:r,key:null,sep:[this.sourceToken]}]});else if(WD(n.key)&&!Fr(n.sep,"newline")){let i=Po(n.start),o=n.key,s=n.sep;s.push(this.sourceToken),delete n.key,delete n.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:i,key:o,sep:s}]})}else if(r.length>0)n.sep=n.sep.concat(r,this.sourceToken);else n.sep.push(this.sourceToken);else if(!n.sep)Object.assign(n,{key:null,sep:[this.sourceToken]});else if(n.value||a)e.items.push({start:r,key:null,sep:[this.sourceToken]});else if(Fr(n.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]});else n.sep.push(this.sourceToken);this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let i=this.flowScalar(this.type);if(a||n.value)e.items.push({start:r,key:i,sep:[]}),this.onKeyLine=!0;else if(n.sep)this.stack.push(i);else Object.assign(n,{key:i,sep:[]}),this.onKeyLine=!0;return}default:{let i=this.startBlockValue(e);if(i){if(i.type==="block-seq"){if(!n.explicitKey&&n.sep&&!Fr(n.sep,"newline")){yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source});return}}else if(t)e.items.push({start:r});this.stack.push(i);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let n=e.items[e.items.length-1];switch(this.type){case"newline":if(n.value){let t="end"in n.value?n.value.end:void 0;if((Array.isArray(t)?t[t.length-1]:void 0)?.type==="comment")t?.push(this.sourceToken);else e.items.push({start:[this.sourceToken]})}else n.start.push(this.sourceToken);return;case"space":case"comment":if(n.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(n.start,e.indent)){let a=e.items[e.items.length-2]?.value?.end;if(Array.isArray(a)){Array.prototype.push.apply(a,n.start),a.push(this.sourceToken),e.items.pop();return}}n.start.push(this.sourceToken)}return;case"anchor":case"tag":if(n.value||this.indent<=e.indent)break;n.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;if(n.value||Fr(n.start,"seq-item-ind"))e.items.push({start:[this.sourceToken]});else n.start.push(this.sourceToken);return}if(this.indent>e.indent){let t=this.startBlockValue(e);if(t){this.stack.push(t);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let n=e.items[e.items.length-1];if(this.type==="flow-error-end"){let t;do yield*this.pop(),t=this.peek(1);while(t?.type==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":if(!n||n.sep)e.items.push({start:[this.sourceToken]});else n.start.push(this.sourceToken);return;case"map-value-ind":if(!n||n.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(n.sep)n.sep.push(this.sourceToken);else Object.assign(n,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":if(!n||n.value)e.items.push({start:[this.sourceToken]});else if(n.sep)n.sep.push(this.sourceToken);else n.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let a=this.flowScalar(this.type);if(!n||n.value)e.items.push({start:[],key:a,sep:[]});else if(n.sep)this.stack.push(a);else Object.assign(n,{key:a,sep:[]});return}case"flow-map-end":case"flow-seq-end":e.end.push(this.sourceToken);return}let t=this.startBlockValue(e);if(t)this.stack.push(t);else yield*this.pop(),yield*this.step()}else{let t=this.peek(2);if(t.type==="block-map"&&(this.type==="map-value-ind"&&t.indent===e.indent||this.type==="newline"&&!t.items[t.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&t.type!=="flow-collection"){let a=nu(t),r=Po(a);KD(e);let i=e.end.splice(1,e.end.length);i.push(this.sourceToken);let o={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:r,key:e,sep:i}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=o}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let n=this.source.indexOf(`
140
140
  `)+1;while(n!==0)this.onNewLine(this.offset+n),n=this.source.indexOf(`
141
- `,n)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let n=nu(e),t=Po(n);return t.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let n=nu(e),t=Po(n);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,n){if(this.type!=="comment")return!1;if(this.indent<=n)return!1;return e.every((t)=>t.type==="newline"||t.type==="space")}*documentEnd(e){if(this.type!=="doc-mode"){if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}}Pae.Parser=JD});var t1=S((Wae)=>{var VD=Tf(),Uae=Tc(),Jc=Oc(),Hae=ef(),Tae=Ge(),Oae=nh(),XD=th();function e1(e){let n=e.prettyErrors!==!1;return{lineCounter:e.lineCounter||n&&new Oae.LineCounter||null,prettyErrors:n}}function Zae(e,n={}){let{lineCounter:t,prettyErrors:a}=e1(n),r=new XD.Parser(t?.addNewLine),i=new VD.Composer(n),o=Array.from(i.compose(r.parse(e)));if(a&&t)for(let s of o)s.errors.forEach(Jc.prettifyError(e,t)),s.warnings.forEach(Jc.prettifyError(e,t));if(o.length>0)return o;return Object.assign([],{empty:!0},i.streamInfo())}function n1(e,n={}){let{lineCounter:t,prettyErrors:a}=e1(n),r=new XD.Parser(t?.addNewLine),i=new VD.Composer(n),o=null;for(let s of i.compose(r.parse(e),!0,e.length))if(!o)o=s;else if(o.options.logLevel!=="silent"){o.errors.push(new Jc.YAMLParseError(s.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(a&&t)o.errors.forEach(Jc.prettifyError(e,t)),o.warnings.forEach(Jc.prettifyError(e,t));return o}function Yae(e,n,t){let a=void 0;if(typeof n==="function")a=n;else if(t===void 0&&n&&typeof n==="object")t=n;let r=n1(e,t);if(!r)return null;if(r.warnings.forEach((i)=>Hae.warn(r.options.logLevel,i)),r.errors.length>0)if(r.options.logLevel!=="silent")throw r.errors[0];else r.errors=[];return r.toJS(Object.assign({reviver:a},t))}function Kae(e,n,t){let a=null;if(typeof n==="function"||Array.isArray(n))a=n;else if(t===void 0&&n)t=n;if(typeof t==="string")t=t.length;if(typeof t==="number"){let r=Math.round(t);t=r<1?void 0:r>8?{indent:8}:{indent:r}}if(e===void 0){let{keepUndefined:r}=t??n??{};if(!r)return}if(Tae.isDocument(e)&&!a)return e.toString(t);return new Uae.Document(e,a,t).toString(t)}Wae.parse=Yae;Wae.parseAllDocuments=Zae;Wae.parseDocument=n1;Wae.stringify=Kae});var lh=S((lUe,fie)=>{fie.exports={name:"@typescape-ai/cli",version:"1.8.9",description:"Typescape CLI - Create review sessions, export feedback, and integrate with AI workflows",type:"module",bin:{typescape:"./dist/cli.js"},files:["dist","README.md"],exports:{".":"./dist/cli.js"},publishConfig:{access:"public"},scripts:{build:"bun build src/index.ts --outfile=dist/cli.js --target=bun --bundle --minify",dev:"bun run --watch src/index.ts",test:"bun test",typecheck:"tsc -p tsconfig.typecheck.json --noEmit",lint:"eslint src",prepublishOnly:"bun run build"},dependencies:{},devDependencies:{"@types/bun":"1.1.14","@typescape/integrity":"workspace:*","@typescape/schemas":"workspace:*",ajv:"8.17.1","ajv-formats":"3.0.1",yaml:"2.8.2",zod:"4.3.0"},engines:{bun:">=1.0.0"},keywords:["typescape","cli","review","documentation","ai","feedback","bun"],repository:{type:"git",url:"https://github.com/voidserf/typescape-docs.git",directory:"apps/cli"},license:"MIT"}});var z1=S((EOe,P1)=>{var Ho=1000,To=Ho*60,Oo=To*60,qi=Oo*24,Woe=qi*7,Joe=qi*365.25;P1.exports=function(e,n){n=n||{};var t=typeof e;if(t==="string"&&e.length>0)return Voe(e);else if(t==="number"&&isFinite(e))return n.long?ese(e):Xoe(e);throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function Voe(e){if(e=String(e),e.length>100)return;var n=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!n)return;var t=parseFloat(n[1]),a=(n[2]||"ms").toLowerCase();switch(a){case"years":case"year":case"yrs":case"yr":case"y":return t*Joe;case"weeks":case"week":case"w":return t*Woe;case"days":case"day":case"d":return t*qi;case"hours":case"hour":case"hrs":case"hr":case"h":return t*Oo;case"minutes":case"minute":case"mins":case"min":case"m":return t*To;case"seconds":case"second":case"secs":case"sec":case"s":return t*Ho;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return t;default:return}}function Xoe(e){var n=Math.abs(e);if(n>=qi)return Math.round(e/qi)+"d";if(n>=Oo)return Math.round(e/Oo)+"h";if(n>=To)return Math.round(e/To)+"m";if(n>=Ho)return Math.round(e/Ho)+"s";return e+"ms"}function ese(e){var n=Math.abs(e);if(n>=qi)return wu(e,n,qi,"day");if(n>=Oo)return wu(e,n,Oo,"hour");if(n>=To)return wu(e,n,To,"minute");if(n>=Ho)return wu(e,n,Ho,"second");return e+" ms"}function wu(e,n,t,a){var r=n>=t*1.5;return Math.round(e/t)+" "+a+(r?"s":"")}});var xh=S((vOe,U1)=>{function nse(e){t.debug=t,t.default=t,t.coerce=c,t.disable=o,t.enable=r,t.enabled=s,t.humanize=z1(),t.destroy=A,Object.keys(e).forEach((l)=>{t[l]=e[l]}),t.names=[],t.skips=[],t.formatters={};function n(l){let d=0;for(let u=0;u<l.length;u++)d=(d<<5)-d+l.charCodeAt(u),d|=0;return t.colors[Math.abs(d)%t.colors.length]}t.selectColor=n;function t(l){let d,u=null,p,m;function g(...y){if(!g.enabled)return;let w=g,_=Number(new Date),C=_-(d||_);if(w.diff=C,w.prev=d,w.curr=_,d=_,y[0]=t.coerce(y[0]),typeof y[0]!=="string")y.unshift("%O");let F=0;y[0]=y[0].replace(/%([a-zA-Z%])/g,(I,U)=>{if(I==="%%")return"%";F++;let P=t.formatters[U];if(typeof P==="function"){let W=y[F];I=P.call(w,W),y.splice(F,1),F--}return I}),t.formatArgs.call(w,y),(w.log||t.log).apply(w,y)}if(g.namespace=l,g.useColors=t.useColors(),g.color=t.selectColor(l),g.extend=a,g.destroy=t.destroy,Object.defineProperty(g,"enabled",{enumerable:!0,configurable:!1,get:()=>{if(u!==null)return u;if(p!==t.namespaces)p=t.namespaces,m=t.enabled(l);return m},set:(y)=>{u=y}}),typeof t.init==="function")t.init(g);return g}function a(l,d){let u=t(this.namespace+(typeof d>"u"?":":d)+l);return u.log=this.log,u}function r(l){t.save(l),t.namespaces=l,t.names=[],t.skips=[];let d=(typeof l==="string"?l:"").trim().replace(/\s+/g,",").split(",").filter(Boolean);for(let u of d)if(u[0]==="-")t.skips.push(u.slice(1));else t.names.push(u)}function i(l,d){let u=0,p=0,m=-1,g=0;while(u<l.length)if(p<d.length&&(d[p]===l[u]||d[p]==="*"))if(d[p]==="*")m=p,g=u,p++;else u++,p++;else if(m!==-1)p=m+1,g++,u=g;else return!1;while(p<d.length&&d[p]==="*")p++;return p===d.length}function o(){let l=[...t.names,...t.skips.map((d)=>"-"+d)].join(",");return t.enable(""),l}function s(l){for(let d of t.skips)if(i(l,d))return!1;for(let d of t.names)if(i(l,d))return!0;return!1}function c(l){if(l instanceof Error)return l.stack||l.message;return l}function A(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return t.enable(t.load()),t}U1.exports=nse});var T1=S((H1,ku)=>{H1.formatArgs=ase;H1.save=rse;H1.load=ise;H1.useColors=tse;H1.storage=ose();H1.destroy=(()=>{let e=!1;return()=>{if(!e)e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}})();H1.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function tse(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function ase(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+ku.exports.humanize(this.diff),!this.useColors)return;let n="color: "+this.color;e.splice(1,0,n,"color: inherit");let t=0,a=0;e[0].replace(/%[a-zA-Z%]/g,(r)=>{if(r==="%%")return;if(t++,r==="%c")a=t}),e.splice(a,0,n)}H1.log=console.debug||console.log||(()=>{});function rse(e){try{if(e)H1.storage.setItem("debug",e);else H1.storage.removeItem("debug")}catch(n){}}function ise(){let e;try{e=H1.storage.getItem("debug")||H1.storage.getItem("DEBUG")}catch(n){}if(!e&&typeof process<"u"&&"env"in process)e=process.env.DEBUG;return e}function ose(){try{return localStorage}catch(e){}}ku.exports=xh()(H1);var{formatters:sse}=ku.exports;sse.j=function(e){try{return JSON.stringify(e)}catch(n){return"[UnexpectedJSONParseError]: "+n.message}}});var Z1=S((xOe,O1)=>{O1.exports=(e,n=process.argv)=>{let t=e.startsWith("-")?"":e.length===1?"-":"--",a=n.indexOf(t+e),r=n.indexOf("--");return a!==-1&&(r===-1||a<r)}});var W1=S((IOe,K1)=>{var gse=Lt("os"),Y1=Lt("tty"),Mt=Z1(),{env:jn}=process,qr;if(Mt("no-color")||Mt("no-colors")||Mt("color=false")||Mt("color=never"))qr=0;else if(Mt("color")||Mt("colors")||Mt("color=true")||Mt("color=always"))qr=1;if("FORCE_COLOR"in jn)if(jn.FORCE_COLOR==="true")qr=1;else if(jn.FORCE_COLOR==="false")qr=0;else qr=jn.FORCE_COLOR.length===0?1:Math.min(parseInt(jn.FORCE_COLOR,10),3);function Ih(e){if(e===0)return!1;return{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function Dh(e,n){if(qr===0)return 0;if(Mt("color=16m")||Mt("color=full")||Mt("color=truecolor"))return 3;if(Mt("color=256"))return 2;if(e&&!n&&qr===void 0)return 0;let t=qr||0;if(jn.TERM==="dumb")return t;if(process.platform==="win32"){let a=gse.release().split(".");if(Number(a[0])>=10&&Number(a[2])>=10586)return Number(a[2])>=14931?3:2;return 1}if("CI"in jn){if(["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((a)=>(a in jn))||jn.CI_NAME==="codeship")return 1;return t}if("TEAMCITY_VERSION"in jn)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(jn.TEAMCITY_VERSION)?1:0;if(jn.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in jn){let a=parseInt((jn.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(jn.TERM_PROGRAM){case"iTerm.app":return a>=3?3:2;case"Apple_Terminal":return 2}}if(/-256(color)?$/i.test(jn.TERM))return 2;if(/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(jn.TERM))return 1;if("COLORTERM"in jn)return 1;return t}function bse(e){let n=Dh(e,e&&e.isTTY);return Ih(n)}K1.exports={supportsColor:bse,stdout:Ih(Dh(!0,Y1.isatty(1))),stderr:Ih(Dh(!0,Y1.isatty(2)))}});var eF=S((V1,Cu)=>{var fse=Lt("tty"),Bu=Lt("util");V1.init=_se;V1.log=kse;V1.formatArgs=yse;V1.save=Bse;V1.load=Cse;V1.useColors=hse;V1.destroy=Bu.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");V1.colors=[6,2,3,4,5,1];try{let e=W1();if(e&&(e.stderr||e).level>=2)V1.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}catch(e){}V1.inspectOpts=Object.keys(process.env).filter((e)=>{return/^debug_/i.test(e)}).reduce((e,n)=>{let t=n.substring(6).toLowerCase().replace(/_([a-z])/g,(r,i)=>{return i.toUpperCase()}),a=process.env[n];if(/^(yes|on|true|enabled)$/i.test(a))a=!0;else if(/^(no|off|false|disabled)$/i.test(a))a=!1;else if(a==="null")a=null;else a=Number(a);return e[t]=a,e},{});function hse(){return"colors"in V1.inspectOpts?Boolean(V1.inspectOpts.colors):fse.isatty(process.stderr.fd)}function yse(e){let{namespace:n,useColors:t}=this;if(t){let a=this.color,r="\x1B[3"+(a<8?a:"8;5;"+a),i=` ${r};1m${n} \x1B[0m`;e[0]=i+e[0].split(`
141
+ `,n)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let n=nu(e),t=Po(n);return t.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let n=nu(e),t=Po(n);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,n){if(this.type!=="comment")return!1;if(this.indent<=n)return!1;return e.every((t)=>t.type==="newline"||t.type==="space")}*documentEnd(e){if(this.type!=="doc-mode"){if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:if(e.end)e.end.push(this.sourceToken);else e.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}}Pae.Parser=JD});var t1=S((Wae)=>{var VD=Tf(),Uae=Tc(),Jc=Oc(),Hae=ef(),Tae=Ge(),Oae=nh(),XD=th();function e1(e){let n=e.prettyErrors!==!1;return{lineCounter:e.lineCounter||n&&new Oae.LineCounter||null,prettyErrors:n}}function Zae(e,n={}){let{lineCounter:t,prettyErrors:a}=e1(n),r=new XD.Parser(t?.addNewLine),i=new VD.Composer(n),o=Array.from(i.compose(r.parse(e)));if(a&&t)for(let s of o)s.errors.forEach(Jc.prettifyError(e,t)),s.warnings.forEach(Jc.prettifyError(e,t));if(o.length>0)return o;return Object.assign([],{empty:!0},i.streamInfo())}function n1(e,n={}){let{lineCounter:t,prettyErrors:a}=e1(n),r=new XD.Parser(t?.addNewLine),i=new VD.Composer(n),o=null;for(let s of i.compose(r.parse(e),!0,e.length))if(!o)o=s;else if(o.options.logLevel!=="silent"){o.errors.push(new Jc.YAMLParseError(s.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(a&&t)o.errors.forEach(Jc.prettifyError(e,t)),o.warnings.forEach(Jc.prettifyError(e,t));return o}function Yae(e,n,t){let a=void 0;if(typeof n==="function")a=n;else if(t===void 0&&n&&typeof n==="object")t=n;let r=n1(e,t);if(!r)return null;if(r.warnings.forEach((i)=>Hae.warn(r.options.logLevel,i)),r.errors.length>0)if(r.options.logLevel!=="silent")throw r.errors[0];else r.errors=[];return r.toJS(Object.assign({reviver:a},t))}function Kae(e,n,t){let a=null;if(typeof n==="function"||Array.isArray(n))a=n;else if(t===void 0&&n)t=n;if(typeof t==="string")t=t.length;if(typeof t==="number"){let r=Math.round(t);t=r<1?void 0:r>8?{indent:8}:{indent:r}}if(e===void 0){let{keepUndefined:r}=t??n??{};if(!r)return}if(Tae.isDocument(e)&&!a)return e.toString(t);return new Uae.Document(e,a,t).toString(t)}Wae.parse=Yae;Wae.parseAllDocuments=Zae;Wae.parseDocument=n1;Wae.stringify=Kae});var lh=S((lUe,fie)=>{fie.exports={name:"@typescape-ai/cli",version:"1.9.1",description:"Typescape CLI - Create review sessions, export feedback, and integrate with AI workflows",type:"module",bin:{typescape:"./dist/cli.js"},files:["dist","README.md"],exports:{".":"./dist/cli.js"},publishConfig:{access:"public"},scripts:{build:"bun build src/index.ts --outfile=dist/cli.js --target=bun --bundle --minify",dev:"bun run --watch src/index.ts",test:"bun test",typecheck:"tsc -p tsconfig.typecheck.json --noEmit",lint:"eslint src",prepublishOnly:"bun run build"},dependencies:{},devDependencies:{"@types/bun":"1.1.14","@typescape/integrity":"workspace:*","@typescape/schemas":"workspace:*",ajv:"8.17.1","ajv-formats":"3.0.1",yaml:"2.8.2",zod:"4.3.0"},engines:{bun:">=1.0.0"},keywords:["typescape","cli","review","documentation","ai","feedback","bun"],repository:{type:"git",url:"https://github.com/voidserf/typescape-docs.git",directory:"apps/cli"},license:"MIT"}});var z1=S((EOe,P1)=>{var Ho=1000,To=Ho*60,Oo=To*60,qi=Oo*24,Woe=qi*7,Joe=qi*365.25;P1.exports=function(e,n){n=n||{};var t=typeof e;if(t==="string"&&e.length>0)return Voe(e);else if(t==="number"&&isFinite(e))return n.long?ese(e):Xoe(e);throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function Voe(e){if(e=String(e),e.length>100)return;var n=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!n)return;var t=parseFloat(n[1]),a=(n[2]||"ms").toLowerCase();switch(a){case"years":case"year":case"yrs":case"yr":case"y":return t*Joe;case"weeks":case"week":case"w":return t*Woe;case"days":case"day":case"d":return t*qi;case"hours":case"hour":case"hrs":case"hr":case"h":return t*Oo;case"minutes":case"minute":case"mins":case"min":case"m":return t*To;case"seconds":case"second":case"secs":case"sec":case"s":return t*Ho;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return t;default:return}}function Xoe(e){var n=Math.abs(e);if(n>=qi)return Math.round(e/qi)+"d";if(n>=Oo)return Math.round(e/Oo)+"h";if(n>=To)return Math.round(e/To)+"m";if(n>=Ho)return Math.round(e/Ho)+"s";return e+"ms"}function ese(e){var n=Math.abs(e);if(n>=qi)return wu(e,n,qi,"day");if(n>=Oo)return wu(e,n,Oo,"hour");if(n>=To)return wu(e,n,To,"minute");if(n>=Ho)return wu(e,n,Ho,"second");return e+" ms"}function wu(e,n,t,a){var r=n>=t*1.5;return Math.round(e/t)+" "+a+(r?"s":"")}});var xh=S((vOe,U1)=>{function nse(e){t.debug=t,t.default=t,t.coerce=c,t.disable=o,t.enable=r,t.enabled=s,t.humanize=z1(),t.destroy=A,Object.keys(e).forEach((l)=>{t[l]=e[l]}),t.names=[],t.skips=[],t.formatters={};function n(l){let d=0;for(let u=0;u<l.length;u++)d=(d<<5)-d+l.charCodeAt(u),d|=0;return t.colors[Math.abs(d)%t.colors.length]}t.selectColor=n;function t(l){let d,u=null,p,m;function g(...y){if(!g.enabled)return;let w=g,_=Number(new Date),C=_-(d||_);if(w.diff=C,w.prev=d,w.curr=_,d=_,y[0]=t.coerce(y[0]),typeof y[0]!=="string")y.unshift("%O");let F=0;y[0]=y[0].replace(/%([a-zA-Z%])/g,(I,U)=>{if(I==="%%")return"%";F++;let P=t.formatters[U];if(typeof P==="function"){let W=y[F];I=P.call(w,W),y.splice(F,1),F--}return I}),t.formatArgs.call(w,y),(w.log||t.log).apply(w,y)}if(g.namespace=l,g.useColors=t.useColors(),g.color=t.selectColor(l),g.extend=a,g.destroy=t.destroy,Object.defineProperty(g,"enabled",{enumerable:!0,configurable:!1,get:()=>{if(u!==null)return u;if(p!==t.namespaces)p=t.namespaces,m=t.enabled(l);return m},set:(y)=>{u=y}}),typeof t.init==="function")t.init(g);return g}function a(l,d){let u=t(this.namespace+(typeof d>"u"?":":d)+l);return u.log=this.log,u}function r(l){t.save(l),t.namespaces=l,t.names=[],t.skips=[];let d=(typeof l==="string"?l:"").trim().replace(/\s+/g,",").split(",").filter(Boolean);for(let u of d)if(u[0]==="-")t.skips.push(u.slice(1));else t.names.push(u)}function i(l,d){let u=0,p=0,m=-1,g=0;while(u<l.length)if(p<d.length&&(d[p]===l[u]||d[p]==="*"))if(d[p]==="*")m=p,g=u,p++;else u++,p++;else if(m!==-1)p=m+1,g++,u=g;else return!1;while(p<d.length&&d[p]==="*")p++;return p===d.length}function o(){let l=[...t.names,...t.skips.map((d)=>"-"+d)].join(",");return t.enable(""),l}function s(l){for(let d of t.skips)if(i(l,d))return!1;for(let d of t.names)if(i(l,d))return!0;return!1}function c(l){if(l instanceof Error)return l.stack||l.message;return l}function A(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return t.enable(t.load()),t}U1.exports=nse});var T1=S((H1,ku)=>{H1.formatArgs=ase;H1.save=rse;H1.load=ise;H1.useColors=tse;H1.storage=ose();H1.destroy=(()=>{let e=!1;return()=>{if(!e)e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}})();H1.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function tse(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function ase(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+ku.exports.humanize(this.diff),!this.useColors)return;let n="color: "+this.color;e.splice(1,0,n,"color: inherit");let t=0,a=0;e[0].replace(/%[a-zA-Z%]/g,(r)=>{if(r==="%%")return;if(t++,r==="%c")a=t}),e.splice(a,0,n)}H1.log=console.debug||console.log||(()=>{});function rse(e){try{if(e)H1.storage.setItem("debug",e);else H1.storage.removeItem("debug")}catch(n){}}function ise(){let e;try{e=H1.storage.getItem("debug")||H1.storage.getItem("DEBUG")}catch(n){}if(!e&&typeof process<"u"&&"env"in process)e=process.env.DEBUG;return e}function ose(){try{return localStorage}catch(e){}}ku.exports=xh()(H1);var{formatters:sse}=ku.exports;sse.j=function(e){try{return JSON.stringify(e)}catch(n){return"[UnexpectedJSONParseError]: "+n.message}}});var Z1=S((xOe,O1)=>{O1.exports=(e,n=process.argv)=>{let t=e.startsWith("-")?"":e.length===1?"-":"--",a=n.indexOf(t+e),r=n.indexOf("--");return a!==-1&&(r===-1||a<r)}});var W1=S((IOe,K1)=>{var gse=Lt("os"),Y1=Lt("tty"),Mt=Z1(),{env:jn}=process,qr;if(Mt("no-color")||Mt("no-colors")||Mt("color=false")||Mt("color=never"))qr=0;else if(Mt("color")||Mt("colors")||Mt("color=true")||Mt("color=always"))qr=1;if("FORCE_COLOR"in jn)if(jn.FORCE_COLOR==="true")qr=1;else if(jn.FORCE_COLOR==="false")qr=0;else qr=jn.FORCE_COLOR.length===0?1:Math.min(parseInt(jn.FORCE_COLOR,10),3);function Ih(e){if(e===0)return!1;return{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function Dh(e,n){if(qr===0)return 0;if(Mt("color=16m")||Mt("color=full")||Mt("color=truecolor"))return 3;if(Mt("color=256"))return 2;if(e&&!n&&qr===void 0)return 0;let t=qr||0;if(jn.TERM==="dumb")return t;if(process.platform==="win32"){let a=gse.release().split(".");if(Number(a[0])>=10&&Number(a[2])>=10586)return Number(a[2])>=14931?3:2;return 1}if("CI"in jn){if(["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((a)=>(a in jn))||jn.CI_NAME==="codeship")return 1;return t}if("TEAMCITY_VERSION"in jn)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(jn.TEAMCITY_VERSION)?1:0;if(jn.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in jn){let a=parseInt((jn.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(jn.TERM_PROGRAM){case"iTerm.app":return a>=3?3:2;case"Apple_Terminal":return 2}}if(/-256(color)?$/i.test(jn.TERM))return 2;if(/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(jn.TERM))return 1;if("COLORTERM"in jn)return 1;return t}function bse(e){let n=Dh(e,e&&e.isTTY);return Ih(n)}K1.exports={supportsColor:bse,stdout:Ih(Dh(!0,Y1.isatty(1))),stderr:Ih(Dh(!0,Y1.isatty(2)))}});var eF=S((V1,Cu)=>{var fse=Lt("tty"),Bu=Lt("util");V1.init=_se;V1.log=kse;V1.formatArgs=yse;V1.save=Bse;V1.load=Cse;V1.useColors=hse;V1.destroy=Bu.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");V1.colors=[6,2,3,4,5,1];try{let e=W1();if(e&&(e.stderr||e).level>=2)V1.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}catch(e){}V1.inspectOpts=Object.keys(process.env).filter((e)=>{return/^debug_/i.test(e)}).reduce((e,n)=>{let t=n.substring(6).toLowerCase().replace(/_([a-z])/g,(r,i)=>{return i.toUpperCase()}),a=process.env[n];if(/^(yes|on|true|enabled)$/i.test(a))a=!0;else if(/^(no|off|false|disabled)$/i.test(a))a=!1;else if(a==="null")a=null;else a=Number(a);return e[t]=a,e},{});function hse(){return"colors"in V1.inspectOpts?Boolean(V1.inspectOpts.colors):fse.isatty(process.stderr.fd)}function yse(e){let{namespace:n,useColors:t}=this;if(t){let a=this.color,r="\x1B[3"+(a<8?a:"8;5;"+a),i=` ${r};1m${n} \x1B[0m`;e[0]=i+e[0].split(`
142
142
  `).join(`
143
143
  `+i),e.push(r+"m+"+Cu.exports.humanize(this.diff)+"\x1B[0m")}else e[0]=wse()+n+" "+e[0]}function wse(){if(V1.inspectOpts.hideDate)return"";return new Date().toISOString()+" "}function kse(...e){return process.stderr.write(Bu.formatWithOptions(V1.inspectOpts,...e)+`
144
144
  `)}function Bse(e){if(e)process.env.DEBUG=e;else delete process.env.DEBUG}function Cse(){return process.env.DEBUG}function _se(e){e.inspectOpts={};let n=Object.keys(V1.inspectOpts);for(let t=0;t<n.length;t++)e.inspectOpts[n[t]]=V1.inspectOpts[n[t]]}Cu.exports=xh()(V1);var{formatters:J1}=Cu.exports;J1.o=function(e){return this.inspectOpts.colors=this.useColors,Bu.inspect(e,this.inspectOpts).split(`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@typescape-ai/cli",
3
- "version": "1.8.9",
3
+ "version": "1.9.1",
4
4
  "description": "Typescape CLI - Create review sessions, export feedback, and integrate with AI workflows",
5
5
  "type": "module",
6
6
  "bin": {