Skip to content

Commit

Permalink
Merge pull request #156 from iuioiua/simplify-update-workflow
Browse files Browse the repository at this point in the history
chore: simplify `update` workflow
  • Loading branch information
iuioiua authored Oct 8, 2023
2 parents 6461901 + 15eb2c9 commit b0d3f46
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 69 deletions.
65 changes: 0 additions & 65 deletions .github/workflows/udd.yml

This file was deleted.

43 changes: 43 additions & 0 deletions .github/workflows/update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Update dependencies

on:
workflow_dispatch:
schedule:
- cron: "0 0 * * *" # Weekly

jobs:
update:
runs-on: ubuntu-latest

services:
redis:
image: redis
ports:
# Maps port 6379 on service container to the host
- 6379:6379

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

- name: Setup Deno
uses: denoland/setup-deno@v1

- name: Create lcov file
run: deno task cov:gen

- name: Upload coverage
uses: codecov/codecov-action@v3
with:
name: ${{ matrix.os }}
files: cov.lcov

- name: Update dependencies
run: deno task update

- name: Create pull request
uses: peter-evans/create-pull-request@v5
with:
title: "chore: update dependencies"
delete-branch: true

3 changes: 2 additions & 1 deletion deno.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"cov:view": "genhtml -o html_cov cov.lcov && open html_cov/index.html",
"ok": "deno fmt --check && deno lint && deno task test",
"ok:dev": "deno fmt --check && deno lint && deno task test:dev",
"update:dev": "deno run -A https://deno.land/x/udd/main.ts --test=\"deno task test:dev\" mod.ts test.ts bench.ts"
"update:dev": "deno run -A https://deno.land/x/udd/main.ts --test=\"deno task ok:dev\" mod.ts test.ts",
"update": "deno run -A https://deno.land/x/udd/main.ts --test=\"deno task ok\" mod.ts test.ts"
},
"exclude": [
"/cov"
Expand Down
6 changes: 3 additions & 3 deletions test.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import {
assertEquals,
assertRejects,
} from "https://deno.land/std@0.200.0/assert/mod.ts";
import { StringReader } from "https://deno.land/std@0.200.0/io/string_reader.ts";
import { readDelim } from "https://deno.land/std@0.200.0/io/read_delim.ts";
} from "https://deno.land/std@0.203.0/assert/mod.ts";
import { StringReader } from "https://deno.land/std@0.203.0/io/string_reader.ts";
import { readDelim } from "https://deno.land/std@0.203.0/io/read_delim.ts";
import { type Command, readReply, RedisClient, type Reply } from "./mod.ts";

const encoder = new TextEncoder();
Expand Down

0 comments on commit b0d3f46

Please sign in to comment.