UNPKG

super-pancake-automation

Version:

A lightweight DOM-based UI automation framework using Chrome DevTools Protocol

45 lines (37 loc) • 1.44 kB
#!/usr/bin/env node import path from 'path'; import fs from 'fs'; import { fileURLToPath } from 'url'; import { dirname } from 'path'; const __filename = fileURLToPath(import.meta.url); const __dirname = dirname(__filename); const packageRoot = path.join(__dirname, '..'); console.log('šŸ” Super Pancake Installation Check'); console.log('====================================='); console.log(`šŸ“¦ Package root: ${packageRoot}`); console.log(`šŸ“‚ Current working directory: ${process.cwd()}`); console.log(`šŸ–„ļø Platform: ${process.platform}`); console.log(`šŸ“ Script location: ${__dirname}`); const requiredFiles = [ 'public/index.html', 'public/styles.css', 'public/app.js', 'scripts/test-ui.js' ]; console.log('\nšŸ“‹ Checking required files:'); let allFilesExist = true; for (const file of requiredFiles) { const filePath = path.join(packageRoot, file); const exists = fs.existsSync(filePath); const status = exists ? 'āœ…' : 'āŒ'; console.log(`${status} ${file} → ${filePath}`); if (!exists) {allFilesExist = false;} } console.log('\nšŸŽÆ Status:', allFilesExist ? 'āœ… Installation OK' : 'āŒ Missing files'); if (allFilesExist) { console.log('\nšŸš€ You can now run:'); console.log(' npx super-pancake-ui - Full test runner'); console.log(' npx super-pancake-server - Simple UI server'); } else { console.log('\nšŸ”§ Please reinstall the package or check installation'); }