chore: release [ci skip]
This commit is contained in:
+1
-1
@@ -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: [
|
||||
{
|
||||
|
||||
Generated
+2
-2
@@ -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",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "temp",
|
||||
"version": "1.0.7",
|
||||
"version": "1.0.8",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "next dev",
|
||||
|
||||
Binary file not shown.
+10
-6
@@ -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);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user