Skip to content

Commit

Permalink
chore: setup project
Browse files Browse the repository at this point in the history
  • Loading branch information
shigma committed Dec 4, 2023
1 parent db39435 commit 28511e6
Show file tree
Hide file tree
Showing 6 changed files with 999 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Build

on:
push:
pull_request:

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Check out
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
- name: Install
run: yarn --no-immutable
- name: Build
run: yarn build

test:
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
node-version: [18, 20]

steps:
- name: Check out
uses: actions/checkout@v4
- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Install
run: yarn --no-immutable
- name: Unit Test
run: yarn test:json
- name: Report Coverage
uses: codecov/codecov-action@v3
with:
file: ./coverage/coverage-final.json
name: codecov
893 changes: 893 additions & 0 deletions .yarn/releases/yarn-4.0.2.cjs

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
nodeLinker: node-modules

yarnPath: .yarn/releases/yarn-4.0.2.cjs
35 changes: 35 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"name": "@root/yakumo",
"private": true,
"version": "1.0.0",
"workspaces": [
"external/*",
"fixtures/*",
"fixtures/default/packages/*",
"packages/*"
],
"license": "MIT",
"scripts": {
"build": "tsc -b",
"yakumo": "node -r esbuild-register packages/core/src/bin",
"bump": "yarn yakumo version",
"dep": "yarn yakumo upgrade",
"pub": "yarn yakumo publish",
"test": "yarn yakumo mocha -r esbuild-register -t 10000",
"test:text": "shx rm -rf coverage && c8 -r text yarn test",
"test:json": "shx rm -rf coverage && c8 -r json yarn test",
"test:html": "shx rm -rf coverage && c8 -r html yarn test"
},
"devDependencies": {
"@types/chai": "^4.3.11",
"@types/mocha": "^9.1.1",
"@types/node": "^20.10.2",
"c8": "^7.14.0",
"chai": "^4.3.10",
"esbuild": "^0.18.20",
"esbuild-register": "^3.5.0",
"mocha": "^9.2.2",
"shx": "^0.3.4",
"typescript": "^5.3.2"
}
}
13 changes: 13 additions & 0 deletions tsconfig.base.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"compilerOptions": {
"target": "es2022",
"module": "commonjs",
"declaration": true,
"composite": true,
"incremental": true,
"skipLibCheck": true,
"esModuleInterop": true,
"moduleResolution": "node",
"strictBindCallApply": true,
},
}
11 changes: 11 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"extends": "./tsconfig.base",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@cordisjs/server": ["packages/core/src"],
"@cordisjs/server-*": ["packages/*/src"],
},
},
"files": [],
}

0 comments on commit 28511e6

Please sign in to comment.