-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsubmit.js
1 lines (1 loc) · 2.59 KB
/
submit.js
1
const _0x4008=['exit','stringify','Password:','git\x20config\x20--get\x20remote.origin.url','message','Usuario\x20de\x20github:','git\x20push\x20https://','trim','\x20master','status','error:\x20','application/json','log','statusText','https://proxy.soyhenry.com:3000/submit','now','split','then','catch','git\x20commit\x20-m\x20\x22CP\x20commiteado\x20por\x20','hide','node-fetch','error','child_process','\x20a\x20las\x20','Submit\x20OK\x0a'];(function(_0xb38a21,_0x4008b7){const _0x41025e=function(_0x581b13){while(--_0x581b13){_0xb38a21['push'](_0xb38a21['shift']());}};_0x41025e(++_0x4008b7);}(_0x4008,0xf9));const _0x4102=function(_0xb38a21,_0x4008b7){_0xb38a21=_0xb38a21-0x0;let _0x41025e=_0x4008[_0xb38a21];return _0x41025e;};const _0x10a193=_0x4102,{exec}=require(_0x10a193('0x8')),fetch=require(_0x10a193('0x6'));var prompt=require('prompt-sync')();const fs=require('fs');function ejecutar(_0x581b13){return new Promise((_0x271981,_0x20ddd5)=>{exec(_0x581b13,(_0x385fb5,_0x30fc7e,_0x57bd88)=>{const _0x560cab=_0x4102;if(_0x385fb5)return _0x20ddd5(_0x560cab('0x15')+_0x385fb5[_0x560cab('0xf')]);if(_0x57bd88)return _0x271981('stderr:\x20'+_0x57bd88);_0x271981(_0x30fc7e);});});}(async function iniciarProceso(){const _0x510d4f=_0x10a193,_0x561e92=prompt('Estas\x20seguro\x20que\x20deseas\x20submitear\x20este\x20resultado?\x20(S/n)\x20')['toLowerCase']();if(_0x561e92!=='s')return process[_0x510d4f('0xb')](0x0);const _0x381aed=prompt(_0x510d4f('0x10'))['toLowerCase'](),_0x3787ac=prompt[_0x510d4f('0x5')](_0x510d4f('0xd'));let _0x3d204c;try{const _0x3c6bea=await ejecutar(_0x510d4f('0xe'));_0x3d204c=_0x3c6bea[_0x510d4f('0x12')]()[_0x510d4f('0x1')]('/')['pop'](),await ejecutar('git\x20add\x20.'),await ejecutar(_0x510d4f('0x4')+_0x381aed+_0x510d4f('0x9')+Date[_0x510d4f('0x0')]()+'\x22'),await ejecutar(_0x510d4f('0x11')+_0x381aed+':'+_0x3787ac+'@github.com/'+_0x381aed+'/'+_0x3d204c+_0x510d4f('0x13'));}catch(_0x4cc2c6){return console[_0x510d4f('0x7')](_0x4cc2c6),process[_0x510d4f('0xb')](0x0);}fetch(_0x510d4f('0x19'),{'method':'post','headers':{'Content-Type':_0x510d4f('0x16')},'body':JSON[_0x510d4f('0xc')]({'github':_0x381aed,'passed':0x0,'total':0x0,'repo':'FTM2\x20-\x2008-React-Estado-LifeCycle'})})[_0x510d4f('0x2')](function(_0x2a3140){const _0x45cfec=_0x510d4f;if(_0x2a3140[_0x45cfec('0x14')]!==0xc8)throw new Error(_0x2a3140[_0x45cfec('0x18')]);return console['log'](_0x45cfec('0xa')),process[_0x45cfec('0xb')](0x0);})[_0x510d4f('0x3')](function(_0x41e851){const _0x33b7ec=_0x510d4f;return console[_0x33b7ec('0x7')](_0x41e851),console[_0x33b7ec('0x17')]('Falló\x20el\x20submit\x0a'),process[_0x33b7ec('0xb')](0x1);});}());