vbapm 0.6.14 → 0.6.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/addins/build/vbapm.xlam +0 -0
- package/lib/_commonjsHelpers-Bjf42z7h.js +1 -0
- package/lib/build-project-BczswKQl.js +3 -0
- package/lib/build-target-D6L5nsgt.js +9 -0
- package/lib/crc32-Cc3OMFYk.js +1 -0
- package/lib/create-project-CPIRr0DV.js +10 -0
- package/lib/debug.js +1 -1
- package/lib/export-project-DQ3bfvbV.js +4 -0
- package/lib/export-target-CN6RA_mA.js +4 -0
- package/lib/{get-target-e760a439.js → get-target-CH6IpAa1.js} +1 -1
- package/lib/index-BlteXxjY.js +1 -0
- package/lib/index-CEojr58e.js +2 -0
- package/lib/index-D-khpcjL.js +54 -0
- package/lib/index-DSgWshzu.js +2 -0
- package/lib/index-DXFu_Z-o.js +6 -0
- package/lib/index-Dg07BXJE.js +14 -0
- package/lib/index.js +1 -1
- package/lib/init-project-dRuDA4YO.js +15 -0
- package/lib/installer-CJlDenLg.js +9 -0
- package/lib/{load-from-project-acf7400a.js → load-from-project-Bpb6Ne_i.js} +1 -1
- package/lib/once-fkpTAKD3.js +1 -0
- package/lib/project-C3bWzV0O.js +29 -0
- package/lib/run-macro-D_9-BO3U.js +1 -0
- package/lib/sat-solver-5AniWyxz.js +1 -0
- package/lib/string_decoder-CW-j4E6X.js +1 -0
- package/lib/test-project-BTkTNZXs.js +1 -0
- package/lib/tmp-C7yJT4iq.js +8 -0
- package/lib/toml-patch.es-CxrbsPnB.js +3 -0
- package/lib/transform-target-Doak2S1q.js +2 -0
- package/lib/vbapm-build-B1OOy6VL.js +9 -0
- package/lib/vbapm-export-vvUDCDqi.js +7 -0
- package/lib/{vbapm-init-5c8eb026.js → vbapm-init-csKsZ87H.js} +2 -2
- package/lib/vbapm-new-Dt0tX1xQ.js +17 -0
- package/lib/{vbapm-run-2f17fb22.js → vbapm-run-Ccciwg2y.js} +1 -1
- package/lib/{vbapm-test-a7b30592.js → vbapm-test-u7AWC-AV.js} +1 -1
- package/lib/vbapm-version-Bsb-cWCD.js +8 -0
- package/lib/vbapm.js +10 -10
- package/package.json +12 -12
- package/lib/_commonjsHelpers-553b27b3.js +0 -1
- package/lib/build-project-eb8454f0.js +0 -3
- package/lib/build-target-dbcc69c7.js +0 -9
- package/lib/create-project-3154aace.js +0 -10
- package/lib/export-project-bc13c1ae.js +0 -4
- package/lib/export-target-5d28d188.js +0 -4
- package/lib/index-4ce3d28b.js +0 -6
- package/lib/index-72c1a91d.js +0 -3
- package/lib/index-c5b5f6d1.js +0 -2
- package/lib/index-ddd39b65.js +0 -5
- package/lib/init-project-ceecd718.js +0 -15
- package/lib/installer-dbc2c34a.js +0 -21
- package/lib/once-5205b917.js +0 -1
- package/lib/project-43370ed3.js +0 -29
- package/lib/run-macro-4f1375ca.js +0 -1
- package/lib/sat-solver-f9155891.js +0 -1
- package/lib/test-project-669dfcfb.js +0 -1
- package/lib/tmp-14f9d850.js +0 -9
- package/lib/toml-patch.es-6bd2145d.js +0 -3
- package/lib/vbapm-build-8ff58485.js +0 -9
- package/lib/vbapm-export-96798f4f.js +0 -7
- package/lib/vbapm-new-cd174cbb.js +0 -17
- package/lib/vbapm-version-c5f3d55a.js +0 -8
- package/lib/workbook-xml-a61269f4.js +0 -2
package/lib/index-72c1a91d.js
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
"use strict";var t=require("./_commonjsHelpers-553b27b3.js");function r(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var e=r(require("buffer")),o=t.createCommonjsModule(function(t,r){
|
|
2
|
-
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
3
|
-
var o=e.default.Buffer;function n(t,r){for(var e in t)r[e]=t[e]}function a(t,r,e){return o(t,r,e)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?t.exports=e.default:(n(e.default,r),r.Buffer=a),a.prototype=Object.create(o.prototype),n(o,a),a.from=function(t,r,e){if("number"==typeof t)throw new TypeError("Argument must not be a number");return o(t,r,e)},a.alloc=function(t,r,e){if("number"!=typeof t)throw new TypeError("Argument must be a number");var n=o(t);return void 0!==r?"string"==typeof e?n.fill(r,e):n.fill(r):n.fill(0),n},a.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return o(t)},a.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return e.default.SlowBuffer(t)}}),n={}.toString,a=Array.isArray||function(t){return"[object Array]"==n.call(t)},i=TypeError,y=Object,f=Error,p=EvalError,u=RangeError,l=ReferenceError,c=SyntaxError,s=URIError,b=Math.abs,g=Math.floor,d=Math.max,h=Math.min,A=Math.pow,m=Math.round,v=Number.isNaN||function(t){return t!=t},w=Object.getOwnPropertyDescriptor;if(w)try{w([],"length")}catch(t){w=null}var P=w,S=Object.defineProperty||!1;if(S)try{S({},"a",{value:1})}catch(t){S=!1}var j,O=S,E=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},r=Symbol("test"),e=Object(r);if("string"==typeof r)return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;if("[object Symbol]"!==Object.prototype.toString.call(e))return!1;for(var o in t[r]=42,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var n=Object.getOwnPropertySymbols(t);if(1!==n.length||n[0]!==r)return!1;if(!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var a=Object.getOwnPropertyDescriptor(t,r);if(42!==a.value||!0!==a.enumerable)return!1}return!0},U="undefined"!=typeof Symbol&&Symbol,F="undefined"!=typeof Reflect&&Reflect.getPrototypeOf||null,R=y,I=R.getPrototypeOf||null,B=Object.prototype.toString,M=Math.max,T=function(t,r){for(var e=[],o=0;o<t.length;o+=1)e[o]=t[o];for(var n=0;n<r.length;n+=1)e[n+t.length]=r[n];return e},_=Function.prototype.bind||function(t){var r=this;if("function"!=typeof r||"[object Function]"!==B.apply(r))throw new TypeError("Function.prototype.bind called on incompatible "+r);for(var e,o=function(t,r){for(var e=[],o=r||0,n=0;o<t.length;o+=1,n+=1)e[n]=t[o];return e}(arguments,1),n=M(0,r.length-o.length),a=[],i=0;i<n;i++)a[i]="$"+i;if(e=Function("binder","return function ("+function(t,r){for(var e="",o=0;o<t.length;o+=1)e+=t[o],o+1<t.length&&(e+=r);return e}(a,",")+"){ return binder.apply(this,arguments); }")(function(){if(this instanceof e){var n=r.apply(this,T(o,arguments));return Object(n)===n?n:this}return r.apply(t,T(o,arguments))}),r.prototype){var y=function(){};y.prototype=r.prototype,e.prototype=new y,y.prototype=null}return e},x=Function.prototype.call,N=Function.prototype.apply,G="undefined"!=typeof Reflect&&Reflect&&Reflect.apply||_.call(x,N),k=i,C=function(t){if(t.length<1||"function"!=typeof t[0])throw new k("a function is required");return G(_,x,t)},D=P;try{j=[].__proto__===Array.prototype}catch(t){if(!t||"object"!=typeof t||!("code"in t)||"ERR_PROTO_ACCESS"!==t.code)throw t}var W,L=!!j&&D&&D(Object.prototype,"__proto__"),V=Object,J=V.getPrototypeOf,$=L&&"function"==typeof L.get?C([L.get]):"function"==typeof J&&function(t){return J(null==t?t:V(t))},q=F?function(t){return F(t)}:I?function(t){if(!t||"object"!=typeof t&&"function"!=typeof t)throw new TypeError("getProto: not an object");return I(t)}:$?function(t){return $(t)}:null,H=Function.prototype.call,z=Object.prototype.hasOwnProperty,Y=_.call(H,z),K=f,Q=p,X=u,Z=l,tt=c,rt=s,et=b,ot=g,nt=d,at=h,it=A,yt=m,ft=function(t){return v(t)||0===t?t:t<0?-1:1},pt=O,ut=Y,lt=Function,ct=function(t){try{return lt('"use strict"; return ('+t+").constructor;")()}catch(t){}},st=function(){throw new k},bt=D?function(){try{return st}catch(t){try{return D(arguments,"callee").get}catch(t){return st}}}():st,gt="function"==typeof U&&"function"==typeof Symbol&&"symbol"==typeof U("foo")&&"symbol"==typeof Symbol("bar")&&E(),dt={},ht="undefined"!=typeof Uint8Array&&q?q(Uint8Array):W,At={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?W:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?W:ArrayBuffer,"%ArrayIteratorPrototype%":gt&&q?q([][Symbol.iterator]()):W,"%AsyncFromSyncIteratorPrototype%":W,"%AsyncFunction%":dt,"%AsyncGenerator%":dt,"%AsyncGeneratorFunction%":dt,"%AsyncIteratorPrototype%":dt,"%Atomics%":"undefined"==typeof Atomics?W:Atomics,"%BigInt%":"undefined"==typeof BigInt?W:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?W:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?W:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?W:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":K,"%eval%":eval,"%EvalError%":Q,"%Float16Array%":"undefined"==typeof Float16Array?W:Float16Array,"%Float32Array%":"undefined"==typeof Float32Array?W:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?W:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?W:FinalizationRegistry,"%Function%":lt,"%GeneratorFunction%":dt,"%Int8Array%":"undefined"==typeof Int8Array?W:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?W:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?W:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":gt&&q?q(q([][Symbol.iterator]())):W,"%JSON%":"object"==typeof JSON?JSON:W,"%Map%":"undefined"==typeof Map?W:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&>&&q?q((new Map)[Symbol.iterator]()):W,"%Math%":Math,"%Number%":Number,"%Object%":R,"%Object.getOwnPropertyDescriptor%":D,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?W:Promise,"%Proxy%":"undefined"==typeof Proxy?W:Proxy,"%RangeError%":X,"%ReferenceError%":Z,"%Reflect%":"undefined"==typeof Reflect?W:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?W:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&>&&q?q((new Set)[Symbol.iterator]()):W,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?W:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":gt&&q?q(""[Symbol.iterator]()):W,"%Symbol%":gt?Symbol:W,"%SyntaxError%":tt,"%ThrowTypeError%":bt,"%TypedArray%":ht,"%TypeError%":k,"%Uint8Array%":"undefined"==typeof Uint8Array?W:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?W:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?W:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?W:Uint32Array,"%URIError%":rt,"%WeakMap%":"undefined"==typeof WeakMap?W:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?W:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?W:WeakSet,"%Function.prototype.call%":x,"%Function.prototype.apply%":N,"%Object.defineProperty%":pt,"%Object.getPrototypeOf%":I,"%Math.abs%":et,"%Math.floor%":ot,"%Math.max%":nt,"%Math.min%":at,"%Math.pow%":it,"%Math.round%":yt,"%Math.sign%":ft,"%Reflect.getPrototypeOf%":F};if(q)try{null.error}catch(t){var mt=q(q(t));At["%Error.prototype%"]=mt}var vt,wt,Pt=function t(r){var e;if("%AsyncFunction%"===r)e=ct("async function () {}");else if("%GeneratorFunction%"===r)e=ct("function* () {}");else if("%AsyncGeneratorFunction%"===r)e=ct("async function* () {}");else if("%AsyncGenerator%"===r){var o=t("%AsyncGeneratorFunction%");o&&(e=o.prototype)}else if("%AsyncIteratorPrototype%"===r){var n=t("%AsyncGenerator%");n&&q&&(e=q(n.prototype))}return At[r]=e,e},St={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},jt=_.call(x,Array.prototype.concat),Ot=_.call(N,Array.prototype.splice),Et=_.call(x,String.prototype.replace),Ut=_.call(x,String.prototype.slice),Ft=_.call(x,RegExp.prototype.exec),Rt=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,It=/\\(\\)?/g,Bt=function(t,r){var e,o=t;if(ut(St,o)&&(o="%"+(e=St[o])[0]+"%"),ut(At,o)){var n=At[o];if(n===dt&&(n=Pt(o)),void 0===n&&!r)throw new k("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:e,name:o,value:n}}throw new tt("intrinsic "+t+" does not exist!")},Mt=function(t,r){if("string"!=typeof t||0===t.length)throw new k("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof r)throw new k('"allowMissing" argument must be a boolean');if(null===Ft(/^%?[^%]*%?$/,t))throw new tt("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var e=function(t){var r=Ut(t,0,1),e=Ut(t,-1);if("%"===r&&"%"!==e)throw new tt("invalid intrinsic syntax, expected closing `%`");if("%"===e&&"%"!==r)throw new tt("invalid intrinsic syntax, expected opening `%`");var o=[];return Et(t,Rt,function(t,r,e,n){o[o.length]=e?Et(n,It,"$1"):r||t}),o}(t),o=e.length>0?e[0]:"",n=Bt("%"+o+"%",r),a=n.name,i=n.value,y=!1,f=n.alias;f&&(o=f[0],Ot(e,jt([0,1],f)));for(var p=1,u=!0;p<e.length;p+=1){var l=e[p],c=Ut(l,0,1),s=Ut(l,-1);if(('"'===c||"'"===c||"`"===c||'"'===s||"'"===s||"`"===s)&&c!==s)throw new tt("property names with quotes must have matching quotes");if("constructor"!==l&&u||(y=!0),ut(At,a="%"+(o+="."+l)+"%"))i=At[a];else if(null!=i){if(!(l in i)){if(!r)throw new k("base intrinsic for "+t+" exists, but the property is not available.");return}if(D&&p+1>=e.length){var b=D(i,l);i=(u=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:i[l]}else u=ut(i,l),i=i[l];u&&!y&&(At[a]=i)}}return i},Tt=C([Mt("%String.prototype.indexOf%")]),_t=Function.prototype.toString,xt="object"==typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"==typeof xt&&"function"==typeof Object.defineProperty)try{vt=Object.defineProperty({},"length",{get:function(){throw wt}}),wt={},xt(function(){throw 42},null,vt)}catch(t){t!==wt&&(xt=null)}else xt=null;var Nt=/^\s*class\b/,Gt=function(t){try{var r=_t.call(t);return Nt.test(r)}catch(t){return!1}},kt=function(t){try{return!Gt(t)&&(_t.call(t),!0)}catch(t){return!1}},Ct=Object.prototype.toString,Dt="function"==typeof Symbol&&!!Symbol.toStringTag,Wt=!(0 in[,]),Lt=function(){return!1};if("object"==typeof document){var Vt=document.all;Ct.call(Vt)===Ct.call(document.all)&&(Lt=function(t){if((Wt||!t)&&(void 0===t||"object"==typeof t))try{var r=Ct.call(t);return("[object HTMLAllCollection]"===r||"[object HTML document.all class]"===r||"[object HTMLCollection]"===r||"[object Object]"===r)&&null==t("")}catch(t){}return!1})}var Jt=xt?function(t){if(Lt(t))return!0;if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;try{xt(t,null,vt)}catch(t){if(t!==wt)return!1}return!Gt(t)&&kt(t)}:function(t){if(Lt(t))return!0;if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if(Dt)return kt(t);if(Gt(t))return!1;var r=Ct.call(t);return!("[object Function]"!==r&&"[object GeneratorFunction]"!==r&&!/^\[object HTML/.test(r))&&kt(t)},$t=Object.prototype.toString,qt=Object.prototype.hasOwnProperty;var Ht=function(t,r,e){if(!Jt(r))throw new TypeError("iterator must be a function");var o,n;arguments.length>=3&&(o=e),n=t,"[object Array]"===$t.call(n)?function(t,r,e){for(var o=0,n=t.length;o<n;o++)qt.call(t,o)&&(null==e?r(t[o],o,t):r.call(e,t[o],o,t))}(t,r,o):"string"==typeof t?function(t,r,e){for(var o=0,n=t.length;o<n;o++)null==e?r(t.charAt(o),o,t):r.call(e,t.charAt(o),o,t)}(t,r,o):function(t,r,e){for(var o in t)qt.call(t,o)&&(null==e?r(t[o],o,t):r.call(e,t[o],o,t))}(t,r,o)},zt=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"],Yt="undefined"==typeof globalThis?t.commonjsGlobal:globalThis,Kt=function(){return!!pt};Kt.hasArrayLengthDefineBug=function(){if(!pt)return null;try{return 1!==pt([],"length",{value:1}).length}catch(t){return!0}};var Qt=function(t,r,e){if(!t||"object"!=typeof t&&"function"!=typeof t)throw new k("`obj` must be an object or a function`");if("string"!=typeof r&&"symbol"!=typeof r)throw new k("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new k("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new k("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new k("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new k("`loose`, if provided, must be a boolean");var o=arguments.length>3?arguments[3]:null,n=arguments.length>4?arguments[4]:null,a=arguments.length>5?arguments[5]:null,i=arguments.length>6&&arguments[6],y=!!D&&D(t,r);if(pt)pt(t,r,{configurable:null===a&&y?y.configurable:!a,enumerable:null===o&&y?y.enumerable:!o,value:e,writable:null===n&&y?y.writable:!n});else{if(!i&&(o||n||a))throw new tt("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");t[r]=e}},Xt=Kt(),Zt=Mt("%Math.floor%"),tr=function(){return G(_,N,arguments)},rr=function(t,r){if("function"!=typeof t)throw new k("`fn` is not a function");if("number"!=typeof r||r<0||r>4294967295||Zt(r)!==r)throw new k("`length` must be a positive 32-bit integer");var e=arguments.length>2&&!!arguments[2],o=!0,n=!0;if("length"in t&&D){var a=D(t,"length");a&&!a.configurable&&(o=!1),a&&!a.writable&&(n=!1)}return(o||n||!e)&&(Xt?Qt(t,"length",r,!0,!0):Qt(t,"length",r)),t},er=t.createCommonjsModule(function(t){t.exports=function(t){var r=C(arguments),e=t.length-(arguments.length-1);return rr(r,1+(e>0?e:0),!0)},pt?pt(t.exports,"apply",{value:tr}):t.exports.apply=tr}),or=function(){for(var t=[],r=0;r<zt.length;r++)"function"==typeof Yt[zt[r]]&&(t[t.length]=zt[r]);return t},nr=function(t,r){var e=Mt(t,!!r);return"function"==typeof e&&Tt(t,".prototype.")>-1?C([e]):e},ar=nr("Object.prototype.toString"),ir=E()&&!!Symbol.toStringTag,yr="undefined"==typeof globalThis?t.commonjsGlobal:globalThis,fr=or(),pr=nr("String.prototype.slice"),ur=nr("Array.prototype.indexOf",!0)||function(t,r){for(var e=0;e<t.length;e+=1)if(t[e]===r)return e;return-1},lr={__proto__:null};Ht(fr,ir&&D&&q?function(t){var r=new yr[t];if(Symbol.toStringTag in r&&q){var e=q(r),o=D(e,Symbol.toStringTag);if(!o&&e){var n=q(e);o=D(n,Symbol.toStringTag)}if(o&&o.get){var a=er(o.get);lr["$"+t]=a}}}:function(t){var r=new yr[t],e=r.slice||r.set;if(e){var o=er(e);lr["$"+t]=o}});var cr=function(t){if(!t||"object"!=typeof t)return!1;if(!ir){var r=pr(ar(t),8,-1);return ur(fr,r)>-1?r:"Object"===r&&function(t){var r=!1;return Ht(lr,function(e,o){if(!r)try{e(t),r=pr(o,1)}catch(t){}}),r}(t)}return D?function(t){var r=!1;return Ht(lr,function(e,o){if(!r)try{"$"+e(t)===o&&(r=pr(o,1))}catch(t){}}),r}(t):null},sr=function(t){return!!cr(t)},br=nr("TypedArray.prototype.buffer",!0)||function(t){if(!sr(t))throw new k("Not a Typed Array");return t.buffer},gr=o.Buffer,dr=ArrayBuffer.isView||function(t){try{return br(t),!0}catch(t){return!1}},hr="undefined"!=typeof Uint8Array,Ar="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,mr=Ar&&(gr.prototype instanceof Uint8Array||gr.TYPED_ARRAY_SUPPORT),vr=function(t,r){if(gr.isBuffer(t))return t.constructor&&!("isBuffer"in t)?gr.from(t):t;if("string"==typeof t)return gr.from(t,r);if(Ar&&dr(t)){if(0===t.byteLength)return gr.alloc(0);if(mr){var e=gr.from(t.buffer,t.byteOffset,t.byteLength);if(e.byteLength===t.byteLength)return e}var o=t instanceof Uint8Array?t:new Uint8Array(t.buffer,t.byteOffset,t.byteLength),n=gr.from(o);if(n.length===t.byteLength)return n}if(hr&&t instanceof Uint8Array)return gr.from(t);var i=a(t);if(i)for(var y=0;y<t.length;y+=1){var f=t[y];if("number"!=typeof f||f<0||f>255||~~f!==f)throw new RangeError("Array items must be numbers in the range 0-255.")}if(i||gr.isBuffer(t)&&t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t))return gr.from(t);throw new TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.')};exports.safeBuffer=o,exports.toBuffer=vr;
|
package/lib/index-c5b5f6d1.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("stream"),t=require("zlib"),r=require("http"),o=require("https"),n=require("./once-5205b917.js"),s=require("querystring"),a=require("url");function u(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var c=u(e),i=u(t),d=u(r),l=u(o),h=u(s),f=u(a);const p=["aborted","complete","headers","httpVersion","httpVersionMinor","httpVersionMajor","method","rawHeaders","rawTrailers","setTimeout","socket","statusCode","statusMessage","trailers","url"];const{Transform:m,PassThrough:y}=c.default;var b=e=>{const t=(e.headers["content-encoding"]||"").toLowerCase();if(!["gzip","deflate","br"].includes(t))return e;const r="br"===t;if(r&&"function"!=typeof i.default.createBrotliDecompress)return e.destroy(new Error("Brotli is not supported on Node.js < 12")),e;let o=!0;const n=new m({transform(e,t,r){o=!1,r(null,e)},flush(e){e()}}),s=new y({autoDestroy:!1,destroy(t,r){e.destroy(),r(t)}}),a=r?i.default.createBrotliDecompress():i.default.createUnzip();return a.once("error",t=>{!o||e.readable?s.destroy(t):s.end()}),((e,t)=>{if(t._readableState.autoDestroy)throw new Error("The second stream must have the `autoDestroy` option set to `false`");const r=new Set(Object.keys(e).concat(p)),o={};for(const n of r)n in t||(o[n]={get(){const t=e[n];return"function"==typeof t?t.bind(e):t},set(t){e[n]=t},enumerable:!0,configurable:!1});Object.defineProperties(t,o),e.once("aborted",()=>{t.destroy(),t.emit("aborted")}),e.once("close",()=>{e.complete&&t.readable?t.once("end",()=>{t.emit("close")}):t.emit("close")})})(e,s),e.pipe(n).pipe(a).pipe(s),s},g=j;
|
|
2
|
-
/*! simple-get. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */const w=e=>null!==e&&"object"==typeof e&&"function"==typeof e.pipe;function j(e,t){if(e=Object.assign({maxRedirects:10},"string"==typeof e?{url:e}:e),t=n.once_1(t),e.url){const{hostname:t,port:r,protocol:o,auth:n,path:s}=f.default.parse(e.url);delete e.url,t||r||o||n?Object.assign(e,{hostname:t,port:r,protocol:o,auth:n,path:s}):e.path=s}const r={"accept-encoding":"gzip, deflate"};let o;e.headers&&Object.keys(e.headers).forEach(t=>r[t.toLowerCase()]=e.headers[t]),e.headers=r,e.body?o=e.json&&!w(e.body)?JSON.stringify(e.body):e.body:e.form&&(o="string"==typeof e.form?e.form:h.default.stringify(e.form),e.headers["content-type"]="application/x-www-form-urlencoded"),o&&(e.method||(e.method="POST"),w(o)||(e.headers["content-length"]=Buffer.byteLength(o)),e.json&&!e.form&&(e.headers["content-type"]="application/json")),delete e.body,delete e.form,e.json&&(e.headers.accept="application/json"),e.method&&(e.method=e.method.toUpperCase());const s=e.hostname,a=("https:"===e.protocol?l.default:d.default).request(e,r=>{if(!1!==e.followRedirects&&r.statusCode>=300&&r.statusCode<400&&r.headers.location){e.url=r.headers.location,delete e.headers.host,r.resume();const o=f.default.parse(e.url).hostname;return null!==o&&o!==s&&(delete e.headers.cookie,delete e.headers.authorization),"POST"===e.method&&[301,302].includes(r.statusCode)&&(e.method="GET",delete e.headers["content-length"],delete e.headers["content-type"]),0===e.maxRedirects--?t(new Error("too many redirects")):j(e,t)}const o="HEAD"!==e.method;t(null,o?b(r):r)});return a.on("timeout",()=>{a.abort(),t(new Error("Request timed out"))}),a.on("error",t),w(o)?o.on("error",t).pipe(a):a.end(o),a}function v(e){return e[Symbol.asyncIterator]?e[Symbol.asyncIterator]():e[Symbol.iterator]?e[Symbol.iterator]():e.next?e:function(e){let t=[e];return{next:()=>Promise.resolve({done:0===t.length,value:t.pop()}),return:()=>(t=[],{}),[Symbol.asyncIterator](){return this}}}(e)}async function S(e,t){const r=v(e);for(;;){const{value:e,done:o}=await r.next();if(e&&await t(e),o)break}r.return&&r.return()}async function q({onProgress:e,url:t,method:r="GET",headers:o={},agent:n,body:s}){return s&&Array.isArray(s)?s=Buffer.from(await async function(e){let t=0;const r=[];await S(e,e=>{r.push(e),t+=e.byteLength});const o=new Uint8Array(t);let n=0;for(const e of r)o.set(e,n),n+=e.byteLength;return o}(s)):s&&(s=function(e){const{PassThrough:t}=require("readable-stream"),r=new t;return setTimeout(async()=>{await S(e,e=>r.write(e)),r.end()},1),r}(s)),new Promise((e,a)=>{g({url:t,method:r,headers:o,agent:n,body:s},(t,r)=>{if(t)return a(t);try{const t=function(e){const t=Object.getOwnPropertyDescriptor(e,Symbol.asyncIterator);if(t&&t.enumerable)return e;let r=!1;const o=[];let n={};return e.on("data",e=>{o.push(e),n.resolve&&(n.resolve({value:o.shift(),done:!1}),n={})}),e.on("error",e=>{n.reject&&(n.reject(e),n={})}),e.on("end",()=>{r=!0,n.resolve&&(n.resolve({done:!0}),n={})}),{next:()=>new Promise((e,t)=>0===o.length&&r?e({done:!0}):o.length>0?e({value:o.shift(),done:!1}):void(0!==o.length||r||(n={resolve:e,reject:t}))),return(){e.removeAllListeners(),e.destroy&&e.destroy()},[Symbol.asyncIterator](){return this}}}(r);e({url:r.url,method:r.method,statusCode:r.statusCode,statusMessage:r.statusMessage,body:t,headers:r.headers})}catch(e){a(e)}})})}j.concat=(e,t)=>j(e,(r,o)=>{if(r)return t(r);!function(e,t){var r=[];e.on("data",function(e){r.push(e)}),e.once("end",function(){t&&t(null,Buffer.concat(r)),t=null}),e.once("error",function(e){t&&t(e),t=null})}(o,(r,n)=>{if(r)return t(r);if(e.json)try{n=JSON.parse(n.toString())}catch(r){return t(r,o,n)}t(null,o,n)})}),["get","post","put","patch","head","delete"].forEach(e=>{j[e]=(t,r)=>("string"==typeof t&&(t={url:t}),j(Object.assign({method:e.toUpperCase()},t),r))});var O={request:q};exports.default=O,exports.request=q;
|
package/lib/index-ddd39b65.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("path"),t=require("./installer-dbc2c34a.js"),r=require("./_commonjsHelpers-553b27b3.js"),n=require("util"),i=require("stream"),o=require("./index-72c1a91d.js"),a=require("fs"),s=require("constants"),f=require("./once-5205b917.js"),u=require("string_decoder"),l=require("zlib"),c=require("events"),m=require("buffer");function p(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function d(e,t){return t.forEach(function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach(function(r){if("default"!==r&&!(r in e)){var n=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(e,r,n.get?n:{enumerable:!0,get:function(){return t[r]}})}})}),Object.freeze(e)}var h=p(e),y=p(n),g=p(i),x=p(a),v=p(s),w=p(u),b=p(l),_=p(c),E=p(m),z=e=>{const t=new Uint8Array(e);if(!(t&&t.length>1))return null;const r=(e,r)=>{r=Object.assign({offset:0},r);for(let n=0;n<e.length;n++)if(e[n]!==t[n+r.offset])return!1;return!0};if(r([255,216,255]))return{ext:"jpg",mime:"image/jpeg"};if(r([137,80,78,71,13,10,26,10]))return{ext:"png",mime:"image/png"};if(r([71,73,70]))return{ext:"gif",mime:"image/gif"};if(r([87,69,66,80],{offset:8}))return{ext:"webp",mime:"image/webp"};if(r([70,76,73,70]))return{ext:"flif",mime:"image/flif"};if((r([73,73,42,0])||r([77,77,0,42]))&&r([67,82],{offset:8}))return{ext:"cr2",mime:"image/x-canon-cr2"};if(r([73,73,42,0])||r([77,77,0,42]))return{ext:"tif",mime:"image/tiff"};if(r([66,77]))return{ext:"bmp",mime:"image/bmp"};if(r([73,73,188]))return{ext:"jxr",mime:"image/vnd.ms-photo"};if(r([56,66,80,83]))return{ext:"psd",mime:"image/vnd.adobe.photoshop"};if(r([80,75,3,4])&&r([109,105,109,101,116,121,112,101,97,112,112,108,105,99,97,116,105,111,110,47,101,112,117,98,43,122,105,112],{offset:30}))return{ext:"epub",mime:"application/epub+zip"};if(r([80,75,3,4])&&r([77,69,84,65,45,73,78,70,47,109,111,122,105,108,108,97,46,114,115,97],{offset:30}))return{ext:"xpi",mime:"application/x-xpinstall"};if(r([80,75])&&(3===t[2]||5===t[2]||7===t[2])&&(4===t[3]||6===t[3]||8===t[3]))return{ext:"zip",mime:"application/zip"};if(r([117,115,116,97,114],{offset:257}))return{ext:"tar",mime:"application/x-tar"};if(r([82,97,114,33,26,7])&&(0===t[6]||1===t[6]))return{ext:"rar",mime:"application/x-rar-compressed"};if(r([31,139,8]))return{ext:"gz",mime:"application/gzip"};if(r([66,90,104]))return{ext:"bz2",mime:"application/x-bzip2"};if(r([55,122,188,175,39,28]))return{ext:"7z",mime:"application/x-7z-compressed"};if(r([120,1]))return{ext:"dmg",mime:"application/x-apple-diskimage"};if(r([0,0,0])&&(24===t[3]||32===t[3])&&r([102,116,121,112],{offset:4})||r([51,103,112,53])||r([0,0,0,28,102,116,121,112,109,112,52,50])&&r([109,112,52,49,109,112,52,50,105,115,111,109],{offset:16})||r([0,0,0,28,102,116,121,112,105,115,111,109])||r([0,0,0,28,102,116,121,112,109,112,52,50,0,0,0,0]))return{ext:"mp4",mime:"video/mp4"};if(r([0,0,0,28,102,116,121,112,77,52,86]))return{ext:"m4v",mime:"video/x-m4v"};if(r([77,84,104,100]))return{ext:"mid",mime:"audio/midi"};if(r([26,69,223,163])){const e=t.subarray(4,4100),r=e.findIndex((e,t,r)=>66===r[t]&&130===r[t+1]);if(r>=0){const t=r+3,n=r=>Array.from(r).every((r,n)=>e[t+n]===r.charCodeAt(0));if(n("matroska"))return{ext:"mkv",mime:"video/x-matroska"};if(n("webm"))return{ext:"webm",mime:"video/webm"}}}return r([0,0,0,20,102,116,121,112,113,116,32,32])||r([102,114,101,101],{offset:4})||r([102,116,121,112,113,116,32,32],{offset:4})||r([109,100,97,116],{offset:4})||r([119,105,100,101],{offset:4})?{ext:"mov",mime:"video/quicktime"}:r([82,73,70,70])&&r([65,86,73],{offset:8})?{ext:"avi",mime:"video/x-msvideo"}:r([48,38,178,117,142,102,207,17,166,217])?{ext:"wmv",mime:"video/x-ms-wmv"}:r([0,0,1,186])?{ext:"mpg",mime:"video/mpeg"}:r([73,68,51])||r([255,251])?{ext:"mp3",mime:"audio/mpeg"}:r([102,116,121,112,77,52,65],{offset:4})||r([77,52,65,32])?{ext:"m4a",mime:"audio/m4a"}:r([79,112,117,115,72,101,97,100],{offset:28})?{ext:"opus",mime:"audio/opus"}:r([79,103,103,83])?{ext:"ogg",mime:"audio/ogg"}:r([102,76,97,67])?{ext:"flac",mime:"audio/x-flac"}:r([82,73,70,70])&&r([87,65,86,69],{offset:8})?{ext:"wav",mime:"audio/x-wav"}:r([35,33,65,77,82,10])?{ext:"amr",mime:"audio/amr"}:r([37,80,68,70])?{ext:"pdf",mime:"application/pdf"}:r([77,90])?{ext:"exe",mime:"application/x-msdownload"}:67!==t[0]&&70!==t[0]||!r([87,83],{offset:1})?r([123,92,114,116,102])?{ext:"rtf",mime:"application/rtf"}:r([0,97,115,109])?{ext:"wasm",mime:"application/wasm"}:r([119,79,70,70])&&(r([0,1,0,0],{offset:4})||r([79,84,84,79],{offset:4}))?{ext:"woff",mime:"font/woff"}:r([119,79,70,50])&&(r([0,1,0,0],{offset:4})||r([79,84,84,79],{offset:4}))?{ext:"woff2",mime:"font/woff2"}:r([76,80],{offset:34})&&(r([0,0,1],{offset:8})||r([1,0,2],{offset:8})||r([2,0,2],{offset:8}))?{ext:"eot",mime:"application/octet-stream"}:r([0,1,0,0,0])?{ext:"ttf",mime:"font/ttf"}:r([79,84,84,79,0])?{ext:"otf",mime:"font/otf"}:r([0,0,1,0])?{ext:"ico",mime:"image/x-icon"}:r([70,76,86,1])?{ext:"flv",mime:"video/x-flv"}:r([37,33])?{ext:"ps",mime:"application/postscript"}:r([253,55,122,88,90,0])?{ext:"xz",mime:"application/x-xz"}:r([83,81,76,105])?{ext:"sqlite",mime:"application/x-sqlite3"}:r([78,69,83,26])?{ext:"nes",mime:"application/x-nintendo-nes-rom"}:r([67,114,50,52])?{ext:"crx",mime:"application/x-google-chrome-extension"}:r([77,83,67,70])||r([73,83,99,40])?{ext:"cab",mime:"application/vnd.ms-cab-compressed"}:r([33,60,97,114,99,104,62,10,100,101,98,105,97,110,45,98,105,110,97,114,121])?{ext:"deb",mime:"application/x-deb"}:r([33,60,97,114,99,104,62])?{ext:"ar",mime:"application/x-unix-archive"}:r([237,171,238,219])?{ext:"rpm",mime:"application/x-rpm"}:r([31,160])||r([31,157])?{ext:"Z",mime:"application/x-compress"}:r([76,90,73,80])?{ext:"lz",mime:"application/x-lzip"}:r([208,207,17,224,161,177,26,225])?{ext:"msi",mime:"application/x-msi"}:r([6,14,43,52,2,5,1,1,13,1,2,1,1,2])?{ext:"mxf",mime:"application/mxf"}:r([71],{offset:4})&&(r([71],{offset:192})||r([71],{offset:196}))?{ext:"mts",mime:"video/mp2t"}:r([66,76,69,78,68,69,82])?{ext:"blend",mime:"application/x-blender"}:r([66,80,71,251])?{ext:"bpg",mime:"image/bpg"}:null:{ext:"swf",mime:"application/x-shockwave-flash"}},B=r.createCommonjsModule(function(e){var t=e.exports=function(e){return null!==e&&"object"==typeof e&&"function"==typeof e.pipe};t.writable=function(e){return t(e)&&!1!==e.writable&&"function"==typeof e._write&&"object"==typeof e._writableState},t.readable=function(e){return t(e)&&!1!==e.readable&&"function"==typeof e._read&&"object"==typeof e._readableState},t.duplex=function(e){return t.writable(e)&&t.readable(e)},t.transform=function(e){return t.duplex(e)&&"function"==typeof e._transform&&"object"==typeof e._transformState}}),C=g.default.Duplex,k=o.safeBuffer.Buffer;function S(e){if(!(this instanceof S))return new S(e);if(this._bufs=[],this.length=0,"function"==typeof e){this._callback=e;var t=function(e){this._callback&&(this._callback(e),this._callback=null)}.bind(this);this.on("pipe",function(e){e.on("error",t)}),this.on("unpipe",function(e){e.removeListener("error",t)})}else this.append(e);C.call(this)}y.default.inherits(S,C),S.prototype._offset=function(e){var t,r=0,n=0;if(0===e)return[0,0];for(;n<this._bufs.length;n++){if(e<(t=r+this._bufs[n].length)||n==this._bufs.length-1)return[n,e-r];r=t}},S.prototype.append=function(e){var t=0;if(k.isBuffer(e))this._appendBuffer(e);else if(Array.isArray(e))for(;t<e.length;t++)this.append(e[t]);else if(e instanceof S)for(;t<e._bufs.length;t++)this.append(e._bufs[t]);else null!=e&&("number"==typeof e&&(e=e.toString()),this._appendBuffer(k.from(e)));return this},S.prototype._appendBuffer=function(e){this._bufs.push(e),this.length+=e.length},S.prototype._write=function(e,t,r){this._appendBuffer(e),"function"==typeof r&&r()},S.prototype._read=function(e){if(!this.length)return this.push(null);e=Math.min(e,this.length),this.push(this.slice(0,e)),this.consume(e)},S.prototype.end=function(e){C.prototype.end.call(this,e),this._callback&&(this._callback(null,this.slice()),this._callback=null)},S.prototype.get=function(e){return this.slice(e,e+1)[0]},S.prototype.slice=function(e,t){return"number"==typeof e&&e<0&&(e+=this.length),"number"==typeof t&&t<0&&(t+=this.length),this.copy(null,0,e,t)},S.prototype.copy=function(e,t,r,n){if(("number"!=typeof r||r<0)&&(r=0),("number"!=typeof n||n>this.length)&&(n=this.length),r>=this.length)return e||k.alloc(0);if(n<=0)return e||k.alloc(0);var i,o,a=!!e,s=this._offset(r),f=n-r,u=f,l=a&&t||0,c=s[1];if(0===r&&n==this.length){if(!a)return 1===this._bufs.length?this._bufs[0]:k.concat(this._bufs,this.length);for(o=0;o<this._bufs.length;o++)this._bufs[o].copy(e,l),l+=this._bufs[o].length;return e}if(u<=this._bufs[s[0]].length-c)return a?this._bufs[s[0]].copy(e,t,c,c+u):this._bufs[s[0]].slice(c,c+u);for(a||(e=k.allocUnsafe(f)),o=s[0];o<this._bufs.length;o++){if(!(u>(i=this._bufs[o].length-c))){this._bufs[o].copy(e,l,c,c+u),l+=i;break}this._bufs[o].copy(e,l,c),l+=i,u-=i,c&&(c=0)}return e.length>l?e.slice(0,l):e},S.prototype.shallowSlice=function(e,t){e=e||0,t=t||this.length,e<0&&(e+=this.length),t<0&&(t+=this.length);var r=this._offset(e),n=this._offset(t),i=this._bufs.slice(r[0],n[0]+1);return 0==n[1]?i.pop():i[i.length-1]=i[i.length-1].slice(0,n[1]),0!=r[1]&&(i[0]=i[0].slice(r[1])),new S(i)},S.prototype.toString=function(e,t,r){return this.slice(t,r).toString(e)},S.prototype.consume=function(e){if(e=Math.trunc(e),Number.isNaN(e)||e<=0)return this;for(;this._bufs.length;){if(!(e>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(e),this.length-=e;break}e-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},S.prototype.duplicate=function(){for(var e=0,t=new S;e<this._bufs.length;e++)t.append(this._bufs[e]);return t},S.prototype.destroy=function(){this._bufs.length=0,this.length=0,this.push(null)},function(){var e={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1};for(var t in e)(function(t){S.prototype[t]=function(r){return this.slice(r,r+e[t])[t](0)}})(t)}();var O=S,A=function(){for(var e={},t=0;t<arguments.length;t++){var r=arguments[t];for(var n in r)L.call(r,n)&&(e[n]=r[n])}return e},L=Object.prototype.hasOwnProperty;var R=function(){try{if(!Buffer.isEncoding("latin1"))return!1;var e=Buffer.alloc?Buffer.alloc(4):new Buffer(4);return e.fill("ab","ucs2"),"61006200"===e.toString("hex")}catch(e){return!1}}();function I(e,t,r,n){if(r<0||n>e.length)throw new RangeError("Out of range index");return r>>>=0,(n=void 0===n?e.length:n>>>0)>r&&e.fill(t,r,n),e}var T=function(e,t,r,n,i){if(R)return e.fill(t,r,n,i);if("number"==typeof t)return I(e,t,r,n);if("string"==typeof t){if("string"==typeof r?(i=r,r=0,n=e.length):"string"==typeof n&&(i=n,n=e.length),void 0!==i&&"string"!=typeof i)throw new TypeError("encoding must be a string");if("latin1"===i&&(i="binary"),"string"==typeof i&&!Buffer.isEncoding(i))throw new TypeError("Unknown encoding: "+i);if(""===t)return I(e,0,r,n);if(function(e){return 1===e.length&&e.charCodeAt(0)<256}(t))return I(e,t.charCodeAt(0),r,n);t=new Buffer(t,i)}return Buffer.isBuffer(t)?function(e,t,r,n){if(r<0||n>e.length)throw new RangeError("Out of range index");if(n<=r)return e;r>>>=0,n=void 0===n?e.length:n>>>0;for(var i=r,o=t.length;i<=n-o;)t.copy(e,i),i+=o;return i!==n&&t.copy(e,i,0,n-i),e}(e,t,r,n):I(e,0,r,n)};var j=function(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative');return Buffer.allocUnsafe?Buffer.allocUnsafe(e):new Buffer(e)},P=function(e,t,r){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative');if(Buffer.alloc)return Buffer.alloc(e,t,r);var n=j(e);return 0===e?n:void 0===t?T(n,0):("string"!=typeof r&&(r=void 0),T(n,t,r))},U="0".charCodeAt(0),F=parseInt("7777",8),N=function(e,t,r,n){for(;r<n;r++)if(e[r]===t)return r;return n},D=function(e){for(var t=256,r=0;r<148;r++)t+=e[r];for(var n=156;n<512;n++)t+=e[n];return t},M=function(e,t){return(e=e.toString(8)).length>t?"7777777777777777777".slice(0,t)+" ":"0000000000000000000".slice(0,t-e.length)+e+" "};var q=function(e,t,r){if(128&(e=e.slice(t,t+r))[t=0])return function(e){var t;if(128===e[0])t=!0;else{if(255!==e[0])return null;t=!1}for(var r=[],n=e.length-1;n>0;n--){var i=e[n];t?r.push(i):r.push(255-i)}var o=0,a=r.length;for(n=0;n<a;n++)o+=r[n]*Math.pow(256,n);return t?o:-1*o}(e);for(;t<e.length&&32===e[t];)t++;for(var n=function(e,t,r){return"number"!=typeof e?r:(e=~~e)>=t?t:e>=0||(e+=t)>=0?e:0}(N(e,32,t,e.length),e.length,e.length);t<n&&0===e[t];)t++;return n===t?0:parseInt(e.slice(t,n).toString(),8)},Z=function(e,t,r,n){return e.slice(t,N(e,0,t,t+r)).toString(n)},G=function(e){var t=Buffer.byteLength(e),r=Math.floor(Math.log(t)/Math.log(10))+1;return t+r>=Math.pow(10,r)&&r++,t+r+e},W=function(e,t){return Z(e,0,e.length,t)},H=function(e){var t="";e.name&&(t+=G(" path="+e.name+"\n")),e.linkname&&(t+=G(" linkpath="+e.linkname+"\n"));var r=e.pax;if(r)for(var n in r)t+=G(" "+n+"="+r[n]+"\n");return o.toBuffer(t)},X=function(e){for(var t={};e.length;){for(var r=0;r<e.length&&32!==e[r];)r++;var n=parseInt(e.slice(0,r).toString(),10);if(!n)return t;var i=e.slice(r+1,n-1).toString(),o=i.indexOf("=");if(-1===o)return t;t[i.slice(0,o)]=i.slice(o+1),e=e.slice(n)}return t},Y=function(e){var t=P(512),r=e.name,n="";if(5===e.typeflag&&"/"!==r[r.length-1]&&(r+="/"),Buffer.byteLength(r)!==r.length)return null;for(;Buffer.byteLength(r)>100;){var i=r.indexOf("/");if(-1===i)return null;n+=n?"/"+r.slice(0,i):r.slice(0,i),r=r.slice(i+1)}return Buffer.byteLength(r)>100||Buffer.byteLength(n)>155||e.linkname&&Buffer.byteLength(e.linkname)>100?null:(t.write(r),t.write(M(e.mode&F,6),100),t.write(M(e.uid,6),108),t.write(M(e.gid,6),116),t.write(M(e.size,11),124),t.write(M(e.mtime.getTime()/1e3|0,11),136),t[156]=U+function(e){switch(e){case"file":return 0;case"link":return 1;case"symlink":return 2;case"character-device":return 3;case"block-device":return 4;case"directory":return 5;case"fifo":return 6;case"contiguous-file":return 7;case"pax-header":return 72}return 0}(e.type),e.linkname&&t.write(e.linkname,157),t.write("ustar\x0000",257),e.uname&&t.write(e.uname,265),e.gname&&t.write(e.gname,297),t.write(M(e.devmajor||0,6),329),t.write(M(e.devminor||0,6),337),n&&t.write(n,345),t.write(M(D(t),6),148),t)},K=function(e,t){var r=0===e[156]?0:e[156]-U,n=Z(e,0,100,t),i=q(e,100,8),o=q(e,108,8),a=q(e,116,8),s=q(e,124,12),f=q(e,136,12),u=function(e){switch(e){case 0:return"file";case 1:return"link";case 2:return"symlink";case 3:return"character-device";case 4:return"block-device";case 5:return"directory";case 6:return"fifo";case 7:return"contiguous-file";case 72:return"pax-header";case 55:return"pax-global-header";case 27:return"gnu-long-link-path";case 28:case 30:return"gnu-long-path"}return null}(r),l=0===e[157]?null:Z(e,157,100,t),c=Z(e,265,32),m=Z(e,297,32),p=q(e,329,8),d=q(e,337,8);e[345]&&(n=Z(e,345,155,t)+"/"+n),0===r&&n&&"/"===n[n.length-1]&&(r=5);var h=D(e);if(256===h)return null;if(h!==q(e,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");return{name:n,mode:i,uid:o,gid:a,size:s,mtime:new Date(1e3*f),type:u,linkname:l,uname:c,gname:m,devmajor:p,devminor:d}},V=r.createCommonjsModule(function(e,t){(t=e.exports=g.default.Readable).Readable=g.default.Readable,t.Writable=g.default.Writable,t.Duplex=g.default.Duplex,t.Transform=g.default.Transform,t.PassThrough=g.default.PassThrough,t.Stream=g.default}),$=V.Writable,J=V.PassThrough,Q=function(){},ee=function(e){return(e&=511)&&512-e},te=function(e,t){this._parent=e,this.offset=t,J.call(this)};y.default.inherits(te,J),te.prototype.destroy=function(e){this._parent.destroy(e)};var re=function(e){if(!(this instanceof re))return new re(e);$.call(this,e),e=e||{},this._offset=0,this._buffer=O(),this._missing=0,this._partial=!1,this._onparse=Q,this._header=null,this._stream=null,this._overflow=null,this._cb=null,this._locked=!1,this._destroyed=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null;var t=this,r=t._buffer,n=function(){t._continue()},i=function(e){if(t._locked=!1,e)return t.destroy(e);t._stream||n()},o=function(){t._stream=null;var e=ee(t._header.size);e?t._parse(e,a):t._parse(512,c),t._locked||n()},a=function(){t._buffer.consume(ee(t._header.size)),t._parse(512,c),n()},s=function(){var e=t._header.size;t._paxGlobal=X(r.slice(0,e)),r.consume(e),o()},f=function(){var e=t._header.size;t._pax=X(r.slice(0,e)),t._paxGlobal&&(t._pax=A(t._paxGlobal,t._pax)),r.consume(e),o()},u=function(){var n=t._header.size;this._gnuLongPath=W(r.slice(0,n),e.filenameEncoding),r.consume(n),o()},l=function(){var n=t._header.size;this._gnuLongLinkPath=W(r.slice(0,n),e.filenameEncoding),r.consume(n),o()},c=function(){var a,m=t._offset;try{a=t._header=K(r.slice(0,512),e.filenameEncoding)}catch(e){t.emit("error",e)}return r.consume(512),a?"gnu-long-path"===a.type?(t._parse(a.size,u),void n()):"gnu-long-link-path"===a.type?(t._parse(a.size,l),void n()):"pax-global-header"===a.type?(t._parse(a.size,s),void n()):"pax-header"===a.type?(t._parse(a.size,f),void n()):(t._gnuLongPath&&(a.name=t._gnuLongPath,t._gnuLongPath=null),t._gnuLongLinkPath&&(a.linkname=t._gnuLongLinkPath,t._gnuLongLinkPath=null),t._pax&&(t._header=a=function(e,t){return t.path&&(e.name=t.path),t.linkpath&&(e.linkname=t.linkpath),t.size&&(e.size=parseInt(t.size,10)),e.pax=t,e}(a,t._pax),t._pax=null),t._locked=!0,a.size&&"directory"!==a.type?(t._stream=new te(t,m),t.emit("entry",a,t._stream,i),t._parse(a.size,o),void n()):(t._parse(512,c),void t.emit("entry",a,function(e,t){var r=new te(e,t);return r.end(),r}(t,m),i))):(t._parse(512,c),void n())};this._onheader=c,this._parse(512,c)};y.default.inherits(re,$),re.prototype.destroy=function(e){this._destroyed||(this._destroyed=!0,e&&this.emit("error",e),this.emit("close"),this._stream&&this._stream.emit("close"))},re.prototype._parse=function(e,t){this._destroyed||(this._offset+=e,this._missing=e,t===this._onheader&&(this._partial=!1),this._onparse=t)},re.prototype._continue=function(){if(!this._destroyed){var e=this._cb;this._cb=Q,this._overflow?this._write(this._overflow,void 0,e):e()}},re.prototype._write=function(e,t,r){if(!this._destroyed){var n=this._stream,i=this._buffer,o=this._missing;if(e.length&&(this._partial=!0),e.length<o)return this._missing-=e.length,this._overflow=null,n?n.write(e,r):(i.append(e),r());this._cb=r,this._missing=0;var a=null;e.length>o&&(a=e.slice(o),e=e.slice(0,o)),n?n.end(e):i.append(e),this._overflow=a,this._onparse()}},re.prototype._final=function(e){if(this._partial)return this.destroy(new Error("Unexpected end of data"));e()};var ne=re,ie=x.default.constants||v.default,oe=function(){},ae=function(e,t,r){if("function"==typeof t)return ae(e,null,t);t||(t={}),r=f.once_1(r||oe);var n=e._writableState,i=e._readableState,o=t.readable||!1!==t.readable&&e.readable,a=t.writable||!1!==t.writable&&e.writable,s=!1,u=function(){e.writable||l()},l=function(){a=!1,o||r.call(e)},c=function(){o=!1,a||r.call(e)},m=function(t){r.call(e,t?new Error("exited with error code: "+t):null)},p=function(t){r.call(e,t)},d=function(){process.nextTick(h)},h=function(){if(!s)return(!o||i&&i.ended&&!i.destroyed)&&(!a||n&&n.ended&&!n.destroyed)?void 0:r.call(e,new Error("premature close"))},y=function(){e.req.on("finish",l)};return!function(e){return e.setHeader&&"function"==typeof e.abort}(e)?a&&!n&&(e.on("end",u),e.on("close",u)):(e.on("complete",l),e.on("abort",d),e.req?y():e.on("request",y)),function(e){return e.stdio&&Array.isArray(e.stdio)&&3===e.stdio.length}(e)&&e.on("exit",m),e.on("end",c),e.on("finish",l),!1!==t.error&&e.on("error",p),e.on("close",d),function(){s=!0,e.removeListener("complete",l),e.removeListener("abort",d),e.removeListener("request",y),e.req&&e.req.removeListener("finish",l),e.removeListener("end",u),e.removeListener("close",u),e.removeListener("finish",l),e.removeListener("exit",m),e.removeListener("end",c),e.removeListener("error",p),e.removeListener("close",d)}},se=ae,fe=V.Readable,ue=V.Writable,le=w.default.StringDecoder,ce=parseInt("755",8),me=parseInt("644",8),pe=P(1024),de=function(){},he=function(e,t){(t&=511)&&e.push(pe.slice(0,512-t))};var ye=function(e){ue.call(this),this.written=0,this._to=e,this._destroyed=!1};y.default.inherits(ye,ue),ye.prototype._write=function(e,t,r){if(this.written+=e.length,this._to.push(e))return r();this._to._drain=r},ye.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var ge=function(){ue.call(this),this.linkname="",this._decoder=new le("utf-8"),this._destroyed=!1};y.default.inherits(ge,ue),ge.prototype._write=function(e,t,r){this.linkname+=this._decoder.write(e),r()},ge.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var xe=function(){ue.call(this),this._destroyed=!1};y.default.inherits(xe,ue),xe.prototype._write=function(e,t,r){r(new Error("No body allowed for this entry"))},xe.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var ve=function(e){if(!(this instanceof ve))return new ve(e);fe.call(this,e),this._drain=de,this._finalized=!1,this._finalizing=!1,this._destroyed=!1,this._stream=null};y.default.inherits(ve,fe),ve.prototype.entry=function(e,t,r){if(this._stream)throw new Error("already piping an entry");if(!this._finalized&&!this._destroyed){"function"==typeof t&&(r=t,t=null),r||(r=de);var n=this;if(e.size&&"symlink"!==e.type||(e.size=0),e.type||(e.type=function(e){switch(e&ie.S_IFMT){case ie.S_IFBLK:return"block-device";case ie.S_IFCHR:return"character-device";case ie.S_IFDIR:return"directory";case ie.S_IFIFO:return"fifo";case ie.S_IFLNK:return"symlink"}return"file"}(e.mode)),e.mode||(e.mode="directory"===e.type?ce:me),e.uid||(e.uid=0),e.gid||(e.gid=0),e.mtime||(e.mtime=new Date),"string"==typeof t&&(t=o.toBuffer(t)),Buffer.isBuffer(t))return e.size=t.length,this._encode(e),this.push(t),he(n,e.size),process.nextTick(r),new xe;if("symlink"===e.type&&!e.linkname){var i=new ge;return se(i,function(t){if(t)return n.destroy(),r(t);e.linkname=i.linkname,n._encode(e),r()}),i}if(this._encode(e),"file"!==e.type&&"contiguous-file"!==e.type)return process.nextTick(r),new xe;var a=new ye(this);return this._stream=a,se(a,function(t){return n._stream=null,t?(n.destroy(),r(t)):a.written!==e.size?(n.destroy(),r(new Error("size mismatch"))):(he(n,e.size),n._finalizing&&n.finalize(),void r())}),a}},ve.prototype.finalize=function(){this._stream?this._finalizing=!0:this._finalized||(this._finalized=!0,this.push(pe),this.push(null))},ve.prototype.destroy=function(e){this._destroyed||(this._destroyed=!0,e&&this.emit("error",e),this.emit("close"),this._stream&&this._stream.destroy&&this._stream.destroy())},ve.prototype._encode=function(e){if(!e.pax){var t=Y(e);if(t)return void this.push(t)}this._encodePax(e)},ve.prototype._encodePax=function(e){var t=H({name:e.name,linkname:e.linkname,pax:e.pax}),r={name:"PaxHeader",mode:e.mode,uid:e.uid,gid:e.gid,size:t.length,mtime:e.mtime,type:"pax-header",linkname:e.linkname&&"PaxHeader",uname:e.uname,gname:e.gname,devmajor:e.devmajor,devminor:e.devminor};this.push(Y(r)),this.push(t),he(this,t.length),r.size=e.size,r.type=e.type,this.push(Y(r))},ve.prototype._read=function(e){var t=this._drain;this._drain=de,t()};var we={extract:ne,pack:ve},be=()=>e=>{if(!Buffer.isBuffer(e)&&!B(e))return Promise.reject(new TypeError("Expected a Buffer or Stream, got "+typeof e));if(Buffer.isBuffer(e)&&(!z(e)||"tar"!==z(e).ext))return Promise.resolve([]);const t=we.extract(),r=[];t.on("entry",(e,t,n)=>{const i=[];t.on("data",e=>i.push(e)),t.on("end",()=>{const t={data:Buffer.concat(i),mode:e.mode,mtime:e.mtime,path:e.name,type:e.type};"symlink"!==e.type&&"link"!==e.type||(t.linkname=e.linkname),r.push(t),n()})});const n=new Promise((n,i)=>{Buffer.isBuffer(e)||e.on("error",i),t.on("finish",()=>n(r)),t.on("error",i)});return t.then=n.then.bind(n),t.catch=n.catch.bind(n),Buffer.isBuffer(e)?t.end(e):e.pipe(t),t};const _e=e=>Array.from(e).map(e=>e.charCodeAt(0)),Ee=_e("META-INF/mozilla.rsa"),ze=_e("[Content_Types].xml"),Be=_e("_rels/.rels");var Ce=e=>{const t=new Uint8Array(e);if(!(t&&t.length>1))return null;const r=(e,r)=>{r=Object.assign({offset:0},r);for(let n=0;n<e.length;n++)if(r.mask){if(e[n]!==(r.mask[n]&t[n+r.offset]))return!1}else if(e[n]!==t[n+r.offset])return!1;return!0};if(r([255,216,255]))return{ext:"jpg",mime:"image/jpeg"};if(r([137,80,78,71,13,10,26,10]))return{ext:"png",mime:"image/png"};if(r([71,73,70]))return{ext:"gif",mime:"image/gif"};if(r([87,69,66,80],{offset:8}))return{ext:"webp",mime:"image/webp"};if(r([70,76,73,70]))return{ext:"flif",mime:"image/flif"};if((r([73,73,42,0])||r([77,77,0,42]))&&r([67,82],{offset:8}))return{ext:"cr2",mime:"image/x-canon-cr2"};if(r([73,73,42,0])||r([77,77,0,42]))return{ext:"tif",mime:"image/tiff"};if(r([66,77]))return{ext:"bmp",mime:"image/bmp"};if(r([73,73,188]))return{ext:"jxr",mime:"image/vnd.ms-photo"};if(r([56,66,80,83]))return{ext:"psd",mime:"image/vnd.adobe.photoshop"};if(r([80,75,3,4])){if(r([109,105,109,101,116,121,112,101,97,112,112,108,105,99,97,116,105,111,110,47,101,112,117,98,43,122,105,112],{offset:30}))return{ext:"epub",mime:"application/epub+zip"};if(r(Ee,{offset:30}))return{ext:"xpi",mime:"application/x-xpinstall"};if(r(ze,{offset:30})||r(Be,{offset:30})){const e=e=>e.findIndex((e,t,r)=>80===r[t]&&75===r[t+1]&&3===r[t+2]&&4===r[t+3]),n=e(t.subarray(4,2004));if(-1!==n){const i=e(t.subarray(n+8,n+8+1e3));if(-1!==i){const e=8+n+i+30;if(r(_e("word/"),{offset:e}))return{ext:"docx",mime:"application/vnd.openxmlformats-officedocument.wordprocessingml.document"};if(r(_e("ppt/"),{offset:e}))return{ext:"pptx",mime:"application/vnd.openxmlformats-officedocument.presentationml.presentation"};if(r(_e("xl/"),{offset:e}))return{ext:"xlsx",mime:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"}}}}}if(r([80,75])&&(3===t[2]||5===t[2]||7===t[2])&&(4===t[3]||6===t[3]||8===t[3]))return{ext:"zip",mime:"application/zip"};if(r([117,115,116,97,114],{offset:257}))return{ext:"tar",mime:"application/x-tar"};if(r([82,97,114,33,26,7])&&(0===t[6]||1===t[6]))return{ext:"rar",mime:"application/x-rar-compressed"};if(r([31,139,8]))return{ext:"gz",mime:"application/gzip"};if(r([66,90,104]))return{ext:"bz2",mime:"application/x-bzip2"};if(r([55,122,188,175,39,28]))return{ext:"7z",mime:"application/x-7z-compressed"};if(r([120,1]))return{ext:"dmg",mime:"application/x-apple-diskimage"};if(r([51,103,112,53])||r([0,0,0])&&r([102,116,121,112],{offset:4})&&(r([109,112,52,49],{offset:8})||r([109,112,52,50],{offset:8})||r([105,115,111,109],{offset:8})||r([105,115,111,50],{offset:8})||r([109,109,112,52],{offset:8})||r([77,52,86],{offset:8})||r([100,97,115,104],{offset:8})))return{ext:"mp4",mime:"video/mp4"};if(r([77,84,104,100]))return{ext:"mid",mime:"audio/midi"};if(r([26,69,223,163])){const e=t.subarray(4,4100),r=e.findIndex((e,t,r)=>66===r[t]&&130===r[t+1]);if(-1!==r){const t=r+3,n=r=>Array.from(r).every((r,n)=>e[t+n]===r.charCodeAt(0));if(n("matroska"))return{ext:"mkv",mime:"video/x-matroska"};if(n("webm"))return{ext:"webm",mime:"video/webm"}}}if(r([0,0,0,20,102,116,121,112,113,116,32,32])||r([102,114,101,101],{offset:4})||r([102,116,121,112,113,116,32,32],{offset:4})||r([109,100,97,116],{offset:4})||r([119,105,100,101],{offset:4}))return{ext:"mov",mime:"video/quicktime"};if(r([82,73,70,70])&&r([65,86,73],{offset:8}))return{ext:"avi",mime:"video/x-msvideo"};if(r([48,38,178,117,142,102,207,17,166,217]))return{ext:"wmv",mime:"video/x-ms-wmv"};if(r([0,0,1,186]))return{ext:"mpg",mime:"video/mpeg"};for(let e=0;e<2&&e<t.length-16;e++)if(r([73,68,51],{offset:e})||r([255,226],{offset:e,mask:[255,226]}))return{ext:"mp3",mime:"audio/mpeg"};return r([102,116,121,112,77,52,65],{offset:4})||r([77,52,65,32])?{ext:"m4a",mime:"audio/m4a"}:r([79,112,117,115,72,101,97,100],{offset:28})?{ext:"opus",mime:"audio/opus"}:r([79,103,103,83])?{ext:"ogg",mime:"audio/ogg"}:r([102,76,97,67])?{ext:"flac",mime:"audio/x-flac"}:r([82,73,70,70])&&r([87,65,86,69],{offset:8})?{ext:"wav",mime:"audio/x-wav"}:r([35,33,65,77,82,10])?{ext:"amr",mime:"audio/amr"}:r([37,80,68,70])?{ext:"pdf",mime:"application/pdf"}:r([77,90])?{ext:"exe",mime:"application/x-msdownload"}:67!==t[0]&&70!==t[0]||!r([87,83],{offset:1})?r([123,92,114,116,102])?{ext:"rtf",mime:"application/rtf"}:r([0,97,115,109])?{ext:"wasm",mime:"application/wasm"}:r([119,79,70,70])&&(r([0,1,0,0],{offset:4})||r([79,84,84,79],{offset:4}))?{ext:"woff",mime:"font/woff"}:r([119,79,70,50])&&(r([0,1,0,0],{offset:4})||r([79,84,84,79],{offset:4}))?{ext:"woff2",mime:"font/woff2"}:r([76,80],{offset:34})&&(r([0,0,1],{offset:8})||r([1,0,2],{offset:8})||r([2,0,2],{offset:8}))?{ext:"eot",mime:"application/octet-stream"}:r([0,1,0,0,0])?{ext:"ttf",mime:"font/ttf"}:r([79,84,84,79,0])?{ext:"otf",mime:"font/otf"}:r([0,0,1,0])?{ext:"ico",mime:"image/x-icon"}:r([70,76,86,1])?{ext:"flv",mime:"video/x-flv"}:r([37,33])?{ext:"ps",mime:"application/postscript"}:r([253,55,122,88,90,0])?{ext:"xz",mime:"application/x-xz"}:r([83,81,76,105])?{ext:"sqlite",mime:"application/x-sqlite3"}:r([78,69,83,26])?{ext:"nes",mime:"application/x-nintendo-nes-rom"}:r([67,114,50,52])?{ext:"crx",mime:"application/x-google-chrome-extension"}:r([77,83,67,70])||r([73,83,99,40])?{ext:"cab",mime:"application/vnd.ms-cab-compressed"}:r([33,60,97,114,99,104,62,10,100,101,98,105,97,110,45,98,105,110,97,114,121])?{ext:"deb",mime:"application/x-deb"}:r([33,60,97,114,99,104,62])?{ext:"ar",mime:"application/x-unix-archive"}:r([237,171,238,219])?{ext:"rpm",mime:"application/x-rpm"}:r([31,160])||r([31,157])?{ext:"Z",mime:"application/x-compress"}:r([76,90,73,80])?{ext:"lz",mime:"application/x-lzip"}:r([208,207,17,224,161,177,26,225])?{ext:"msi",mime:"application/x-msi"}:r([6,14,43,52,2,5,1,1,13,1,2,1,1,2])?{ext:"mxf",mime:"application/mxf"}:r([71],{offset:4})&&(r([71],{offset:192})||r([71],{offset:196}))?{ext:"mts",mime:"video/mp2t"}:r([66,76,69,78,68,69,82])?{ext:"blend",mime:"application/x-blender"}:r([66,80,71,251])?{ext:"bpg",mime:"image/bpg"}:null:{ext:"swf",mime:"application/x-shockwave-flash"}},ke=[0,1,3,7,15,31,63,127,255],Se=function(e){this.stream=e,this.bitOffset=0,this.curByte=0,this.hasByte=!1};Se.prototype._ensureByte=function(){this.hasByte||(this.curByte=this.stream.readByte(),this.hasByte=!0)},Se.prototype.read=function(e){for(var t=0;e>0;){this._ensureByte();var r=8-this.bitOffset;if(e>=r)t<<=r,t|=ke[r]&this.curByte,this.hasByte=!1,this.bitOffset=0,e-=r;else{t<<=e;var n=r-e;t|=(this.curByte&ke[e]<<n)>>n,this.bitOffset+=e,e=0}}return t},Se.prototype.seek=function(e){var t=e%8,r=(e-t)/8;this.bitOffset=t,this.stream.seek(r),this.hasByte=!1},Se.prototype.pi=function(){var e,t=new Buffer(6);for(e=0;e<t.length;e++)t[e]=this.read(8);return t.toString("hex")};var Oe=Se,Ae=function(){};Ae.prototype.readByte=function(){throw new Error("abstract method readByte() not implemented")},Ae.prototype.read=function(e,t,r){for(var n=0;n<r;){var i=this.readByte();if(i<0)return 0===n?-1:n;e[t++]=i,n++}return n},Ae.prototype.seek=function(e){throw new Error("abstract method seek() not implemented")},Ae.prototype.writeByte=function(e){throw new Error("abstract method readByte() not implemented")},Ae.prototype.write=function(e,t,r){var n;for(n=0;n<r;n++)this.writeByte(e[t++]);return r},Ae.prototype.flush=function(){};var Le,Re=Ae,Ie=(Le=new Uint32Array([0,79764919,159529838,222504665,319059676,398814059,445009330,507990021,638119352,583659535,797628118,726387553,890018660,835552979,1015980042,944750013,1276238704,1221641927,1167319070,1095957929,1595256236,1540665371,1452775106,1381403509,1780037320,1859660671,1671105958,1733955601,2031960084,2111593891,1889500026,1952343757,2552477408,2632100695,2443283854,2506133561,2334638140,2414271883,2191915858,2254759653,3190512472,3135915759,3081330742,3009969537,2905550212,2850959411,2762807018,2691435357,3560074640,3505614887,3719321342,3648080713,3342211916,3287746299,3467911202,3396681109,4063920168,4143685023,4223187782,4286162673,3779000052,3858754371,3904687514,3967668269,881225847,809987520,1023691545,969234094,662832811,591600412,771767749,717299826,311336399,374308984,453813921,533576470,25881363,88864420,134795389,214552010,2023205639,2086057648,1897238633,1976864222,1804852699,1867694188,1645340341,1724971778,1587496639,1516133128,1461550545,1406951526,1302016099,1230646740,1142491917,1087903418,2896545431,2825181984,2770861561,2716262478,3215044683,3143675388,3055782693,3001194130,2326604591,2389456536,2200899649,2280525302,2578013683,2640855108,2418763421,2498394922,3769900519,3832873040,3912640137,3992402750,4088425275,4151408268,4197601365,4277358050,3334271071,3263032808,3476998961,3422541446,3585640067,3514407732,3694837229,3640369242,1762451694,1842216281,1619975040,1682949687,2047383090,2127137669,1938468188,2001449195,1325665622,1271206113,1183200824,1111960463,1543535498,1489069629,1434599652,1363369299,622672798,568075817,748617968,677256519,907627842,853037301,1067152940,995781531,51762726,131386257,177728840,240578815,269590778,349224269,429104020,491947555,4046411278,4126034873,4172115296,4234965207,3794477266,3874110821,3953728444,4016571915,3609705398,3555108353,3735388376,3664026991,3290680682,3236090077,3449943556,3378572211,3174993278,3120533705,3032266256,2961025959,2923101090,2868635157,2813903052,2742672763,2604032198,2683796849,2461293480,2524268063,2284983834,2364738477,2175806836,2238787779,1569362073,1498123566,1409854455,1355396672,1317987909,1246755826,1192025387,1137557660,2072149281,2135122070,1912620623,1992383480,1753615357,1816598090,1627664531,1707420964,295390185,358241886,404320391,483945776,43990325,106832002,186451547,266083308,932423249,861060070,1041341759,986742920,613929101,542559546,756411363,701822548,3316196985,3244833742,3425377559,3370778784,3601682597,3530312978,3744426955,3689838204,3819031489,3881883254,3928223919,4007849240,4037393693,4100235434,4180117107,4259748804,2310601993,2373574846,2151335527,2231098320,2596047829,2659030626,2470359227,2550115596,2947551409,2876312838,2788305887,2733848168,3165939309,3094707162,3040238851,2985771188]),function(){var e=4294967295;this.getCRC=function(){return~e>>>0},this.updateCRC=function(t){e=e<<8^Le[255&(e>>>24^t)]},this.updateCRCRun=function(t,r){for(;r-- >0;)e=e<<8^Le[255&(e>>>24^t)]}}),Te="1.0.6",je="MIT",Pe=function(e,t){var r,n=e[t];for(r=t;r>0;r--)e[r]=e[r-1];return e[0]=n,n},Ue={OK:0,LAST_BLOCK:-1,NOT_BZIP_DATA:-2,UNEXPECTED_INPUT_EOF:-3,UNEXPECTED_OUTPUT_EOF:-4,DATA_ERROR:-5,OUT_OF_MEMORY:-6,OBSOLETE_INPUT:-7,END_OF_BLOCK:-8},Fe={};Fe[Ue.LAST_BLOCK]="Bad file checksum",Fe[Ue.NOT_BZIP_DATA]="Not bzip data",Fe[Ue.UNEXPECTED_INPUT_EOF]="Unexpected input EOF",Fe[Ue.UNEXPECTED_OUTPUT_EOF]="Unexpected output EOF",Fe[Ue.DATA_ERROR]="Data error",Fe[Ue.OUT_OF_MEMORY]="Out of memory",Fe[Ue.OBSOLETE_INPUT]="Obsolete (pre 0.9.5) bzip format not supported.";var Ne=function(e,t){var r=Fe[e]||"unknown error";t&&(r+=": "+t);var n=new TypeError(r);throw n.errorCode=e,n},De=function(e,t){this.writePos=this.writeCurrent=this.writeCount=0,this._start_bunzip(e,t)};De.prototype._init_block=function(){return this._get_next_block()?(this.blockCRC=new Ie,!0):(this.writeCount=-1,!1)},De.prototype._start_bunzip=function(e,t){var r=new Buffer(4);4===e.read(r,0,4)&&"BZh"===String.fromCharCode(r[0],r[1],r[2])||Ne(Ue.NOT_BZIP_DATA,"bad magic");var n=r[3]-48;(n<1||n>9)&&Ne(Ue.NOT_BZIP_DATA,"level out of range"),this.reader=new Oe(e),this.dbufSize=1e5*n,this.nextoutput=0,this.outputStream=t,this.streamCRC=0},De.prototype._get_next_block=function(){var e,t,r,n=this.reader,i=n.pi();if("177245385090"===i)return!1;"314159265359"!==i&&Ne(Ue.NOT_BZIP_DATA),this.targetBlockCRC=n.read(32)>>>0,this.streamCRC=(this.targetBlockCRC^(this.streamCRC<<1|this.streamCRC>>>31))>>>0,n.read(1)&&Ne(Ue.OBSOLETE_INPUT);var o=n.read(24);o>this.dbufSize&&Ne(Ue.DATA_ERROR,"initial position out of bounds");var a=n.read(16),s=new Buffer(256),f=0;for(e=0;e<16;e++)if(a&1<<15-e){var u=16*e;for(r=n.read(16),t=0;t<16;t++)r&1<<15-t&&(s[f++]=u+t)}var l=n.read(3);(l<2||l>6)&&Ne(Ue.DATA_ERROR);var c=n.read(15);0===c&&Ne(Ue.DATA_ERROR);var m=new Buffer(256);for(e=0;e<l;e++)m[e]=e;var p=new Buffer(c);for(e=0;e<c;e++){for(t=0;n.read(1);t++)t>=l&&Ne(Ue.DATA_ERROR);p[e]=Pe(m,t)}var d,h=f+2,y=[];for(t=0;t<l;t++){var g,x,v=new Buffer(h),w=new Uint16Array(21);for(a=n.read(5),e=0;e<h;e++){for(;(a<1||a>20)&&Ne(Ue.DATA_ERROR),n.read(1);)n.read(1)?a--:a++;v[e]=a}for(g=x=v[0],e=1;e<h;e++)v[e]>x?x=v[e]:v[e]<g&&(g=v[e]);d={},y.push(d),d.permute=new Uint16Array(258),d.limit=new Uint32Array(22),d.base=new Uint32Array(21),d.minLen=g,d.maxLen=x;var b=0;for(e=g;e<=x;e++)for(w[e]=d.limit[e]=0,a=0;a<h;a++)v[a]===e&&(d.permute[b++]=a);for(e=0;e<h;e++)w[v[e]]++;for(b=a=0,e=g;e<x;e++)b+=w[e],d.limit[e]=b-1,b<<=1,a+=w[e],d.base[e+1]=b-a;d.limit[x+1]=Number.MAX_VALUE,d.limit[x]=b+w[x]-1,d.base[g]=0}var _=new Uint32Array(256);for(e=0;e<256;e++)m[e]=e;var E,z=0,B=0,C=0,k=this.dbuf=new Uint32Array(this.dbufSize);for(h=0;;){for(h--||(h=49,C>=c&&Ne(Ue.DATA_ERROR),d=y[p[C++]]),e=d.minLen,t=n.read(e);e>d.maxLen&&Ne(Ue.DATA_ERROR),!(t<=d.limit[e]);e++)t=t<<1|n.read(1);((t-=d.base[e])<0||t>=258)&&Ne(Ue.DATA_ERROR);var S=d.permute[t];if(0!==S&&1!==S){if(z)for(z=0,B+a>this.dbufSize&&Ne(Ue.DATA_ERROR),_[E=s[m[0]]]+=a;a--;)k[B++]=E;if(S>f)break;B>=this.dbufSize&&Ne(Ue.DATA_ERROR),_[E=s[E=Pe(m,e=S-1)]]++,k[B++]=E}else z||(z=1,a=0),a+=0===S?z:2*z,z<<=1}for((o<0||o>=B)&&Ne(Ue.DATA_ERROR),t=0,e=0;e<256;e++)r=t+_[e],_[e]=t,t=r;for(e=0;e<B;e++)k[_[E=255&k[e]]]|=e<<8,_[E]++;var O=0,A=0,L=0;return B&&(A=255&(O=k[o]),O>>=8,L=-1),this.writePos=O,this.writeCurrent=A,this.writeCount=B,this.writeRun=L,!0},De.prototype._read_bunzip=function(e,t){var r,n,i;if(this.writeCount<0)return 0;var o=this.dbuf,a=this.writePos,s=this.writeCurrent,f=this.writeCount;this.outputsize;for(var u=this.writeRun;f;){for(f--,n=s,s=255&(a=o[a]),a>>=8,3===u++?(r=s,i=n,s=-1):(r=1,i=s),this.blockCRC.updateCRCRun(i,r);r--;)this.outputStream.writeByte(i),this.nextoutput++;s!=n&&(u=0)}return this.writeCount=f,this.blockCRC.getCRC()!==this.targetBlockCRC&&Ne(Ue.DATA_ERROR,"Bad block CRC (got "+this.blockCRC.getCRC().toString(16)+" expected "+this.targetBlockCRC.toString(16)+")"),this.nextoutput};var Me=function(e){if("readByte"in e)return e;var t=new Re;return t.pos=0,t.readByte=function(){return e[this.pos++]},t.seek=function(e){this.pos=e},t.eof=function(){return this.pos>=e.length},t},qe=function(e){var t=new Re,r=!0;if(e)if("number"==typeof e)t.buffer=new Buffer(e),r=!1;else{if("writeByte"in e)return e;t.buffer=e,r=!1}else t.buffer=new Buffer(16384);return t.pos=0,t.writeByte=function(e){if(r&&this.pos>=this.buffer.length){var t=new Buffer(2*this.buffer.length);this.buffer.copy(t),this.buffer=t}this.buffer[this.pos++]=e},t.getBuffer=function(){if(this.pos!==this.buffer.length){if(!r)throw new TypeError("outputsize does not match decoded input");var e=new Buffer(this.pos);this.buffer.copy(e,0,0,this.pos),this.buffer=e}return this.buffer},t._coerced=!0,t};De.Err=Ue,De.decode=function(e,t,r){for(var n=Me(e),i=qe(t),o=new De(n,i);!("eof"in n)||!n.eof();)if(o._init_block())o._read_bunzip();else{var a=o.reader.read(32)>>>0;if(a!==o.streamCRC&&Ne(Ue.DATA_ERROR,"Bad stream CRC (got "+o.streamCRC.toString(16)+" expected "+a.toString(16)+")"),!r||!("eof"in n)||n.eof())break;o._start_bunzip(n,i)}if("getBuffer"in i)return i.getBuffer()},De.decodeBlock=function(e,t,r){var n=Me(e),i=qe(r),o=new De(n,i);if(o.reader.seek(t),o._get_next_block()&&(o.blockCRC=new Ie,o.writeCopies=0,o._read_bunzip()),"getBuffer"in i)return i.getBuffer()},De.table=function(e,t,r){var n=new Re;n.delegate=Me(e),n.pos=0,n.readByte=function(){return this.pos++,this.delegate.readByte()},n.delegate.eof&&(n.eof=n.delegate.eof.bind(n.delegate));var i=new Re;i.pos=0,i.writeByte=function(){this.pos++};for(var o=new De(n,i),a=o.dbufSize;!("eof"in n)||!n.eof();){var s=8*n.pos+o.reader.bitOffset;if(o.reader.hasByte&&(s-=8),o._init_block()){var f=i.pos;o._read_bunzip(),t(s,i.pos-f)}else{if(o.reader.read(32),!r||!("eof"in n)||n.eof())break;o._start_bunzip(n,i),console.assert(o.dbufSize===a,"shouldn't change block size within multistream file")}}},De.Stream=Re,De.version=Te,De.license=je;var Ze=De,Ge=r.createCommonjsModule(function(e,t){function r(e,t,r){e=e||function(e){this.queue(e)},t=t||function(){this.queue(null)};var n=!1,i=!1,o=[],a=!1,s=new g.default;function f(){for(;o.length&&!s.paused;){var e=o.shift();if(null===e)return s.emit("end");s.emit("data",e)}}return s.readable=s.writable=!0,s.paused=!1,s.autoDestroy=!(r&&!1===r.autoDestroy),s.write=function(t){return e.call(this,t),!s.paused},s.queue=s.push=function(e){return a||(null===e&&(a=!0),o.push(e),f()),s},s.on("end",function(){s.readable=!1,!s.writable&&s.autoDestroy&&process.nextTick(function(){s.destroy()})}),s.end=function(e){if(!n)return n=!0,arguments.length&&s.write(e),s.writable=!1,t.call(s),!s.readable&&s.autoDestroy&&s.destroy(),s},s.destroy=function(){if(!i)return i=!0,n=!0,o.length=0,s.writable=s.readable=!1,s.emit("close"),s},s.pause=function(){if(!s.paused)return s.paused=!0,s},s.resume=function(){return s.paused&&(s.paused=!1,s.emit("resume")),f(),s.paused||s.emit("drain"),s},s}e.exports=r,r.through=r});function We(e){this.name="Bzip2Error",this.message=e,this.stack=(new Error).stack}We.prototype=new Error;var He=function(e){throw new We(e)},Xe={};Xe.Bzip2Error=We,Xe.crcTable=[0,79764919,159529838,222504665,319059676,398814059,445009330,507990021,638119352,583659535,797628118,726387553,890018660,835552979,1015980042,944750013,1276238704,1221641927,1167319070,1095957929,1595256236,1540665371,1452775106,1381403509,1780037320,1859660671,1671105958,1733955601,2031960084,2111593891,1889500026,1952343757,2552477408,2632100695,2443283854,2506133561,2334638140,2414271883,2191915858,2254759653,3190512472,3135915759,3081330742,3009969537,2905550212,2850959411,2762807018,2691435357,3560074640,3505614887,3719321342,3648080713,3342211916,3287746299,3467911202,3396681109,4063920168,4143685023,4223187782,4286162673,3779000052,3858754371,3904687514,3967668269,881225847,809987520,1023691545,969234094,662832811,591600412,771767749,717299826,311336399,374308984,453813921,533576470,25881363,88864420,134795389,214552010,2023205639,2086057648,1897238633,1976864222,1804852699,1867694188,1645340341,1724971778,1587496639,1516133128,1461550545,1406951526,1302016099,1230646740,1142491917,1087903418,2896545431,2825181984,2770861561,2716262478,3215044683,3143675388,3055782693,3001194130,2326604591,2389456536,2200899649,2280525302,2578013683,2640855108,2418763421,2498394922,3769900519,3832873040,3912640137,3992402750,4088425275,4151408268,4197601365,4277358050,3334271071,3263032808,3476998961,3422541446,3585640067,3514407732,3694837229,3640369242,1762451694,1842216281,1619975040,1682949687,2047383090,2127137669,1938468188,2001449195,1325665622,1271206113,1183200824,1111960463,1543535498,1489069629,1434599652,1363369299,622672798,568075817,748617968,677256519,907627842,853037301,1067152940,995781531,51762726,131386257,177728840,240578815,269590778,349224269,429104020,491947555,4046411278,4126034873,4172115296,4234965207,3794477266,3874110821,3953728444,4016571915,3609705398,3555108353,3735388376,3664026991,3290680682,3236090077,3449943556,3378572211,3174993278,3120533705,3032266256,2961025959,2923101090,2868635157,2813903052,2742672763,2604032198,2683796849,2461293480,2524268063,2284983834,2364738477,2175806836,2238787779,1569362073,1498123566,1409854455,1355396672,1317987909,1246755826,1192025387,1137557660,2072149281,2135122070,1912620623,1992383480,1753615357,1816598090,1627664531,1707420964,295390185,358241886,404320391,483945776,43990325,106832002,186451547,266083308,932423249,861060070,1041341759,986742920,613929101,542559546,756411363,701822548,3316196985,3244833742,3425377559,3370778784,3601682597,3530312978,3744426955,3689838204,3819031489,3881883254,3928223919,4007849240,4037393693,4100235434,4180117107,4259748804,2310601993,2373574846,2151335527,2231098320,2596047829,2659030626,2470359227,2550115596,2947551409,2876312838,2788305887,2733848168,3165939309,3094707162,3040238851,2985771188],Xe.array=function(e){var t=0,r=0,n=[0,1,3,7,15,31,63,127,255];return function(i){for(var o=0;i>0;){var a=8-t;i>=a?(o<<=a,o|=n[a]&e[r++],t=0,i-=a):(o<<=i,o|=(e[r]&n[i]<<8-i-t)>>8-i-t,t+=i,i=0)}return o}},Xe.simple=function(e,t){var r=Xe.array(e),n=!1,i=1e5*Xe.header(r),o=new Int32Array(i);do{n=Xe.decompress(r,t,o,i)}while(!n)},Xe.header=function(e){this.byteCount=new Int32Array(256),this.symToByte=new Uint8Array(256),this.mtfSymbol=new Int32Array(256),this.selectors=new Uint8Array(32768),4348520!=e(24)&&He("No magic number found");var t=e(8)-48;return(t<1||t>9)&&He("Not a BZIP archive"),t},Xe.decompress=function(e,t,r,n,i){for(var o=~0,a="",s=0;s<6;s++)a+=e(8).toString(16);if("177245385090"==a)return(0|e(32))!==i&&He("Error in bzip2: crc32 do not match"),e(null),null;"314159265359"!=a&&He("eek not valid bzip data");var f=0|e(32);e(1)&&He("unsupported obsolete version");var u=e(24);u>n&&He("Initial position larger than buffer size");var l=e(16),c=0;for(s=0;s<16;s++)if(l&1<<15-s){var m=e(16);for(h=0;h<16;h++)m&1<<15-h&&(this.symToByte[c++]=16*s+h)}var p=e(3);(p<2||p>6)&&He("another error");var d=e(15);0==d&&He("meh");for(s=0;s<p;s++)this.mtfSymbol[s]=s;for(s=0;s<d;s++){for(var h=0;e(1);h++)h>=p&&He("whoops another error");var y=this.mtfSymbol[h];for(m=h-1;m>=0;m--)this.mtfSymbol[m+1]=this.mtfSymbol[m];this.mtfSymbol[0]=y,this.selectors[s]=y}var g,x,v,w,b=c+2,_=[],E=new Uint8Array(258),z=new Uint16Array(21);for(h=0;h<p;h++){l=e(5);for(s=0;s<b;s++){for(;(l<1||l>20)&&He("I gave up a while ago on writing error messages"),e(1);)e(1)?l--:l++;E[s]=l}var B,C;B=C=E[0];for(s=1;s<b;s++)E[s]>C?C=E[s]:E[s]<B&&(B=E[s]);(g=_[h]={}).permute=new Int32Array(258),g.limit=new Int32Array(21),g.base=new Int32Array(21),g.minLen=B,g.maxLen=C;var k=g.base,S=g.limit,O=0;for(s=B;s<=C;s++)for(l=0;l<b;l++)E[l]==s&&(g.permute[O++]=l);for(s=B;s<=C;s++)z[s]=S[s]=0;for(s=0;s<b;s++)z[E[s]]++;for(O=l=0,s=B;s<C;s++)O+=z[s],S[s]=O-1,O<<=1,k[s+1]=O-(l+=z[s]);S[C]=O+z[C]-1,k[B]=0}for(s=0;s<256;s++)this.mtfSymbol[s]=s,this.byteCount[s]=0;for(x=v=b=w=0;;){for(b--||(b=49,w>=d&&He("meow i'm a kitty, that's an error"),k=(g=_[this.selectors[w++]]).base,S=g.limit),h=e(s=g.minLen);s>g.maxLen&&He("rawr i'm a dinosaur"),!(h<=S[s]);)s++,h=h<<1|e(1);((h-=k[s])<0||h>=258)&&He("moo i'm a cow");var A=g.permute[h];if(0!=A&&1!=A){if(x)for(x=0,v+l>n&&He("Boom."),y=this.symToByte[this.mtfSymbol[0]],this.byteCount[y]+=l;l--;)r[v++]=y;if(A>c)break;v>=n&&He("I can't think of anything. Error"),s=A-1,y=this.mtfSymbol[s];for(m=s-1;m>=0;m--)this.mtfSymbol[m+1]=this.mtfSymbol[m];this.mtfSymbol[0]=y,y=this.symToByte[y],this.byteCount[y]++,r[v++]=y}else x||(x=1,l=0),l+=0==A?x:2*x,x<<=1}(u<0||u>=v)&&He("I'm a monkey and I'm throwing something at someone, namely you");for(h=0,s=0;s<256;s++)m=h+this.byteCount[s],this.byteCount[s]=h,h=m;for(s=0;s<v;s++)y=255&r[s],r[this.byteCount[y]]|=s<<8,this.byteCount[y]++;var L,R,I,T=0,j=0,P=0;for(v&&(j=255&(T=r[u]),T>>=8,P=-1);v;){for(v--,R=j,j=255&(T=r[T]),T>>=8,3==P++?(L=j,I=R,j=-1):(L=1,I=j);L--;)o=4294967295&(o<<8^this.crcTable[255&(o>>24^I)]),t(I);j!=R&&(P=0)}return(0|(o=(-1^o)>>>0))!=(0|f)&&He("Error in bzip2: crc32 do not match"),i=4294967295&(o^(i<<1|i>>>31))};var Ye=Xe,Ke=[0,1,3,7,15,31,63,127,255],Ve=function(){var e=[],t=0,r=0,n=!1,i=null,o=null;function a(e){if(!n)try{return function(e){if(r){var t=1e5*r,n=new Int32Array(t),a=[];return null===(o=Ye.decompress(i,function(e){a.push(e)},n,t,o))?(r=0,!1):(e(Buffer.from(a)),!0)}return r=Ye.header(i),o=0,!0}(function(t){e.queue(t),null!==t&&t.length})}catch(t){return e.emit("error",t),n=!0,!1}}return Ge(function(o){var s,f,u,l,c;for(e.push(o),t+=o.length,null===i&&(f=0,u=0,l=(s=function(){return e.shift()})(),(c=function(e){if(null===e&&0!=f)return f=0,void u++;for(var t=0;e>0;){u>=l.length&&(u=0,l=s());var r=8-f;0===f&&e>0&&c.bytesRead++,e>=r?(t<<=r,t|=Ke[r]&l[u++],f=0,e-=r):(t<<=e,t|=(l[u]&Ke[e]<<8-e-f)>>8-e-f,f+=e,e=0)}return t}).bytesRead=0,i=c);!n&&t-i.bytesRead+1>=(25e3+1e5*r||4);)a(this)},function(e){for(;!n&&i&&t>i.bytesRead;)a(this);n||(null!==o&&this.emit("error",new Error("input stream ended prematurely")),this.queue(null))})};var $e,Je=function(e){return e&&e.length>1?255===e[0]&&216===e[1]&&255===e[2]?{ext:"jpg",mime:"image/jpeg"}:137===e[0]&&80===e[1]&&78===e[2]&&71===e[3]?{ext:"png",mime:"image/png"}:71===e[0]&&73===e[1]&&70===e[2]?{ext:"gif",mime:"image/gif"}:87===e[8]&&69===e[9]&&66===e[10]&&80===e[11]?{ext:"webp",mime:"image/webp"}:70===e[0]&&76===e[1]&&73===e[2]&&70===e[3]?{ext:"flif",mime:"image/flif"}:(73===e[0]&&73===e[1]&&42===e[2]&&0===e[3]||77===e[0]&&77===e[1]&&0===e[2]&&42===e[3])&&67===e[8]&&82===e[9]?{ext:"cr2",mime:"image/x-canon-cr2"}:73===e[0]&&73===e[1]&&42===e[2]&&0===e[3]||77===e[0]&&77===e[1]&&0===e[2]&&42===e[3]?{ext:"tif",mime:"image/tiff"}:66===e[0]&&77===e[1]?{ext:"bmp",mime:"image/bmp"}:73===e[0]&&73===e[1]&&188===e[2]?{ext:"jxr",mime:"image/vnd.ms-photo"}:56===e[0]&&66===e[1]&&80===e[2]&&83===e[3]?{ext:"psd",mime:"image/vnd.adobe.photoshop"}:80===e[0]&&75===e[1]&&3===e[2]&&4===e[3]&&109===e[30]&&105===e[31]&&109===e[32]&&101===e[33]&&116===e[34]&&121===e[35]&&112===e[36]&&101===e[37]&&97===e[38]&&112===e[39]&&112===e[40]&&108===e[41]&&105===e[42]&&99===e[43]&&97===e[44]&&116===e[45]&&105===e[46]&&111===e[47]&&110===e[48]&&47===e[49]&&101===e[50]&&112===e[51]&&117===e[52]&&98===e[53]&&43===e[54]&&122===e[55]&&105===e[56]&&112===e[57]?{ext:"epub",mime:"application/epub+zip"}:80===e[0]&&75===e[1]&&3===e[2]&&4===e[3]&&77===e[30]&&69===e[31]&&84===e[32]&&65===e[33]&&45===e[34]&&73===e[35]&&78===e[36]&&70===e[37]&&47===e[38]&&109===e[39]&&111===e[40]&&122===e[41]&&105===e[42]&&108===e[43]&&108===e[44]&&97===e[45]&&46===e[46]&&114===e[47]&&115===e[48]&&97===e[49]?{ext:"xpi",mime:"application/x-xpinstall"}:80!==e[0]||75!==e[1]||3!==e[2]&&5!==e[2]&&7!==e[2]||4!==e[3]&&6!==e[3]&&8!==e[3]?117===e[257]&&115===e[258]&&116===e[259]&&97===e[260]&&114===e[261]?{ext:"tar",mime:"application/x-tar"}:82!==e[0]||97!==e[1]||114!==e[2]||33!==e[3]||26!==e[4]||7!==e[5]||0!==e[6]&&1!==e[6]?31===e[0]&&139===e[1]&&8===e[2]?{ext:"gz",mime:"application/gzip"}:66===e[0]&&90===e[1]&&104===e[2]?{ext:"bz2",mime:"application/x-bzip2"}:55===e[0]&&122===e[1]&&188===e[2]&&175===e[3]&&39===e[4]&&28===e[5]?{ext:"7z",mime:"application/x-7z-compressed"}:120===e[0]&&1===e[1]?{ext:"dmg",mime:"application/x-apple-diskimage"}:0===e[0]&&0===e[1]&&0===e[2]&&(24===e[3]||32===e[3])&&102===e[4]&&116===e[5]&&121===e[6]&&112===e[7]||51===e[0]&&103===e[1]&&112===e[2]&&53===e[3]||0===e[0]&&0===e[1]&&0===e[2]&&28===e[3]&&102===e[4]&&116===e[5]&&121===e[6]&&112===e[7]&&109===e[8]&&112===e[9]&&52===e[10]&&50===e[11]&&109===e[16]&&112===e[17]&&52===e[18]&&49===e[19]&&109===e[20]&&112===e[21]&&52===e[22]&&50===e[23]&&105===e[24]&&115===e[25]&&111===e[26]&&109===e[27]||0===e[0]&&0===e[1]&&0===e[2]&&28===e[3]&&102===e[4]&&116===e[5]&&121===e[6]&&112===e[7]&&105===e[8]&&115===e[9]&&111===e[10]&&109===e[11]||0===e[0]&&0===e[1]&&0===e[2]&&28===e[3]&&102===e[4]&&116===e[5]&&121===e[6]&&112===e[7]&&109===e[8]&&112===e[9]&&52===e[10]&&50===e[11]&&0===e[12]&&0===e[13]&&0===e[14]&&0===e[15]?{ext:"mp4",mime:"video/mp4"}:0===e[0]&&0===e[1]&&0===e[2]&&28===e[3]&&102===e[4]&&116===e[5]&&121===e[6]&&112===e[7]&&77===e[8]&&52===e[9]&&86===e[10]?{ext:"m4v",mime:"video/x-m4v"}:77===e[0]&&84===e[1]&&104===e[2]&&100===e[3]?{ext:"mid",mime:"audio/midi"}:109===e[31]&&97===e[32]&&116===e[33]&&114===e[34]&&111===e[35]&&115===e[36]&&107===e[37]&&97===e[38]?{ext:"mkv",mime:"video/x-matroska"}:26===e[0]&&69===e[1]&&223===e[2]&&163===e[3]?{ext:"webm",mime:"video/webm"}:0===e[0]&&0===e[1]&&0===e[2]&&20===e[3]&&102===e[4]&&116===e[5]&&121===e[6]&&112===e[7]?{ext:"mov",mime:"video/quicktime"}:82===e[0]&&73===e[1]&&70===e[2]&&70===e[3]&&65===e[8]&&86===e[9]&&73===e[10]?{ext:"avi",mime:"video/x-msvideo"}:48===e[0]&&38===e[1]&&178===e[2]&&117===e[3]&&142===e[4]&&102===e[5]&&207===e[6]&&17===e[7]&&166===e[8]&&217===e[9]?{ext:"wmv",mime:"video/x-ms-wmv"}:0===e[0]&&0===e[1]&&1===e[2]&&"b"===e[3].toString(16)[0]?{ext:"mpg",mime:"video/mpeg"}:73===e[0]&&68===e[1]&&51===e[2]||255===e[0]&&251===e[1]?{ext:"mp3",mime:"audio/mpeg"}:102===e[4]&&116===e[5]&&121===e[6]&&112===e[7]&&77===e[8]&&52===e[9]&&65===e[10]||77===e[0]&&52===e[1]&&65===e[2]&&32===e[3]?{ext:"m4a",mime:"audio/m4a"}:79===e[28]&&112===e[29]&&117===e[30]&&115===e[31]&&72===e[32]&&101===e[33]&&97===e[34]&&100===e[35]?{ext:"opus",mime:"audio/opus"}:79===e[0]&&103===e[1]&&103===e[2]&&83===e[3]?{ext:"ogg",mime:"audio/ogg"}:102===e[0]&&76===e[1]&&97===e[2]&&67===e[3]?{ext:"flac",mime:"audio/x-flac"}:82===e[0]&&73===e[1]&&70===e[2]&&70===e[3]&&87===e[8]&&65===e[9]&&86===e[10]&&69===e[11]?{ext:"wav",mime:"audio/x-wav"}:35===e[0]&&33===e[1]&&65===e[2]&&77===e[3]&&82===e[4]&&10===e[5]?{ext:"amr",mime:"audio/amr"}:37===e[0]&&80===e[1]&&68===e[2]&&70===e[3]?{ext:"pdf",mime:"application/pdf"}:77===e[0]&&90===e[1]?{ext:"exe",mime:"application/x-msdownload"}:67!==e[0]&&70!==e[0]||87!==e[1]||83!==e[2]?123===e[0]&&92===e[1]&&114===e[2]&&116===e[3]&&102===e[4]?{ext:"rtf",mime:"application/rtf"}:119===e[0]&&79===e[1]&&70===e[2]&&70===e[3]&&(0===e[4]&&1===e[5]&&0===e[6]&&0===e[7]||79===e[4]&&84===e[5]&&84===e[6]&&79===e[7])?{ext:"woff",mime:"application/font-woff"}:119===e[0]&&79===e[1]&&70===e[2]&&50===e[3]&&(0===e[4]&&1===e[5]&&0===e[6]&&0===e[7]||79===e[4]&&84===e[5]&&84===e[6]&&79===e[7])?{ext:"woff2",mime:"application/font-woff"}:76===e[34]&&80===e[35]&&(0===e[8]&&0===e[9]&&1===e[10]||1===e[8]&&0===e[9]&&2===e[10]||2===e[8]&&0===e[9]&&2===e[10])?{ext:"eot",mime:"application/octet-stream"}:0===e[0]&&1===e[1]&&0===e[2]&&0===e[3]&&0===e[4]?{ext:"ttf",mime:"application/font-sfnt"}:79===e[0]&&84===e[1]&&84===e[2]&&79===e[3]&&0===e[4]?{ext:"otf",mime:"application/font-sfnt"}:0===e[0]&&0===e[1]&&1===e[2]&&0===e[3]?{ext:"ico",mime:"image/x-icon"}:70===e[0]&&76===e[1]&&86===e[2]&&1===e[3]?{ext:"flv",mime:"video/x-flv"}:37===e[0]&&33===e[1]?{ext:"ps",mime:"application/postscript"}:253===e[0]&&55===e[1]&&122===e[2]&&88===e[3]&&90===e[4]&&0===e[5]?{ext:"xz",mime:"application/x-xz"}:83===e[0]&&81===e[1]&&76===e[2]&&105===e[3]?{ext:"sqlite",mime:"application/x-sqlite3"}:78===e[0]&&69===e[1]&&83===e[2]&&26===e[3]?{ext:"nes",mime:"application/x-nintendo-nes-rom"}:67===e[0]&&114===e[1]&&50===e[2]&&52===e[3]?{ext:"crx",mime:"application/x-google-chrome-extension"}:77===e[0]&&83===e[1]&&67===e[2]&&70===e[3]||73===e[0]&&83===e[1]&&99===e[2]&&40===e[3]?{ext:"cab",mime:"application/vnd.ms-cab-compressed"}:33===e[0]&&60===e[1]&&97===e[2]&&114===e[3]&&99===e[4]&&104===e[5]&&62===e[6]&&10===e[7]&&100===e[8]&&101===e[9]&&98===e[10]&&105===e[11]&&97===e[12]&&110===e[13]&&45===e[14]&&98===e[15]&&105===e[16]&&110===e[17]&&97===e[18]&&114===e[19]&&121===e[20]?{ext:"deb",mime:"application/x-deb"}:33===e[0]&&60===e[1]&&97===e[2]&&114===e[3]&&99===e[4]&&104===e[5]&&62===e[6]?{ext:"ar",mime:"application/x-unix-archive"}:237===e[0]&&171===e[1]&&238===e[2]&&219===e[3]?{ext:"rpm",mime:"application/x-rpm"}:31===e[0]&&160===e[1]||31===e[0]&&157===e[1]?{ext:"Z",mime:"application/x-compress"}:76===e[0]&&90===e[1]&&73===e[2]&&80===e[3]?{ext:"lz",mime:"application/x-lzip"}:208===e[0]&&207===e[1]&&17===e[2]&&224===e[3]&&161===e[4]&&177===e[5]&&26===e[6]&&225===e[7]?{ext:"msi",mime:"application/x-msi"}:null:{ext:"swf",mime:"application/x-shockwave-flash"}:{ext:"rar",mime:"application/x-rar-compressed"}:{ext:"zip",mime:"application/zip"}:null},Qe="pending",et="settled",tt="fulfilled",rt="rejected",nt=function(){},it=void 0!==r.commonjsGlobal&&void 0!==r.commonjsGlobal.process&&"function"==typeof r.commonjsGlobal.process.emit,ot="undefined"==typeof setImmediate?setTimeout:setImmediate,at=[];function st(){for(var e=0;e<at.length;e++)at[e][0](at[e][1]);at=[],$e=!1}function ft(e,t){at.push([e,t]),$e||($e=!0,ot(st,0))}function ut(e){var t=e.owner,r=t._state,n=t._data,i=e[r],o=e.then;if("function"==typeof i){r=tt;try{n=i(n)}catch(e){pt(o,e)}}lt(o,n)||(r===tt&&ct(o,n),r===rt&&pt(o,n))}function lt(e,t){var r;try{if(e===t)throw new TypeError("A promises callback cannot return that same promise.");if(t&&("function"==typeof t||"object"==typeof t)){var n=t.then;if("function"==typeof n)return n.call(t,function(n){r||(r=!0,t===n?mt(e,n):ct(e,n))},function(t){r||(r=!0,pt(e,t))}),!0}}catch(t){return r||pt(e,t),!0}return!1}function ct(e,t){e!==t&<(e,t)||mt(e,t)}function mt(e,t){e._state===Qe&&(e._state=et,e._data=t,ft(ht,e))}function pt(e,t){e._state===Qe&&(e._state=et,e._data=t,ft(yt,e))}function dt(e){e._then=e._then.forEach(ut)}function ht(e){e._state=tt,dt(e)}function yt(e){e._state=rt,dt(e),!e._handled&&it&&r.commonjsGlobal.process.emit("unhandledRejection",e._data,e)}function gt(e){r.commonjsGlobal.process.emit("rejectionHandled",e)}function xt(e){if("function"!=typeof e)throw new TypeError("Promise resolver "+e+" is not a function");if(this instanceof xt==!1)throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");this._then=[],function(e,t){function r(e){pt(t,e)}try{e(function(e){ct(t,e)},r)}catch(e){r(e)}}(e,this)}xt.prototype={constructor:xt,_state:Qe,_then:null,_data:void 0,_handled:!1,then:function(e,t){var r={owner:this,then:new this.constructor(nt),fulfilled:e,rejected:t};return!t&&!e||this._handled||(this._handled=!0,this._state===rt&&it&&ft(gt,this)),this._state===tt||this._state===rt?ft(ut,r):this._then.push(r),r.then},catch:function(e){return this.then(null,e)}},xt.all=function(e){if(!Array.isArray(e))throw new TypeError("You must pass an array to Promise.all().");return new xt(function(t,r){var n=[],i=0;function o(e){return i++,function(r){n[e]=r,--i||t(n)}}for(var a,s=0;s<e.length;s++)(a=e[s])&&"function"==typeof a.then?a.then(o(s),r):n[s]=a;i||t(n)})},xt.race=function(e){if(!Array.isArray(e))throw new TypeError("You must pass an array to Promise.race().");return new xt(function(t,r){for(var n,i=0;i<e.length;i++)(n=e[i])&&"function"==typeof n.then?n.then(t,r):t(n)})},xt.resolve=function(e){return e&&"object"==typeof e&&e.constructor===xt?e:new xt(function(t){t(e)})},xt.reject=function(e){return new xt(function(t,r){r(e)})};var vt="function"==typeof Promise?Promise:xt,wt=Object.getOwnPropertySymbols,bt=Object.prototype.hasOwnProperty,_t=Object.prototype.propertyIsEnumerable;var Et=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach(function(e){n[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var r,n,i=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),o=1;o<arguments.length;o++){for(var a in r=Object(arguments[o]))bt.call(r,a)&&(i[a]=r[a]);if(wt){n=wt(r);for(var s=0;s<n.length;s++)_t.call(r,n[s])&&(i[n[s]]=r[n[s]])}}return i},zt=g.default.PassThrough;function Bt(e,t){if(!e)return vt.reject(new Error("Expected a stream"));var r,n,i=(t=Et({maxBuffer:1/0},t)).maxBuffer,o=new vt(function(o,a){function s(e){e&&(e.bufferedData=r.getBufferedValue()),a(e)}r=function(e){var t=(e=Et({},e)).array,r=e.encoding,n="buffer"===r,i=!1;t?i=!(r||n):r=r||"utf8",n&&(r=null);var o=0,a=[],s=new zt({objectMode:i});return r&&s.setEncoding(r),s.on("data",function(e){a.push(e),i?o=a.length:o+=e.length}),s.getBufferedValue=function(){return t?a:n?Buffer.concat(a,o):a.join("")},s.getBufferedLength=function(){return o},s}(t),e.once("error",s),e.pipe(r),r.on("data",function(){r.getBufferedLength()>i&&a(new Error("maxBuffer exceeded"))}),r.once("error",s),r.on("end",o),n=function(){e.unpipe&&e.unpipe(r)}});return o.then(n,n),o.then(function(){return r.getBufferedValue()})}var Ct=Bt;Ct.buffer=function(e,t){return Bt(e,Et({},t,{encoding:"buffer"}))},Ct.array=function(e,t){return Bt(e,Et({},t,{array:!0}))};var kt=r.createCommonjsModule(function(e){var t=function(e,t,r){return function(){for(var n=this,i=new Array(arguments.length),o=0;o<arguments.length;o++)i[o]=arguments[o];return new t(function(t,o){i.push(function(e,n){if(e)o(e);else if(r.multiArgs){for(var i=new Array(arguments.length-1),a=1;a<arguments.length;a++)i[a-1]=arguments[a];t(i)}else t(n)}),e.apply(n,i)})}},r=e.exports=function(e,r,n){"function"!=typeof r&&(n=r,r=Promise),(n=n||{}).exclude=n.exclude||[/.+Sync$/];var i="function"==typeof e?function(){return n.excludeMain?e.apply(this,arguments):t(e,r,n).apply(this,arguments)}:{};return Object.keys(e).reduce(function(i,o){var a=e[o];return i[o]="function"==typeof a&&function(e){var t=function(t){return"string"==typeof t?e===t:t.test(e)};return n.include?n.include.some(t):!n.exclude.some(t)}(o)?t(a,r,n):a,i},i)};r.all=r}),St=Ot;function Ot(){this.pending=0,this.max=1/0,this.listeners=[],this.waiting=[],this.error=null}function At(e){e.pending+=1;var t=!1;return function(n){if(t)throw new Error("callback called twice");if(t=!0,e.error=e.error||n,e.pending-=1,e.waiting.length>0&&e.pending<e.max)Lt(e,e.waiting.shift());else if(0===e.pending){var i=e.listeners;e.listeners=[],i.forEach(r)}};function r(t){t(e.error)}}function Lt(e,t){t(At(e))}Ot.prototype.go=function(e){this.pending<this.max?Lt(this,e):this.waiting.push(e)},Ot.prototype.wait=function(e){0===this.pending?e(this.error):this.listeners.push(e)},Ot.prototype.hold=function(){return At(this)};var Rt=g.default.Readable,It=g.default.Writable,Tt=g.default.PassThrough,jt=_.default.EventEmitter,Pt=function(e,t){return new Zt(e,t)},Ut=function(e,t){return new Dt(e,t)},Ft=Zt,Nt=Dt;function Dt(e,t){t=t||{},jt.call(this),this.fd=e,this.pend=new St,this.pend.max=1,this.refCount=0,this.autoClose=!!t.autoClose}function Mt(e,t){t=t||{},Rt.call(this,t),this.context=e,this.context.ref(),this.start=t.start||0,this.endOffset=t.end,this.pos=this.start,this.destroyed=!1}function qt(e,t){t=t||{},It.call(this,t),this.context=e,this.context.ref(),this.start=t.start||0,this.endOffset=null==t.end?1/0:+t.end,this.bytesWritten=0,this.pos=this.start,this.destroyed=!1,this.on("finish",this.destroy.bind(this))}function Zt(e,t){jt.call(this),t=t||{},this.refCount=0,this.buffer=e,this.maxChunkSize=t.maxChunkSize||Number.MAX_SAFE_INTEGER}y.default.inherits(Dt,jt),Dt.prototype.read=function(e,t,r,n,i){var o=this;o.pend.go(function(a){x.default.read(o.fd,e,t,r,n,function(e,t,r){a(),i(e,t,r)})})},Dt.prototype.write=function(e,t,r,n,i){var o=this;o.pend.go(function(a){x.default.write(o.fd,e,t,r,n,function(e,t,r){a(),i(e,t,r)})})},Dt.prototype.createReadStream=function(e){return new Mt(this,e)},Dt.prototype.createWriteStream=function(e){return new qt(this,e)},Dt.prototype.ref=function(){this.refCount+=1},Dt.prototype.unref=function(){var e=this;if(e.refCount-=1,!(e.refCount>0)){if(e.refCount<0)throw new Error("invalid unref");e.autoClose&&x.default.close(e.fd,function(t){t?e.emit("error",t):e.emit("close")})}},y.default.inherits(Mt,Rt),Mt.prototype._read=function(e){var t=this;if(!t.destroyed){var r=Math.min(t._readableState.highWaterMark,e);if(null!=t.endOffset&&(r=Math.min(r,t.endOffset-t.pos)),r<=0)return t.destroyed=!0,t.push(null),void t.context.unref();t.context.pend.go(function(e){if(t.destroyed)return e();var n=new Buffer(r);x.default.read(t.context.fd,n,0,r,t.pos,function(r,i){r?t.destroy(r):0===i?(t.destroyed=!0,t.push(null),t.context.unref()):(t.pos+=i,t.push(n.slice(0,i))),e()})})}},Mt.prototype.destroy=function(e){this.destroyed||(e=e||new Error("stream destroyed"),this.destroyed=!0,this.emit("error",e),this.context.unref())},y.default.inherits(qt,It),qt.prototype._write=function(e,t,r){var n=this;if(!n.destroyed){if(n.pos+e.length>n.endOffset){var i=new Error("maximum file length exceeded");return i.code="ETOOBIG",n.destroy(),void r(i)}n.context.pend.go(function(t){if(n.destroyed)return t();x.default.write(n.context.fd,e,0,e.length,n.pos,function(e,i){e?(n.destroy(),t(),r(e)):(n.bytesWritten+=i,n.pos+=i,n.emit("progress"),t(),r())})})}},qt.prototype.destroy=function(){this.destroyed||(this.destroyed=!0,this.context.unref())},y.default.inherits(Zt,jt),Zt.prototype.read=function(e,t,r,n,i){var o=n+r,a=o-this.buffer.length,s=a>0?a:r;this.buffer.copy(e,t,n,o),setImmediate(function(){i(null,s)})},Zt.prototype.write=function(e,t,r,n,i){e.copy(this.buffer,n,t,t+r),setImmediate(function(){i(null,r,e)})},Zt.prototype.createReadStream=function(e){var t=new Tt(e=e||{});t.destroyed=!1,t.start=e.start||0,t.endOffset=e.end,t.pos=t.endOffset||this.buffer.length;for(var r=this.buffer.slice(t.start,t.pos),n=0;;){var i=n+this.maxChunkSize;if(i>=r.length){n<r.length&&t.write(r.slice(n,r.length));break}t.write(r.slice(n,i)),n=i}return t.end(),t.destroy=function(){t.destroyed=!0},t},Zt.prototype.createWriteStream=function(e){var t=this,r=new It(e=e||{});return r.start=e.start||0,r.endOffset=null==e.end?this.buffer.length:+e.end,r.bytesWritten=0,r.pos=r.start,r.destroyed=!1,r._write=function(e,n,i){if(!r.destroyed){var o=r.pos+e.length;if(o>r.endOffset){var a=new Error("maximum file length exceeded");return a.code="ETOOBIG",r.destroyed=!0,void i(a)}e.copy(t.buffer,r.pos,0,e.length),r.bytesWritten+=e.length,r.pos=o,r.emit("progress"),i()}},r.destroy=function(){r.destroyed=!0},r},Zt.prototype.ref=function(){this.refCount+=1},Zt.prototype.unref=function(){if(this.refCount-=1,this.refCount<0)throw new Error("invalid unref")};var Gt={createFromBuffer:Pt,createFromFd:Ut,BufferSlicer:Ft,FdSlicer:Nt},Wt=E.default.Buffer,Ht=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];function Xt(e){if(Wt.isBuffer(e))return e;var t="function"==typeof Wt.alloc&&"function"==typeof Wt.from;if("number"==typeof e)return t?Wt.alloc(e):new Wt(e);if("string"==typeof e)return t?Wt.from(e):new Wt(e);throw new Error("input must be buffer, number, or string, received "+typeof e)}function Yt(e,t){e=Xt(e),Wt.isBuffer(t)&&(t=t.readUInt32BE(0));for(var r=-1^t,n=0;n<e.length;n++)r=Ht[255&(r^e[n])]^r>>>8;return-1^r}function Kt(){return e=Yt.apply(null,arguments),(t=Xt(4)).writeInt32BE(e,0),t;var e,t}"undefined"!=typeof Int32Array&&(Ht=new Int32Array(Ht)),Kt.signed=function(){return Yt.apply(null,arguments)},Kt.unsigned=function(){return Yt.apply(null,arguments)>>>0};var Vt=Kt,$t=_.default.EventEmitter,Jt=g.default.Transform,Qt=g.default.PassThrough,er=g.default.Writable,tr=function(e,t,r){"function"==typeof t&&(r=t,t=null);null==t&&(t={});null==t.autoClose&&(t.autoClose=!0);null==t.lazyEntries&&(t.lazyEntries=!1);null==t.decodeStrings&&(t.decodeStrings=!0);null==t.validateEntrySizes&&(t.validateEntrySizes=!0);null==t.strictFileNames&&(t.strictFileNames=!1);null==r&&(r=Cr);x.default.open(e,"r",function(e,n){if(e)return r(e);lr(n,t,function(e,t){e&&x.default.close(n,Cr),r(e,t)})})},rr=lr,nr=function(e,t,r){"function"==typeof t&&(r=t,t=null);null==t&&(t={});t.autoClose=!1,null==t.lazyEntries&&(t.lazyEntries=!1);null==t.decodeStrings&&(t.decodeStrings=!0);null==t.validateEntrySizes&&(t.validateEntrySizes=!0);null==t.strictFileNames&&(t.strictFileNames=!1);var n=Gt.createFromBuffer(e,{maxChunkSize:65536});cr(n,e.length,t,r)},ir=cr,or=yr,ar=gr,sr=mr,fr=hr,ur=wr;function lr(e,t,r){"function"==typeof t&&(r=t,t=null),null==t&&(t={}),null==t.autoClose&&(t.autoClose=!1),null==t.lazyEntries&&(t.lazyEntries=!1),null==t.decodeStrings&&(t.decodeStrings=!0),null==t.validateEntrySizes&&(t.validateEntrySizes=!0),null==t.strictFileNames&&(t.strictFileNames=!1),null==r&&(r=Cr),x.default.fstat(e,function(n,i){if(n)return r(n);cr(Gt.createFromFd(e,{autoClose:!0}),i.size,t,r)})}function cr(e,t,r,n){"function"==typeof r&&(n=r,r=null),null==r&&(r={}),null==r.autoClose&&(r.autoClose=!0),null==r.lazyEntries&&(r.lazyEntries=!1),null==r.decodeStrings&&(r.decodeStrings=!0);var i=!!r.decodeStrings;if(null==r.validateEntrySizes&&(r.validateEntrySizes=!0),null==r.strictFileNames&&(r.strictFileNames=!1),null==n&&(n=Cr),"number"!=typeof t)throw new Error("expected totalSize parameter to be a number");if(t>Number.MAX_SAFE_INTEGER)throw new Error("zip file too large. only file sizes up to 2^52 are supported due to JavaScript's Number type being an IEEE 754 double.");e.ref();var o=Math.min(65557,t),a=_r(o),s=t-a.length;xr(e,a,0,o,s,function(f){if(f)return n(f);for(var u=o-22;u>=0;u-=1)if(101010256===a.readUInt32LE(u)){var l=a.slice(u),c=l.readUInt16LE(4);if(0!==c)return n(new Error("multi-disk zip files are not supported: found disk number: "+c));var m=l.readUInt16LE(10),p=l.readUInt32LE(16),d=l.readUInt16LE(20),h=l.length-22;if(d!==h)return n(new Error("invalid comment length. expected: "+h+". found: "+d));var y=i?zr(l,22,l.length,!1):l.slice(22);if(65535!==m&&4294967295!==p)return n(null,new mr(e,p,t,m,y,r.autoClose,r.lazyEntries,i,r.validateEntrySizes,r.strictFileNames));var g=_r(20),x=s+u-g.length;return void xr(e,g,0,g.length,x,function(o){if(o)return n(o);if(117853008!==g.readUInt32LE(0))return n(new Error("invalid zip64 end of central directory locator signature"));var a=Br(g,8),s=_r(56);xr(e,s,0,s.length,a,function(o){return o?n(o):101075792!==s.readUInt32LE(0)?n(new Error("invalid zip64 end of central directory record signature")):(m=Br(s,32),p=Br(s,48),n(null,new mr(e,p,t,m,y,r.autoClose,r.lazyEntries,i,r.validateEntrySizes,r.strictFileNames)))})})}n(new Error("end of central directory record signature not found"))})}function mr(e,t,r,n,i,o,a,s,f,u){var l=this;$t.call(l),l.reader=e,l.reader.on("error",function(e){dr(l,e)}),l.reader.once("close",function(){l.emit("close")}),l.readEntryCursor=t,l.fileSize=r,l.entryCount=n,l.comment=i,l.entriesRead=0,l.autoClose=!!o,l.lazyEntries=!!a,l.decodeStrings=!!s,l.validateEntrySizes=!!f,l.strictFileNames=!!u,l.isOpen=!0,l.emittedError=!1,l.lazyEntries||l._readEntry()}function pr(e,t){e.autoClose&&e.close(),dr(e,t)}function dr(e,t){e.emittedError||(e.emittedError=!0,e.emit("error",t))}function hr(){}function yr(e,t){return new Date(1980+(e>>9&127),(e>>5&15)-1,31&e,t>>11&31,t>>5&63,2*(31&t),0)}function gr(e){return-1!==e.indexOf("\\")?"invalid characters in fileName: "+e:/^[a-zA-Z]:/.test(e)||/^\//.test(e)?"absolute path: "+e:-1!==e.split("/").indexOf("..")?"invalid relative path: "+e:null}function xr(e,t,r,n,i,o){if(0===n)return setImmediate(function(){o(null,_r(0))});e.read(t,r,n,i,function(e,t){return e?o(e):t<n?o(new Error("unexpected EOF")):void o()})}function vr(e){Jt.call(this),this.actualByteCount=0,this.expectedByteCount=e}function wr(){$t.call(this),this.refCount=0}function br(e){Qt.call(this),this.context=e,this.context.ref(),this.unreffedYet=!1}y.default.inherits(mr,$t),mr.prototype.close=function(){this.isOpen&&(this.isOpen=!1,this.reader.unref())},mr.prototype.readEntry=function(){if(!this.lazyEntries)throw new Error("readEntry() called without lazyEntries:true");this._readEntry()},mr.prototype._readEntry=function(){var e=this;if(e.entryCount!==e.entriesRead){if(!e.emittedError){var t=_r(46);xr(e.reader,t,0,t.length,e.readEntryCursor,function(r){if(r)return pr(e,r);if(!e.emittedError){var n=new hr,i=t.readUInt32LE(0);if(33639248!==i)return pr(e,new Error("invalid central directory file header signature: 0x"+i.toString(16)));if(n.versionMadeBy=t.readUInt16LE(4),n.versionNeededToExtract=t.readUInt16LE(6),n.generalPurposeBitFlag=t.readUInt16LE(8),n.compressionMethod=t.readUInt16LE(10),n.lastModFileTime=t.readUInt16LE(12),n.lastModFileDate=t.readUInt16LE(14),n.crc32=t.readUInt32LE(16),n.compressedSize=t.readUInt32LE(20),n.uncompressedSize=t.readUInt32LE(24),n.fileNameLength=t.readUInt16LE(28),n.extraFieldLength=t.readUInt16LE(30),n.fileCommentLength=t.readUInt16LE(32),n.internalFileAttributes=t.readUInt16LE(36),n.externalFileAttributes=t.readUInt32LE(38),n.relativeOffsetOfLocalHeader=t.readUInt32LE(42),64&n.generalPurposeBitFlag)return pr(e,new Error("strong encryption is not supported"));e.readEntryCursor+=46,t=_r(n.fileNameLength+n.extraFieldLength+n.fileCommentLength),xr(e.reader,t,0,t.length,e.readEntryCursor,function(r){if(r)return pr(e,r);if(!e.emittedError){var i=!!(2048&n.generalPurposeBitFlag);n.fileName=e.decodeStrings?zr(t,0,n.fileNameLength,i):t.slice(0,n.fileNameLength);var o=n.fileNameLength+n.extraFieldLength,a=t.slice(n.fileNameLength,o);n.extraFields=[];for(var s=0;s<a.length-3;){var f=a.readUInt16LE(s+0),u=a.readUInt16LE(s+2),l=s+4,c=l+u;if(c>a.length)return pr(e,new Error("extra field length exceeds extra field buffer size"));var m=_r(u);a.copy(m,0,l,c),n.extraFields.push({id:f,data:m}),s=c}if(n.fileComment=e.decodeStrings?zr(t,o,o+n.fileCommentLength,i):t.slice(o,o+n.fileCommentLength),n.comment=n.fileComment,e.readEntryCursor+=t.length,e.entriesRead+=1,4294967295===n.uncompressedSize||4294967295===n.compressedSize||4294967295===n.relativeOffsetOfLocalHeader){var p=null;for(s=0;s<n.extraFields.length;s++){if(1===(h=n.extraFields[s]).id){p=h.data;break}}if(null==p)return pr(e,new Error("expected zip64 extended information extra field"));var d=0;if(4294967295===n.uncompressedSize){if(d+8>p.length)return pr(e,new Error("zip64 extended information extra field does not include uncompressed size"));n.uncompressedSize=Br(p,d),d+=8}if(4294967295===n.compressedSize){if(d+8>p.length)return pr(e,new Error("zip64 extended information extra field does not include compressed size"));n.compressedSize=Br(p,d),d+=8}if(4294967295===n.relativeOffsetOfLocalHeader){if(d+8>p.length)return pr(e,new Error("zip64 extended information extra field does not include relative header offset"));n.relativeOffsetOfLocalHeader=Br(p,d),d+=8}}if(e.decodeStrings)for(s=0;s<n.extraFields.length;s++){var h;if(28789===(h=n.extraFields[s]).id){if(h.data.length<6)continue;if(1!==h.data.readUInt8(0))continue;var y=h.data.readUInt32LE(1);if(Vt.unsigned(t.slice(0,n.fileNameLength))!==y)continue;n.fileName=zr(h.data,5,h.data.length,!0);break}}if(e.validateEntrySizes&&0===n.compressionMethod){var g=n.uncompressedSize;if(n.isEncrypted()&&(g+=12),n.compressedSize!==g){var x="compressed/uncompressed size mismatch for stored file: "+n.compressedSize+" != "+n.uncompressedSize;return pr(e,new Error(x))}}if(e.decodeStrings){e.strictFileNames||(n.fileName=n.fileName.replace(/\\/g,"/"));var v=gr(n.fileName,e.validateFileNameOptions);if(null!=v)return pr(e,new Error(v))}e.emit("entry",n),e.lazyEntries||e._readEntry()}})}})}}else setImmediate(function(){e.autoClose&&e.close(),e.emittedError||e.emit("end")})},mr.prototype.openReadStream=function(e,t,r){var n=this,i=0,o=e.compressedSize;if(null==r)r=t,t={};else{if(null!=t.decrypt){if(!e.isEncrypted())throw new Error("options.decrypt can only be specified for encrypted entries");if(!1!==t.decrypt)throw new Error("invalid options.decrypt value: "+t.decrypt);if(e.isCompressed()&&!1!==t.decompress)throw new Error("entry is encrypted and compressed, and options.decompress !== false")}if(null!=t.decompress){if(!e.isCompressed())throw new Error("options.decompress can only be specified for compressed entries");if(!1!==t.decompress&&!0!==t.decompress)throw new Error("invalid options.decompress value: "+t.decompress)}if(null!=t.start||null!=t.end){if(e.isCompressed()&&!1!==t.decompress)throw new Error("start/end range not allowed for compressed entry without options.decompress === false");if(e.isEncrypted()&&!1!==t.decrypt)throw new Error("start/end range not allowed for encrypted entry without options.decrypt === false")}if(null!=t.start){if((i=t.start)<0)throw new Error("options.start < 0");if(i>e.compressedSize)throw new Error("options.start > entry.compressedSize")}if(null!=t.end){if((o=t.end)<0)throw new Error("options.end < 0");if(o>e.compressedSize)throw new Error("options.end > entry.compressedSize");if(o<i)throw new Error("options.end < options.start")}}if(!n.isOpen)return r(new Error("closed"));if(e.isEncrypted()&&!1!==t.decrypt)return r(new Error("entry is encrypted, and options.decrypt !== false"));n.reader.ref();var a=_r(30);xr(n.reader,a,0,a.length,e.relativeOffsetOfLocalHeader,function(s){try{if(s)return r(s);var f=a.readUInt32LE(0);if(67324752!==f)return r(new Error("invalid local file header signature: 0x"+f.toString(16)));var u,l=a.readUInt16LE(26),c=a.readUInt16LE(28),m=e.relativeOffsetOfLocalHeader+a.length+l+c;if(0===e.compressionMethod)u=!1;else{if(8!==e.compressionMethod)return r(new Error("unsupported compression method: "+e.compressionMethod));u=null==t.decompress||t.decompress}var p=m,d=p+e.compressedSize;if(0!==e.compressedSize&&d>n.fileSize)return r(new Error("file data overflows file bounds: "+p+" + "+e.compressedSize+" > "+n.fileSize));var h=n.reader.createReadStream({start:p+i,end:p+o}),y=h;if(u){var g=!1,x=b.default.createInflateRaw();h.on("error",function(e){setImmediate(function(){g||x.emit("error",e)})}),h.pipe(x),n.validateEntrySizes?(y=new vr(e.uncompressedSize),x.on("error",function(e){setImmediate(function(){g||y.emit("error",e)})}),x.pipe(y)):y=x,y.destroy=function(){g=!0,x!==y&&x.unpipe(y),h.unpipe(x),h.destroy()}}r(null,y)}finally{n.reader.unref()}})},hr.prototype.getLastModDate=function(){return yr(this.lastModFileDate,this.lastModFileTime)},hr.prototype.isEncrypted=function(){return!!(1&this.generalPurposeBitFlag)},hr.prototype.isCompressed=function(){return 8===this.compressionMethod},y.default.inherits(vr,Jt),vr.prototype._transform=function(e,t,r){if(this.actualByteCount+=e.length,this.actualByteCount>this.expectedByteCount){var n="too many bytes in the stream. expected "+this.expectedByteCount+". got at least "+this.actualByteCount;return r(new Error(n))}r(null,e)},vr.prototype._flush=function(e){if(this.actualByteCount<this.expectedByteCount){var t="not enough bytes in the stream. expected "+this.expectedByteCount+". got only "+this.actualByteCount;return e(new Error(t))}e()},y.default.inherits(wr,$t),wr.prototype.ref=function(){this.refCount+=1},wr.prototype.unref=function(){var e=this;if(e.refCount-=1,!(e.refCount>0)){if(e.refCount<0)throw new Error("invalid unref");e.close(function(t){if(t)return e.emit("error",t);e.emit("close")})}},wr.prototype.createReadStream=function(e){var t=e.start,r=e.end;if(t===r){var n=new Qt;return setImmediate(function(){n.end()}),n}var i=this._readStreamForRange(t,r),o=!1,a=new br(this);i.on("error",function(e){setImmediate(function(){o||a.emit("error",e)})}),a.destroy=function(){i.unpipe(a),a.unref(),i.destroy()};var s=new vr(r-t);return a.on("error",function(e){setImmediate(function(){o||s.emit("error",e)})}),s.destroy=function(){o=!0,a.unpipe(s),a.destroy()},i.pipe(a).pipe(s)},wr.prototype._readStreamForRange=function(e,t){throw new Error("not implemented")},wr.prototype.read=function(e,t,r,n,i){var o=this.createReadStream({start:n,end:n+r}),a=new er,s=0;a._write=function(r,n,i){r.copy(e,t+s,0,r.length),s+=r.length,i()},a.on("finish",i),o.on("error",function(e){i(e)}),o.pipe(a)},wr.prototype.close=function(e){setImmediate(e)},y.default.inherits(br,Qt),br.prototype._flush=function(e){this.unref(),e()},br.prototype.unref=function(e){this.unreffedYet||(this.unreffedYet=!0,this.context.unref())};var _r,Er="\0☺☻♥♦♣♠•◘○◙♂♀♪♫☼►◄↕‼¶§▬↨↑↓→←∟↔▲▼ !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~⌂ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ ";function zr(e,t,r,n){if(n)return e.toString("utf8",t,r);for(var i="",o=t;o<r;o++)i+=Er[e[o]];return i}function Br(e,t){var r=e.readUInt32LE(t);return 4294967296*e.readUInt32LE(t+4)+r}function Cr(e){if(e)throw e}_r="function"==typeof Buffer.allocUnsafe?function(e){return Buffer.allocUnsafe(e)}:function(e){return new Buffer(e)};var kr={open:tr,fromFd:rr,fromBuffer:nr,fromRandomAccessReader:ir,dosDateTimeToDate:or,validateFileName:ar,ZipFile:sr,Entry:fr,RandomAccessReader:ur};const Sr=e=>new Promise((t,r)=>{const n=[];e.readEntry(),e.on("entry",t=>{((e,t)=>{const r={mode:e.externalFileAttributes>>16&65535,mtime:e.getLastModDate(),path:e.fileName};return r.type=((e,t)=>{const r=e.versionMadeBy>>8;return 40960==(61440&t)?"symlink":16384==(61440&t)||0===r&&16===e.externalFileAttributes?"directory":"file"})(e,r.mode),0===r.mode&&"directory"===r.type&&(r.mode=493),0===r.mode&&(r.mode=420),kt(t.openReadStream.bind(t))(e).then(Ct.buffer).then(e=>(r.data=e,"symlink"===r.type&&(r.linkname=e.toString()),r)).catch(e=>{throw t.close(),e})})(t,e).catch(r).then(t=>{n.push(t),e.readEntry()})}),e.on("error",r),e.on("end",()=>t(n))});const Or=(e,t)=>function(){const r=t.promiseModule,n=new Array(arguments.length);for(let e=0;e<arguments.length;e++)n[e]=arguments[e];return new r((r,i)=>{t.errorFirst?n.push(function(e,n){if(t.multiArgs){const t=new Array(arguments.length-1);for(let e=1;e<arguments.length;e++)t[e-1]=arguments[e];e?(t.unshift(e),i(t)):r(t)}else e?i(e):r(n)}):n.push(function(e){if(t.multiArgs){const e=new Array(arguments.length-1);for(let t=0;t<arguments.length;t++)e[t]=arguments[t];r(e)}else r(e)}),e.apply(this,n)})};var Ar=(e,t)=>{t=Object.assign({exclude:[/.+(Sync|Stream)$/],errorFirst:!0,promiseModule:Promise},t);const r=e=>{const r=t=>"string"==typeof t?e===t:t.test(e);return t.include?t.include.some(r):!t.exclude.some(r)};let n;n="function"==typeof e?function(){return t.excludeMain?e.apply(this,arguments):Or(e,t).apply(this,arguments)}:Object.create(Object.getPrototypeOf(e));for(const i in e){const o=e[i];n[i]="function"==typeof o&&r(i)?Or(o,t):o}return n};const Lr={mode:511&~process.umask(),fs:x.default},Rr=e=>{if("win32"===process.platform){if(/[<>:"|?*]/.test(e.replace(h.default.parse(e).root,""))){const t=new Error(`Path contains invalid characters: ${e}`);throw t.code="EINVAL",t}}};var Ir=(e,t)=>Promise.resolve().then(()=>{Rr(e),t=Object.assign({},Lr,t);const r=Ar(t.fs.mkdir),n=Ar(t.fs.stat),i=e=>r(e,t.mode).then(()=>e).catch(t=>{if("ENOENT"===t.code){if(t.message.includes("null bytes")||h.default.dirname(e)===e)throw t;return i(h.default.dirname(e)).then(()=>i(e))}return n(e).then(t=>t.isDirectory()?e:Promise.reject()).catch(()=>{throw t})});return i(h.default.resolve(e))});Ir.sync=(e,t)=>{Rr(e),t=Object.assign({},Lr,t);const r=e=>{try{t.fs.mkdirSync(e,t.mode)}catch(n){if("ENOENT"===n.code){if(n.message.includes("null bytes")||h.default.dirname(e)===e)throw n;return r(h.default.dirname(e)),r(e)}try{if(!t.fs.statSync(e).isDirectory())throw new Error("The path is not a directory")}catch(e){throw n}}return e};return r(h.default.resolve(e))};var Tr=r.createCommonjsModule(function(e){var t=function(e,t,r){return function(){for(var n=this,i=new Array(arguments.length),o=0;o<arguments.length;o++)i[o]=arguments[o];return new t(function(t,o){i.push(function(e,n){if(e)o(e);else if(r.multiArgs){for(var i=new Array(arguments.length-1),a=1;a<arguments.length;a++)i[a-1]=arguments[a];t(i)}else t(n)}),e.apply(n,i)})}},r=e.exports=function(e,r,n){"function"!=typeof r&&(n=r,r=Promise),(n=n||{}).exclude=n.exclude||[/.+Sync$/];var i="function"==typeof e?function(){return n.excludeMain?e.apply(this,arguments):t(e,r,n).apply(this,arguments)}:{};return Object.keys(e).reduce(function(i,o){var a=e[o];return i[o]="function"==typeof a&&function(e){var t=function(t){return"string"==typeof t?e===t:t.test(e)};return n.include?n.include.some(t):!n.exclude.some(t)}(o)?t(a,r,n):a,i},i)};r.all=r}),jr=function(e,t,r){if("string"!=typeof e)throw new TypeError(y.default.inspect(e)+" is not a string. First argument to strip-dirs must be a path string.");if(h.default.posix.isAbsolute(e)||h.default.win32.isAbsolute(e))throw new Error(`${e} is an absolute path. strip-dirs requires a relative path.`);if(!function(e,t){if(t){if("object"!=typeof t)throw new TypeError(String(t)+" is not an object. Expected an object that has boolean `includeZero` property.");if("includeZero"in t){if("boolean"!=typeof t.includeZero)throw new TypeError(String(t.includeZero)+" is neither true nor false. `includeZero` option must be a Boolean value.");if(t.includeZero&&0===e)return!0}}return Number.isSafeInteger(e)&&e>=1}(t,{includeZero:!0}))throw new Error("The Second argument of strip-dirs must be a natural number or 0, but received "+y.default.inspect(t)+".");if(r){if("object"!=typeof r)throw new TypeError(y.default.inspect(r)+" is not an object. Expected an object with a boolean `disallowOverflow` property.");if(Array.isArray(r))throw new TypeError(y.default.inspect(r)+" is an array. Expected an object with a boolean `disallowOverflow` property.");if("disallowOverflow"in r&&"boolean"!=typeof r.disallowOverflow)throw new TypeError(y.default.inspect(r.disallowOverflow)+" is neither true nor false. `disallowOverflow` option must be a Boolean value.")}else r={disallowOverflow:!1};const n=h.default.normalize(e).split(h.default.sep);if(n.length>1&&"."===n[0]&&n.shift(),t>n.length-1){if(r.disallowOverflow)throw new RangeError("Cannot strip more directories than there are.");t=n.length-1}return h.default.join.apply(null,n.slice(t))};
|
|
2
|
-
/*!
|
|
3
|
-
* is-natural-number.js | MIT (c) Shinnosuke Watanabe
|
|
4
|
-
* https://github.com/shinnn/is-natural-number.js
|
|
5
|
-
*/const Pr=Tr(t.gracefulFs),Ur=(e,t)=>Pr.realpath(e).catch(r=>{const n=h.default.dirname(e);return Ur(n,t)}).then(r=>{if(0!==r.indexOf(t))throw new Error("Refusing to create a directory outside the output path.");return Ir(e).then(Pr.realpath)}),Fr=(e,t,r)=>((e,t)=>0===t.plugins.length?Promise.resolve([]):Promise.all(t.plugins.map(r=>r(e,t))).then(e=>e.reduce((e,t)=>e.concat(t))))(e,r).then(e=>(r.strip>0&&(e=e.map(e=>(e.path=jr(e.path,r.strip),e)).filter(e=>"."!==e.path)),"function"==typeof r.filter&&(e=e.filter(r.filter)),"function"==typeof r.map&&(e=e.map(r.map)),t?Promise.all(e.map(e=>{const r=h.default.join(t,e.path),n=e.mode&~process.umask(),i=new Date;return"directory"===e.type?Ir(t).then(e=>Pr.realpath(e)).then(e=>Ur(r,e)).then(()=>Pr.utimes(r,i,e.mtime)).then(()=>e):Ir(t).then(e=>Pr.realpath(e)).then(e=>Ur(h.default.dirname(r),e).then(()=>e)).then(t=>"file"===e.type?((e,t)=>Pr.readlink(e).catch(e=>null).then(e=>{if(e)throw new Error("Refusing to write into a symlink");return t}))(r,t):t).then(e=>Pr.realpath(h.default.dirname(r)).then(t=>{if(0!==t.indexOf(e))throw new Error("Refusing to write outside output directory: "+t)})).then(()=>"link"===e.type||"symlink"===e.type&&"win32"===process.platform?Pr.link(e.linkname,r):"symlink"===e.type?Pr.symlink(e.linkname,r):Pr.writeFile(r,e.data,{mode:n})).then(()=>"file"===e.type&&Pr.utimes(r,i,e.mtime)).then(()=>e)})):e));var Nr=(e,t,r)=>{if("string"!=typeof e&&!Buffer.isBuffer(e))return Promise.reject(new TypeError("Input file required"));"object"==typeof t&&(r=t,t=null),r=Object.assign({plugins:[be(),e=>Buffer.isBuffer(e)||B(e)?!Buffer.isBuffer(e)||Ce(e)&&"bz2"===Ce(e).ext?Buffer.isBuffer(e)?be()(Ze.decode(e)):be()(e.pipe(Ve())):Promise.resolve([]):Promise.reject(new TypeError("Expected a Buffer or Stream, got "+typeof e)),e=>{if(!Buffer.isBuffer(e)&&!B(e))return Promise.reject(new TypeError("Expected a Buffer or Stream, got "+typeof e));if(Buffer.isBuffer(e)&&(!z(e)||"gz"!==z(e).ext))return Promise.resolve([]);const t=b.default.createGunzip(),r=be()(t);return Buffer.isBuffer(e)?t.end(e):e.pipe(t),r},e=>Buffer.isBuffer(e)?Je(e)&&"zip"===Je(e).ext?kt(kr.fromBuffer)(e,{lazyEntries:!0}).then(Sr):Promise.resolve([]):Promise.reject(new TypeError("Expected a Buffer, got "+typeof e))]},r);return("string"==typeof e?Pr.readFile(e):Promise.resolve(e)).then(e=>Fr(e,t,r))},Dr=d({__proto__:null,default:Nr},[Nr]);exports.index=Dr;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("./installer-dbc2c34a.js"),t=require("./project-43370ed3.js"),i=require("./workbook-xml-a61269f4.js"),r=require("./build-target-dbcc69c7.js"),a=require("./export-target-5d28d188.js"),o=require("path");exports.initProject=async function(n){let{name:s,dir:c=e.env.cwd,target:p,from:d,pkg:m,git:l}=n;if(await e.pathExists_1.pathExists(e.join(c,"vbaproject.toml")))throw new e.CliError(e.ErrorCode.InitAlreadyInitialized,"A vbapm project already exists in this directory.");if(d&&!await e.pathExists_1.pathExists(d))throw new e.CliError(e.ErrorCode.FromNotFound,`The "from" document was not found at "${d}".`);if(s=s||(d?o.basename(d,o.extname(d)):o.basename(c)),!s)throw new e.CliError(e.ErrorCode.InitNameRequired,e.dedent`
|
|
2
|
-
Unable to determine name from current directory or --from.
|
|
3
|
-
--name NAME is required to initialize this project.
|
|
4
|
-
`);if(!p&&!d&&s.includes(".")){const e=s.split(".");p=e.pop(),s=e.join(".")}if(!m&&!p&&!d)throw new e.CliError(e.ErrorCode.InitTargetRequired,e.dedent`
|
|
5
|
-
--target or --from is required for vbapm projects.
|
|
6
|
-
(e.g. vbapm init --target xlsm)
|
|
7
|
-
`);await e.mkdirs_1.ensureDir(e.join(c,"src")),l&&!await e.pathExists_1.pathExists(e.join(c,".git"))&&(await t.init(c),await e.writeFile(e.join(c,".gitignore"),"/build"),await e.writeFile(e.join(c,".gitattributes"),"* text=auto\n*.bas text eol=crlf\n*.cls text eol=crlf"),await e.writeFile(e.join(c,".editorconfig"),e.dedent`
|
|
8
|
-
[*]
|
|
9
|
-
trim_trailing_whitespace = true
|
|
10
|
-
insert_final_newline = true
|
|
11
|
-
charset = utf-8
|
|
12
|
-
|
|
13
|
-
[*.{bas,cls}]
|
|
14
|
-
end_of_line = crlf
|
|
15
|
-
`));const w=await t.initProject(s,c,{type:m?"package":"project"});if(d&&(p=o.extname(d).replace(".","")),p){const n=[];await async function(n,s,c={}){const{project:p}=s;let{from:d,name:m=p.manifest.name,path:l="target"}=c;if(p.manifest.target)throw new e.CliError(e.ErrorCode.TargetAlreadyDefined,"A target is already defined for this project.");const w=e.join(p.paths.staging,"export");await e.mkdirs_1.ensureDir(w),await e.empty.emptyDir(w);try{let c;if(d)d=e.resolve(d),m=o.basename(d,o.extname(d)),c=p.manifest.target={name:m,type:n,path:e.join(p.paths.dir,l),filename:`${e.sanitize(m)}.${n}`},await e.copy.copy(d,e.join(p.paths.build,c.filename)),await i.exportTo(p,c,w),await a.exportTarget(c,s,w);else{c=p.manifest.target={name:m,type:n,path:e.join(p.paths.dir,l),filename:`${e.sanitize(m)}.${n}`},await i.createDocument(p,c);const t=await a.extractTarget(p,c,w);await e.remove.remove(c.path),await e.copy.copy(t,c.path),await r.buildTarget(c,s)}await t.writeManifest(p.manifest,p.paths.dir)}catch(e){throw e}finally{await e.remove.remove(w)}}(p,{project:w,dependencies:n},{from:d})}await t.writeManifest(w.manifest,w.paths.dir)};
|