UNPKG

progresspulse-pwa

Version:

A modern PWA for tracking progress and achieving goals with iPhone-style design

67 lines (58 loc) • 2.43 kB
#!/usr/bin/env node import { writeFileSync } from 'fs'; import { join, dirname } from 'path'; import { fileURLToPath } from 'url'; const __filename = fileURLToPath(import.meta.url); const __dirname = dirname(__filename); const projectRoot = join(__dirname, '..'); console.log('šŸŽ¬ ProgressPulse Update Demo'); console.log('============================\n'); // Create a demo update with realistic changes const demoUpdate = { version: "1.0.2", timestamp: new Date().toISOString(), changes: [ "šŸŽØ New iPhone 15 Pro-style animations and haptic feedback", "šŸ“Š Enhanced progress tracking with AI insights", "šŸ”” Smart notification system with personalized reminders", "⚔ 40% faster app performance and reduced memory usage", "šŸ”’ Advanced biometric security with Face ID support", "šŸŒ™ Improved dark mode with OLED optimization", "šŸ“± Better iPad and large screen support" ], downloadUrl: "https://progresspulse.app/updates/1.0.2", size: 3247892, // ~3.2MB critical: false, rollout: { percentage: 100, regions: ["all"] } }; // Save the demo update writeFileSync( join(projectRoot, 'public', 'update-manifest.json'), JSON.stringify(demoUpdate, null, 2) ); console.log('āœ… Demo update created successfully!'); console.log(`šŸ“¦ Version: ${demoUpdate.version}`); console.log(`šŸ“ Size: ${(demoUpdate.size / 1024 / 1024).toFixed(1)} MB`); console.log(`šŸ”„ Changes: ${demoUpdate.changes.length} improvements`); console.log('\nšŸš€ To test the update system:'); console.log('1. npm run dev'); console.log('2. Open http://localhost:5173'); console.log('3. Go to Settings → Updates'); console.log('4. Click "Check for Updates"'); console.log('5. Watch the iPhone-style update flow!'); console.log('\nšŸ“± The update will show:'); console.log('• Real-time download progress'); console.log('• Network speed and time remaining'); console.log('• iPhone-style animations'); console.log('• Success notification when complete'); console.log('\nšŸŽÆ Demo Features:'); console.log('• āœ… Update detection'); console.log('• āœ… Real-time progress bar'); console.log('• āœ… Download speed tracking'); console.log('• āœ… iPhone-style UI'); console.log('• āœ… Push notifications (when enabled)'); console.log('• āœ… Update history tracking'); console.log('• āœ… Auto-update preferences');