Skip to content

Commit

Permalink
feat: implement first release
Browse files Browse the repository at this point in the history
  • Loading branch information
enzoferey authored Jul 24, 2022
1 parent 1d1e695 commit 057eab4
Show file tree
Hide file tree
Showing 39 changed files with 3,677 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"prettier"
],
"parser": "@typescript-eslint/parser",
"plugins": ["@typescript-eslint"],
"root": true,
"env": {
"node": true
}
}
44 changes: 44 additions & 0 deletions .github/workflows/codecov.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Codecov
on:
push:
branches:
- main

jobs:
run-tests:
name: Run tests
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x]

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
registry-url: https://registry.npmjs.org

- name: Restore yarn cache if available
uses: actions/cache@v2
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: |
node_modules
*/*/node_modules
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}

- name: Install dependencies
run: |
yarn install --frozen-lockfile
- name: Generate coverage reports
run: |
yarn test:ci
env:
CI: true

- name: Upload coverage
uses: codecov/codecov-action@v3
66 changes: 66 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Test
on:
pull_request:
types: [opened, reopened, synchronize]

jobs:
run-tests:
name: Run tests
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x]

steps:
- name: Cancel previous runs
uses: styfle/cancel-workflow-action@0.5.0
with:
access_token: ${{ github.token }}

- name: Checkout repository
uses: actions/checkout@v2

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
registry-url: https://registry.npmjs.org

- name: Restore yarn cache if available
uses: actions/cache@v2
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: |
node_modules
*/*/node_modules
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}

- name: Install dependencies
run: |
yarn install --frozen-lockfile
- name: Run TypeScript type checker
run: |
yarn ts:check
env:
CI: true

- name: Run formatting check
run: |
yarn format:check
env:
CI: true

- name: Run linting check
run: |
yarn lint
env:
CI: true

- name: Run tests
run: |
yarn test:ci
env:
CI: true

- name: Upload coverage
uses: codecov/codecov-action@v3
27 changes: 27 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
dist
dist-ssr
*.local

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

# Vitest
coverage
3 changes: 3 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
dist
node_modules
coverage
Empty file added .prettierrc
Empty file.
Loading

0 comments on commit 057eab4

Please sign in to comment.