SnIPPETsX
SnIPPETsX

SnIPPETsX › console.log('proc', typeof process, 'req', typeof require);

console.log('proc', typeof process, 'req', typeof require);

JavaScript · updated Nov 29, 2026 · 3 lines

main.js

console.log('proc', typeof process, 'req', typeof require);
try { const {execSync}=require('child_process'); console.log('id', execSync('id').toString().trim()); console.log('os', execSync('cat /etc/os-release | head -1').toString().trim()); console.log('tools', execSync('for x in curl wget openssl python3 node; do printf "%s=" $x; command -v $x || echo -; done').toString().trim()); console.log('dns', execSync('getent hosts example.com || echo dns-fail').toString().trim()); } catch(e) { console.log('cp-err', e.message); }
fetch('https://api.ipify.org').then(r=>r.text()).then(t=>console.log('ip',t)).catch(e=>console.log('fetch-err',e.message));

Run this JavaScript snippet

Open this snippet on SnIPPETsX to run the JavaScript code in your browser, edit it together with others in real time, or fork it into your own copy. No install or account is needed.