Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: [INTER-166] use shared workflows #141

Merged
merged 22 commits into from
Oct 30, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 0 additions & 42 deletions .github/workflows/build.yml

This file was deleted.

12 changes: 12 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: ci
on:
push:
branches-ignore:
- main
paths-ignore:
- '**.md'
TheUnderScorer marked this conversation as resolved.
Show resolved Hide resolved

jobs:
build-and-check:
name: Build project and run CI checks
uses: fingerprintjs/dx-team-toolkit/.github/workflows/build-typescript-project.yml@v1
31 changes: 1 addition & 30 deletions .github/workflows/coverage-diff.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,37 +5,8 @@ on:

jobs:
run-tests-check-coverage:
runs-on: ubuntu-20.04
name: Run tests & check coverage
permissions:
checks: write
pull-requests: write
steps:
- uses: actions/checkout@v3

- name: Install node
uses: actions/setup-node@v3
with:
node-version-file: '.node-version'

- name: Jest coverage comment
id: coverage
uses: ArtiomTr/jest-coverage-report-action@df2b025553c31d68f84be6337843e277e2576844
with:
package-manager: yarn
output: report-markdown
- run: yarn test
- name: Read coverage text report
uses: fingerprintjs/action-coverage-report-md@v1
id: coverage-md
with:
srcBasePath: './src'
- uses: marocchino/sticky-pull-request-comment@adca94abcaf73c10466a71cc83ae561fd66d1a56
with:
message: |
${{ steps.coverage.outputs.report }}
<details>
<summary>Show full coverage report</summary>

${{ steps.coverage-md.outputs.markdownReport }}
</details>
uses: fingerprintjs/dx-team-toolkit/.github/workflows/coverage-diff.yml@v1
15 changes: 15 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Generate docs and coverage report

on:
push:
branches:
- main

jobs:
generate-docs-and-coverage:
name: Generate docs and coverage report
uses: fingerprintjs/dx-team-toolkit/.github/workflows/docs-and-coverage.yml@v1
with:
skip-docs-step: true
prepare-gh-pages-commands: |
mv coverage/lcov-report ./gh-pages/coverage
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,4 @@ See [CloudFront Proxy Integration guide](https://dev.fingerprint.com/docs/cloudf
## License

This project is licensed under the MIT license. See the [LICENSE](https://github.com/fingerprintjs/fingerprint-pro-cloudfront-integration/blob/main/LICENSE) file for more info.

5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
"build": "rimraf dist && rollup -c rollup.config.js",
"lint": "eslint --ext .js,.ts --ignore-path .gitignore --max-warnings 0 src/",
"lint:fix": "yarn lint --fix",
"test": "jest --coverage",
"test": "jest",
"test:coverage": "jest --coverage",
"test:dts": "tsc --noEmit --isolatedModules dist/fingerprintjs-pro-cloudfront-lambda-function.d.ts"
},
"main": "dist/fingerprintjs-pro-cloudflare-lambda-function.js",
Expand All @@ -17,7 +18,7 @@
"dist"
],
"engines": {
"node": "~16"
"node": ">=16"
TheUnderScorer marked this conversation as resolved.
Show resolved Hide resolved
},
"dependencies": {
"aws-sdk": "^2.1234.0",
Expand Down