Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
lhr0909 committed Jan 4, 2025
1 parent 6e18458 commit 1a85ac5
Show file tree
Hide file tree
Showing 34 changed files with 239 additions and 652 deletions.
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# My Minimal Astro Blog
# Astro Etch

This is a minimal blog system that I use to write. It is based on [Astro](https://astro.build). Styling is done with [Tailwind CSS](https://tailwindcss.com). The theme was based off of a hugo theme named [etch](https://github.com/LukasJoswiak/etch).

The main motivation is to set up a template that can pull my Obsidian vault notes at build time for the blog posts. This way, I can write my notes in Obsidian and have them published to my blog.
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "simon-liang",
"name": "astro-commit",
"type": "module",
"version": "0.0.1",
"scripts": {
Expand All @@ -18,7 +18,6 @@
"@types/react": "^19.0.2",
"@types/react-dom": "^19.0.2",
"astro": "^5.1.1",
"astro-disqus": "^1.0.1",
"astro-seo": "^0.8.4",
"react": "^19.0.0",
"react-dom": "^19.0.0",
Expand Down
8 changes: 0 additions & 8 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file removed public/InterVariable.woff
Binary file not shown.
Binary file added public/astro.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed public/clappy-bird.mp4
Binary file not shown.
Binary file removed public/remotion-demo.mp4
Binary file not shown.
53 changes: 6 additions & 47 deletions src/components/Footer.astro
Original file line number Diff line number Diff line change
@@ -1,57 +1,16 @@
---
import { SITE_TITLE } from "@/consts";
---

<footer class="text-gray-500 font-extralight pb-8 flex flex-col justify-center md:flex-row md:justify-between space-y-2 md:space-y-0">
<span>Copyright (c) {new Date().getFullYear()} Simon Liang</span>
<span>Copyright (c) {new Date().getFullYear()} {SITE_TITLE}</span>
<span class="flex space-x-2">
<a href="https://github.com/lhr0909"
<a href="https://github.com/lhr0909/astro-etch"
class="hover:text-blue-500"
target="_blank"
rel="noopener"
>
GitHub
<!-- <GithubIcon class="h-6 w-6" /> -->
</a>
<a
href="https://x.com/lhr0909"
class="hover:text-blue-500"
target="_blank"
rel="noopener"
>
Twitter
<!-- <TwitterIcon class="h-6 w-6" /> -->
</a>
<a
href="https://www.linkedin.com/in/simon-liang"
class="hover:text-blue-500"
target="_blank"
rel="noopener"
>
LinkedIn
<!-- <LinkedInIcon class="h-6 w-6" /> -->
</a>
<a
href="https://www.youtube.com/@simon_liang"
class="hover:text-blue-500"
target="_blank"
rel="noopener"
>
YouTube
<!-- <YoutubeIcon class="h-6 w-6" /> -->
</a>
<a
href="https://space.bilibili.com/41930008/"
class="hover:text-blue-500"
target="_blank"
rel="noopener"
>
Bilibili
<!-- <BilibiliIcon class="h-6 w-6" /> -->
</a>
<a
href="https://www.xiaohongshu.com/user/profile/5b0836e96b58b740556e8701"
class="hover:text-blue-500"
target="_blank"
rel="noopener"
>
XHS
</a>
</span>
</footer>
12 changes: 6 additions & 6 deletions src/components/OgTemplates.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import fs from "node:fs";

const image = fs.readFileSync("./src/content/images/simonliang.jpg");
const imageDataUrl = `data:image/jpeg;base64,${image.toString("base64")}`;
import { SITE_TITLE } from "@/consts";
const image = fs.readFileSync("./public/astro.png");
const imageDataUrl = `data:image/png;base64,${image.toString("base64")}`;

export function HomeOgTemplate() {
return (
Expand All @@ -26,11 +27,11 @@ export function HomeOgTemplate() {
>
<img
style={{ borderRadius: "12px" }}
src="https://www.divby0.io/simonliang.jpg"
src={imageDataUrl}
width="192"
height="192"
/>
<div>Simon Liang</div>
<div>{SITE_TITLE}</div>
</div>
);
}
Expand Down Expand Up @@ -69,11 +70,10 @@ export function PostOgTemplate({ title }: { title: string }) {
<img
style={{ borderRadius: "12px" }}
src={imageDataUrl}
// src="https://www.divby0.io/simonliang.jpg"
width="128"
height="128"
/>
<div>Simon Liang</div>
<div>{SITE_TITLE}</div>
</div>
<div
style={{
Expand Down
4 changes: 2 additions & 2 deletions src/consts.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Place any global data in this file.
// You can import this data from anywhere in your site by using the `import` keyword.

export const SITE_TITLE = 'Simon Liang';
export const SITE_DESCRIPTION = 'Simon Liang\'s Blog';
export const SITE_TITLE = 'Astro Etch';
export const SITE_DESCRIPTION = 'Astro Etch is a blog style template written in Astro. It is optimized for simplicity.';
2 changes: 0 additions & 2 deletions src/content.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ const blog = defineCollection({
// TODO: add modified date
// modDate: z.coerce.date().optional(),
tags: z.array(z.string()).optional(),
// for disqus comments
oldUrl: z.string().optional(),
}),
});

Expand Down
32 changes: 0 additions & 32 deletions src/content/blog/clappy-bird.md

This file was deleted.

Loading

0 comments on commit 1a85ac5

Please sign in to comment.