Skip to content

Commit

Permalink
Merge pull request #6 from hostari/add-ci
Browse files Browse the repository at this point in the history
Add CI and add explicit dependency versioning to all workflows
  • Loading branch information
xaviablaza authored Feb 12, 2024
2 parents a00f98e + 2174b23 commit a3e5bfa
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 6 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Crystal CI
on:
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v4
with:
node-version: 20.x
- uses: crystal-lang/install-crystal@v1
with:
crystal: 1.6.2
- name: Download source
uses: actions/checkout@v4
- name: Install dependencies
run: shards install
- name: Run tests
run: crystal spec
13 changes: 7 additions & 6 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ name: Crystal Docs Generation
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

Expand All @@ -25,11 +23,14 @@ jobs:

runs-on: ubuntu-latest

container:
image: crystallang/crystal

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: 20.x
- uses: crystal-lang/install-crystal@v1
with:
crystal: 1.6.2
- uses: actions/checkout@v4
- name: Generate docs
run: crystal docs
- name: Move docs to _site
Expand Down

0 comments on commit a3e5bfa

Please sign in to comment.