mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2025-12-17 09:46:05 +00:00
Update web
This commit is contained in:
parent
9e3334d75f
commit
a8dcf5e8f5
@ -7,34 +7,52 @@ import type React from "react"
|
|||||||
const inter = Inter({ subsets: ["latin"] })
|
const inter = Inter({ subsets: ["latin"] })
|
||||||
|
|
||||||
export const metadata = {
|
export const metadata = {
|
||||||
title: "ProxMenux",
|
title: "ProxMenux - Menu-Driven Script for Proxmox VE Management",
|
||||||
generator: "Next.js",
|
generator: "Next.js",
|
||||||
applicationName: "ProxMenux",
|
applicationName: "ProxMenux",
|
||||||
referrer: "origin-when-cross-origin",
|
referrer: "origin-when-cross-origin",
|
||||||
keywords: ["Proxmox VE", "VE", "ProxMenux", "MacRimi", "menu-driven", "menu", "scripts", "virtualization"],
|
keywords: [
|
||||||
authors: [{ name: "MacRimi" }],
|
"Proxmox VE",
|
||||||
|
"Proxmox",
|
||||||
|
"PVE",
|
||||||
|
"ProxMenux",
|
||||||
|
"MacRimi",
|
||||||
|
"menu-driven",
|
||||||
|
"menu script",
|
||||||
|
"scripts",
|
||||||
|
"virtualization",
|
||||||
|
"automation",
|
||||||
|
"server management",
|
||||||
|
"VM management",
|
||||||
|
"container management",
|
||||||
|
"LXC",
|
||||||
|
],
|
||||||
|
authors: [{ name: "MacRimi", url: "https://github.com/MacRimi" }],
|
||||||
creator: "MacRimi",
|
creator: "MacRimi",
|
||||||
publisher: "MacRimi",
|
publisher: "MacRimi",
|
||||||
description:
|
description:
|
||||||
"A menu-driven script for Proxmox VE management, designed to simplify and streamline the execution of commands and tasks.",
|
"ProxMenux is a powerful menu-driven script for Proxmox VE management, designed to simplify and streamline the execution of commands and tasks. Manage VMs, containers, networking, storage, and more with an intuitive interface.",
|
||||||
formatDetection: {
|
formatDetection: {
|
||||||
email: false,
|
email: false,
|
||||||
address: false,
|
address: false,
|
||||||
telephone: false,
|
telephone: false,
|
||||||
},
|
},
|
||||||
metadataBase: new URL(`https://macrimi.github.io/ProxMenux/`),
|
metadataBase: new URL("https://proxmenux.com"),
|
||||||
|
alternates: {
|
||||||
|
canonical: "https://proxmenux.com",
|
||||||
|
},
|
||||||
openGraph: {
|
openGraph: {
|
||||||
title: "ProxMenux",
|
title: "ProxMenux - Menu-Driven Script for Proxmox VE Management",
|
||||||
description:
|
description:
|
||||||
"A menu-driven script for Proxmox VE management, designed to simplify and streamline the execution of commands and tasks.",
|
"ProxMenux is a powerful menu-driven script for Proxmox VE management, designed to simplify and streamline the execution of commands and tasks. Manage VMs, containers, networking, storage, and more.",
|
||||||
url: "https://macrimi.github.io/ProxMenux/",
|
url: "https://proxmenux.com",
|
||||||
siteName: "ProxMenux",
|
siteName: "ProxMenux",
|
||||||
images: [
|
images: [
|
||||||
{
|
{
|
||||||
url: "https://macrimi.github.io/ProxMenux/main.png",
|
url: "https://proxmenux.com/main.png",
|
||||||
width: 1363,
|
width: 1363,
|
||||||
height: 735,
|
height: 735,
|
||||||
alt: "ProxMenux",
|
alt: "ProxMenux - Proxmox VE Management Interface",
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
locale: "en_US",
|
locale: "en_US",
|
||||||
@ -42,17 +60,29 @@ export const metadata = {
|
|||||||
},
|
},
|
||||||
twitter: {
|
twitter: {
|
||||||
card: "summary_large_image",
|
card: "summary_large_image",
|
||||||
title: "ProxMenux",
|
title: "ProxMenux - Menu-Driven Script for Proxmox VE",
|
||||||
description:
|
description:
|
||||||
"A menu-driven script for Proxmox VE management, designed to simplify and streamline the execution of commands and tasks.",
|
"Powerful menu-driven script for Proxmox VE management. Simplify VM, container, networking, and storage management with an intuitive interface.",
|
||||||
images: ["https://macrimi.github.io/ProxMenux/main.png"],
|
images: ["https://proxmenux.com/main.png"],
|
||||||
|
creator: "@MacRimi",
|
||||||
|
},
|
||||||
|
robots: {
|
||||||
|
index: true,
|
||||||
|
follow: true,
|
||||||
|
googleBot: {
|
||||||
|
index: true,
|
||||||
|
follow: true,
|
||||||
|
"max-video-preview": -1,
|
||||||
|
"max-image-preview": "large",
|
||||||
|
"max-snippet": -1,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
icons: {
|
icons: {
|
||||||
icon: [
|
icon: [
|
||||||
{ url: "https://macrimi.github.io/ProxMenux/favicon.ico", sizes: "any" },
|
{ url: "/favicon.ico", sizes: "any" },
|
||||||
{ url: "https://macrimi.github.io/ProxMenux/icon.svg", type: "image/svg+xml" },
|
{ url: "/icon.svg", type: "image/svg+xml" },
|
||||||
],
|
],
|
||||||
apple: [{ url: "https://macrimi.github.io/ProxMenux/apple-touch-icon.png", sizes: "180x180" } as const],
|
apple: [{ url: "/apple-touch-icon.png", sizes: "180x180" }],
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -60,24 +90,32 @@ export default function RootLayout({ children }: { children: React.ReactNode })
|
|||||||
return (
|
return (
|
||||||
<html lang="en" className="dark">
|
<html lang="en" className="dark">
|
||||||
<head>
|
<head>
|
||||||
<meta name="description" content={metadata.description} />
|
<script
|
||||||
<meta property="og:title" content={metadata.openGraph?.title} />
|
type="application/ld+json"
|
||||||
<meta property="og:description" content={metadata.openGraph?.description} />
|
dangerouslySetInnerHTML={{
|
||||||
<meta property="og:image" content={metadata.openGraph?.images?.[0]?.url} />
|
__html: JSON.stringify({
|
||||||
<meta property="og:url" content={metadata.openGraph?.url} />
|
"@context": "https://schema.org",
|
||||||
<meta name="twitter:card" content="summary_large_image" />
|
"@type": "SoftwareApplication",
|
||||||
<meta name="twitter:title" content={metadata.twitter?.title} />
|
name: "ProxMenux",
|
||||||
<meta name="twitter:description" content={metadata.twitter?.description} />
|
description:
|
||||||
<meta name="twitter:image" content={metadata.twitter?.images?.[0]} />
|
"A powerful menu-driven script for Proxmox VE management, designed to simplify and streamline the execution of commands and tasks.",
|
||||||
<link rel="canonical" href={metadata.metadataBase.href} />
|
applicationCategory: "DeveloperApplication",
|
||||||
|
operatingSystem: "Linux",
|
||||||
{/* Favicon y Apple Icons */}
|
offers: {
|
||||||
{metadata.icons.icon.map((icon, index) => (
|
"@type": "Offer",
|
||||||
<link key={index} rel="icon" type={icon.type} sizes={icon.sizes} href={icon.url} />
|
price: "0",
|
||||||
))}
|
priceCurrency: "USD",
|
||||||
{metadata.icons.apple.map((icon, index) => (
|
},
|
||||||
<link key={index} rel="apple-touch-icon" sizes={icon.sizes} href={icon.url} />
|
author: {
|
||||||
))}
|
"@type": "Person",
|
||||||
|
name: "MacRimi",
|
||||||
|
url: "https://github.com/MacRimi",
|
||||||
|
},
|
||||||
|
url: "https://proxmenux.com",
|
||||||
|
image: "https://proxmenux.com/main.png",
|
||||||
|
}),
|
||||||
|
}}
|
||||||
|
/>
|
||||||
</head>
|
</head>
|
||||||
<body className={`${inter.className} bg-background text-foreground antialiased`}>
|
<body className={`${inter.className} bg-background text-foreground antialiased`}>
|
||||||
<Navbar />
|
<Navbar />
|
||||||
|
|||||||
@ -10,25 +10,24 @@ interface ChangelogEntry {
|
|||||||
title: string
|
title: string
|
||||||
}
|
}
|
||||||
|
|
||||||
// Function to clean and format markdown content for RSS
|
|
||||||
function formatContentForRSS(content: string): string {
|
function formatContentForRSS(content: string): string {
|
||||||
return (
|
return (
|
||||||
content
|
content
|
||||||
// Convert ### headers to bold text
|
// Convert ### headers to <h3> tags
|
||||||
.replace(/^### (.+)$/gm, "**$1**")
|
.replace(/^### (.+)$/gm, "<h3>$1</h3>")
|
||||||
// Convert ** bold ** to simple bold
|
// Convert ** bold ** to <strong> tags
|
||||||
.replace(/\*\*(.*?)\*\*/g, "$1")
|
.replace(/\*\*(.*?)\*\*/g, "<strong>$1</strong>")
|
||||||
// Clean code blocks - remove ``` and format nicely
|
// Convert code blocks to <pre><code> tags
|
||||||
.replace(/```[\s\S]*?```/g, (match) => {
|
.replace(/```[\s\S]*?```/g, (match) => {
|
||||||
const code = match.replace(/```/g, "").trim()
|
const code = match.replace(/```/g, "").trim()
|
||||||
return `\n${code}\n`
|
return `<pre><code>${code}</code></pre>`
|
||||||
})
|
})
|
||||||
// Convert - bullet points to •
|
// Convert - bullet points to <ul><li> tags
|
||||||
.replace(/^- /gm, "• ")
|
.replace(/^- (.+)$/gm, "<li>$1</li>")
|
||||||
// Clean up multiple newlines
|
// Wrap consecutive <li> tags in <ul>
|
||||||
.replace(/\n{3,}/g, "\n\n")
|
.replace(/(<li>.*?<\/li>\s*)+/g, (match) => `<ul>${match}</ul>`)
|
||||||
// Remove backslashes used for line breaks
|
// Convert double newlines to <br><br> for paragraphs
|
||||||
.replace(/\\\s*$/gm, "")
|
.replace(/\n\n/g, "<br><br>")
|
||||||
// Clean up extra spaces
|
// Clean up extra spaces
|
||||||
.replace(/\s+/g, " ")
|
.replace(/\s+/g, " ")
|
||||||
.trim()
|
.trim()
|
||||||
@ -75,7 +74,7 @@ async function parseChangelog(): Promise<ChangelogEntry[]> {
|
|||||||
currentEntry = {
|
currentEntry = {
|
||||||
version,
|
version,
|
||||||
date,
|
date,
|
||||||
url: `https://macrimi.github.io/ProxMenux/changelog#${version}`,
|
url: `https://proxmenux.com/changelog#${version}`,
|
||||||
title: `ProxMenux ${version}`,
|
title: `ProxMenux ${version}`,
|
||||||
}
|
}
|
||||||
} else if (dateMatch) {
|
} else if (dateMatch) {
|
||||||
@ -83,7 +82,7 @@ async function parseChangelog(): Promise<ChangelogEntry[]> {
|
|||||||
currentEntry = {
|
currentEntry = {
|
||||||
version: date,
|
version: date,
|
||||||
date,
|
date,
|
||||||
url: `https://macrimi.github.io/ProxMenux/changelog#${date}`,
|
url: `https://proxmenux.com/changelog#${date}`,
|
||||||
title: `ProxMenux Update ${date}`,
|
title: `ProxMenux Update ${date}`,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -115,13 +114,13 @@ async function parseChangelog(): Promise<ChangelogEntry[]> {
|
|||||||
|
|
||||||
export async function GET() {
|
export async function GET() {
|
||||||
const entries = await parseChangelog()
|
const entries = await parseChangelog()
|
||||||
const siteUrl = "https://macrimi.github.io/ProxMenux"
|
const siteUrl = "https://proxmenux.com"
|
||||||
|
|
||||||
const rssXml = `<?xml version="1.0" encoding="UTF-8"?>
|
const rssXml = `<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
|
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
|
||||||
<channel>
|
<channel>
|
||||||
<title>ProxMenux Changelog</title>
|
<title>ProxMenux Changelog</title>
|
||||||
<description>Latest updates and changes in ProxMenux</description>
|
<description>Latest updates and changes in ProxMenux - An Interactive Menu for Proxmox VE Management</description>
|
||||||
<link>${siteUrl}/changelog</link>
|
<link>${siteUrl}/changelog</link>
|
||||||
<atom:link href="${siteUrl}/rss.xml" rel="self" type="application/rss+xml"/>
|
<atom:link href="${siteUrl}/rss.xml" rel="self" type="application/rss+xml"/>
|
||||||
<language>en-US</language>
|
<language>en-US</language>
|
||||||
@ -134,7 +133,7 @@ export async function GET() {
|
|||||||
(entry) => `
|
(entry) => `
|
||||||
<item>
|
<item>
|
||||||
<title>${entry.title}</title>
|
<title>${entry.title}</title>
|
||||||
<description><![CDATA[${entry.content.length > 1000 ? entry.content.substring(0, 1000) + "..." : entry.content}]]></description>
|
<description><![CDATA[${entry.content}]]></description>
|
||||||
<link>${entry.url}</link>
|
<link>${entry.url}</link>
|
||||||
<guid isPermaLink="true">${entry.url}</guid>
|
<guid isPermaLink="true">${entry.url}</guid>
|
||||||
<pubDate>${new Date(entry.date).toUTCString()}</pubDate>
|
<pubDate>${new Date(entry.date).toUTCString()}</pubDate>
|
||||||
@ -151,4 +150,4 @@ export async function GET() {
|
|||||||
"Cache-Control": "public, max-age=3600, s-maxage=3600",
|
"Cache-Control": "public, max-age=3600, s-maxage=3600",
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user