Skip to content

Commit 0adcf40

Browse files
authored
Update CI badge and add GH workflow for documentation (#25)
1 parent 52b7af3 commit 0adcf40

File tree

2 files changed

+42
-1
lines changed

2 files changed

+42
-1
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: "Create API docs"
2+
on:
3+
push:
4+
branches: [master]
5+
workflow_dispatch:
6+
7+
permissions:
8+
contents: read
9+
pages: write
10+
id-token: write
11+
12+
jobs:
13+
build:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
19+
- name: Install Crystal
20+
uses: crystal-lang/install-crystal@v1
21+
22+
- name: Build
23+
run: shards && crystal docs
24+
25+
- name: Upload
26+
uses: actions/upload-pages-artifact@v3
27+
with:
28+
path: ./docs
29+
30+
deploy:
31+
if: github.event_name == 'push' && github.ref_name == github.event.repository.default_branch
32+
needs: build
33+
runs-on: ubuntu-latest
34+
steps:
35+
- name: Deploy to Pages
36+
id: deployment
37+
uses: actions/deploy-pages@v2
38+
39+
environment:
40+
name: github-pages
41+
url: ${{ steps.deployment.outputs.page_url }}

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# html_builder [![Build Status](https://travis-ci.org/crystal-lang/html_builder.svg)](https://travis-ci.org/crystal-lang/html_builder)
1+
# `html_builder` ![Build Status](https://github.com/crystal-lang/html_builder/actions/workflows/weekly.yml/badge.svg)
22

33
DSL for creating HTML programatically (extracted from Crystal's standard library).
44

0 commit comments

Comments
 (0)