termill 0.2.0

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/CHANGELOG.md ADDED
@@ -0,0 +1,8 @@
1
+ # v0.2.0 — Author Tooling
2
+
3
+ Released: 2026-03-21
4
+
5
+ - Added `AUTHORING.md` — full termill package authoring spec covering discoverability metadata, terminal lifecycle contract, entry point requirements, and a getting-started guide for game developers
6
+ - Added `termill validate` command — validates a local project or published npm package against the termill authoring spec, reporting pass/fail per check with fix instructions
7
+ - Added `termill init` command — scaffolds a minimal spec-compliant terminal game project with correct `package.json`, entry point stub, `.gitignore`, and README
8
+ - Uninstall games from the library — press D on a selected game to remove it from the global npm install and the local library
package/README.md ADDED
@@ -0,0 +1,63 @@
1
+ # termill
2
+
3
+ [![npm version](https://img.shields.io/npm/v/termill.svg)](https://www.npmjs.com/package/termill)
4
+ [![license](https://img.shields.io/npm/l/termill.svg)](LICENSE)
5
+
6
+ A decentralized terminal gaming platform. Discover, install, and launch Node.js terminal games — all from your command line.
7
+
8
+ ---
9
+
10
+ ## Install
11
+
12
+ ```bash
13
+ npm install -g termill
14
+ ```
15
+
16
+ Requires **Node.js v20+**.
17
+
18
+ ---
19
+
20
+ ## What is termill?
21
+
22
+ termill is a command-line platform for terminal game discovery and management. It connects to a peer-to-peer gossip network to surface available games, lets you install them globally with one keypress, and launches them directly from your library.
23
+
24
+ - **Discover** — browse and search for terminal games from peers and npm
25
+ - **Install** — install any listed game globally in one step
26
+ - **Play** — launch installed games instantly from your library
27
+
28
+ ---
29
+
30
+ ## Quick start
31
+
32
+ ```bash
33
+ termill
34
+ ```
35
+
36
+ On first launch termill generates a local Ed25519 identity (stored in `~/.termill/`).
37
+
38
+ | Screen | What you can do |
39
+ |--------|-----------------|
40
+ | **Discover** | Type to search, `↑↓` to navigate, `ENTER` to install, `L` to open library |
41
+ | **Library** | `↑↓` to navigate, `ENTER` to launch, `H`/`ESC` to go back |
42
+
43
+ Press `CTRL+C` at any time to quit.
44
+
45
+ ---
46
+
47
+ ## Requirements
48
+
49
+ - Node.js v20 or later
50
+ - npm (for game installation)
51
+ - A terminal with standard ANSI support
52
+
53
+ ---
54
+
55
+ ## For Game Authors
56
+
57
+ Want to publish a terminal game to the termill ecosystem? Use `termill init` to scaffold a compliant project in seconds, `termill validate .` to check it before publishing, then `npm publish` to make it discoverable. Full spec and getting-started guide in [AUTHORING.md](AUTHORING.md).
58
+
59
+ ---
60
+
61
+ ## License
62
+
63
+ MIT
package/dist/index.js ADDED
@@ -0,0 +1,2 @@
1
+ #!/usr/bin/env node
2
+ const _0x1325f3=_0x3bc5;(function(_0x9bd684,_0x47b163){const _0xe74a44=_0x3bc5,_0x558614=_0x9bd684();while(!![]){try{const _0x184986=-parseInt(_0xe74a44(0x224))/0x1+parseInt(_0xe74a44(0x1a8))/0x2+parseInt(_0xe74a44(0x25e))/0x3*(parseInt(_0xe74a44(0x276))/0x4)+-parseInt(_0xe74a44(0x20f))/0x5*(-parseInt(_0xe74a44(0x251))/0x6)+-parseInt(_0xe74a44(0x234))/0x7*(parseInt(_0xe74a44(0x1c2))/0x8)+parseInt(_0xe74a44(0x26a))/0x9*(-parseInt(_0xe74a44(0x238))/0xa)+parseInt(_0xe74a44(0x26e))/0xb;if(_0x184986===_0x47b163)break;else _0x558614['push'](_0x558614['shift']());}catch(_0x207228){_0x558614['push'](_0x558614['shift']());}}}(_0x26f3,0x1a6ce));import{mkdirSync as _0x289ad9}from'node:fs';import{homedir as _0x24a0d5}from'node:os';import{join as _0x468661}from'node:path';var w=_0x468661(_0x24a0d5(),_0x1325f3(0x21d)),x=_0x468661(w,'keys'),k=_0x468661(w,_0x1325f3(0x1d5)),b=_0x468661(w,_0x1325f3(0x253)),O=[];import{generateKeyPairSync as _0x1984ce,sign as _0x1bd5e2,verify as _0xfa5d3c,createPublicKey as _0x365047}from'node:crypto';import{readFileSync as _0x920764,writeFileSync as _0x38a686,existsSync as _0x5bf2e9,mkdirSync as _0x11ffc5}from'node:fs';import{join as _0xf2cf44}from'node:path';var z=_0xf2cf44(x,_0x1325f3(0x1c7)),D=_0xf2cf44(x,'id_ed25519.pub');function Q(){const _0x1e4f73=_0x1325f3;_0x11ffc5(x,{'recursive':!0x0});let {privateKey:_0x2e38d4,publicKey:_0x42346c}=_0x1984ce(_0x1e4f73(0x26d),{'privateKeyEncoding':{'type':_0x1e4f73(0x1f1),'format':_0x1e4f73(0x278)},'publicKeyEncoding':{'type':_0x1e4f73(0x254),'format':_0x1e4f73(0x23a)}}),_0x48b97a=_0x42346c[_0x1e4f73(0x230)](-0x20)['toString'](_0x1e4f73(0x215));return _0x38a686(z,_0x2e38d4,{'encoding':'utf8','mode':0x180}),_0x38a686(D,_0x48b97a,{'encoding':_0x1e4f73(0x1b3),'mode':0x1a4}),{'publicKey':_0x48b97a};}function X(){return _0x5bf2e9(z)&&_0x5bf2e9(D);}function Z(){const _0x8b2d0b=_0x1325f3;return _0x920764(D,_0x8b2d0b(0x1b3))['trim']();}import{readFileSync as _0x4a8713,writeFileSync as _0x2285d4,existsSync as _0x2a836b,mkdirSync as _0x3581e4}from'node:fs';import{dirname as _0x19b491}from'node:path';function N(){const _0x465a71=_0x1325f3;if(!_0x2a836b(k))return[];try{return JSON[_0x465a71(0x207)](_0x4a8713(k,_0x465a71(0x1b3)));}catch{return[];}}function q(_0x4037bc){const _0x4ea162=_0x1325f3;_0x3581e4(_0x19b491(k),{'recursive':!0x0}),_0x2285d4(k,JSON[_0x4ea162(0x264)](_0x4037bc,null,0x2),_0x4ea162(0x1b3));}function ee(_0x2d2908){const _0x399ce4=_0x1325f3;let _0x3d3a93=N()[_0x399ce4(0x23c)](_0x3f3f7f=>_0x3f3f7f[_0x399ce4(0x265)]!==_0x2d2908[_0x399ce4(0x265)]);_0x3d3a93['push'](_0x2d2908),q(_0x3d3a93);}function _0x26f3(){const _0x54c4e2=['Searching…','toISOString','38169kyBOAC','```bash','resume','ed25519','1624623BcYmCo','repeat','stdin','\x0a✓\x20Project\x20scaffolded\x20at\x20./','isDirectory','```','Shebang\x20found','\x0aNext\x20steps:','76DlQQJN','npm\x20view\x20','pem','title','\x20\x20v','objects','73046sqkHTR','do\x20shell\x20script\x20\x22open\x20-a\x20Terminal\x20','check','down','\x20uninstalled.\x20Press\x20ENTER\x20to\x20continue.','termill.description\x20is\x20missing\x20or\x20empty','\x20updated\x20to\x20latest.\x20Launching…','//\x20TODO:\x20implement\x20your\x20game\x20here','flat','No\x20package.json\x20found\x20at\x20','process.stdin.once(\x27data\x27,\x20()\x20=>\x20{','utf8','\x20\x20npm\x20link\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20link\x20globally\x20for\x20local\x20testing','keywords:termill','\x0a✓\x20','keywords','termill.description:\x20\x22','\x1b[A','termill\x20metadata\x20block\x20found','termill.name\x20is\x20missing\x20or\x20empty','process.exit(','stdout','test','bin\x20file\x20not\x20found\x20at\x20path:\x20','cmd.exe','message','56QDRVOU','timeout','toLowerCase','length','bin\x20file\x20exists','id_ed25519','launchCommand','log','[7m','WARNING:\x20No\x20process.exit()\x20found.\x20termill\x20spawns\x20a\x20new\x20terminal\x20window\x20—\x20your\x20game\x20must\x20call\x20process.exit()\x20on\x20quit\x20to\x20close\x20it\x20cleanly','find','json','npm\x20list\x20-g\x20--json\x20','name','backspace','.\x20Press\x20ENTER\x20to\x20continue.','updated','right','inherit','library.json','Short\x20description:\x20','console.log(\x27Press\x20ENTER\x20to\x20quit.\x27);','Generating\x20Ed25519\x20keypair…','[1m','\x0atermill\x20init\x20—\x20scaffold\x20a\x20new\x20termill\x20game\x20project\x0a','.gitignore','xterm','error','/games','!\x27);','Package\x20name\x20(npm\x20package\x20name,\x20e.g.\x20my-termill-game):\x20','catch','\x22\x20is\x20missing\x20a\x20\x22termill\x22\x20property\x20in\x20its\x20package.json','TERM','\x1b[D','description:\x20\x22','termill','\x0aIdentity\x20created.\x20Your\x20public\x20key:','process.exit()\x20call\x20found\x20in\x20source\x20files','process.stdin.setEncoding(\x27utf8\x27);','env','Press\x20ENTER\x20to\x20generate\x20a\x20new\x20keypair\x20and\x20create\x20your\x20identity.\x0a','unknown','\x20keywords:termill','escape','index.js','isTTY','pkcs8','[2m','object','setRawMode','trim','?text=','termill\x20—\x20discover','description','bin\x20field\x20found:\x20','//\x20','argv','Discovering\x20games…','push','\x0a✗\x20Uninstall\x20failed:\x20','isArray','\x20installed.\x20Press\x20ENTER\x20to\x20continue.','\x20version\x20--json','write','Add\x20\x22termill\x22\x20to\x20the\x20keywords\x20array\x20in\x20package.json\x20for\x20discoverability','MIT','start','function','parse','stop','\x0a\x20\x20No\x20games\x20installed.\x20Press\x20H\x20to\x20discover\x20games.\x0a','\x0aWelcome\x20back!','Package\x20\x22','termill\x20—\x20identity','Missing\x20\x22termill\x22\x20block\x20in\x20package.json\x20—\x20add\x20{\x20\x22termill\x22:\x20{\x20\x22name\x22:\x20\x22...\x22,\x20\x22description\x22:\x20\x22...\x22,\x20\x22launchCommand\x22:\x20\x22...\x22\x20}\x20}','values','214910nlsRkF','termill\x20—\x20library','ignore','\x20is\x20up\x20to\x20date.\x20Launching…','README.md','##\x20License','hex','Press\x20ENTER\x20to\x20continue.','data','?\x20[Y/N]','columns','\x0aError:\x20directory\x20\x22','removeListener','bin\x20file\x20has\x20#!/usr/bin/env\x20node\x20shebang','.termill','\x0aNo\x20identity\x20found.','library','all','npm\x20uninstall\x20-g\x20','includes','description\x20is\x20non-empty','61961wynrDc','forEach','keywords\x20includes\x20\x22termill\x22','linux','floor','min','home','platform','exit','\x20\x20termill\x20validate\x20.\x20\x20\x20\x20#\x20check\x20compliance\x20before\x20publishing','join','process.stdin.resume();','slice','process.exit()\x20call\x20found\x20(warn\x20only)','./index.js','node_modules\x0a','101213FsJRdY','npm\x20install\x20-g\x20','close','1.0.0','140MHYXOe','npm\x20root\x20-g','der','dependencies','filter','bin\x20file\x20found:\x20','darwin','Missing\x20\x22bin\x22\x20field\x20in\x20package.json\x20—\x20add\x20a\x20bin\x20entry\x20pointing\x20to\x20your\x20entry\x20file','\x20—\x20entry\x20point','\x1b[C','\x0aInstalling\x20','package.json','return','\x22\x20already\x20exists\x20in\x20the\x20current\x20folder.','[termill]\x20Fatal\x20error:','\x20--json','\x0a✗\x20Install\x20failed:\x20','[↑↓]\x20navigate\x20\x20[ENTER]\x20launch\x20\x20[D]\x20uninstall\x20\x20[H/ESC]\x20home\x20\x20[CTRL+C]\x20quit','cwd','\x20is\x20missing\x20\x22#!/usr/bin/env\x20node\x22\x20on\x20line\x201','ctrl+c','Missing\x20or\x20empty\x20\x22description\x22\x20field\x20in\x20package.json','version','setEncoding','question','6jemuqZ','padEnd','peers.json','spki','termill.name:\x20\x22','init','max','\x0aSearch:\x20','startsWith','[↑↓]\x20navigate\x20\x20[ENTER]\x20install\x20\x20[L]\x20library\x20\x20[CTRL+C]\x20quit','has','termill.description\x20is\x20set','string','16356fgLDIl','Checking\x20','node_modules','\x22\x20from\x20npm','validate','map','stringify','packageName','warn\x20only','\x20\x20cd\x20'];_0x26f3=function(){return _0x54c4e2;};return _0x26f3();}function te(_0x160cfd){const _0x5d377e=_0x1325f3;return N()[_0x5d377e(0x1cc)](_0x29bb1e=>_0x29bb1e[_0x5d377e(0x265)]===_0x160cfd)??null;}function ne(_0x5b35e7){const _0x4181cb=_0x1325f3;let _0x20cb74=N()[_0x4181cb(0x23c)](_0x25ac7c=>_0x25ac7c[_0x4181cb(0x265)]!==_0x5b35e7);q(_0x20cb74);}function re(){return N();}import{execSync as _0xb103a8}from'node:child_process';import{readFileSync as _0x9e6573}from'node:fs';import{join as _0x44aba5}from'node:path';function Te(_0x4eee8b){const _0x3fbcaf=_0x1325f3;let _0x39a5a3=_0xb103a8(_0x3fbcaf(0x239),{'encoding':'utf8'})[_0x3fbcaf(0x1f5)](),_0x34ea34=_0x44aba5(_0x39a5a3,_0x4eee8b,_0x3fbcaf(0x243)),_0x22bff3=JSON['parse'](_0x9e6573(_0x34ea34,_0x3fbcaf(0x1b3)));if(!_0x22bff3['termill'])throw new Error(_0x3fbcaf(0x20b)+_0x4eee8b+_0x3fbcaf(0x1e2));return _0x22bff3[_0x3fbcaf(0x1e6)];}function Re(_0x38d06d){const _0x3a75bf=_0x1325f3;try{let _0x929e5a=JSON[_0x3a75bf(0x207)](_0xb103a8(_0x3a75bf(0x277)+_0x38d06d+_0x3a75bf(0x201),{'encoding':'utf8'}));return typeof _0x929e5a=='string'?_0x929e5a:String(_0x929e5a);}catch{return _0x3a75bf(0x1ec);}}async function _(_0x3ff5a5){const _0x4729a3=_0x1325f3;let _0x151c1d=te(_0x3ff5a5);if(_0x151c1d){let _0x1c396c=Re(_0x3ff5a5);if(_0x1c396c!==_0x4729a3(0x1ec)&&_0x1c396c===_0x151c1d[_0x4729a3(0x24e)])return{'alreadyCurrent':!0x0};}_0xb103a8(_0x4729a3(0x235)+_0x3ff5a5,{'stdio':_0x4729a3(0x1d4)});let _0x21d104=Te(_0x3ff5a5),_0x5b815a=JSON['parse'](_0xb103a8(_0x4729a3(0x1ce)+_0x3ff5a5,{'encoding':_0x4729a3(0x1b3)}))[_0x4729a3(0x23b)]?.[_0x3ff5a5]?.[_0x4729a3(0x24e)]??_0x4729a3(0x1ec);return ee({'packageName':_0x3ff5a5,'title':_0x21d104[_0x4729a3(0x1a5)]??_0x3ff5a5,'description':_0x21d104[_0x4729a3(0x1f8)]??'','version':_0x5b815a,'launchCommand':_0x21d104[_0x4729a3(0x1c8)],'installedAt':new Date()[_0x4729a3(0x269)]()}),_0x151c1d?{'updated':!0x0}:{};}async function oe(_0x415dc9){const _0x382dbb=_0x1325f3;_0xb103a8(_0x382dbb(0x221)+_0x415dc9,{'stdio':_0x382dbb(0x1d4)}),ne(_0x415dc9);}import{spawn as _0x4a2a58}from'node:child_process';function Ae(){const _0x1c9aa4=_0x1325f3;let _0x233706=process[_0x1c9aa4(0x22b)];return _0x233706==='win32'||_0x233706===_0x1c9aa4(0x23e)?_0x233706:_0x1c9aa4(0x227);}function Le(_0x4cffa3,_0x54c50d){const _0x510ef1=_0x1325f3;switch(_0x54c50d){case'win32':return{'cmd':_0x510ef1(0x1c0),'args':['/c','start',_0x510ef1(0x1c0),'/k',_0x4cffa3],'options':{'detached':!0x0,'shell':!0x1}};case _0x510ef1(0x23e):return{'cmd':'osascript','args':['-e',_0x510ef1(0x1a9)+_0x4cffa3+'\x22'],'options':{'detached':!0x0}};case _0x510ef1(0x227):default:return{'cmd':process[_0x510ef1(0x1ea)][_0x510ef1(0x1e3)]??_0x510ef1(0x1dc),'args':['-e',_0x4cffa3],'options':{'detached':!0x0}};}}function T(_0xd1ee37){const _0xe14f2d=_0x1325f3;let {cmd:_0x5d35ec,args:_0x3dfa01,options:_0x4d074b}=Le(_0xd1ee37,Ae());_0x4a2a58(_0x5d35ec,_0x3dfa01,{..._0x4d074b,'stdio':_0xe14f2d(0x211)})['unref']();}import{readFileSync as _0x31b765,writeFileSync as _0x29cfbd,existsSync as _0x36d5bc,mkdirSync as _0x25e6c3}from'node:fs';import{dirname as _0x1a40e3}from'node:path';function Je(){const _0x518ddf=_0x1325f3;if(!_0x36d5bc(b))return[...O];try{return JSON[_0x518ddf(0x207)](_0x31b765(b,_0x518ddf(0x1b3)));}catch{return[...O];}}function Ge(_0xb4439d){const _0xcd697e=_0x1325f3;_0x25e6c3(_0x1a40e3(b),{'recursive':!0x0}),_0x29cfbd(b,JSON[_0xcd697e(0x264)](_0xb4439d,null,0x2),_0xcd697e(0x1b3));}async function He(_0x53db16){const _0x2d7803=_0x1325f3;try{let _0x67cd70=await fetch(_0x53db16+_0x2d7803(0x1de),{'signal':AbortSignal[_0x2d7803(0x1c3)](0x1388)});return _0x67cd70['ok']?await _0x67cd70['json']():[];}catch{return[];}}async function Be(_0x16a54a){const _0x2583bb=_0x1325f3;try{let _0x1a6046=await fetch(_0x16a54a+'/peers',{'signal':AbortSignal[_0x2583bb(0x1c3)](0x1388)});return _0x1a6046['ok']?await _0x1a6046[_0x2583bb(0x1cd)]():[];}catch{return[];}}async function se(){const _0x2c0cb9=_0x1325f3;let _0x3e77cd=Je(),[_0x3e8acf,_0x37c082]=await Promise[_0x2c0cb9(0x220)]([Promise[_0x2c0cb9(0x220)](_0x3e77cd[_0x2c0cb9(0x263)](_0x52cbc5=>He(_0x52cbc5))),Promise['all'](_0x3e77cd[_0x2c0cb9(0x263)](_0x27f6af=>Be(_0x27f6af)))]),_0x543aff=_0x3e8acf['flat'](),_0x4f4f86=_0x37c082[_0x2c0cb9(0x1b0)](),_0x49e650=[...new Set([..._0x3e77cd,..._0x4f4f86])];return Ge(_0x49e650),{'games':_0x543aff,'peers':_0x49e650};}function _0x3bc5(_0x26a7da,_0x4ef9c0){_0x26a7da=_0x26a7da-0x1a5;const _0x26f334=_0x26f3();let _0x3bc5cf=_0x26f334[_0x26a7da];return _0x3bc5cf;}var Ye='https://registry.npmjs.org/-/v1/search';function Fe(_0x377862){const _0x4ce3c5=_0x1325f3;let _0x565453=_0x377862[_0x4ce3c5(0x1e6)]??{};return{'packageName':_0x377862['name'],'title':_0x565453[_0x4ce3c5(0x1a5)]??_0x377862[_0x4ce3c5(0x1cf)],'description':_0x565453['description']??_0x377862[_0x4ce3c5(0x1f8)]??'','version':_0x377862['version']??_0x4ce3c5(0x1ec),'keywords':_0x377862['keywords']??[]};}async function R(_0x4d6bbe=''){const _0x142b8a=_0x1325f3;let [_0x7d89d,_0x5024c1]=await Promise[_0x142b8a(0x220)]([se()[_0x142b8a(0x1e1)](()=>({'games':[]})),Ue(_0x4d6bbe)]),_0x5df081=_0x7d89d['games']??[],_0x2bf2be=new Set(_0x5df081[_0x142b8a(0x263)](_0xbeeea3=>_0xbeeea3['packageName'])),_0x259a0d=_0x5024c1[_0x142b8a(0x23c)](_0x2dd768=>!_0x2bf2be[_0x142b8a(0x25b)](_0x2dd768[_0x142b8a(0x265)])),_0x2e4780=_0x4d6bbe[_0x142b8a(0x1f5)]()[_0x142b8a(0x1c4)](),_0x39686f=_0x4b0c47=>_0x2e4780?_0x4b0c47[_0x142b8a(0x265)]['toLowerCase']()['includes'](_0x2e4780)||(_0x4b0c47[_0x142b8a(0x1a5)]??'')['toLowerCase']()['includes'](_0x2e4780)||(_0x4b0c47[_0x142b8a(0x1f8)]??'')[_0x142b8a(0x1c4)]()[_0x142b8a(0x222)](_0x2e4780):!0x0;return[..._0x5df081[_0x142b8a(0x23c)](_0x39686f),..._0x259a0d[_0x142b8a(0x23c)](_0x39686f)];}async function Ue(_0x1d410c){const _0x26f831=_0x1325f3;try{let _0x2c5e36=_0x1d410c?encodeURIComponent(_0x1d410c+_0x26f831(0x1ed)):_0x26f831(0x1b5),_0x3dc4bf=Ye+_0x26f831(0x1f6)+_0x2c5e36+'&size=20',_0x5f2081=await fetch(_0x3dc4bf,{'signal':AbortSignal['timeout'](0x1f40)});return _0x5f2081['ok']?((await _0x5f2081[_0x26f831(0x1cd)]())[_0x26f831(0x1a7)]??[])[_0x26f831(0x263)](_0x545483=>Fe(_0x545483['package'])):[];}catch{return[];}}import{stdout as _0x2332d9}from'node:process';var j='\x1b',M=j+'[0m',Ve=j+_0x1325f3(0x1ca),ze=j+_0x1325f3(0x1f2),Qe=j+_0x1325f3(0x1d9),ie=()=>_0x2332d9[_0x1325f3(0x219)]??0x50;function m(_0x547505){const _0x5670ee=_0x1325f3;let _0xb7b99f=ie(),_0x4c7436='\x20'+_0x547505+'\x20',_0x2674fa=Math[_0x5670ee(0x228)]((_0xb7b99f-_0x4c7436[_0x5670ee(0x1c5)])/0x2),_0x54a75b='─'['repeat'](Math[_0x5670ee(0x257)](0x0,_0x2674fa))+_0x4c7436+'─'[_0x5670ee(0x26f)](Math[_0x5670ee(0x257)](0x0,_0x2674fa));console[_0x5670ee(0x1c9)](Qe+_0x54a75b[_0x5670ee(0x230)](0x0,_0xb7b99f)+M);}function K(_0x1137ba,_0x1268f1){const _0x224c26=_0x1325f3;_0x1137ba[_0x224c26(0x225)]((_0x2c641a,_0x3f5abe)=>{const _0x25a7c8=_0x224c26;let _0x541ef8=(_0x3f5abe===_0x1268f1?'>\x20':'\x20\x20')+_0x2c641a;console[_0x25a7c8(0x1c9)](_0x3f5abe===_0x1268f1?Ve+_0x541ef8[_0x25a7c8(0x252)](ie())+M:_0x541ef8);});}function J(_0x2137ba){console['log'](ze+_0x2137ba+M);}function h(_0x5cbbe2){let _0x285617=['⠋','⠙','⠹','⠸','⠼','⠴','⠦','⠧','⠇','⠏'],_0xb0bcc2=0x0,_0x5282a4=null;return{'start'(){_0x5282a4=setInterval(()=>{const _0x274fc4=_0x3bc5;process['stdout'][_0x274fc4(0x202)]('\x0d'+_0x285617[_0xb0bcc2++%_0x285617['length']]+'\x20'+_0x5cbbe2);},0x50);},'stop'(){const _0x4987db=_0x3bc5;_0x5282a4&&(clearInterval(_0x5282a4),_0x5282a4=null,process[_0x4987db(0x1bd)]['write']('\x0d'+'\x20'['repeat'](_0x5cbbe2[_0x4987db(0x1c5)]+0x4)+'\x0d'));}};}function f(){const _0x396e91=_0x1325f3;process[_0x396e91(0x1bd)][_0x396e91(0x202)]('\x1b[2J\x1b[H');}function G(){return new Promise(_0x5de550=>{const _0x1e26cc=_0x3bc5;let {stdin:_0x42eed1}=process,_0x193aee=_0x42eed1['isRaw'];_0x42eed1['isTTY']&&_0x42eed1[_0x1e26cc(0x1f4)](!0x0),_0x42eed1[_0x1e26cc(0x26c)](),_0x42eed1[_0x1e26cc(0x24f)](_0x1e26cc(0x1b3));function _0x456573(_0x56f45e){const _0x14bfb9=_0x1e26cc;_0x42eed1[_0x14bfb9(0x21b)](_0x14bfb9(0x217),_0x456573),_0x42eed1['isTTY']&&!_0x193aee&&_0x42eed1[_0x14bfb9(0x1f4)](!0x1),_0x42eed1['pause']();let _0x39ab63=ae(_0x56f45e);_0x5de550({'name':_0x39ab63,'sequence':_0x56f45e,'ctrl':_0x56f45e<='\x1a'&&_0x56f45e!=='\x0d','shift':!0x1});}_0x42eed1['once'](_0x1e26cc(0x217),_0x456573);});}function H(_0x19a87c){const _0x342a77=_0x1325f3;let {stdin:_0x3ad783}=process;_0x3ad783[_0x342a77(0x1f0)]&&_0x3ad783[_0x342a77(0x1f4)](!0x0),_0x3ad783['resume'](),_0x3ad783[_0x342a77(0x24f)]('utf8');function _0xa44ee(_0x40ca33){_0x19a87c({'name':ae(_0x40ca33),'sequence':_0x40ca33});}return _0x3ad783['on']('data',_0xa44ee),function(){const _0xd34435=_0x342a77;_0x3ad783[_0xd34435(0x21b)](_0xd34435(0x217),_0xa44ee),_0x3ad783[_0xd34435(0x1f0)]&&_0x3ad783[_0xd34435(0x1f4)](!0x1),_0x3ad783['pause']();};}function ae(_0x27d60e){const _0x58e65f=_0x1325f3;return _0x27d60e==='\x0d'||_0x27d60e==='\x0a'?_0x58e65f(0x244):_0x27d60e==='\x1b'?_0x58e65f(0x1ee):_0x27d60e===_0x58e65f(0x1b9)?'up':_0x27d60e==='\x1b[B'?'down':_0x27d60e===_0x58e65f(0x241)?_0x58e65f(0x1d3):_0x27d60e===_0x58e65f(0x1e4)?'left':_0x27d60e==='\x7f'||_0x27d60e==='\x08'?_0x58e65f(0x1d0):_0x27d60e==='\x03'?_0x58e65f(0x24c):_0x27d60e;}async function ce(){const _0x12395f=_0x1325f3;if(f(),m(_0x12395f(0x20c)),X()){let _0x28b46d=Z();console['log'](_0x12395f(0x20a)),console[_0x12395f(0x1c9)]('Your\x20identity:\x20'+_0x28b46d[_0x12395f(0x230)](0x0,0x10)+'…\x0a'),console[_0x12395f(0x1c9)](_0x12395f(0x216)),await E();}else{console[_0x12395f(0x1c9)](_0x12395f(0x21e)),console[_0x12395f(0x1c9)](_0x12395f(0x1eb)),await E();let _0x727d54=h(_0x12395f(0x1d8));_0x727d54['start']();let {publicKey:_0x41ed89}=Q();_0x727d54[_0x12395f(0x208)](),console[_0x12395f(0x1c9)](_0x12395f(0x1e7)),console[_0x12395f(0x1c9)]('\x20\x20'+_0x41ed89[_0x12395f(0x230)](0x0,0x10)+'…\x0a'),console[_0x12395f(0x1c9)](_0x12395f(0x216)),await E();}}async function B(_0x1d7020=R){const _0x522c9d=_0x1325f3;f(),m(_0x522c9d(0x1f7));let _0xf1570e='',_0x1bb790=[],_0x13c7b8=0x0,_0x17d8df=()=>{const _0x2ea853=_0x522c9d;f(),m(_0x2ea853(0x1f7)),console[_0x2ea853(0x1c9)](_0x2ea853(0x258)+_0xf1570e+'_\x0a'),_0x1bb790['length']===0x0?console['log']('\x20\x20No\x20results.\x20Type\x20to\x20search\x20or\x20wait\x20for\x20peer\x20gossip.\x0a'):K(_0x1bb790[_0x2ea853(0x263)](_0x47727b=>(_0x47727b[_0x2ea853(0x1a5)]??_0x47727b[_0x2ea853(0x265)])+'\x20\x20'+(_0x47727b['version']??'')+'\x20\x20'+(_0x47727b[_0x2ea853(0x1f8)]??'')),_0x13c7b8),J(_0x2ea853(0x25a));},_0x5ec5bd=h(_0x522c9d(0x1fc));_0x5ec5bd[_0x522c9d(0x205)]();try{_0x1bb790=await _0x1d7020('');}catch{_0x1bb790=[];}return _0x5ec5bd[_0x522c9d(0x208)](),_0x17d8df(),new Promise(_0x4c516d=>{let _0x17543b=H(async({name:_0x4355ee,sequence:_0x451796})=>{const _0x525ad1=_0x3bc5;if(_0x4355ee===_0x525ad1(0x24c)&&(_0x17543b(),process[_0x525ad1(0x22c)](0x0)),_0x4355ee==='up'){_0x13c7b8=Math[_0x525ad1(0x257)](0x0,_0x13c7b8-0x1),_0x17d8df();return;}if(_0x4355ee==='down'){_0x13c7b8=Math[_0x525ad1(0x229)](_0x1bb790[_0x525ad1(0x1c5)]-0x1,_0x13c7b8+0x1),_0x17d8df();return;}if(_0x4355ee===_0x525ad1(0x244)){if(_0x1bb790[_0x525ad1(0x1c5)]===0x0)return;let _0xda48b9=_0x1bb790[_0x13c7b8];_0x17543b(),f(),m('termill\x20—\x20installing'),console[_0x525ad1(0x1c9)](_0x525ad1(0x242)+_0xda48b9[_0x525ad1(0x265)]+'…\x0a');let _0x3a8013=h(_0x525ad1(0x235)+_0xda48b9[_0x525ad1(0x265)]);_0x3a8013[_0x525ad1(0x205)]();try{await _(_0xda48b9[_0x525ad1(0x265)]),_0x3a8013[_0x525ad1(0x208)](),console['log'](_0x525ad1(0x1b6)+_0xda48b9[_0x525ad1(0x265)]+_0x525ad1(0x200));}catch(_0x267639){_0x3a8013['stop'](),console['log'](_0x525ad1(0x248)+_0x267639['message']+_0x525ad1(0x1d1));}await E(),_0x4c516d(B(_0x1d7020));return;}if(_0x4355ee['toLowerCase']()==='l'){_0x17543b(),_0x4c516d('library');return;}if(_0x4355ee===_0x525ad1(0x1d0))_0xf1570e=_0xf1570e[_0x525ad1(0x230)](0x0,-0x1);else{if(_0x451796[_0x525ad1(0x1c5)]===0x1&&_0x451796>='\x20')_0xf1570e+=_0x451796;else return;}_0x13c7b8=0x0;let _0x255281=h(_0x525ad1(0x268));_0x255281[_0x525ad1(0x205)]();try{_0x1bb790=await _0x1d7020(_0xf1570e);}catch{_0x1bb790=[];}_0x255281[_0x525ad1(0x208)](),_0x17d8df();});});}async function C(_0x2951ab=T){f(),m('termill\x20—\x20library');let _0x592073=re(),_0x1fa0ae=0x0,_0x36cec2=()=>{const _0x49493c=_0x3bc5;f(),m(_0x49493c(0x210)),_0x592073[_0x49493c(0x1c5)]===0x0?console[_0x49493c(0x1c9)](_0x49493c(0x209)):(console[_0x49493c(0x1c9)](''),K(_0x592073[_0x49493c(0x263)](_0x153515=>(_0x153515['title']??_0x153515['packageName'])+_0x49493c(0x1a6)+(_0x153515['version']??'?')),_0x1fa0ae)),J(_0x49493c(0x249));};return _0x36cec2(),new Promise(_0x190298=>{let _0x2ed45f=H(async({name:_0x390aec})=>{const _0x5bb879=_0x3bc5;if(_0x390aec==='ctrl+c'&&(_0x2ed45f(),process[_0x5bb879(0x22c)](0x0)),_0x390aec==='up'){_0x1fa0ae=Math[_0x5bb879(0x257)](0x0,_0x1fa0ae-0x1),_0x36cec2();return;}if(_0x390aec===_0x5bb879(0x1ab)){_0x1fa0ae=Math[_0x5bb879(0x229)](_0x592073[_0x5bb879(0x1c5)]-0x1,_0x1fa0ae+0x1),_0x36cec2();return;}if(_0x390aec===_0x5bb879(0x244)&&_0x592073[_0x5bb879(0x1c5)]>0x0){let _0xbbced7=_0x592073[_0x1fa0ae];_0x2ed45f(),f(),m('termill\x20—\x20library');let _0x977497=h(_0x5bb879(0x25f)+_0xbbced7[_0x5bb879(0x265)]+'\x20for\x20updates…');_0x977497['start']();let _0x29740a;try{_0x29740a=await _(_0xbbced7['packageName']);}catch{_0x29740a={'alreadyCurrent':!0x0};}_0x977497[_0x5bb879(0x208)](),_0x29740a[_0x5bb879(0x1d2)]?console[_0x5bb879(0x1c9)](_0x5bb879(0x1b6)+_0xbbced7[_0x5bb879(0x265)]+_0x5bb879(0x1ae)):console[_0x5bb879(0x1c9)]('\x0a'+(_0xbbced7[_0x5bb879(0x1a5)]??_0xbbced7[_0x5bb879(0x265)])+_0x5bb879(0x212)),_0x2951ab(_0xbbced7[_0x5bb879(0x1c8)]),_0x190298(C(_0x2951ab));return;}if(_0x390aec==='d'||_0x390aec==='D'){if(_0x592073[_0x5bb879(0x1c5)]===0x0)return;let _0x1d45b3=_0x592073[_0x1fa0ae];if(_0x2ed45f(),f(),m(_0x5bb879(0x210)),console[_0x5bb879(0x1c9)]('\x0aUninstall\x20'+(_0x1d45b3[_0x5bb879(0x1a5)]??_0x1d45b3[_0x5bb879(0x265)])+_0x5bb879(0x218)),(await G())[_0x5bb879(0x1cf)][_0x5bb879(0x1c4)]()==='y'){let _0x3479d2=h('Uninstalling\x20'+_0x1d45b3[_0x5bb879(0x265)]+'…');_0x3479d2[_0x5bb879(0x205)]();try{await oe(_0x1d45b3['packageName']),_0x3479d2[_0x5bb879(0x208)](),console[_0x5bb879(0x1c9)](_0x5bb879(0x1b6)+_0x1d45b3[_0x5bb879(0x265)]+_0x5bb879(0x1ac));}catch(_0x20afc4){_0x3479d2[_0x5bb879(0x208)](),console[_0x5bb879(0x1c9)](_0x5bb879(0x1fe)+_0x20afc4[_0x5bb879(0x1c1)]+_0x5bb879(0x1d1));}await E();}_0x190298(C(_0x2951ab));return;}if(_0x390aec==='h'||_0x390aec==='H'||_0x390aec===_0x5bb879(0x1ee)){_0x2ed45f(),_0x190298(_0x5bb879(0x22a));return;}});});}async function E(){const _0x154f83=_0x1325f3;let _0x399043;do _0x399043=await G();while(_0x399043['name']!==_0x154f83(0x244));}import{readFileSync as _0x395f8d,existsSync as _0x26e2c2,readdirSync as _0x5f3207,statSync as _0x357e4c}from'node:fs';import{join as _0x4adc9f,resolve as _0x437dea,isAbsolute as _0x500915}from'node:path';import{execSync as _0x5176f5}from'node:child_process';function tt(_0x5a9d04){const _0xd98ed0=_0x1325f3;return _0x5a9d04[_0xd98ed0(0x259)]('.')||_0x5a9d04[_0xd98ed0(0x259)]('/')||_0x500915(_0x5a9d04);}function nt(_0xca37b6){const _0x26dfe1=_0x1325f3;let _0x27e0d5=_0x4adc9f(_0x437dea(_0xca37b6),_0x26dfe1(0x243));if(!_0x26e2c2(_0x27e0d5))return null;try{return JSON[_0x26dfe1(0x207)](_0x395f8d(_0x27e0d5,'utf8'));}catch{return null;}}function rt(_0x10a910){const _0x5d0ca6=_0x1325f3;try{return JSON['parse'](_0x5176f5(_0x5d0ca6(0x277)+_0x10a910+_0x5d0ca6(0x247),{'encoding':_0x5d0ca6(0x1b3)}));}catch{return null;}}function pe(_0x45ce34,_0x5decfa=[]){const _0x82afdd=_0x1325f3;let _0x172b93=[];try{for(let _0x457a2c of _0x5f3207(_0x45ce34)){if(_0x5decfa[_0x82afdd(0x222)](_0x457a2c))continue;let _0xd8a0dd=_0x4adc9f(_0x45ce34,_0x457a2c),_0x3b6862;try{_0x3b6862=_0x357e4c(_0xd8a0dd);}catch{continue;}_0x3b6862[_0x82afdd(0x272)]()?_0x172b93[_0x82afdd(0x1fd)](...pe(_0xd8a0dd,_0x5decfa)):/\.(js|mjs|cjs)$/[_0x82afdd(0x1be)](_0x457a2c)&&_0x172b93['push'](_0xd8a0dd);}}catch{}return _0x172b93;}function ue(_0x538ec9){const _0x451d5e=_0x1325f3;let _0x7e15=tt(_0x538ec9),_0x5aa85a=_0x7e15?nt(_0x538ec9):rt(_0x538ec9),_0x4315e3=[];if(!_0x5aa85a)return _0x4315e3['push']({'check':'package.json\x20readable','passed':!0x1,'message':_0x7e15?_0x451d5e(0x1b1)+_0x538ec9:'Could\x20not\x20fetch\x20package\x20info\x20for\x20\x22'+_0x538ec9+_0x451d5e(0x261)}),_0x4315e3;let _0x14eb50=_0x5aa85a['bin'],_0x5dfca2=typeof _0x14eb50==_0x451d5e(0x25d)?_0x14eb50:_0x14eb50&&typeof _0x14eb50==_0x451d5e(0x1f3)?Object[_0x451d5e(0x20e)](_0x14eb50)[0x0]:null,_0x5deafc=!!_0x5dfca2;_0x4315e3[_0x451d5e(0x1fd)]({'check':'bin\x20field\x20present','passed':_0x5deafc,'message':_0x5deafc?_0x451d5e(0x1f9)+JSON[_0x451d5e(0x264)](_0x14eb50):_0x451d5e(0x23f)});let _0x10df33=!0x1;if(_0x7e15&&_0x5deafc&&(_0x10df33=_0x26e2c2(_0x4adc9f(_0x437dea(_0x538ec9),_0x5dfca2)),_0x4315e3['push']({'check':_0x451d5e(0x1c6),'passed':_0x10df33,'message':_0x10df33?_0x451d5e(0x23d)+_0x5dfca2:_0x451d5e(0x1bf)+_0x5dfca2})),_0x7e15&&_0x5deafc&&_0x10df33){let _0xc8dfc9=_0x4adc9f(_0x437dea(_0x538ec9),_0x5dfca2),_0xfcf707=!0x1;try{_0xfcf707=_0x395f8d(_0xc8dfc9,_0x451d5e(0x1b3))[_0x451d5e(0x259)]('#!/usr/bin/env\x20node');}catch{}_0x4315e3[_0x451d5e(0x1fd)]({'check':_0x451d5e(0x21c),'passed':_0xfcf707,'message':_0xfcf707?_0x451d5e(0x274):_0x5dfca2+_0x451d5e(0x24b)});}let _0x380596=(Array[_0x451d5e(0x1ff)](_0x5aa85a['keywords'])?_0x5aa85a[_0x451d5e(0x1b7)]:[])['includes'](_0x451d5e(0x1e6));_0x4315e3[_0x451d5e(0x1fd)]({'check':_0x451d5e(0x226),'passed':_0x380596,'message':_0x380596?_0x451d5e(0x226):_0x451d5e(0x203)});let _0x4dd5b6=typeof _0x5aa85a[_0x451d5e(0x1f8)]==_0x451d5e(0x25d)&&_0x5aa85a[_0x451d5e(0x1f8)][_0x451d5e(0x1f5)]()[_0x451d5e(0x1c5)]>0x0;_0x4315e3['push']({'check':_0x451d5e(0x223),'passed':_0x4dd5b6,'message':_0x4dd5b6?_0x451d5e(0x1e5)+_0x5aa85a[_0x451d5e(0x1f8)]+'\x22':_0x451d5e(0x24d)});let _0x11dd5a=_0x5aa85a[_0x451d5e(0x1e6)],_0xc3417f=!!_0x11dd5a&&typeof _0x11dd5a==_0x451d5e(0x1f3);if(_0x4315e3['push']({'check':'termill\x20metadata\x20block\x20present','passed':_0xc3417f,'message':_0xc3417f?_0x451d5e(0x1ba):_0x451d5e(0x20d)}),_0xc3417f){let _0x65c200=typeof _0x11dd5a[_0x451d5e(0x1cf)]==_0x451d5e(0x25d)&&_0x11dd5a[_0x451d5e(0x1cf)][_0x451d5e(0x1f5)]()[_0x451d5e(0x1c5)]>0x0,_0x2e37e8=typeof _0x11dd5a[_0x451d5e(0x1f8)]==_0x451d5e(0x25d)&&_0x11dd5a[_0x451d5e(0x1f8)]['trim']()[_0x451d5e(0x1c5)]>0x0;_0x4315e3[_0x451d5e(0x1fd)]({'check':'termill.name\x20is\x20set','passed':_0x65c200,'message':_0x65c200?_0x451d5e(0x255)+_0x11dd5a[_0x451d5e(0x1cf)]+'\x22':_0x451d5e(0x1bb)}),_0x4315e3[_0x451d5e(0x1fd)]({'check':_0x451d5e(0x25c),'passed':_0x2e37e8,'message':_0x2e37e8?_0x451d5e(0x1b8)+_0x11dd5a['description']+'\x22':_0x451d5e(0x1ad)});}if(_0x7e15){let _0x4b991b=!0x1,_0xa8fa15=pe(_0x437dea(_0x538ec9),[_0x451d5e(0x260),'.git','dist']);for(let _0x49969b of _0xa8fa15)try{if(_0x395f8d(_0x49969b,'utf8')[_0x451d5e(0x222)](_0x451d5e(0x1bc))){_0x4b991b=!0x0;break;}}catch{}_0x4315e3[_0x451d5e(0x1fd)]({'check':_0x451d5e(0x231),'passed':_0x4b991b,'message':_0x4b991b?_0x451d5e(0x1e8):_0x451d5e(0x1cb)});}return _0x4315e3;}import{mkdirSync as _0x483241,writeFileSync as _0x425ffb,existsSync as _0x4b75bd}from'node:fs';import{join as _0x45e4a7}from'node:path';import{createInterface as _0x227187}from'node:readline';function P(_0x5f3642,_0x12ecba){return new Promise(_0x4f2ee4=>{const _0x581352=_0x3bc5;_0x5f3642[_0x581352(0x250)](_0x12ecba,_0x95c04f=>_0x4f2ee4(_0x95c04f['trim']()));});}async function me(){const _0x5a7f59=_0x1325f3;let _0x4e6c6e=_0x227187({'input':process[_0x5a7f59(0x270)],'output':process[_0x5a7f59(0x1bd)]});console[_0x5a7f59(0x1c9)](_0x5a7f59(0x1da));let _0x2464d6=await P(_0x4e6c6e,_0x5a7f59(0x1e0)),_0x4dd971=await P(_0x4e6c6e,'Display\x20name\x20(e.g.\x20My\x20Termill\x20Game):\x20'),_0x5b0823=await P(_0x4e6c6e,_0x5a7f59(0x1d6)),_0x64748f=await P(_0x4e6c6e,'Author\x20(e.g.\x20Jane\x20Doe\x20<jane@example.com>):\x20'),_0x12935a=await P(_0x4e6c6e,'Category\x20(e.g.\x20puzzle,\x20action,\x20arcade)\x20[optional,\x20press\x20Enter\x20to\x20skip]:\x20');_0x4e6c6e[_0x5a7f59(0x236)](),_0x2464d6||(console[_0x5a7f59(0x1dd)]('\x0aError:\x20package\x20name\x20is\x20required.'),process['exit'](0x1));let _0x216404=_0x45e4a7(process[_0x5a7f59(0x24a)](),_0x2464d6);_0x4b75bd(_0x216404)&&(console['error'](_0x5a7f59(0x21a)+_0x2464d6+_0x5a7f59(0x245)),process['exit'](0x1)),_0x483241(_0x216404,{'recursive':!0x0});let _0x5586f4={'name':_0x2464d6,'version':_0x5a7f59(0x237),'description':_0x5b0823||'','main':'index.js','bin':{[_0x2464d6]:_0x5a7f59(0x232)},'keywords':['termill'],'author':_0x64748f||'','license':_0x5a7f59(0x204),'termill':{'name':_0x4dd971||_0x2464d6,'description':_0x5b0823||'','launchCommand':_0x2464d6,..._0x12935a?{'category':_0x12935a}:{}}};_0x425ffb(_0x45e4a7(_0x216404,_0x5a7f59(0x243)),JSON[_0x5a7f59(0x264)](_0x5586f4,null,0x2)+'\x0a',_0x5a7f59(0x1b3));let _0x1a3caa=['#!/usr/bin/env\x20node','',_0x5a7f59(0x1fa)+(_0x4dd971||_0x2464d6)+_0x5a7f59(0x240),_0x5a7f59(0x1af),'','console.log(\x27Welcome\x20to\x20'+(_0x4dd971||_0x2464d6)+_0x5a7f59(0x1df),_0x5a7f59(0x1d7),'',_0x5a7f59(0x22f),_0x5a7f59(0x1e9),_0x5a7f59(0x1b2),'\x20\x20process.exit(0);','});',''][_0x5a7f59(0x22e)]('\x0a');_0x425ffb(_0x45e4a7(_0x216404,_0x5a7f59(0x1ef)),_0x1a3caa,_0x5a7f59(0x1b3)),_0x425ffb(_0x45e4a7(_0x216404,_0x5a7f59(0x1db)),_0x5a7f59(0x233),'utf8');let _0x59764b=['#\x20'+(_0x4dd971||_0x2464d6),'',_0x5b0823||'A\x20termill\x20game.','','##\x20Play','',_0x5a7f59(0x26b),_0x5a7f59(0x235)+_0x2464d6,_0x5a7f59(0x1e6),_0x5a7f59(0x273),'','Or\x20run\x20directly:','',_0x5a7f59(0x26b),_0x2464d6,_0x5a7f59(0x273),'',_0x5a7f59(0x214),'','MIT','']['join']('\x0a');_0x425ffb(_0x45e4a7(_0x216404,_0x5a7f59(0x213)),_0x59764b,'utf8'),console[_0x5a7f59(0x1c9)](_0x5a7f59(0x271)+_0x2464d6+'/'),console['log'](_0x5a7f59(0x275)),console[_0x5a7f59(0x1c9)](_0x5a7f59(0x267)+_0x2464d6),console[_0x5a7f59(0x1c9)](_0x5a7f59(0x1b4)),console[_0x5a7f59(0x1c9)](_0x5a7f59(0x22d)),console[_0x5a7f59(0x1c9)]('\x20\x20npm\x20publish\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20publish\x20to\x20npm\x20when\x20ready'),console[_0x5a7f59(0x1c9)]('');}function at(){_0x289ad9(w,{'recursive':!0x0}),_0x289ad9(x,{'recursive':!0x0});}async function ct(){const _0xf0684=_0x1325f3;at(),await ce();let _0x66f4aa=_0xf0684(0x22a);for(;;)_0x66f4aa===_0xf0684(0x22a)?_0x66f4aa=await B(R):_0x66f4aa===_0xf0684(0x21f)?_0x66f4aa=await C(T):_0x66f4aa&&typeof _0x66f4aa['then']==_0xf0684(0x206)?_0x66f4aa=await _0x66f4aa:_0x66f4aa=_0xf0684(0x22a);}var de=process[_0x1325f3(0x1fb)][0x2];if(de===_0x1325f3(0x262)){let e=process[_0x1325f3(0x1fb)][0x3]??'.',t=ue(e),r=!0x0;for(let n of t)n['passed']?console['log']('✓\x20'+n['check']):n[_0x1325f3(0x1aa)]['includes'](_0x1325f3(0x266))?console[_0x1325f3(0x1c9)]('⚠\x20'+n[_0x1325f3(0x1aa)]+':\x20'+n[_0x1325f3(0x1c1)]):(console[_0x1325f3(0x1c9)]('✗\x20'+n['check']+':\x20'+n['message']),r=!0x1);process[_0x1325f3(0x22c)](r?0x0:0x1);}else de===_0x1325f3(0x256)?me()['catch'](_0x4e533d=>{const _0x5ce207=_0x1325f3;console[_0x5ce207(0x1dd)]('Init\x20failed:',_0x4e533d[_0x5ce207(0x1c1)]??_0x4e533d),process[_0x5ce207(0x22c)](0x1);}):ct()['catch'](_0x186bab=>{const _0x16fb79=_0x1325f3;console[_0x16fb79(0x1dd)](_0x16fb79(0x246),_0x186bab[_0x16fb79(0x1c1)]??_0x186bab),process[_0x16fb79(0x22c)](0x1);});
package/package.json ADDED
@@ -0,0 +1,40 @@
1
+ {
2
+ "name": "termill",
3
+ "version": "0.2.0",
4
+ "description": "A decentralized terminal gaming platform to discover, install, and launch Node.js terminal games.",
5
+ "type": "module",
6
+ "bin": {
7
+ "termill": "dist/index.js"
8
+ },
9
+ "files": [
10
+ "dist/",
11
+ "README.md",
12
+ "CHANGELOG.md"
13
+ ],
14
+ "scripts": {
15
+ "start": "node dist/index.js",
16
+ "build": "node build.js",
17
+ "dist:obfuscate": "node build.js --obfuscate",
18
+ "prepublishOnly": "npm run dist:obfuscate",
19
+ "test": "vitest run",
20
+ "test:watch": "vitest",
21
+ "test:coverage": "vitest run --coverage",
22
+ "lint": "eslint src/**/*.js",
23
+ "format": "prettier --write src/**/*.js test/**/*.js"
24
+ },
25
+ "keywords": [
26
+ "terminal",
27
+ "gaming",
28
+ "platform",
29
+ "cli"
30
+ ],
31
+ "license": "MIT",
32
+ "devDependencies": {
33
+ "@vitest/coverage-v8": "^1.0.0",
34
+ "esbuild": "^0.20.0",
35
+ "eslint": "^8.0.0",
36
+ "javascript-obfuscator": "^4.0.0",
37
+ "prettier": "^3.0.0",
38
+ "vitest": "^1.0.0"
39
+ }
40
+ }