diff --git a/next.config.ts b/next.config.ts index 83e90cf..798d55e 100644 --- a/next.config.ts +++ b/next.config.ts @@ -10,7 +10,7 @@ import type { NextConfig } from "next"; * Docs: https://nextjs.org/docs/app/api-reference/next-config-js */ const nextConfig: NextConfig = { - output: 'standalone', + output: "standalone", images: { remotePatterns: [ { diff --git a/package-lock.json b/package-lock.json index 79df6b8..45bf20e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "temp", - "version": "1.0.7", + "version": "1.0.8", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "temp", - "version": "1.0.7", + "version": "1.0.8", "dependencies": { "next": "16.1.7", "php": "^1.1.0", diff --git a/package.json b/package.json index 35124f1..8a61610 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "temp", - "version": "1.0.7", + "version": "1.0.8", "private": true, "scripts": { "dev": "next dev", diff --git a/release-v1.0.8.zip b/release-v1.0.8.zip new file mode 100644 index 0000000..3afcb52 Binary files /dev/null and b/release-v1.0.8.zip differ diff --git a/scripts/release.ts b/scripts/release.ts index 2e10ce1..1033a62 100644 --- a/scripts/release.ts +++ b/scripts/release.ts @@ -9,11 +9,15 @@ if (!version) { const zipPath = `release-v${version}.zip`; // Thêm version vào tên file cho dễ quản lý -console.log(`📦 Đang chuẩn bị đóng gói App Router Standalone cho version: ${version}...`); +console.log( + `📦 Đang chuẩn bị đóng gói App Router Standalone cho version: ${version}...`, +); // Kiểm tra xem đã build chưa if (!fs.existsSync(".next/standalone")) { - console.error("❌ Thư mục .next/standalone không tồn tại. Hãy chạy 'pnpm build' trước!"); + console.error( + "❌ Thư mục .next/standalone không tồn tại. Hãy chạy 'pnpm build' trước!", + ); process.exit(1); } @@ -27,10 +31,10 @@ if (!fs.existsSync(".next/standalone")) { try { // Tạo thư mục tạm để cấu trúc lại file trước khi nén execSync("rm -rf temp_release && mkdir -p temp_release"); - + console.log("🚚 Đang sao chép các file standalone..."); execSync("cp -r .next/standalone/. temp_release/"); - + console.log("🚚 Đang sao chép static và public..."); execSync("mkdir -p temp_release/.next/static"); execSync("cp -r .next/static/. temp_release/.next/static/"); @@ -44,9 +48,9 @@ try { execSync("rm -rf temp_release"); console.log(`✅ Đã tạo file thành công: ${zipPath}`); - + execSync("pnpm format"); } catch (error) { console.error("❌ Có lỗi xảy ra trong quá trình nén:", error.message); process.exit(1); -} \ No newline at end of file +}