mirror of
https://github.com/andwati/andwati.com.git
synced 2026-11-01 07:12:15 +00:00
- Fresh structure: Next.js App Router + Tailwind v4 at the repo root, exported as static files (output: export) and served by static-web-server - Remove the Strapi CMS, Astro app, Pagefind search, comments, old scripts, Lighthouse config and compose files; content in content/ is now plain markdown with YAML frontmatter - Pages: About, Writing, Reading (3D bookshelf) and Portfolio, styled after adammaj.com - SEO: metadata and canonicals, JSON-LD, generated OG images, sitemap, robots, RSS and JSON feeds, llms.txt - Umami via PUBLIC_UMAMI_SCRIPT_URL / PUBLIC_UMAMI_WEBSITE_ID (build args) - Dockerfile builds the export and serves it with sws.toml (security headers, clean URLs, .well-known, OG image content type, immutable asset caching) - Prettier and cspell for content with a husky/lint-staged pre-commit hook - Old redirect list dropped to start from a clean slate
39 lines
931 B
TypeScript
39 lines
931 B
TypeScript
import { getBooks, getWritings } from "@/lib/content";
|
|
import { abs, site } from "@/lib/site";
|
|
|
|
export const dynamic = "force-static";
|
|
|
|
export function GET() {
|
|
const body = `# ${site.name}
|
|
|
|
> ${site.description}
|
|
|
|
${site.name} (also known as ${site.alias}) is a software engineer and the captain of the binarysith CTF team. This site collects his original essays, CTF writeups, reading list and projects.
|
|
|
|
## Writing
|
|
|
|
${getWritings()
|
|
.map(
|
|
(p) =>
|
|
`- [${p.data.title}](${abs(`/writing/${p.slug}`)})${p.data.description ? `: ${p.data.description}` : ""}`,
|
|
)
|
|
.join("\n")}
|
|
|
|
## Reading
|
|
|
|
${getBooks()
|
|
.map((b) => `- [${b.data.title}](${abs(`/reading/${b.slug}`)})`)
|
|
.join("\n")}
|
|
|
|
## Other
|
|
|
|
- [About](${abs("/")})
|
|
- [Portfolio](${abs("/portfolio")})
|
|
- [RSS](${abs("/rss.xml")})
|
|
- [Sitemap](${abs("/sitemap.xml")})
|
|
`;
|
|
return new Response(body, {
|
|
headers: { "Content-Type": "text/plain; charset=utf-8" },
|
|
});
|
|
}
|