Skip to content

Commit 7b4a0d5

Browse files
committed
chore: Move to lume-blog
1 parent 00d295d commit 7b4a0d5

File tree

14 files changed

+911
-351
lines changed

14 files changed

+911
-351
lines changed

.github/workflows/ci.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,7 @@ jobs:
2525
- name: Run lint
2626
run: |
2727
deno task lint
28+
29+
- name: Run build
30+
run: |
31+
deno task build

.github/workflows/deploy.yaml

+7-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: ci
1+
name: Deploy
22

33
on:
44
push:
@@ -10,7 +10,7 @@ permissions:
1010
contents: read
1111

1212
jobs:
13-
test:
13+
deploy:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: Checkout
@@ -20,9 +20,13 @@ jobs:
2020
uses: denoland/setup-deno@v1
2121
with:
2222
deno-version: v1.x
23+
24+
- name: Build
25+
run: deno task build
2326

2427
- name: Deploy to Deno Deploy
2528
uses: denoland/deployctl@v1
2629
with:
2730
project: pulsate-blog
28-
entrypoint: main.ts
31+
entrypoint: serve.ts
32+
import-map: "./deno.jsonc"

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
_site
2+
_cache
3+
.DS_Store

README

-12
This file was deleted.

README.md

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# Pulsate Blog
2+
3+
[![CI](https://github.com/pulsate-dev/blog/actions/workflows/ci.yaml/badge.svg)](https://github.com/pulsate-dev/blog/actions/workflows/ci.yaml)
4+
[![Deploy](https://github.com/pulsate-dev/blog/actions/workflows/deploy.yaml/badge.svg)](https://github.com/pulsate-dev/blog/actions/workflows/deploy.yaml)
5+
6+
Pulsate の開発情報などを発信するブログ.
7+
[`blog.pulsate.dev`](https://blog.pulsate.dev) で公開されています.
8+
コンテンツの投稿は Pulsate プロジェクトチームのみが行うことができます.
9+
10+
---
11+
12+
1. `src/posts` に新しい Markdown ファイルを作成する.
13+
2. ファイルの先頭に以下のようなメタデータを記述する.
14+
- `title`: 記事のタイトルを指定する.
15+
- `date`: 記事の公開日を指定する.
16+
- `author`: 記事の著者を指定する.
17+
- `tags`: 記事のタグを指定する.
18+
- リリースノートの場合は `release` タグを指定する.
19+
- `comments.src`: 記事のコメントソースを指定する. Pulsate をはじめとする
20+
ActivityPub インスタンスに対応. 必ずしも指定する必要はない.
21+
- `draft`: 下書きの場合は `true` を指定する.
22+
23+
```markdown
24+
---
25+
title: The example post
26+
date: '2023-09-10'
27+
author: Sho Sakuma
28+
tags:
29+
- ActivityPub
30+
comments:
31+
src: 'https://mstdn.mand.io/@m1sk9/0000000'
32+
draft: true
33+
---
34+
```

_config.ts

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import lume from "lume/mod.ts";
2+
import blog from "blog/mod.ts";
3+
4+
const site = lume({
5+
src: "./src",
6+
});
7+
8+
site.use(blog());
9+
10+
export default site;

deno.jsonc

+10-4
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,19 @@
11
{
22
"tasks": {
3-
"dev": "deno run --allow-net --allow-read --allow-env --watch main.ts --dev",
4-
"serve": "deno run --allow-net --allow-read --allow-env --no-check main.ts",
5-
"create": "cp template.md posts/$(date + '%Y-%m-%d')-post-title.md",
3+
"lume": "echo \"import 'lume/cli.ts'\" | deno run -A -",
4+
"build": "deno task lume",
5+
"serve": "deno task lume -s",
66
"fmt": "deno fmt .",
77
"fmt:check": "deno fmt --check .",
88
"lint": "deno lint"
99
},
1010
"imports": {
11-
"deno_blog": "https://deno.land/x/[email protected]/blog.tsx"
11+
"lume/": "https://deno.land/x/[email protected]/",
12+
"blog/": "https://deno.land/x/[email protected]/"
13+
},
14+
"compilerOptions": {
15+
"types": [
16+
"lume/types.ts"
17+
]
1218
}
1319
}

0 commit comments

Comments
 (0)