From a52aa33f66725953da8d793a0cfb36cbfd24e3c4 Mon Sep 17 00:00:00 2001 From: Nex Zhu Date: Mon, 11 Dec 2023 18:59:12 +0800 Subject: [PATCH] ci(all): do build Docker images, switch from docker/build-push-action to @nx-tools/nx-container --- .github/workflows/ci.yml | 88 +++------ apps/desktop/project.json | 25 ++- apps/web/project.json | 25 ++- nx.js | 22 +++ nx.json | 29 ++- package.json | 2 + pnpm-lock.yaml | 368 ++++++++++++++++++++++++++++++++++++++ tsconfig.base.json | 4 +- 8 files changed, 494 insertions(+), 69 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 713b456..08ce7ab 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,64 +1,5 @@ name: build -snippets: - step-set-common-vars: &step-set-common-vars - name: Set common variables - id: commonVars - run: | - commit_id_8=${GITHUB_SHA::8} - CONTAINER_REGISTRY_DOMAIN=docker.io - echo commit_id_8=${commit_id_8} >> $GITHUB_OUTPUT - echo repo_url=https://github.com/${{ github.repository }} >> $GITHUB_OUTPUT - - step-set-project-vars: &step-set-project-vars - name: Set project variables - id: projectVars - run: | - tmp=${{ github.job }} - proj=${tmp#docker-} - echo proj=$proj >> $GITHUB_OUTPUT - if echo '${{ needs.build.outputs.affectedProjs }}' | grep -qE "(^|,)${proj}($|,)"; then - affected=true - fi - echo affected=${affected} >> $GITHUB_OUTPUT - docker_image=${{ steps.commonVars.outputs.container_registry_domain }}/daotl/web-monorepo-starter-${proj} - echo docker_image=${docker_image} >> $GITHUB_OUTPUT - echo commit_id_image=${docker_image}:commit-${{ steps.commonVars.outputs.commit_id_8 }} - - step-docker-setup-buildx: &step-docker-setup-buildx - uses: docker/setup-buildx-action@v3 - if: steps.projectVars.outputs.affected == 'true' && github.ref == 'refs/heads/main' && github.event_name == 'push' - - step-docker-login: &step-docker-login - uses: docker/login-action@v3 - if: steps.projectVars.outputs.affected == 'true' && github.ref == 'refs/heads/main' && github.event_name == 'push' - with: - username: ${{ secrets.DOCKERHUB_USERNAME }} - password: ${{ secrets.DOCKERHUB_TOKEN }} - - step-docker-build-push: &step-docker-build-push - uses: docker/build-push-action@v5 - if: steps.projectVars.outputs.affected == 'true' && github.ref == 'refs/heads/main' && github.event_name == 'push' - with: - context: apps/${{ github.job }} - file: apps/${{github.job}}/docker/Dockerfile.ci - push: true - tags: ${{ steps.projectVars.outputs.docker_image }}:commit-${{ steps.commonVars.outputs.commit_id_8 }},${{ steps.projectVars.outputs.docker_image }}:${{ github.ref_name }},${{ steps.projectVars.outputs.docker_image }}:latest - # cache-from: type=registry,ref=${{ steps.projectVars.outputs.docker_image }}:buildcache-${{ github.ref_name }} - # cache-to: type=registry,ref=${{ steps.projectVars.outputs.docker_image }}:buildcache-${{ github.ref_name }},mode=max - - job-docker: &job-docker - needs: [build] - runs-on: ubuntu-latest - env: - RUNNER_TOOL_CACHE: /toolcache - steps: - - *step-set-common-vars - - *step-set-project-vars - - *step-docker-setup-buildx - - *step-docker-login - - *step-docker-build-push - on: push: branches: [main, single-page, feat/*, fix/*, chore/*, debug/*] @@ -84,7 +25,13 @@ jobs: node-version: [18.x, 20.x] steps: - - *step-set-common-vars + - name: Set common variables + id: common-vars + run: | + commit_id_8=${GITHUB_SHA::8} + CONTAINER_REGISTRY_DOMAIN=docker.io + echo commit_id_8=${commit_id_8} >> $GITHUB_OUTPUT + echo repo_url=https://github.com/${{ github.repository }} >> $GITHUB_OUTPUT # Needs to come first, `actions/setup-node` uses `pnpm-lock.yaml` - uses: actions/checkout@v3 @@ -126,9 +73,22 @@ jobs: # https://github.com/pnpm/pnpm/issues/6300#issuecomment-1722120409 run: CYPRESS_INSTALL_BINARY=0 ./scripts/pnpm-install-filtered.js --frozen-lockfile=true ${{ steps.affected.outputs.projs }} - - name: build & lint - run: pnpm nx affected -t build lint + - run: pnpm nx affected -t build lint - docker-web: *job-docker + # Build Docker images - docker-desktop: *job-docker + - uses: docker/setup-buildx-action@v3 + id: docker-setup-buildx + if: github.ref == 'refs/heads/main' && github.event_name == 'push' && matrix.node-version == '20.x' + + - uses: docker/login-action@v3 + if: github.ref == 'refs/heads/main' && github.event_name == 'push' && matrix.node-version == '20.x' + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + + - name: Build and push Docker images + if: github.ref == 'refs/heads/main' && github.event_name == 'push' && matrix.node-version == '20.x' + env: + INPUT_BUILDER: ${{ steps.docker-setup-buildx.outputs.name }} + run: pnpm nx affected -t container -c ci diff --git a/apps/desktop/project.json b/apps/desktop/project.json index bfe7a12..1e107a9 100644 --- a/apps/desktop/project.json +++ b/apps/desktop/project.json @@ -1,17 +1,40 @@ { "name": "desktop", + "$schema": "../../node_modules/nx/schemas/project-schema.json", "sourceRoot": "apps/desktop/src", "targets": { "build": { "executor": "nx:run-commands", "options": { "cwd": "./apps/desktop", - "command": "mkdir dist && echo 'app' > dist/index.js" + "command": "mkdir -p dist && echo 'app' > dist/index.js" } }, "lint": { "command": "echo lint", "options": {} + }, + "container": { + "executor": "@nx-tools/nx-container:build", + "options": { + "engine": "docker", + "context": "apps/desktop", + "file": "apps/desktop/docker/Dockerfile.ci", + "tags": [ + "daotl/web-monorepo-starter-desktop:dev" + ], + "metadata": { + "images": [ + "daotl/web-monorepo-starter-desktop" + ] + } + }, + "configurations": { + "ci": { + // "cache-from": ["type=registry,ref=daotl/web-monorepo-starter-desktop:buildcache-${{ github.ref_name }}"], + // "cache-to": ["type=registry,ref=daotl/web-monorepo-starter-desktop:buildcache-${{ github.ref_name }},mode=max"] + } + } } } } diff --git a/apps/web/project.json b/apps/web/project.json index 30ddc71..0420e94 100644 --- a/apps/web/project.json +++ b/apps/web/project.json @@ -1,17 +1,40 @@ { "name": "web", + "$schema": "../../node_modules/nx/schemas/project-schema.json", "sourceRoot": "apps/web/src", "targets": { "build": { "executor": "nx:run-commands", "options": { "cwd": "./apps/web", - "command": "mkdir dist && echo 'app' > dist/index.js" + "command": "mkdir -p dist && echo 'app' > dist/index.js" } }, "lint": { "command": "echo lint", "options": {} + }, + "container": { + "executor": "@nx-tools/nx-container:build", + "options": { + "engine": "docker", + "context": "apps/web", + "file": "apps/web/docker/Dockerfile.ci", + "tags": [ + "daotl/web-monorepo-starter-web:dev" + ], + "metadata": { + "images": [ + "daotl/web-monorepo-starter-web" + ] + } + }, + "configurations": { + "ci": { + // "cache-from": ["type=registry,ref=daotl/web-monorepo-starter-web:buildcache-${{ github.ref_name }}"], + // "cache-to": ["type=registry,ref=daotl/web-monorepo-starter-web:buildcache-${{ github.ref_name }},mode=max"] + } + } } } } diff --git a/nx.js b/nx.js index 0f46d11..6be06af 100644 --- a/nx.js +++ b/nx.js @@ -58,6 +58,28 @@ const config = { cache: true, }, + container: { + dependsOn: ['build'], + cache: true, + options: { + load: true, + platforms: ['linux/amd64', 'linux/arm64'], + }, + configurations: { + ci: { + load: false, + push: true, + metadata: { + tags: [ + 'type=match,pattern=v(.*),group=1', + 'type=edge,branch=main', + 'type=sha,enabled={{is_default_branch}},prefix=sha-', + ], + }, + }, + }, + }, + deploy: { dependsOn: ['build', 'test', 'lint'], cache: false, diff --git a/nx.json b/nx.json index 30d0235..3b6e06b 100644 --- a/nx.json +++ b/nx.json @@ -9,8 +9,9 @@ } ], "default": [ + "sharedGlobals", "{projectRoot}/**/*", - "sharedGlobals" + "!{projectRoot}/**/?(*.)+spec.ts" ] }, "targetDefaults": { @@ -51,6 +52,32 @@ "input": [], "cache": true }, + "container": { + "dependsOn": [ + "build" + ], + "cache": true, + "options": { + "load": true, + "platforms": [ + "linux/amd64", + "linux/arm64" + ] + }, + "configurations": { + "ci": { + "load": false, + "push": true, + "metadata": { + "tags": [ + "type=match,pattern=v(.*),group=1", + "type=edge,branch=main", + "type=sha,enabled={{is_default_branch}},prefix=sha-" + ] + } + } + } + }, "deploy": { "dependsOn": [ "build", diff --git a/package.json b/package.json index fe4b38d..f585a30 100644 --- a/package.json +++ b/package.json @@ -33,6 +33,8 @@ "@daotl/biome-config": "0.0.4", "@daotl/tsconfig": "^0.1.2", "@manypkg/cli": "npm:@daotl/manypkg-cli@^0.21.1", + "@nx-tools/container-metadata": "^5.1.0", + "@nx-tools/nx-container": "^5.1.0", "@traf/nx": "^0.0.16", "commitiquette": "^1.2.1", "commitizen": "^4.3.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f4d3fdf..7594d61 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -26,6 +26,12 @@ importers: '@manypkg/cli': specifier: npm:@daotl/manypkg-cli@^0.21.1 version: /@daotl/manypkg-cli@0.21.1 + '@nx-tools/container-metadata': + specifier: ^5.1.0 + version: 5.1.0(@nx/devkit@17.2.0)(dotenv@16.3.1)(tslib@2.6.2) + '@nx-tools/nx-container': + specifier: ^5.1.0 + version: 5.1.0(@nx/devkit@17.2.0)(dotenv@16.3.1)(tslib@2.6.2) '@traf/nx': specifier: ^0.0.16 version: 0.0.16 @@ -139,6 +145,34 @@ packages: engines: {node: '>=0.10.0'} dev: true + /@actions/exec@1.1.1: + resolution: {integrity: sha512-+sCcHHbVdk93a0XT19ECtO/gIXoxvdsgQLzb2fE2/5sIZmWQuluYyjPQtrtTHdU1YzTZ7bAPN4sITq2xi1679w==} + dependencies: + '@actions/io': 1.1.3 + dev: false + + /@actions/github@5.1.1: + resolution: {integrity: sha512-Nk59rMDoJaV+mHCOJPXuvB1zIbomlKS0dmSIqPGxd0enAXBnOfn4VWF+CGtRCwXZG9Epa54tZA7VIRlJDS8A6g==} + dependencies: + '@actions/http-client': 2.2.0 + '@octokit/core': 3.6.0 + '@octokit/plugin-paginate-rest': 2.21.3(@octokit/core@3.6.0) + '@octokit/plugin-rest-endpoint-methods': 5.16.2(@octokit/core@3.6.0) + transitivePeerDependencies: + - encoding + dev: false + + /@actions/http-client@2.2.0: + resolution: {integrity: sha512-q+epW0trjVUUHboliPb4UF9g2msf+w61b32tAkFEwL/IwP0DQWgbCMM0Hbe3e3WXSKz5VcUXbzJQgy8Hkra/Lg==} + dependencies: + tunnel: 0.0.6 + undici: 5.28.2 + dev: false + + /@actions/io@1.1.3: + resolution: {integrity: sha512-wi9JjgKLYS7U/z8PPbco+PvTb/nRWjeoFlJ1Qer83k/3C5PHQi28hiVdeE2kHXmIL99mQFawx8qt/JPjZilJ8Q==} + dev: false + /@antfu/eslint-config@1.2.1(eslint@8.54.0)(typescript@5.3.2): resolution: {integrity: sha512-/B7jSc9RARxGNZUoxkB2EL7pL7v5ubt25Ah3QbQaCalcIOC3YF+60mL4/G8Oi9Rtdng7ytNGg3bi50voKfqINQ==} hasBin: true @@ -217,6 +251,14 @@ packages: chalk: 2.4.2 js-tokens: 4.0.0 + /@babel/runtime-corejs3@7.23.5: + resolution: {integrity: sha512-7+ziVclejQTLYhXl+Oi1f6gTGD1XDCeLa4R472TNGQxb08zbEJ0OdNoh5Piz+57Ltmui6xR88BXR4gS3/Toslw==} + engines: {node: '>=6.9.0'} + dependencies: + core-js-pure: 3.34.0 + regenerator-runtime: 0.14.0 + dev: false + /@biomejs/biome@1.4.0: resolution: {integrity: sha512-/rDlao6ra38nhxo4IYCqWCzfTJcpMk4YHjSVBI9yN/ifdhnzSwirL25xDVH7G9hZdNhpF9g78FaPJhFa9DX0Cw==} engines: {node: '>=14.*'} @@ -559,6 +601,11 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true + /@fastify/busboy@2.1.0: + resolution: {integrity: sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA==} + engines: {node: '>=14'} + dev: false + /@grpc/grpc-js@1.9.6: resolution: {integrity: sha512-yq3qTy23u++8zdvf+h4mz4ohDFi681JAkMZZPTKh8zmUVh0AKLisFlgxcn22FMNowXz15oJ6pqgwT7DJ+PdJvg==} engines: {node: ^8.13.0 || >=10.10.0} @@ -668,6 +715,14 @@ packages: '@nodelib/fs.scandir': 2.1.5 fastq: 1.13.0 + /@nrwl/devkit@17.2.0(nx@17.1.3): + resolution: {integrity: sha512-FqyZbFGNwS51pKTF+d2sB4xym1yD/OYRKC4Sz3ku7mjk8yAWlJeT1JHT5gz56wrXiFKvATN/qEAXg7wlx3M1NA==} + dependencies: + '@nx/devkit': 17.2.0(nx@17.1.3) + transitivePeerDependencies: + - nx + dev: false + /@nrwl/tao@17.1.3: resolution: {integrity: sha512-9YpfEkUpVqOweqgQvMDcWApNx4jhCqBNH5IByZj302Enp3TLnQSvhuX5Dfr8hNQRQokIpEn6tW8SGTctTM5LXw==} hasBin: true @@ -680,6 +735,88 @@ packages: - debug dev: false + /@nx-tools/ci-context@5.1.0(@nx/devkit@17.2.0)(tslib@2.6.2): + resolution: {integrity: sha512-nmnhXCD7316/NEAy7A9Fim82WgwIB+MOZQHpuBfOEGkdL7FOE8uE1it1271O91c2STvQa4tQ4xlcBtqcqdqC1w==} + peerDependencies: + tslib: ^2.5.3 + dependencies: + '@actions/github': 5.1.1 + '@nx-tools/core': 5.1.0(@nx/devkit@17.2.0)(tslib@2.6.2) + '@octokit/openapi-types': 12.11.0 + ci-info: 3.8.0 + properties-file: 2.2.4 + tslib: 2.6.2 + transitivePeerDependencies: + - '@nx/devkit' + - encoding + dev: false + + /@nx-tools/container-metadata@5.1.0(@nx/devkit@17.2.0)(dotenv@16.3.1)(tslib@2.6.2): + resolution: {integrity: sha512-bPnsh3TnepSPr8TgIAcQguCURM/PO27nEl+OrJSBiO1t5pjV3gL7kReilGQAatFPFbD+pR+M19wsrFhTJ/q/ew==} + peerDependencies: + '@nx/devkit': ^16.0.0 || ^17.0.0 + dotenv: '>=10.0.0' + tslib: ^2.5.3 + dependencies: + '@nx-tools/ci-context': 5.1.0(@nx/devkit@17.2.0)(tslib@2.6.2) + '@nx-tools/core': 5.1.0(@nx/devkit@17.2.0)(tslib@2.6.2) + '@nx/devkit': 17.2.0(nx@17.1.3) + '@renovate/pep440': 1.0.0 + csv-parse: 5.4.0 + dotenv: 16.3.1 + handlebars: 4.7.7 + moment-timezone: 0.5.43 + semver: 7.5.4 + tslib: 2.6.2 + transitivePeerDependencies: + - encoding + dev: false + + /@nx-tools/core@5.1.0(@nx/devkit@17.2.0)(tslib@2.6.2): + resolution: {integrity: sha512-mc4nXNSQUUxoDoJsn+pqGYLddce/vFClOZLWZLH5XEsowxce2F1hB8aBttNZXD1egZmmtED1+cNfkq1BaO18zw==} + peerDependencies: + '@nx/devkit': ^16.0.0 || ^17.0.0 + tslib: ^2.5.3 + dependencies: + '@actions/exec': 1.1.1 + '@nx/devkit': 17.2.0(nx@17.1.3) + chalk: 4.1.2 + ci-info: 3.8.0 + tslib: 2.6.2 + dev: false + + /@nx-tools/nx-container@5.1.0(@nx/devkit@17.2.0)(dotenv@16.3.1)(tslib@2.6.2): + resolution: {integrity: sha512-pFIVp6q7hWN05AUgK9JXnaGav/N4QAjrbTZu0yA06w5D7/IEEl/QaD3yHJqEy5zKNpr77HBUXyxbqmIDRFZxwQ==} + peerDependencies: + '@nx/devkit': ^16.0.0 || ^17.0.0 + dotenv: '>=10.0.0' + tslib: ^2.5.3 + dependencies: + '@nx-tools/core': 5.1.0(@nx/devkit@17.2.0)(tslib@2.6.2) + '@nx/devkit': 17.2.0(nx@17.1.3) + csv-parse: 5.4.0 + dotenv: 16.3.1 + handlebars: 4.7.7 + semver: 7.5.4 + tmp: 0.2.1 + tslib: 2.6.2 + dev: false + + /@nx/devkit@17.2.0(nx@17.1.3): + resolution: {integrity: sha512-9cgVDicIf2rdlMfWLq48RIBCzpHNgLJhuUtHCyvogr1ePZfG3YGA2NPHHW/QtRAm5kT8x5dWLtf68nlrAkcP/A==} + peerDependencies: + nx: '>= 16 <= 18' + dependencies: + '@nrwl/devkit': 17.2.0(nx@17.1.3) + ejs: 3.1.9 + enquirer: 2.3.6 + ignore: 5.3.0 + nx: 17.1.3 + semver: 7.5.3 + tmp: 0.2.1 + tslib: 2.6.2 + dev: false + /@nx/nx-darwin-arm64@17.1.3: resolution: {integrity: sha512-f4qLa0y3C4uuhYKgq+MU892WaQvtvmHqrEhHINUOxYXNiLy2sgyJPW0mOZvzXtC4dPaUmiVaFP5RMVzc8Lxhtg==} engines: {node: '>= 10'} @@ -770,6 +907,94 @@ packages: dev: false optional: true + /@octokit/auth-token@2.5.0: + resolution: {integrity: sha512-r5FVUJCOLl19AxiuZD2VRZ/ORjp/4IN98Of6YJoJOkY75CIBuYfmiNHGrDwXr+aLGG55igl9QrxX3hbiXlLb+g==} + dependencies: + '@octokit/types': 6.41.0 + dev: false + + /@octokit/core@3.6.0: + resolution: {integrity: sha512-7RKRKuA4xTjMhY+eG3jthb3hlZCsOwg3rztWh75Xc+ShDWOfDDATWbeZpAHBNRpm4Tv9WgBMOy1zEJYXG6NJ7Q==} + dependencies: + '@octokit/auth-token': 2.5.0 + '@octokit/graphql': 4.8.0 + '@octokit/request': 5.6.3 + '@octokit/request-error': 2.1.0 + '@octokit/types': 6.41.0 + before-after-hook: 2.2.3 + universal-user-agent: 6.0.1 + transitivePeerDependencies: + - encoding + dev: false + + /@octokit/endpoint@6.0.12: + resolution: {integrity: sha512-lF3puPwkQWGfkMClXb4k/eUT/nZKQfxinRWJrdZaJO85Dqwo/G0yOC434Jr2ojwafWJMYqFGFa5ms4jJUgujdA==} + dependencies: + '@octokit/types': 6.41.0 + is-plain-object: 5.0.0 + universal-user-agent: 6.0.1 + dev: false + + /@octokit/graphql@4.8.0: + resolution: {integrity: sha512-0gv+qLSBLKF0z8TKaSKTsS39scVKF9dbMxJpj3U0vC7wjNWFuIpL/z76Qe2fiuCbDRcJSavkXsVtMS6/dtQQsg==} + dependencies: + '@octokit/request': 5.6.3 + '@octokit/types': 6.41.0 + universal-user-agent: 6.0.1 + transitivePeerDependencies: + - encoding + dev: false + + /@octokit/openapi-types@12.11.0: + resolution: {integrity: sha512-VsXyi8peyRq9PqIz/tpqiL2w3w80OgVMwBHltTml3LmVvXiphgeqmY9mvBw9Wu7e0QWk/fqD37ux8yP5uVekyQ==} + dev: false + + /@octokit/plugin-paginate-rest@2.21.3(@octokit/core@3.6.0): + resolution: {integrity: sha512-aCZTEf0y2h3OLbrgKkrfFdjRL6eSOo8komneVQJnYecAxIej7Bafor2xhuDJOIFau4pk0i/P28/XgtbyPF0ZHw==} + peerDependencies: + '@octokit/core': '>=2' + dependencies: + '@octokit/core': 3.6.0 + '@octokit/types': 6.41.0 + dev: false + + /@octokit/plugin-rest-endpoint-methods@5.16.2(@octokit/core@3.6.0): + resolution: {integrity: sha512-8QFz29Fg5jDuTPXVtey05BLm7OB+M8fnvE64RNegzX7U+5NUXcOcnpTIK0YfSHBg8gYd0oxIq3IZTe9SfPZiRw==} + peerDependencies: + '@octokit/core': '>=3' + dependencies: + '@octokit/core': 3.6.0 + '@octokit/types': 6.41.0 + deprecation: 2.3.1 + dev: false + + /@octokit/request-error@2.1.0: + resolution: {integrity: sha512-1VIvgXxs9WHSjicsRwq8PlR2LR2x6DwsJAaFgzdi0JfJoGSO8mYI/cHJQ+9FbN21aa+DrgNLnwObmyeSC8Rmpg==} + dependencies: + '@octokit/types': 6.41.0 + deprecation: 2.3.1 + once: 1.4.0 + dev: false + + /@octokit/request@5.6.3: + resolution: {integrity: sha512-bFJl0I1KVc9jYTe9tdGGpAMPy32dLBXXo1dS/YwSCTL/2nd9XeHsY616RE3HPXDVk+a+dBuzyz5YdlXwcDTr2A==} + dependencies: + '@octokit/endpoint': 6.0.12 + '@octokit/request-error': 2.1.0 + '@octokit/types': 6.41.0 + is-plain-object: 5.0.0 + node-fetch: 2.6.7 + universal-user-agent: 6.0.1 + transitivePeerDependencies: + - encoding + dev: false + + /@octokit/types@6.41.0: + resolution: {integrity: sha512-eJ2jbzjdijiL3B4PrSQaSjuF2sPEQPVCPzBvTHJD9Nz+9dw2SGH4K4xeQJ77YfTq5bRQ+bD8wT11JbeDPmxmGg==} + dependencies: + '@octokit/openapi-types': 12.11.0 + dev: false + /@opentelemetry/api-metrics@0.32.0: resolution: {integrity: sha512-g1WLhpG8B6iuDyZJFRGsR+JKyZ94m5LEmY2f+duEJ9Xb4XRlLHrZvh6G34OH6GJ8iDHxfHb/sWjJ1ZpkI9yGMQ==} engines: {node: '>=14'} @@ -1052,6 +1277,12 @@ packages: resolution: {integrity: sha512-xfo+yLRM2zVjVEA4p23IjQWzyWl1ZhWOGobsBqRpIarzLvwNH/RAGaoehdxlhx4X92302DrpdIFgTICMN4P38w==} dev: false + /@renovate/pep440@1.0.0: + resolution: {integrity: sha512-k3pZVxGEGpU7rpH507/9vxfFjuxX7qx4MSj9Fk+6zBsf/uZmAy8x97dNtZacbge7gP9TazbW1d7SEb5vsOmKlw==} + dependencies: + xregexp: 4.4.1 + dev: false + /@sinclair/typebox@0.27.8: resolution: {integrity: sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==} dev: false @@ -1573,6 +1804,10 @@ packages: resolution: {integrity: sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=} dev: false + /async@3.2.5: + resolution: {integrity: sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg==} + dev: false + /asynckit@0.4.0: resolution: {integrity: sha1-x57Zf380y48robyXkLzDZkdLS3k=} dev: false @@ -1603,6 +1838,10 @@ packages: resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} dev: false + /before-after-hook@2.2.3: + resolution: {integrity: sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ==} + dev: false + /bindings@1.5.0: resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==} dependencies: @@ -1780,6 +2019,11 @@ packages: resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} dev: false + /ci-info@3.8.0: + resolution: {integrity: sha512-eXTggHWSooYhq49F2opQhuHWgzucfF2YgODK4e1566GQs5BIfP30B0oenwBJHfWxAs2fyPB1s7Mg949zLf61Yw==} + engines: {node: '>=8'} + dev: false + /ci-info@3.9.0: resolution: {integrity: sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==} engines: {node: '>=8'} @@ -1960,6 +2204,11 @@ packages: split2: 4.2.0 dev: false + /core-js-pure@3.34.0: + resolution: {integrity: sha512-pmhivkYXkymswFfbXsANmBAewXx86UBfmagP+w0wkK06kLsLlTK5oQmsURPivzMkIBQiYq2cjamcZExIwlFQIg==} + requiresBuild: true + dev: false + /cosmiconfig-typescript-loader@5.0.0(@types/node@18.11.10)(cosmiconfig@8.3.6)(typescript@5.3.2): resolution: {integrity: sha512-+8cK7jRAReYkMwMiG+bxhcNKiHJDM6bR9FD/nGBXOWdMLuYawjF5cGrtLilJ+LGd3ZjCXnJjR5DkfWPoIVlqJA==} engines: {node: '>=v16'} @@ -2012,6 +2261,10 @@ packages: hasBin: true dev: true + /csv-parse@5.4.0: + resolution: {integrity: sha512-JiQosUWiOFgp4hQn0an+SBoV9IKdqzhROM0iiN4LB7UpfJBlsSJlWl9nq4zGgxgMAzHJ6V4t29VAVD+3+2NJAg==} + dev: false + /cz-conventional-changelog@3.3.0(typescript@5.3.2): resolution: {integrity: sha512-U466fIzU5U22eES5lTNiNbZ+d8dfcHcssH4o7QsdWaCcRs/feIPCxKYSWkYBNs5mny7MvEfwpTLWjvbm94hecw==} engines: {node: '>= 10'} @@ -2139,6 +2392,10 @@ packages: engines: {node: '>=0.4.0'} dev: false + /deprecation@2.3.1: + resolution: {integrity: sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ==} + dev: false + /detect-file@1.0.0: resolution: {integrity: sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc=} engines: {node: '>=0.10.0'} @@ -2219,6 +2476,14 @@ packages: resolution: {integrity: sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==} dev: false + /ejs@3.1.9: + resolution: {integrity: sha512-rC+QVNMJWv+MtPgkt0y+0rVEIdbtxVADApW9JXrUVlzHetgcyczP/E7DJmWJ4fJCZF2cPcBk0laWO9ZHMG3DmQ==} + engines: {node: '>=0.10.0'} + hasBin: true + dependencies: + jake: 10.8.7 + dev: false + /emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} @@ -2904,6 +3169,12 @@ packages: resolution: {integrity: sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==} dev: false + /filelist@1.0.4: + resolution: {integrity: sha512-w1cEuf3S+DrLCQL7ET6kz+gmlJdbq9J7yXCSjK/OZCPA+qEN1WyF4ZAf0YYJa4/shHJra2t/d/r8SV4Ji+x+8Q==} + dependencies: + minimatch: 5.1.6 + dev: false + /fill-range@7.0.1: resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==} engines: {node: '>=8'} @@ -3261,6 +3532,19 @@ packages: resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} dev: true + /handlebars@4.7.7: + resolution: {integrity: sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA==} + engines: {node: '>=0.4.7'} + hasBin: true + dependencies: + minimist: 1.2.8 + neo-async: 2.6.2 + source-map: 0.6.1 + wordwrap: 1.0.0 + optionalDependencies: + uglify-js: 3.17.4 + dev: false + /hard-rejection@2.1.0: resolution: {integrity: sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA==} engines: {node: '>=6'} @@ -3559,6 +3843,11 @@ packages: engines: {node: '>=0.10.0'} dev: false + /is-plain-object@5.0.0: + resolution: {integrity: sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==} + engines: {node: '>=0.10.0'} + dev: false + /is-regex@1.1.4: resolution: {integrity: sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==} engines: {node: '>= 0.4'} @@ -3638,6 +3927,17 @@ packages: /isexe@2.0.0: resolution: {integrity: sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=} + /jake@10.8.7: + resolution: {integrity: sha512-ZDi3aP+fG/LchyBzUM804VjddnwfSfsdeYkwt8NcbKRvo4rFkjhs456iLFn3k2ZUWvNe4i48WACDbza8fhq2+w==} + engines: {node: '>=10'} + hasBin: true + dependencies: + async: 3.2.5 + chalk: 4.1.2 + filelist: 1.0.4 + minimatch: 3.1.2 + dev: false + /jest-diff@29.7.0: resolution: {integrity: sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} @@ -4127,6 +4427,13 @@ packages: dependencies: brace-expansion: 1.1.11 + /minimatch@5.1.6: + resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} + engines: {node: '>=10'} + dependencies: + brace-expansion: 2.0.1 + dev: false + /minimatch@7.4.6: resolution: {integrity: sha512-sBz8G/YjVniEz6lKPNpKxXwazJe4c19fEfV2GDMX6AjFz+MX9uDWIZW8XreVhkFW3fkIdTv/gxWr/Kks5FFAVw==} engines: {node: '>=10'} @@ -4183,6 +4490,16 @@ packages: resolution: {integrity: sha512-ySViT69/76t8VhE1xXHK6Ch4NcDd26gx0MzKXLO+F7NOtnqH68d9zF94nT8ZWSxXh8ELOERsnJO/sWt1xZYw5A==} dev: false + /moment-timezone@0.5.43: + resolution: {integrity: sha512-72j3aNyuIsDxdF1i7CEgV2FfxM1r6aaqJyLB2vwb33mXYyoyLly+F1zbWqhA3/bVIoJ4szlUoMbUnVdid32NUQ==} + dependencies: + moment: 2.29.4 + dev: false + + /moment@2.29.4: + resolution: {integrity: sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==} + dev: false + /ms@2.1.2: resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} @@ -4202,6 +4519,10 @@ packages: resolution: {integrity: sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=} dev: true + /neo-async@2.6.2: + resolution: {integrity: sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==} + dev: false + /no-case@3.0.4: resolution: {integrity: sha512-fgAN3jGAh+RoxUGZHTSOLJIqUc2wmoBwGR4tbpNAKmmovFoWq0OdRkb0VkldReO2a2iBT/OEulG9XSUc10r3zg==} dependencies: @@ -4697,6 +5018,11 @@ packages: sisteransi: 1.0.5 dev: true + /properties-file@2.2.4: + resolution: {integrity: sha512-+DOHK/QgbEeyu96G5MB1Sc1dfdPr/E5dpD6BexTn0XYVLn6VZhfYmWQRaz7sMjrj4nEdIaWX+tYaDboEnk50GQ==} + engines: {node: ^14.18.1 || >=16.0.0} + dev: false + /proto-list@1.2.4: resolution: {integrity: sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA==} dev: false @@ -4838,6 +5164,10 @@ packages: strip-indent: 3.0.0 dev: false + /regenerator-runtime@0.14.0: + resolution: {integrity: sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA==} + dev: false + /regexp-tree@0.1.27: resolution: {integrity: sha512-iETxpjK6YoRWJG5o6hXLwvjYAoW+FEZn9os0PD/b6AP6xQwsa/Y7lCVgIixBbUPMfhu+i2LtdeAqVTgGlQarfA==} hasBin: true @@ -5415,6 +5745,15 @@ packages: resolution: {integrity: sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==} dev: false + /tslib@2.6.2: + resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} + dev: false + + /tunnel@0.0.6: + resolution: {integrity: sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==} + engines: {node: '>=0.6.11 <=0.7.0 || >=0.7.3'} + dev: false + /type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} @@ -5499,6 +5838,14 @@ packages: resolution: {integrity: sha512-o+ORpgGwaYQXgqGDwd+hkS4PuZ3QnmqMMxRuajK/a38L6fTpcE5GPIfrf+L/KemFzfUpeUQc1rRS1iDBozvnFA==} dev: true + /uglify-js@3.17.4: + resolution: {integrity: sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==} + engines: {node: '>=0.8.0'} + hasBin: true + requiresBuild: true + dev: false + optional: true + /unbox-primitive@1.0.2: resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} dependencies: @@ -5510,12 +5857,23 @@ packages: /undici-types@5.26.5: resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + /undici@5.28.2: + resolution: {integrity: sha512-wh1pHJHnUeQV5Xa8/kyQhO7WFa8M34l026L5P/+2TYiakvGy5Rdc8jWZVyG7ieht/0WgJLEd3kcU5gKx+6GC8w==} + engines: {node: '>=14.0'} + dependencies: + '@fastify/busboy': 2.1.0 + dev: false + /unist-util-stringify-position@2.0.3: resolution: {integrity: sha512-3faScn5I+hy9VleOq/qNbAd6pAx7iH5jYBMS9I1HgQVijz/4mv5Bvw5iw1sC/90CODiKo81G/ps8AJrISn687g==} dependencies: '@types/unist': 2.0.6 dev: true + /universal-user-agent@6.0.1: + resolution: {integrity: sha512-yCzhz6FN2wU1NiiQRogkTQszlQSlpWaw8SvVegAc+bDxbzHgh1vX8uIe8OYyMH6DwH+sdTJsgMl36+mSMdRJIQ==} + dev: false + /universalify@0.1.2: resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} engines: {node: '>= 4.0.0'} @@ -5664,6 +6022,10 @@ packages: engines: {node: '>=0.10.0'} dev: false + /wordwrap@1.0.0: + resolution: {integrity: sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==} + dev: false + /wrap-ansi@7.0.0: resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} engines: {node: '>=10'} @@ -5680,6 +6042,12 @@ packages: engines: {node: '>=12'} dev: true + /xregexp@4.4.1: + resolution: {integrity: sha512-2u9HwfadaJaY9zHtRRnH6BY6CQVNQKkYm3oLtC9gJXXzfsbACg5X5e4EZZGVAH+YIfa+QA9lsFQTTe3HURF3ag==} + dependencies: + '@babel/runtime-corejs3': 7.23.5 + dev: false + /y18n@5.0.8: resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} engines: {node: '>=10'} diff --git a/tsconfig.base.json b/tsconfig.base.json index 814fa62..da5ac8d 100644 --- a/tsconfig.base.json +++ b/tsconfig.base.json @@ -3,10 +3,10 @@ "compileOnSave": false, "compilerOptions": { "paths": { + "@daotl/desktop": ["apps/desktop/src/index.ts"], "@daotl/myutil": ["lib/myutil/src/index.ts"], - "@daotl/yourutil": ["lib/yourutil/src/index.ts"], "@daotl/web": ["apps/web/src/index.ts"], - "@daotl/desktop": ["apps/desktop/src/index.ts"] + "@daotl/yourutil": ["lib/yourutil/src/index.ts"] } } }