-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
18 changed files
with
623 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
name: ci | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
|
||
jobs: | ||
test: | ||
runs-on: ${{ matrix.os }} | ||
timeout-minutes: 30 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
deno: | ||
- v1.x | ||
- canary | ||
os: | ||
- ubuntu-22.04 | ||
- windows-2022 | ||
- macOS-12 | ||
|
||
steps: | ||
- name: Clone repository | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
|
||
- name: Set up Deno | ||
uses: denoland/setup-deno@v1 | ||
with: | ||
deno-version: ${{ matrix.deno }} | ||
|
||
- name: Run tests canary | ||
run: deno task test | ||
|
||
- name: Generate lcov | ||
run: deno task cov:gen | ||
|
||
- name: Upload coverage | ||
uses: codecov/codecov-action@v3 | ||
env: | ||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | ||
with: | ||
name: ${{ matrix.os }}-${{ matrix.deno }} | ||
files: cov.lcov | ||
|
||
lint: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Clone repository | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: false | ||
persist-credentials: false | ||
|
||
- name: Set up Deno | ||
uses: denoland/setup-deno@v1 | ||
with: | ||
deno-version: canary | ||
|
||
- name: Format | ||
run: deno fmt --check | ||
|
||
- name: Lint | ||
run: deno task lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
docs/ | ||
coverage/ | ||
cov.lcov |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,38 @@ | ||
{ | ||
"compilerOptions": { | ||
"strict": true, | ||
"useUnknownInCatchVariables": true, | ||
"noImplicitOverride": true | ||
}, | ||
"imports": { | ||
"std/": "https://deno.land/[email protected]/" | ||
}, | ||
"tasks": { | ||
"docs": "deno doc --html --name=json-rpc-ts --output=./docs/ ./src/index.ts" | ||
"lint": "deno lint", | ||
"fmt": "deno fmt", | ||
"docs": "deno doc --html --name=json-rpc-ts --output=./docs/ ./mod.ts", | ||
"test": "deno test --parallel --coverage --trace-ops", | ||
"cov:gen": "deno coverage coverage --lcov --output=cov.lcov", | ||
"cov:view": "deno coverage --html coverage", | ||
"cov:clean": "rm -rf ./coverage/ cov.lcov" | ||
}, | ||
"fmt": { | ||
"lineWidth": 80, | ||
"semiColons": false, | ||
"indentWidth": 4, | ||
"singleQuote": true, | ||
"proseWrap": "preserve", | ||
"include": ["*"], | ||
"exclude": [] | ||
} | ||
"include": [ | ||
"src", | ||
".github", | ||
"deno.json", | ||
"README.md", | ||
"mod.ts" | ||
] | ||
}, | ||
"exclude": [ | ||
".git", | ||
"docs", | ||
"coverage" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
export * from "./src/index.ts" | ||
export * from './src/index.ts' |
Oops, something went wrong.