Skip to content

Commit

Permalink
update workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
jollytoad committed May 14, 2024
1 parent 07f9a7f commit 3aa1056
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 15 deletions.
21 changes: 12 additions & 9 deletions .github/workflows/deno.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
name: Deno
name: ci

on:
push:
branches: ["main"]
branches:
- main
pull_request:
branches: ["main"]
branches:
- main

permissions:
contents: read
Expand All @@ -14,13 +16,11 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Setup repo
uses: actions/checkout@v3
- name: Checkout
uses: actions/checkout@v4

- name: Setup Deno
- name: Install Deno
uses: denoland/setup-deno@v1
with:
deno-version: v1.x

- name: Verify formatting
run: deno fmt --check
Expand All @@ -29,7 +29,10 @@ jobs:
run: deno lint

- name: Run TypeScript checking
run: deno check --import-map=examples/import_map.json **/*.ts
run: deno task check

- name: Run tests
run: deno task test

- name: Publish dry run
run: deno publish --dry-run
11 changes: 6 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Publish

on:
push:
branches:
- jsr
- workspaces
release:
types:
- published

jobs:
publish:
Expand All @@ -14,7 +14,8 @@ jobs:
id-token: write

steps:
- uses: actions/checkout@v4
- name: Checkout
uses: actions/checkout@v4

- name: Install Deno
uses: denoland/setup-deno@v1
Expand Down
3 changes: 2 additions & 1 deletion deno.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
"tasks": {
"example": "deno run -A --import-map=./import_map_local.json --watch",
"test": "deno test -A --import-map=./import_map_local.json --location=http://localhost:8000 --coverage --no-check",
"ok": "deno fmt && deno lint && deno task packages && deno task local-import-map && deno check --import-map=./import_map_local.json **/*.ts && deno task test && deno publish --dry-run --allow-dirty",
"check": "deno check --import-map=./import_map_local.json **/*.ts",
"ok": "deno fmt && deno lint && deno task packages && deno task local-import-map && deno task check && deno task test && deno publish --dry-run --allow-dirty",
"packages": "./_tools/packages.ts",
"local-import-map": "./_tools/local-import-map.ts",
"outdated": "deno run --allow-read=. --allow-net=jsr.io,registry.npmjs.org jsr:@check/deps",
Expand Down

0 comments on commit 3aa1056

Please sign in to comment.