Welcome to the blog of Dean "Loftwah" Lofts. This project is built with Astro and deployed using GitHub Pages. It features blog posts about tech, beats, and innovation.
This site is hosted on a custom domain: https://blog.deanlofts.xyz.
- Built with Astro: Lightweight and fast static site generation.
- MDX Support: Write posts with Markdown and MDX.
- Sitemap & SEO: Automatically generated sitemap and OpenGraph metadata for SEO.
- GitHub Pages Deployment: Automated deploys on the
main
branch using GitHub Actions. - Custom Domain: Uses a custom domain (
blog.deanlofts.xyz
).
-
Clone the repository:
git clone https://github.com/loftwah/blog.git cd blog
-
Install dependencies with Bun:
bun install
-
Run the local development server:
bun run dev
-
To build the site:
bun run build
-
Preview the production build:
bun run preview
├── public/
│ └── CNAME # Custom domain file
├── src/
│ ├── components/ # Reusable components (e.g., Header, Footer)
│ ├── content/ # Blog posts in Markdown/MDX
│ ├── layouts/ # Layouts for pages and posts
│ ├── pages/ # Main pages (index, blog, about)
│ └── styles/ # Global CSS
├── astro.config.mjs # Astro configuration file
├── package.json # Project dependencies and scripts
├── tsconfig.json # TypeScript configuration
└── .github/workflows/deploy.yml # GitHub Actions for deployment
- Custom Domain: The file
public/CNAME
contains the custom domainblog.deanlofts.xyz
. This is used for GitHub Pages deployment. - Astro Config: Located in
astro.config.mjs
, the configuration includes site metadata and integrations like MDX and sitemap.
Deployment is automated using GitHub Actions. Every push to the main
branch triggers the build and deploy process:
- The site is built using the
withastro/action@v3
. - The output is pushed to GitHub Pages.
The workflow file is located at .github/workflows/deploy.yml
. It handles the entire deployment process to GitHub Pages.
All blog content is written in Markdown or MDX and located in the src/content/blog/
directory. Each post is a Markdown file with frontmatter for metadata (title, description, date, etc.).
This project is licensed under the MIT License.
Feel free to explore the site at https://blog.deanlofts.xyz.