mirror of
https://github.com/AeThex-Corporation/AeThex-OS.git
synced 2026-04-17 22:27:19 +00:00
- ModuleManager: Central tracking for installed marketplace modules - DataAnalyzerWidget: Real-time CPU/RAM/Battery/Storage widget (unlocked by Data Analyzer module) - BottomNavBar: Navigation bar for Projects/Chat/Marketplace/Settings - RootShell: Real root command execution utility - TerminalActivity: Full root shell with neofetch, sysinfo, real Linux commands - Terminal Pro module: Adds aliases (ll, la, h), command history - ArcadeActivity + SnakeGame: Pixel Arcade module unlocks retro games - fade_in/fade_out animations for smooth transitions
43 lines
1 KiB
JavaScript
43 lines
1 KiB
JavaScript
#!/usr/bin/env node
|
|
import fs from "fs";
|
|
import path from "path";
|
|
import { fileURLToPath } from "url";
|
|
|
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
|
|
function copyDir(src, dest) {
|
|
if (!fs.existsSync(src)) {
|
|
console.warn(`Source directory not found: ${src}`);
|
|
return;
|
|
}
|
|
|
|
if (fs.existsSync(dest)) {
|
|
fs.rmSync(dest, { recursive: true, force: true });
|
|
}
|
|
|
|
fs.mkdirSync(dest, { recursive: true });
|
|
|
|
const entries = fs.readdirSync(src, { withFileTypes: true });
|
|
|
|
for (const entry of entries) {
|
|
const srcPath = path.join(src, entry.name);
|
|
const destPath = path.join(dest, entry.name);
|
|
|
|
if (entry.isDirectory()) {
|
|
copyDir(srcPath, destPath);
|
|
} else {
|
|
fs.copyFileSync(srcPath, destPath);
|
|
}
|
|
}
|
|
|
|
console.log(`✓ Copied ${src} to ${dest}`);
|
|
}
|
|
|
|
// When this file is at code/copy-api.js:
|
|
// __dirname = code/
|
|
// srcApi = code/api
|
|
// destApi = .../api (at root)
|
|
const srcApi = path.resolve(__dirname, "api");
|
|
const destApi = path.resolve(__dirname, "..", "api");
|
|
|
|
copyDir(srcApi, destApi);
|