diff --git a/.circleci/config.yml b/.circleci/config.yml index 014411831c3..7d9140d8244 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -40,6 +40,7 @@ aliases: sudo apt install -y curl gnupg git libappindicator3-1 ca-certificates binutils icnsutils graphicsmagick python3 -m pip install packaging setuptools sudo npm install --quiet node-gyp@10.2.0 -g + sudo npm install --quiet ts-node@10.9.2 -g sudo npm config set python /usr/bin/python - &install-yarn diff --git a/.cspell.json b/.cspell.json index bf87afc19f5..44250d3e2c9 100644 --- a/.cspell.json +++ b/.cspell.json @@ -49,6 +49,7 @@ "browserslist", "Buildable", "buildjet", + "buildtools", "buildx", "Buildx", "Bykey", @@ -62,6 +63,7 @@ "Chetan", "childout", "Chinthagunta", + "choco", "circlon", "Civo", "CIVO", @@ -181,6 +183,7 @@ "Harbir", "healthcheck", "honeycombio", + "hostedtoolcache", "Hoster", "hubstaff", "HUBSTAFF", @@ -194,6 +197,7 @@ "icrud", "ienvironment", "IKPI", + "ilammy", "ILIKE", "ilinked", "immer", @@ -331,6 +335,11 @@ "mjml", "modelcontextprotocol", "msedge", + "msbuild", + "MSVC", + "msvc", + "msvs", + "MSVS", "MSYS", "Mustero", "napi", @@ -352,6 +361,7 @@ "nodenext", "nodownload", "NOLOGO", + "norestart", "notif", "npmignore", "NQCHAR", @@ -440,6 +450,7 @@ "resave", "rfdc", "roboto", + "runneradmin", "Ruslan", "sarif", "SARIF", @@ -522,6 +533,7 @@ "toastr", "togglefullscreen", "TOOLSDIRECTORY", + "Toolset", "traefik", "trasp", "Trendshift", @@ -568,8 +580,10 @@ "VMFE", "VULTR", "Wakatime", + "WARPBUILD", "wasabisys", "wbars", + "Wbem", "wdth", "webapp", "websockets", diff --git a/.deploy/api/Dockerfile b/.deploy/api/Dockerfile index 88922a96a26..b95036c94d0 100644 --- a/.deploy/api/Dockerfile +++ b/.deploy/api/Dockerfile @@ -126,7 +126,7 @@ RUN apk --update add bash && npm i -g npm@9 \ # Verify installed versions RUN node --version && npm --version && python3 --version -RUN npm install --quiet node-gyp@10.2.0 -g && npm install yarn -g --force +RUN npm install --quiet node-gyp@10.2.0 -g && npm install yarn -g --force && npm install --quiet ts-node@10.9.2 -g RUN mkdir /srv/gauzy && chown -R node:node /srv/gauzy COPY wait .deploy/api/entrypoint.prod.sh .deploy/api/entrypoint.compose.sh / @@ -192,7 +192,7 @@ RUN apk --update add bash && npm i -g npm@9 \ # Verify installed versions RUN node --version && npm --version && python3 --version -RUN npm install --quiet node-gyp@10.2.0 -g && npm install yarn -g --force +RUN npm install --quiet node-gyp@10.2.0 -g && npm install yarn -g --force && npm install --quiet ts-node@10.9.2 -g RUN mkdir /srv/gauzy && chown -R node:node /srv/gauzy USER node:node diff --git a/.deploy/mcp-auth/Dockerfile b/.deploy/mcp-auth/Dockerfile index 39da1b01a05..e423de7db2c 100644 --- a/.deploy/mcp-auth/Dockerfile +++ b/.deploy/mcp-auth/Dockerfile @@ -42,8 +42,11 @@ FROM node:20.18.1-alpine3.19 AS dependencies LABEL maintainer="ever@ever.co" LABEL org.opencontainers.image.source="https://github.com/ever-co/ever-gauzy" -RUN apk add --no-cache python3 make g++ \ - && npm install yarn -g --force +RUN apk add --no-cache python3 python3-dev py3-pip py3-setuptools build-base gcc g++ make autoconf automake git \ + && npm install --quiet node-gyp@10.2.0 -g \ + && npm install yarn -g --force \ + && npm install --quiet ts-node@10.9.2 -g + RUN mkdir /srv/gauzy-mcp-auth && chown -R node:node /srv/gauzy-mcp-auth USER node:node @@ -60,9 +63,10 @@ COPY --chown=node:node packages/core/package.json ./packages/core/ COPY --chown=node:node packages/plugin/package.json ./packages/plugin/ COPY --chown=node:node packages/utils/package.json ./packages/utils/ COPY --chown=node:node lerna.json package.json yarn.lock ./ +COPY --chown=node:node .scripts/postinstall.js ./.scripts/ RUN yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts \ - && npm rebuild bcrypt better-sqlite3 --build-from-source \ + && yarn postinstall.manual \ && yarn cache clean COPY --chown=node:node apps/mcp-auth ./apps/mcp-auth @@ -100,7 +104,10 @@ RUN yarn build:mcp-auth:prod # Only prod dependencies FROM node:20.18.1-alpine3.19 AS proddependencies -RUN apk add --no-cache python3 make g++ +RUN apk add --no-cache python3 python3-dev py3-pip py3-setuptools build-base gcc g++ make autoconf automake git \ + && npm install --quiet node-gyp@10.2.0 -g \ + && npm install yarn -g --force \ + && npm install --quiet ts-node@10.9.2 -g USER node:node @@ -108,9 +115,10 @@ WORKDIR /srv/gauzy-mcp-auth COPY --chown=node:node --from=build /srv/gauzy-mcp-auth/dist . COPY --chown=node:node lerna.json package.json yarn.lock ./ +COPY --chown=node:node .scripts/postinstall.js ./.scripts/ RUN yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts --production \ - && npm rebuild bcrypt better-sqlite3 --build-from-source \ + && yarn postinstall.manual \ && yarn cache clean # PROD diff --git a/.deploy/mcp/Dockerfile b/.deploy/mcp/Dockerfile index e66aa0b72df..92acc0728d6 100644 --- a/.deploy/mcp/Dockerfile +++ b/.deploy/mcp/Dockerfile @@ -88,8 +88,10 @@ FROM node:20.18.1-alpine3.19 AS dependencies LABEL maintainer="ever@ever.co" LABEL org.opencontainers.image.source="https://github.com/ever-co/ever-gauzy" -RUN apk add --no-cache python3 make g++ \ - && npm install yarn -g --force +RUN apk add --no-cache python3 python3-dev py3-pip py3-setuptools build-base gcc g++ make autoconf automake git \ + && npm install --quiet node-gyp@10.2.0 -g \ + && npm install yarn -g --force \ + && npm install --quiet ts-node@10.9.2 -g RUN mkdir /srv/gauzy-mcp && chown -R node:node /srv/gauzy-mcp @@ -106,9 +108,10 @@ COPY --chown=node:node packages/constants/package.json ./packages/constants/ COPY --chown=node:node packages/contracts/package.json ./packages/contracts/ COPY --chown=node:node packages/utils/package.json ./packages/utils/ COPY --chown=node:node lerna.json package.json yarn.lock ./ +COPY --chown=node:node .scripts/postinstall.js ./.scripts/ RUN yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts \ - && npm rebuild bcrypt --build-from-source \ + && yarn postinstall.manual \ && yarn cache clean COPY --chown=node:node apps/mcp ./apps/mcp @@ -145,7 +148,10 @@ RUN yarn build:mcp:prod # Only prod dependencies FROM node:20.18.1-alpine3.19 AS proddependencies -RUN apk add --no-cache python3 make g++ +RUN apk add --no-cache python3 python3-dev py3-pip py3-setuptools build-base gcc g++ make autoconf automake git \ + && npm install --quiet node-gyp@10.2.0 -g \ + && npm install yarn -g --force \ + && npm install --quiet ts-node@10.9.2 -g USER node:node @@ -153,9 +159,10 @@ WORKDIR /srv/gauzy-mcp COPY --chown=node:node --from=build /srv/gauzy-mcp/dist . COPY --chown=node:node lerna.json package.json yarn.lock ./ +COPY --chown=node:node .scripts/postinstall.js ./.scripts/ RUN yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts --production \ - && npm rebuild bcrypt --build-from-source \ + && yarn postinstall.manual \ && yarn cache clean # PROD diff --git a/.github/workflows/agent-prod.yml b/.github/workflows/agent-prod.yml index f266781ee78..c92c6c6a0e1 100644 --- a/.github/workflows/agent-prod.yml +++ b/.github/workflows/agent-prod.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: AGENT_APP_DESCRIPTION: "Ever Gauzy Agent" AGENT_APP_ID: "com.ever.gauzyagent" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Agent + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:agent:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/agent-stage.yml b/.github/workflows/agent-stage.yml index f80c35b4a54..a8100e4191c 100644 --- a/.github/workflows/agent-stage.yml +++ b/.github/workflows/agent-stage.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: AGENT_APP_DESCRIPTION: "Ever Gauzy Agent" AGENT_APP_ID: "com.ever.gauzyagent" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Agent + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:agent:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/desktop-app-prod.yml b/.github/workflows/desktop-app-prod.yml index 0c096c76e50..2d20f464ca5 100644 --- a/.github/workflows/desktop-app-prod.yml +++ b/.github/workflows/desktop-app-prod.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_APP_DESCRIPTION: "Ever Gauzy Desktop" DESKTOP_APP_ID: "com.ever.gauzydesktop" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Desktop App + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:desktop:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/desktop-app-stage.yml b/.github/workflows/desktop-app-stage.yml index 50aca5ed78b..984388712d0 100644 --- a/.github/workflows/desktop-app-stage.yml +++ b/.github/workflows/desktop-app-stage.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_APP_DESCRIPTION: "Ever Gauzy Desktop" DESKTOP_APP_ID: "com.ever.gauzydesktop" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Desktop App + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:desktop:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/desktop-timer-app-prod.yml b/.github/workflows/desktop-timer-app-prod.yml index 5ba30afda36..abcb6f7ea83 100644 --- a/.github/workflows/desktop-timer-app-prod.yml +++ b/.github/workflows/desktop-timer-app-prod.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_TIMER_APP_DESCRIPTION: "Ever Gauzy Desktop Timer" DESKTOP_TIMER_APP_ID: "com.ever.gauzydesktoptimer" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Desktop Timer App + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:desktop-timer:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/desktop-timer-app-stage.yml b/.github/workflows/desktop-timer-app-stage.yml index 9195b4e39f8..110d1229eff 100644 --- a/.github/workflows/desktop-timer-app-stage.yml +++ b/.github/workflows/desktop-timer-app-stage.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,106 +220,30 @@ jobs: DESKTOP_TIMER_APP_DESCRIPTION: "Ever Gauzy Desktop Timer" DESKTOP_TIMER_APP_ID: "com.ever.gauzydesktoptimer" - - name: Print environment variables and their sizes + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH shell: powershell run: | - foreach ($envVar in [System.Environment]::GetEnvironmentVariables().Keys) { - $value = [System.Environment]::GetEnvironmentVariable($envVar) - - if ($null -ne $value) { - $length = $value.Length - Write-Output "${envVar}: ${length}" - } - } - - - name: Print PATH var value - shell: powershell - run: | - $path = [System.Environment]::GetEnvironmentVariable('PATH') - Write-Output "PATH environment variable is:" - Write-Output $path + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" - name: Build Desktop Timer App + shell: powershell run: | - # We need to clear some environment variables to avoid the error about the limit of env vars size - set AZURE_CONFIG_DIR= - set AZURE_DEVOPS_CACHE_DIR= - set AZURE_EXTENSION_DIR= - set STATS_BLT= - set STATS_D= - set STATS_D_D= - set STATS_EXT= - set STATS_EXTP= - set STATS_RDCL= - set STATS_TIS= - set STATS_TRP= - set STATS_UE= - set STATS_V3PS= - set STATS_VMD= - set STATS_VMFE= - set ANDROID_HOME= - set ANDROID_NDK= - set ANDROID_NDK_HOME= - set ANDROID_NDK_LATEST_HOME= - set ANDROID_NDK_ROOT= - set ANDROID_SDK_ROOT= - set GOROOT_1_20_X64= - set GOROOT_1_21_X64= - set GOROOT_1_22_X64= - set GRADLE_HOME= - set JAVA_HOME= - set JAVA_HOME_11_X64= - set JAVA_HOME_17_X64= - set JAVA_HOME_21_X64= - set JAVA_HOME_8_X64= - set PGBIN= - set PGDATA= - set PGPASSWORD= - set PGROOT= - set PGUSER= - set PHPROOT= - set WARPBUILD_GH_JIT_TOKEN= - set npm_package_scripts_build_package_plugins_post_docker= - set npm_package_scripts_build_package_plugins_post_prod= - set npm_package_scripts_build_package_plugins_post= - set npm_package_scripts_build_package_all_docker= - set npm_package_scripts_build_package_all_prod= - set npm_package_scripts_build_package_plugins_pre_docker= - set npm_package_scripts_build_package_plugins_pre_prod= - set npm_package_scripts_build_package_all= - set npm_package_scripts_build_package_plugins_pre= - set npm_package_scripts_build_desktop= - set npm_package_scripts_build_desktop_timer= - set npm_package_scripts_build_gauzy_server= - set npm_package_scripts_build_gauzy_api_server= - set npm_package_scripts_build_gauzy_mcp_server= - set npm_package_scripts_build_package_gauzy_docker= - set npm_package_scripts_build_package_gauzy_prod= - set npm_package_scripts_build_integration_ui_plugins_docker= - set npm_package_scripts_build_package_api_docker= - set npm_package_scripts_build_integration_ui_plugins_prod= - set npm_package_scripts_build_package_api= - set npm_package_scripts_build_package_api_prod= - set npm_package_scripts_build_package_gauzy= - set npm_package_scripts_build_gauzy_server_linux_release_gh= - set npm_package_scripts_build_gauzy_server_linux_release= - set npm_package_scripts_build_gauzy_api_server_linux_release= - set npm_package_scripts_build_gauzy_api_server_linux_release_gh= - set npm_package_scripts_build_gauzy_mcp_server_linux_release_gh= - set npm_package_scripts_build_gauzy_mcp_server_linux_release= - set npm_package_scripts_build_gauzy_mcp_server_linux= - set npm_package_scripts_build_gauzy_api_server_linux= - set npm_package_scripts_build_gauzy_server_linux= - set npm_package_scripts_build_gauzy_mcp_server_windows_release_gh= - set npm_package_scripts_build_gauzy_mcp_server_windows_release= - set npm_package_scripts_build_gauzy_api_server_windows_release_gh= - set npm_package_scripts_build_gauzy_api_server_windows_release= - set npm_package_scripts_build_gauzy_server_windows_release_gh= - set npm_package_scripts_build_gauzy_server_windows_release= - set npm_package_scripts_build_gauzy_api_server_windows= - set npm_package_scripts_build_gauzy_mcp_server_windows= - set npm_package_scripts_build_gauzy_server_windows= - set npm_package_scripts_build_gauzy_api_server_linux_release_gh= + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:desktop-timer:windows:release:gh env: USE_HARD_LINKS: false @@ -302,4 +258,3 @@ jobs: DO_KEY_ID: ${{ secrets.DO_KEY_ID }} DO_SECRET_KEY: ${{ secrets.DO_SECRET_KEY }} NX_NO_CLOUD: true - Path: 'C:\hostedtoolcache\windows\node\20.18.1\x64;C:\npm\prefix;C:\Program Files\Git\cmd;C:\Program Files\Git\usr\bin;C:\hostedtoolcache\windows\Python\3.9.13\x64\Scripts;C:\hostedtoolcache\windows\Python\3.9.13\x64;C:\ProgramData\Chocolatey\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files\PowerShell\7\;C:\Program Files (x86)\NSIS\;C:\Program Files (x86)\WiX Toolset v3.14\bin;C:\Program Files\CMake\bin;C:\Users\runneradmin\AppData\Local\Microsoft\WindowsApps' diff --git a/.github/workflows/server-api-prod.yml b/.github/workflows/server-api-prod.yml index 2062c8b4212..1a7e3a25b73 100644 --- a/.github/workflows/server-api-prod.yml +++ b/.github/workflows/server-api-prod.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_API_SERVER_APP_DESCRIPTION: "Ever Gauzy API Server" DESKTOP_API_SERVER_APP_ID: "com.ever.gauzyapiserver" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Server + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:gauzy-api-server:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/server-api-stage.yml b/.github/workflows/server-api-stage.yml index 98b38bb8629..95febd46335 100644 --- a/.github/workflows/server-api-stage.yml +++ b/.github/workflows/server-api-stage.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_API_SERVER_APP_DESCRIPTION: "Ever Gauzy API Server" DESKTOP_API_SERVER_APP_ID: "com.ever.gauzyapiserver" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Server + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:gauzy-api-server:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/server-mcp-prod.yml b/.github/workflows/server-mcp-prod.yml index 6158d7232ac..20f33861485 100644 --- a/.github/workflows/server-mcp-prod.yml +++ b/.github/workflows/server-mcp-prod.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_MCP_SERVER_APP_DESCRIPTION: "Ever Gauzy MCP Server" DESKTOP_MCP_SERVER_APP_ID: "com.ever.gauzymcpserver" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Server + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:gauzy-mcp-server:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/server-mcp-stage.yml b/.github/workflows/server-mcp-stage.yml index 67fe8bd9587..49f47daf45c 100644 --- a/.github/workflows/server-mcp-stage.yml +++ b/.github/workflows/server-mcp-stage.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_MCP_SERVER_APP_DESCRIPTION: "Ever Gauzy MCP Server" DESKTOP_MCP_SERVER_APP_ID: "com.ever.gauzymcpserver" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Server + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:gauzy-mcp-server:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/server-prod.yml b/.github/workflows/server-prod.yml index 815e0aeef1b..298a8ba6e13 100644 --- a/.github/workflows/server-prod.yml +++ b/.github/workflows/server-prod.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_SERVER_APP_DESCRIPTION: "Ever Gauzy Server" DESKTOP_SERVER_APP_ID: "com.ever.gauzyserver" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Server + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:gauzy-server:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/server-stage.yml b/.github/workflows/server-stage.yml index f6d7435e73e..60d1673d982 100644 --- a/.github/workflows/server-stage.yml +++ b/.github/workflows/server-stage.yml @@ -26,7 +26,7 @@ jobs: - name: Install Node.js, NPM and Yarn uses: buildjet/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Change permissions @@ -39,10 +39,10 @@ jobs: run: python3 -m pip install packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -93,17 +93,17 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" - name: Fix node-gyp and Python run: python3 -m pip install --break-system-packages packaging setuptools - name: Install latest version of NPM - run: "sudo npm install -g npm@9" + run: "sudo npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "sudo npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "sudo npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -157,17 +157,49 @@ jobs: - name: Install Node.js, NPM and Yarn uses: actions/setup-node@v4 with: - node-version: 20.18.1 + node-version: 22.21.1 cache: "yarn" + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Fix node-gyp and Python run: python3 -m pip install packaging setuptools + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + - name: Install latest version of NPM - run: "npm install -g npm@9" + run: "npm install -g npm@10.9.4" - - name: Install node-gyp package - run: "npm install --quiet -g node-gyp@10.2.0" + - name: Install globally node-gyp, ts-node and nx packages + run: "npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0" + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" - name: Install Yarn dependencies run: "yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts" @@ -188,8 +220,30 @@ jobs: DESKTOP_SERVER_APP_DESCRIPTION: "Ever Gauzy Server" DESKTOP_SERVER_APP_ID: "com.ever.gauzyserver" + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + $npmGlobalBin = npm config get prefix + $localBin = Join-Path $PWD "node_modules\.bin" + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { echo $nodePath >> $env:GITHUB_PATH } + Write-Host "Added to GITHUB_PATH: $localBin, $npmGlobalBin, $yarnPath, $nodePath" + - name: Build Server + shell: powershell run: | + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" yarn build:gauzy-server:windows:release:gh env: USE_HARD_LINKS: false diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml new file mode 100644 index 00000000000..ed200a999aa --- /dev/null +++ b/.github/workflows/windows.yml @@ -0,0 +1,173 @@ +name: Desktop Build Windows Fixing + +on: + push: + branches: [win] + +concurrency: + group: ${{ github.ref }}-${{ github.workflow }} + cancel-in-progress: true + +jobs: + release-windows: + runs-on: ${{ matrix.os }} + + strategy: + matrix: + os: [warp-windows-latest-x64-16x] + + steps: + - name: Check out Git repository + uses: actions/checkout@v4 + + - name: Install Node.js, NPM and Yarn + uses: actions/setup-node@v4 + with: + node-version: 22.21.1 + cache: 'yarn' + + - name: Install Visual Studio 2022 Build Tools (VCTools) + shell: powershell + run: | + choco install -y visualstudio2022buildtools --execution-timeout=21600 --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional --passive --norestart" + + # ✅ Help node-gyp pick VS 2022 explicitly + - name: Configure node-gyp to use VS 2022 + shell: powershell + run: | + "GYP_MSVS_VERSION=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + "npm_config_msvs_version=2022" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Fix node-gyp and Python + run: python3 -m pip install packaging setuptools + + - name: Setup MSVC (VS 2022 dev env) + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + + - name: Install latest version of NPM + run: 'npm install -g npm@10.9.4' + + - name: Install globally node-gyp, ts-node and nx packages + run: 'npm install --quiet -g node-gyp@10.2.0 ts-node@10.9.2 nx@20.8.0' + + - name: Configure npm python for node-gyp + shell: powershell + run: | + $py = (Get-Command python.exe).Source + Write-Host "python is: $py" + "npm_config_python=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + "PYTHON=$py" | Out-File -FilePath $env:GITHUB_ENV -Append + + - name: Show tool versions + shell: powershell + run: | + node -v + npm -v + python --version + python -c "import sys; print(sys.executable)" + + - name: Install Yarn dependencies + run: 'yarn install --network-timeout 1000000 --frozen-lockfile --ignore-scripts' + + - name: Run Postinstall Manually + run: 'yarn postinstall.manual' + + - name: Bump version desktop timer app + uses: actions/github-script@v7 + with: + script: | + const script = require('./.scripts/bump-version-electron.js') + console.log(script.desktopTimer(false)) + env: + PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git' + DESKTOP_TIMER_APP_NAME: 'ever-gauzy-desktop-timer' + COMPANY_SITE_LINK: 'https://gauzy.co' + DESKTOP_TIMER_APP_DESCRIPTION: 'Ever Gauzy Desktop Timer' + DESKTOP_TIMER_APP_ID: 'com.ever.gauzydesktoptimer' + + - name: Print environment variables and their sizes + shell: powershell + run: | + foreach ($envVar in [System.Environment]::GetEnvironmentVariables().Keys) { + $value = [System.Environment]::GetEnvironmentVariable($envVar) + + if ($null -ne $value) { + $length = $value.Length + Write-Output "${envVar}: ${length}" + } + } + + - name: Print PATH var value + shell: powershell + run: | + $path = [System.Environment]::GetEnvironmentVariable('PATH') + Write-Output "PATH environment variable is:" + Write-Output $path + + - name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH + shell: powershell + run: | + # Get yarn and node directories + $yarnPath = (Get-Command yarn).Source | Split-Path -Parent + $nodePath = (Get-Command node).Source | Split-Path -Parent + + # Get npm global prefix (where global packages are installed) + $npmGlobalBin = npm config get prefix + + # Get the workspace's node_modules/.bin for local binaries (cross-env, ts-node, etc.) + $localBin = Join-Path $PWD "node_modules\.bin" + + # Add all paths to GITHUB_PATH for subprocess inheritance + echo $localBin >> $env:GITHUB_PATH + echo $npmGlobalBin >> $env:GITHUB_PATH + echo $yarnPath >> $env:GITHUB_PATH + if ($nodePath -ne $yarnPath) { + echo $nodePath >> $env:GITHUB_PATH + } + + Write-Host "Added to GITHUB_PATH:" + Write-Host " Local bin: $localBin" + Write-Host " npm global: $npmGlobalBin" + Write-Host " Yarn path: $yarnPath" + Write-Host " Node path: $nodePath" + + # Verify the binaries exist + Write-Host "" + Write-Host "Checking local binaries:" + if (Test-Path "$localBin\cross-env.cmd") { Write-Host " cross-env: found" } else { Write-Host " cross-env: NOT FOUND" } + if (Test-Path "$localBin\ts-node.cmd") { Write-Host " ts-node: found" } else { Write-Host " ts-node: NOT FOUND" } + if (Test-Path "$localBin\nx.cmd") { Write-Host " nx: found" } else { Write-Host " nx: NOT FOUND" } + + - name: Build Desktop Timer App + shell: powershell + run: | + # Print PATH for debugging + Write-Host "=== Current PATH ===" + $env:PATH -split ';' | ForEach-Object { Write-Host " $_" } + Write-Host "" + Write-Host "=== Command locations ===" + Write-Host "Node: $((Get-Command node -ErrorAction SilentlyContinue).Source)" + Write-Host "Yarn: $((Get-Command yarn -ErrorAction SilentlyContinue).Source)" + Write-Host "npx: $((Get-Command npx -ErrorAction SilentlyContinue).Source)" + Write-Host "ts-node: $((Get-Command ts-node -ErrorAction SilentlyContinue).Source)" + Write-Host "cross-env: $((Get-Command cross-env -ErrorAction SilentlyContinue).Source)" + Write-Host "nx: $((Get-Command nx -ErrorAction SilentlyContinue).Source)" + Write-Host "" + Write-Host "=== Starting build ===" + # Run the build + yarn build:desktop-timer:windows:release:gh + env: + USE_HARD_LINKS: false + GH_TOKEN: ${{ secrets.GH_TOKEN }} + EP_GH_IGNORE_TIME: true + SENTRY_DSN: ${{ secrets.SENTRY_DSN }} + SENTRY_TRACES_SAMPLE_RATE: '${{ secrets.SENTRY_TRACES_SAMPLE_RATE }}' + SENTRY_PROFILE_SAMPLE_RATE: '${{ secrets.SENTRY_PROFILE_SAMPLE_RATE }}' + SENTRY_HTTP_TRACING_ENABLED: '${{ secrets.SENTRY_HTTP_TRACING_ENABLED }}' + SENTRY_POSTGRES_TRACKING_ENABLED: '${{ secrets.SENTRY_POSTGRES_TRACKING_ENABLED }}' + SENTRY_PROFILING_ENABLED: '${{ secrets.SENTRY_PROFILING_ENABLED }}' + DO_KEY_ID: ${{ secrets.DO_KEY_ID }} + DO_SECRET_KEY: ${{ secrets.DO_SECRET_KEY }} + NX_NO_CLOUD: true diff --git a/.scripts/icon-utils/concrete-generators/desktop-icon-generator.ts b/.scripts/icon-utils/concrete-generators/desktop-icon-generator.ts index 30a4ee92591..4cbda4654ab 100644 --- a/.scripts/icon-utils/concrete-generators/desktop-icon-generator.ts +++ b/.scripts/icon-utils/concrete-generators/desktop-icon-generator.ts @@ -10,8 +10,7 @@ import { DesktopEnvironmentManager } from '../../electron-desktop-environment/de export class DesktopIconGenerator extends IconGenerator - implements IDesktopIconGenerator -{ + implements IDesktopIconGenerator { constructor() { super(); this.imageUrl = env.GAUZY_DESKTOP_LOGO_512X512; @@ -102,6 +101,8 @@ export class DesktopIconGenerator public async generateTrayIcon(originalImage: Jimp): Promise { const REF_SIZE = 16; + const colors = ['gray', 'normal']; + const grayColor = '#999999'; const scales = [1, 1.25, 1.33, 1.4, 1.5, 1.8, 2, 2.5, 3, 4, 5]; const pngFilePath = path.join( 'apps', @@ -111,28 +112,41 @@ export class DesktopIconGenerator 'icons', 'tray' ); - for (const scale of scales) { - const size = REF_SIZE * scale; - const icon = - scale === scales[0] ? 'icon.png' : `icon@${scale}x.png`; - await new Promise((resolve) => - originalImage - .clone() - .resize(size, size) - .write(path.join(pngFilePath, icon), () => { + for (const color of colors) { + for (const scale of scales) { + const size = REF_SIZE * scale; + const suffix = color === 'gray' ? '_gray' : ''; + const scalePart = scale === scales[0] ? '' : `@${scale}x`; + + const icon = `icon${scalePart}${suffix}.png`; + await new Promise((resolve) => { + const imgJimp = originalImage + .clone() + .resize(size, size) + if (color === 'gray') { + imgJimp.color([{ + apply: 'mix' as any, + params: [grayColor, 60] + }]) + imgJimp.grayscale(); + imgJimp.brightness(-0.1); + } + return imgJimp.write(path.join(pngFilePath, icon), () => { console.log( `✔ tray icon ${icon} generated successfully.` ); resolve(true); }) - ); + }); + } } + } public async generateMenuIcon(originalImage: Jimp): Promise { - const iconSizes = [ 512, 256, 192, 128, 96, 64, 48, 40, 32, 24, 20, 16]; + const iconSizes = [512, 256, 192, 128, 96, 64, 48, 40, 32, 24, 20, 16]; // Remove 512x512 pixels for windows apps - if(process.platform === 'win32') { + if (process.platform === 'win32') { iconSizes.shift(); } const destination = path.join( @@ -143,8 +157,8 @@ export class DesktopIconGenerator 'icons', 'menu' ); - for(const iconSize of iconSizes) { - const png = iconSize === iconSizes[0] ? 'icon.png' :`icon_${iconSize}x${iconSize}.png`; + for (const iconSize of iconSizes) { + const png = iconSize === iconSizes[0] ? 'icon.png' : `icon_${iconSize}x${iconSize}.png`; const menuIconFilePath = path.join(destination, png); await originalImage .clone() diff --git a/apps/agent/src/main/api.ts b/apps/agent/src/main/api.ts index 7a70748ce0a..fda3272fbec 100644 --- a/apps/agent/src/main/api.ts +++ b/apps/agent/src/main/api.ts @@ -1,5 +1,5 @@ import { LocalStore, TTimeSlot } from '@gauzy/desktop-lib'; -import { getAuthConfig, getApiBaseUrl, TAuthConfig, TEmployeeResponse, updateAuthConfig } from './util'; +import { getAuthConfig, getApiBaseUrl, TAuthConfig, TEmployeeResponse, updateAuthConfig, getProjectConfig } from './util'; import fetch, { HeadersInit } from 'node-fetch'; import * as moment from 'moment'; import * as fs from 'node:fs'; @@ -7,6 +7,7 @@ import * as FormData from 'form-data'; import { TimeLogSourceEnum, TimeLogType } from '@gauzy/desktop-activity'; import MainEvent from './events/events'; import { MAIN_EVENT, MAIN_EVENT_TYPE } from '../constant'; +import { TaskStatusEnum, IBaseTaskProperties, ITaskStatus, IPagination } from '@gauzy/contracts'; export interface ITimerResponse { deletedAt: any @@ -62,8 +63,7 @@ type UploadParams = { export type TResponseTimeSlot = { id?: string, - recordedAt?: string, - + recordedAt?: string } export type TResponseScreenshot = { @@ -144,11 +144,19 @@ export interface ITimeLogResp { isEdited: boolean } +export type TUpdateTaskStatusReq = { + title: string, + status: TaskStatusEnum, + organizationId: string, + tenantId: string +} + export class ApiService { static instance: ApiService; private mainEvent: MainEvent; private isLogout: boolean; + private statusProgress: ITaskStatus; constructor() { this.mainEvent = MainEvent.getInstance(); @@ -211,17 +219,18 @@ export class ApiService { } getTimeToggleParams(payload: TToggleParams): TTimerParams { + const projectConfig = getProjectConfig(); return { description: '', isBillable: true, logType: TimeLogType.TRACKED, - projectId: null, - taskId: null, + projectId: projectConfig.projectId, + taskId: projectConfig.taskId || null, source: TimeLogSourceEnum.DESKTOP, manualTimeSlot: null, organizationId: payload.organizationId, tenantId: payload.tenantId, - organizationContactId: payload.organizationContactId, + organizationContactId: payload.organizationContactId || projectConfig.organizationContactId || null, isRunning: true, version: null, startedAt: moment(payload.startedAt).utc().toISOString(), @@ -359,6 +368,54 @@ export class ApiService { return false; } + async isAuthenticated(): Promise { + const path = '/api/auth/authenticated'; + try { + const res = await this.get(path, {}); + if (res) { + return true; + } + return false; + } catch (error) { + return false; + } + } + + async getTask(taskId: string): Promise> { + const path = `/api/tasks/${taskId}`; + return this.get(path, {}); + } + + async updateTaskStatus(taskId: string, task: TUpdateTaskStatusReq) { + const path = `/api/tasks/${taskId}`; + await this.getTasksStatuses({ + tenantId: task.tenantId, + organizationId: task.organizationId + }); + + return this.put(path, { + ...task, + ...(this.statusProgress?.id ? { + taskStatusId: this.statusProgress.id + } : {}) + }); + } + + async getTasksStatuses({ + tenantId, + organizationId + }: { tenantId: string, organizationId: string }): Promise { + if (this.statusProgress) { + return; + } + const path = `/api/task-statuses`; + const taskStatuses: Partial> = await this.get(path, { + tenantId, + organizationId + }); + this.statusProgress = taskStatuses.items?.find((i) => i.value === TaskStatusEnum.IN_PROGRESS); + } + async request( path: string, options: { diff --git a/apps/agent/src/main/auth.ts b/apps/agent/src/main/auth.ts index eb81b0f0cf8..1b05b80d9a5 100644 --- a/apps/agent/src/main/auth.ts +++ b/apps/agent/src/main/auth.ts @@ -5,6 +5,9 @@ import { TranslateService } from '@gauzy/desktop-lib'; import AppWindow from './window-manager'; +import * as isOnline from 'is-online'; +import { ApiService } from './api'; +const apiService = ApiService.getInstance(); function getAuthConfig() { const authConfig: { userId: string; @@ -29,6 +32,15 @@ export async function checkUserAuthentication(rootPath: string): Promise false); + if (!online) { + return true; + } + + const isAuthenticated = await apiService.isAuthenticated(); + if (!isAuthenticated) { + return false; + } return true; } diff --git a/apps/agent/src/main/init/ipcMain.ts b/apps/agent/src/main/init/ipcMain.ts index 348f21e80f3..a195ebde7d6 100644 --- a/apps/agent/src/main/init/ipcMain.ts +++ b/apps/agent/src/main/init/ipcMain.ts @@ -15,7 +15,7 @@ import { pluginListeners, ProviderFactory, } from '@gauzy/desktop-lib'; -import { getApiBaseUrl, delaySync, getAuthConfig, getAppSetting } from '../util'; +import { getApiBaseUrl, delaySync, getAuthConfig, getAppSetting, updateProject } from '../util'; import { startServer } from './app'; import AppWindow, { WindowType } from '../window-manager'; import * as moment from 'moment'; @@ -321,7 +321,14 @@ export default function AppIpcMain() { appWindow.setWindowIsReady(WindowType.notificationWindow); }); - + ipcMain.handle('TASK_SELECTED', (_, data: { taskId: string; organizationId: string; projectId: string }) => { + updateProject({ + taskId: data.taskId ?? null, + organizationId: data.organizationId ?? null, + projectId: data.projectId ?? null + }); + return true; + }); pluginListeners(); } diff --git a/apps/agent/src/main/util.ts b/apps/agent/src/main/util.ts index 2d1c463d7e3..b2cb91a94b0 100644 --- a/apps/agent/src/main/util.ts +++ b/apps/agent/src/main/util.ts @@ -50,6 +50,12 @@ export type TInitialConfig = { isSetup: boolean } +export type TProjectConfig = { + projectId: string | null; + taskId: string | null; + organizationContactId: string | null; +} + export function resolveHtmlPath(htmlFileName: string, hash: string) { if (process.env.NODE_ENV === 'development') { const port = process.env.PORT || 4200; @@ -83,6 +89,11 @@ export function getAuthConfig(): TAuthConfig { return auth; } +export function getProjectConfig(): TProjectConfig { + const project: TProjectConfig = LocalStore.getStore('project'); + return project; +} + export function getScreen() { const displays = screen.getAllDisplays(); const cursor = screen.getCursorScreenPoint(); @@ -119,6 +130,17 @@ export function getInitialConfig(): Partial { return initialConfig; } +export function updateProject(project: { + projectId: string; + taskId: string; + organizationId: string; +}) { + LocalStore.updateConfigProject({ + projectId: project.projectId, + taskId: project.taskId + }); +} + export function getScreenshotSoundPath(): string { if (process.env.NODE_ENV === 'development') { return path.join(__dirname, '..', 'data', 'sound', 'snapshot-sound.wav'); diff --git a/apps/agent/src/main/workers/push-activities.ts b/apps/agent/src/main/workers/push-activities.ts index 0a5398c34c0..9225c18bd58 100644 --- a/apps/agent/src/main/workers/push-activities.ts +++ b/apps/agent/src/main/workers/push-activities.ts @@ -18,7 +18,7 @@ import { ITimerCallbackPayload } from '@gauzy/desktop-activity'; import { ApiService, TResponseTimeSlot } from '../api'; -import { getAuthConfig, TAuthConfig, getInitialConfig } from '../util'; +import { getAuthConfig, TAuthConfig, getInitialConfig, getProjectConfig } from '../util'; import * as moment from 'moment'; import { AgentLogger } from '../agent-logger'; import { environment } from '../../environments/environment'; @@ -26,6 +26,7 @@ import * as fs from 'node:fs'; import MainEvent from '../events/events'; import { MAIN_EVENT, MAIN_EVENT_TYPE } from '../../constant'; import { WorkerQueue } from '../queue/worker-queue'; +import { TaskStatusEnum } from '@gauzy/contracts'; type TParamsActivities = Omit & { recordedAt: string }; @@ -88,6 +89,9 @@ class PushActivities { (async () => { try { await this.syncTimer(job); + if (!job.data?.isStopped) { + await this.updateTaskStatus(); + } return cb(null); } catch (error) { job.attempts += 1; @@ -110,15 +114,19 @@ class PushActivities { await this.syncTimeSlot(job); return cb(null); } catch (error) { - await this.kbMouseActivityService.update({ - id: job.activityId, - isOffline: true - }); job.attempts += 1; - if (!job.isRetry) { - job.isRetry = true; - job.queue = 'time_slot_retry'; - this.workerQueue.desktopQueue.enqueueTimeSlot(job); + try { + await this.kbMouseActivityService.update({ + id: job.activityId, + isOffline: true + }); + if (!job.isRetry) { + job.isRetry = true; + job.queue = 'time_slot_retry'; + this.workerQueue.desktopQueue.enqueueTimeSlot(job); + } + } catch (error) { + console.error('TIMER_QUEUE_ERROR', error); } return cb(new Error(error.message)); } @@ -141,21 +149,25 @@ class PushActivities { return cb(null); } catch (error) { job.attempts += 1; - const screenshot = await this.screenshotService.saveAndReturn({ - timeslotId: job.data?.timeSlotId, - imagePath: job.data?.imagePath, - synced: false, - activityId: job.data?.activityId, - recordedAt: new Date(job.data?.recordedAt) - }); - if (!job.isRetry) { - job.isRetry = true; - job.queue = 'screenshot_retry'; - job.data = { - ...job.data, - id: screenshot.id + try { + const screenshot = await this.screenshotService.saveAndReturn({ + timeslotId: job.data?.timeSlotId, + imagePath: job.data?.imagePath, + synced: false, + activityId: job.data?.activityId, + recordedAt: new Date(job.data?.recordedAt) + }); + if (!job.isRetry) { + job.isRetry = true; + job.queue = 'screenshot_retry'; + job.data = { + ...job.data, + id: screenshot.id + } + this.workerQueue.desktopQueue.enqueueScreenshot(job); } - this.workerQueue.desktopQueue.enqueueScreenshot(job); + } catch (error) { + console.error('SCREENSHOT_QUEUE_ERR', error); } return cb(new Error(error.message)); } @@ -270,6 +282,29 @@ class PushActivities { ); } + async updateTaskStatus() { + try { + const authConfig = getAuthConfig(); + const projectConfig = getProjectConfig(); + if (!projectConfig?.taskId) { + return; + } + const taskStatus = await this.apiService.getTask(projectConfig.taskId); + if (taskStatus.status === TaskStatusEnum.IN_PROGRESS) { + return; + } + return this.apiService.updateTaskStatus(projectConfig.taskId, { + tenantId: authConfig?.user?.employee?.tenantId, + organizationId: authConfig?.user?.employee?.organizationId, + status: TaskStatusEnum.IN_PROGRESS, + title: taskStatus.title + }); + } catch (error) { + console.error('Failed update task status', error); + } + + } + async saveImage(recordedAt: string, images: string[], timeSlotId?: string) { try { const auth = getAuthConfig(); @@ -415,6 +450,7 @@ class PushActivities { if (!isAuthenticated) { return; } + const projectConfig = getProjectConfig(); const overall = this.getDurationOverAllSeconds(new Date(activities.timeStart), new Date(activities.timeEnd), activities.afkDuration); const duration = this.getDurationSeconds(new Date(activities.timeStart), new Date(activities.timeEnd)); return { @@ -427,7 +463,10 @@ class PushActivities { startedAt: moment(activities.timeStart).toISOString(), recordedAt: moment(activities.timeStart).toISOString(), activities: this.getActivities(activities, overall, auth), - employeeId: auth?.user?.employee?.id + employeeId: auth?.user?.employee?.id, + ...(projectConfig?.projectId ? { projectId: projectConfig?.projectId } : {}), + ...(projectConfig?.taskId ? { taskId: projectConfig?.taskId } : {}), + ...(projectConfig?.organizationContactId ? { organizationContactId: projectConfig?.organizationContactId } : {}) }; } diff --git a/apps/api/package.json b/apps/api/package.json index 896cb6b086e..7f6de28beb5 100644 --- a/apps/api/package.json +++ b/apps/api/package.json @@ -68,6 +68,7 @@ "@nestjs/cli": "^11.0.7", "@nestjs/schematics": "^11.0.5", "@nestjs/testing": "^11.0.0", + "cross-env": "^7.0.3", "nodemon": "^3.1.0", "ts-node": "^10.9.2", "typescript": "^5.8.3" diff --git a/apps/gauzy-e2e/package.json b/apps/gauzy-e2e/package.json index ec72aaaa0e2..b912e5ee82a 100644 --- a/apps/gauzy-e2e/package.json +++ b/apps/gauzy-e2e/package.json @@ -57,6 +57,8 @@ "@4tw/cypress-drag-drop": "^2.1.0", "@cypress/browserify-preprocessor": "^3.0.2", "@types/jest": "29.5.14", + "concurrently": "^5.3.0", + "cross-env": "^7.0.3", "cypress": "^9.4.1", "cypress-cucumber-preprocessor": "^4.3.1", "cypress-file-upload": "^5.0.8", @@ -69,7 +71,8 @@ "karma-cli": "^2.0.0", "karma-coverage-istanbul-reporter": "^3.0.3", "karma-jasmine": "^5.1.0", - "karma-jasmine-html-reporter": "^1.7.0" + "karma-jasmine-html-reporter": "^1.7.0", + "ts-node": "^10.9.2" }, "cypress-cucumber-preprocessor": { "nonGlobalStepDefinitions": true, diff --git a/packages/config/package.json b/packages/config/package.json index f6d66c23e21..ed11479b330 100644 --- a/packages/config/package.json +++ b/packages/config/package.json @@ -51,6 +51,7 @@ "@types/jest": "29.5.14", "@types/node": "^20.14.9", "cross-env": "^7.0.3", + "ts-node": "^10.9.2", "typescript": "^5.8.3" }, "keywords": [ diff --git a/packages/core/package.json b/packages/core/package.json index 0576247af8f..726923a3064 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -212,6 +212,7 @@ "supertest": "^6.0.1", "ts-jest": "29.1.1", "ts-node": "^10.9.2", + "cross-env": "^7.0.3", "tslint-config-prettier": "^1.18.0", "typescript": "^5.8.3" }, diff --git a/packages/core/project.json b/packages/core/project.json index 662615c8457..190e280ea3e 100644 --- a/packages/core/project.json +++ b/packages/core/project.json @@ -35,7 +35,7 @@ "serve": { "executor": "nx:run-commands", "options": { - "command": "nodemon --restartable rs --ignore .git --ignore node_modules/ --ignore dist/ --ignore coverage/ --ignore src/**/*.spec.ts --watch packages/core/src --exec \"yarn ts-node -r tsconfig-paths/register packages/core/src/lib/main.ts\" --env NODE_ENV=development --ext ts", + "command": "nodemon --restartable rs --ignore .git --ignore node_modules/ --ignore dist/ --ignore coverage/ --ignore src/**/*.spec.ts --watch packages/core/src --exec \"ts-node -r tsconfig-paths/register packages/core/src/lib/main.ts\" --env NODE_ENV=development --ext ts", "cwd": "." } }, diff --git a/packages/desktop-lib/src/lib/desktop-tray.ts b/packages/desktop-lib/src/lib/desktop-tray.ts index 651335eddfa..61fa8d1d093 100644 --- a/packages/desktop-lib/src/lib/desktop-tray.ts +++ b/packages/desktop-lib/src/lib/desktop-tray.ts @@ -5,6 +5,7 @@ import { handleLogoutDialog } from './desktop-ipc'; import { LocalStore } from './desktop-store'; import { User, UserService } from './offline'; import { TranslateService } from './translation'; +import * as path from 'node:path'; import TitleOptions = Electron.TitleOptions; export class TrayIcon { @@ -17,7 +18,10 @@ export class TrayIcon { const options: TitleOptions = { fontType: 'monospacedDigit' }; const appConfig = LocalStore.getStore('configs'); console.log('icon path', iconPath); - const iconNativePath = nativeImage.createFromPath(iconPath); + const iconDir = path.dirname(iconPath); + const grayIcon = path.join(iconDir, 'icon_gray.png'); + const normalIcon = path.join(iconDir, 'icon.png'); + const iconNativePath = nativeImage.createFromPath(grayIcon); iconNativePath.resize({ width: 16, height: 16 }); this.tray = new Tray(iconNativePath); this.tray.setTitle('--:--:--', options); @@ -275,6 +279,7 @@ export class TrayIcon { this.contextMenu[2].enabled = false; this.contextMenu[0].visible = true; this.contextMenu[3].enabled = true; + this.tray.setImage(nativeImage.createFromPath(normalIcon)); this.build(); }); @@ -282,6 +287,7 @@ export class TrayIcon { this.contextMenu[2].enabled = true; this.contextMenu[0].visible = false; this.contextMenu[3].enabled = false; + this.tray.setImage(nativeImage.createFromPath(grayIcon)); this.build(); }); diff --git a/packages/desktop-ui-lib/src/lib/always-on/always-on.component.html b/packages/desktop-ui-lib/src/lib/always-on/always-on.component.html index 948845328c1..b169a0562d6 100644 --- a/packages/desktop-ui-lib/src/lib/always-on/always-on.component.html +++ b/packages/desktop-ui-lib/src/lib/always-on/always-on.component.html @@ -13,12 +13,11 @@ {{ (counter$ | async)?.current }} Today {{ (counter$ | async)?.today }} +
- diff --git a/packages/desktop-ui-lib/src/lib/always-on/always-on.component.scss b/packages/desktop-ui-lib/src/lib/always-on/always-on.component.scss index fc5e7e0713e..9ad732ae3d4 100644 --- a/packages/desktop-ui-lib/src/lib/always-on/always-on.component.scss +++ b/packages/desktop-ui-lib/src/lib/always-on/always-on.component.scss @@ -143,15 +143,20 @@ button { text-align: left; .current-session { - font-size: 18px; + font-size: 16px; font-weight: bold; line-height: 1.2; + position: absolute; + top: 7px; } .today-time { - font-size: 12px; + font-size: 10px; opacity: 0.7; margin-top: 2px; + position: absolute; + top: 20px; + font-weight: bolder; } } diff --git a/packages/desktop-ui-lib/src/lib/time-tracker/task-table/table/task-table.component.ts b/packages/desktop-ui-lib/src/lib/time-tracker/task-table/table/task-table.component.ts index b8eee305186..856390e474b 100644 --- a/packages/desktop-ui-lib/src/lib/time-tracker/task-table/table/task-table.component.ts +++ b/packages/desktop-ui-lib/src/lib/time-tracker/task-table/table/task-table.component.ts @@ -24,10 +24,10 @@ import { SearchTermStore } from '../search/+state/search-term.store'; @UntilDestroy({ checkProperties: true }) @Component({ - selector: 'ngx-task-table', - templateUrl: './task-table.component.html', - styleUrls: ['./task-table.component.scss'], - standalone: false + selector: 'ngx-task-table', + templateUrl: './task-table.component.html', + styleUrls: ['./task-table.component.scss'], + standalone: false }) export class TaskTableComponent implements OnInit, AfterViewInit { private _smartTable: Angular2SmartTableComponent; @@ -61,7 +61,7 @@ export class TaskTableComponent implements OnInit, AfterViewInit { private readonly searchTermStore: SearchTermStore, private readonly taskCacheService: TaskCacheService, private readonly store: Store - ) {} + ) { } ngOnInit(): void { combineLatest([ this.teamSelectorService.selected$, @@ -99,6 +99,19 @@ export class TaskTableComponent implements OnInit, AfterViewInit { } else { const selectedRow = selectionEvent.data; this.handleSelectedTaskChange(selectedRow.id); + this.handleTimerTaskSelected(selectedRow); + } + } + + private async handleTimerTaskSelected(task: Record) { + try { + await this.electronService.ipcRenderer.invoke('TASK_SELECTED', { + projectId: task.taskStatus?.projectId, + taskId: task.id, + organizationId: task.organizationId + }); + } catch (error) { + console.error('Failed to send TASK_SELECTED event:', error); } } diff --git a/packages/desktop-window/src/lib/always-on.ts b/packages/desktop-window/src/lib/always-on.ts index a0aab2cc520..2e821a4acfc 100644 --- a/packages/desktop-window/src/lib/always-on.ts +++ b/packages/desktop-window/src/lib/always-on.ts @@ -21,7 +21,7 @@ export class AlwaysOn extends BaseWindow implements IBaseWindow { ) { if (isExpandMode) { AlwaysOn.WIDTH = 270; - AlwaysOn.HEIGHT = 90; + AlwaysOn.HEIGHT = 45; } super( diff --git a/packages/mcp-server/package.json b/packages/mcp-server/package.json index 1f54975a112..8101573feed 100644 --- a/packages/mcp-server/package.json +++ b/packages/mcp-server/package.json @@ -62,6 +62,7 @@ "@types/jsonwebtoken": "^9.0.10", "@types/express-session": "^1.18.2", "cross-env": "^7.0.3", + "ts-node": "^10.9.2", "typescript": "^5.8.3" }, "keywords": [ diff --git a/packages/ui-config/package.json b/packages/ui-config/package.json index 75108f29892..fa7582d88d7 100644 --- a/packages/ui-config/package.json +++ b/packages/ui-config/package.json @@ -34,6 +34,7 @@ "@types/jest": "29.5.14", "@types/node": "^20.14.9", "cross-env": "^7.0.3", + "ts-node": "^10.9.2", "jest-preset-angular": "14.5.5" }, "keywords": [ diff --git a/packages/ui-config/project.json b/packages/ui-config/project.json index 1cc8bf17d74..1b4ff91f2ff 100644 --- a/packages/ui-config/project.json +++ b/packages/ui-config/project.json @@ -33,10 +33,10 @@ "executor": "nx:run-commands", "configurations": { "production": { - "commands": ["yarn run config:prod"] + "commands": ["cross-env NODE_ENV=production ts-node ./.scripts/configure.ts --environment=prod"] }, "development": { - "commands": ["yarn run config:dev"] + "commands": ["cross-env NODE_ENV=development ts-node ./.scripts/configure.ts --environment=dev"] } }, "defaultConfiguration": "production" @@ -51,10 +51,10 @@ ], "configurations": { "production": { - "command": "cross-env NODE_ENV=production yarn ts-node packages/ui-config/scripts/replace-env-files.ts" + "command": "cross-env NODE_ENV=production ts-node packages/ui-config/scripts/replace-env-files.ts" }, "development": { - "command": "cross-env NODE_ENV=development yarn ts-node packages/ui-config/scripts/replace-env-files.ts" + "command": "cross-env NODE_ENV=development ts-node packages/ui-config/scripts/replace-env-files.ts" } }, "defaultConfiguration": "production" diff --git a/packages/ui-core/package.json b/packages/ui-core/package.json index 99b6f14ee5c..5dd62fb0ae9 100644 --- a/packages/ui-core/package.json +++ b/packages/ui-core/package.json @@ -112,6 +112,8 @@ "@types/ckeditor": "^4.9.10", "@types/jest": "29.5.14", "@types/node": "^20.14.9", + "cross-env": "^7.0.3", + "ts-node": "^10.9.2", "jest-preset-angular": "14.5.5" }, "keywords": [ diff --git a/packages/ui-core/project.json b/packages/ui-core/project.json index 21e03470159..aeda7d8cb53 100644 --- a/packages/ui-core/project.json +++ b/packages/ui-core/project.json @@ -35,10 +35,10 @@ "executor": "nx:run-commands", "configurations": { "production": { - "commands": ["yarn nx build ui-config --configuration=production"] + "commands": ["nx build ui-config --configuration=production"] }, "development": { - "commands": ["yarn nx build ui-config --configuration=development"] + "commands": ["nx build ui-config --configuration=development"] } }, "defaultConfiguration": "production" diff --git a/yarn.lock b/yarn.lock index bfc7709cb0d..fd2def677ea 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6503,11 +6503,12 @@ postgres-interval "4.0.2" "@modelcontextprotocol/sdk@^1.13.1": - version "1.15.1" - resolved "https://registry.yarnpkg.com/@modelcontextprotocol/sdk/-/sdk-1.15.1.tgz#30a235f91e144b62ef1810bc63679e423bac37ec" - integrity sha512-W/XlN9c528yYn+9MQkVjxiTPgPxoxt+oczfjHBDsJx0+59+O7B75Zhsp0B16Xbwbz8ANISDajh6+V7nIcPMc5w== + version "1.24.0" + resolved "https://registry.yarnpkg.com/@modelcontextprotocol/sdk/-/sdk-1.24.0.tgz#3bd1d539490d1d4228537ab815b8d854bc0e3143" + integrity sha512-D8h5KXY2vHFW8zTuxn2vuZGN0HGrQ5No6LkHwlEA9trVgNdPL3TF1dSqKA7Dny6BbBYKSW/rOBDXdC8KJAjUCg== dependencies: - ajv "^6.12.6" + ajv "^8.17.1" + ajv-formats "^3.0.1" content-type "^1.0.5" cors "^2.8.5" cross-spawn "^7.0.5" @@ -6515,10 +6516,11 @@ eventsource-parser "^3.0.0" express "^5.0.1" express-rate-limit "^7.5.0" + jose "^6.1.1" pkce-challenge "^5.0.0" raw-body "^3.0.0" - zod "^3.23.8" - zod-to-json-schema "^3.24.1" + zod "^3.25 || ^4.0" + zod-to-json-schema "^3.25.0" "@modern-js/node-bundle-require@2.65.1": version "2.65.1" @@ -13672,27 +13674,27 @@ dependencies: "@types/node" "*" -"@typescript-eslint/project-service@8.48.1": - version "8.48.1" - resolved "https://registry.yarnpkg.com/@typescript-eslint/project-service/-/project-service-8.48.1.tgz#cfe1741613b9112d85ae766de9e09b27a7d3f2f1" - integrity sha512-HQWSicah4s9z2/HifRPQ6b6R7G+SBx64JlFQpgSSHWPKdvCZX57XCbszg/bapbRsOEv42q5tayTYcEFpACcX1w== +"@typescript-eslint/project-service@8.49.0": + version "8.49.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/project-service/-/project-service-8.49.0.tgz#ce220525c88cb2d23792b391c07e14cb9697651a" + integrity sha512-/wJN0/DKkmRUMXjZUXYZpD1NEQzQAAn9QWfGwo+Ai8gnzqH7tvqS7oNVdTjKqOcPyVIdZdyCMoqN66Ia789e7g== dependencies: - "@typescript-eslint/tsconfig-utils" "^8.48.1" - "@typescript-eslint/types" "^8.48.1" + "@typescript-eslint/tsconfig-utils" "^8.49.0" + "@typescript-eslint/types" "^8.49.0" debug "^4.3.4" -"@typescript-eslint/scope-manager@8.48.1", "@typescript-eslint/scope-manager@^8.31.0": - version "8.48.1" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-8.48.1.tgz#8bc70643e7cca57864b1ff95dd350fc27756bec0" - integrity sha512-rj4vWQsytQbLxC5Bf4XwZ0/CKd362DkWMUkviT7DCS057SK64D5lH74sSGzhI6PDD2HCEq02xAP9cX68dYyg1w== +"@typescript-eslint/scope-manager@8.49.0", "@typescript-eslint/scope-manager@^8.31.0": + version "8.49.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-8.49.0.tgz#a3496765b57fb48035d671174552e462e5bffa63" + integrity sha512-npgS3zi+/30KSOkXNs0LQXtsg9ekZ8OISAOLGWA/ZOEn0ZH74Ginfl7foziV8DT+D98WfQ5Kopwqb/PZOaIJGg== dependencies: - "@typescript-eslint/types" "8.48.1" - "@typescript-eslint/visitor-keys" "8.48.1" + "@typescript-eslint/types" "8.49.0" + "@typescript-eslint/visitor-keys" "8.49.0" -"@typescript-eslint/tsconfig-utils@8.48.1", "@typescript-eslint/tsconfig-utils@^8.48.1": - version "8.48.1" - resolved "https://registry.yarnpkg.com/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.48.1.tgz#68139ce2d258f984e2b33a95389158f1212af646" - integrity sha512-k0Jhs4CpEffIBm6wPaCXBAD7jxBtrHjrSgtfCjUvPp9AZ78lXKdTR8fxyZO5y4vWNlOvYXRtngSZNSn+H53Jkw== +"@typescript-eslint/tsconfig-utils@8.49.0", "@typescript-eslint/tsconfig-utils@^8.49.0": + version "8.49.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.49.0.tgz#857777c8e35dd1e564505833d8043f544442fbf4" + integrity sha512-8prixNi1/6nawsRYxet4YOhnbW+W9FK/bQPxsGB1D3ZrDzbJ5FXw5XmzxZv82X3B+ZccuSxo/X8q9nQ+mFecWA== "@typescript-eslint/type-utils@^8.0.0": version "8.32.0" @@ -13709,10 +13711,10 @@ resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-8.32.0.tgz#a4a66b8876b8391970cf069b49572e43f1fc957a" integrity sha512-O5Id6tGadAZEMThM6L9HmVf5hQUXNSxLVKeGJYWNhhVseps/0LddMkp7//VDkzwJ69lPL0UmZdcZwggj9akJaA== -"@typescript-eslint/types@8.48.1", "@typescript-eslint/types@^8.48.1": - version "8.48.1" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-8.48.1.tgz#a9ff808f5f798f28767d5c0b015a88fa7ce46bd7" - integrity sha512-+fZ3LZNeiELGmimrujsDCT4CRIbq5oXdHe7chLiW8qzqyPMnn1puNstCrMNVAqwcl2FdIxkuJ4tOs/RFDBVc/Q== +"@typescript-eslint/types@8.49.0", "@typescript-eslint/types@^8.49.0": + version "8.49.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-8.49.0.tgz#c1bd3ebf956d9e5216396349ca23c58d74f06aee" + integrity sha512-e9k/fneezorUo6WShlQpMxXh8/8wfyc+biu6tnAqA81oWrEic0k21RHzP9uqqpyBBeBKu4T+Bsjy9/b8u7obXQ== "@typescript-eslint/typescript-estree@8.32.0": version "8.32.0" @@ -13728,15 +13730,15 @@ semver "^7.6.0" ts-api-utils "^2.1.0" -"@typescript-eslint/typescript-estree@8.48.1": - version "8.48.1" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-8.48.1.tgz#0d0e31fc47c5796c6463ab50cde19e1718d465b1" - integrity sha512-/9wQ4PqaefTK6POVTjJaYS0bynCgzh6ClJHGSBj06XEHjkfylzB+A3qvyaXnErEZSaxhIo4YdyBgq6j4RysxDg== +"@typescript-eslint/typescript-estree@8.49.0": + version "8.49.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-8.49.0.tgz#99c5a53275197ccb4e849786dad68344e9924135" + integrity sha512-jrLdRuAbPfPIdYNppHJ/D0wN+wwNfJ32YTAm10eJVsFmrVpXQnDWBn8niCSMlWjvml8jsce5E/O+86IQtTbJWA== dependencies: - "@typescript-eslint/project-service" "8.48.1" - "@typescript-eslint/tsconfig-utils" "8.48.1" - "@typescript-eslint/types" "8.48.1" - "@typescript-eslint/visitor-keys" "8.48.1" + "@typescript-eslint/project-service" "8.49.0" + "@typescript-eslint/tsconfig-utils" "8.49.0" + "@typescript-eslint/types" "8.49.0" + "@typescript-eslint/visitor-keys" "8.49.0" debug "^4.3.4" minimatch "^9.0.4" semver "^7.6.0" @@ -13744,21 +13746,21 @@ ts-api-utils "^2.1.0" "@typescript-eslint/utils@8.32.0", "@typescript-eslint/utils@^5.58.0", "@typescript-eslint/utils@^8.0.0", "@typescript-eslint/utils@^8.31.0": - version "8.48.1" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-8.48.1.tgz#6cf7b99e0943b33a983ef687b9a86b65578b5c32" - integrity sha512-fAnhLrDjiVfey5wwFRwrweyRlCmdz5ZxXz2G/4cLn0YDLjTapmN4gcCsTBR1N2rWnZSDeWpYtgLDsJt+FpmcwA== + version "8.49.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-8.49.0.tgz#43b3b91d30afd6f6114532cf0b228f1790f43aff" + integrity sha512-N3W7rJw7Rw+z1tRsHZbK395TWSYvufBXumYtEGzypgMUthlg0/hmCImeA8hgO2d2G4pd7ftpxxul2J8OdtdaFA== dependencies: "@eslint-community/eslint-utils" "^4.7.0" - "@typescript-eslint/scope-manager" "8.48.1" - "@typescript-eslint/types" "8.48.1" - "@typescript-eslint/typescript-estree" "8.48.1" + "@typescript-eslint/scope-manager" "8.49.0" + "@typescript-eslint/types" "8.49.0" + "@typescript-eslint/typescript-estree" "8.49.0" -"@typescript-eslint/visitor-keys@8.32.0", "@typescript-eslint/visitor-keys@8.48.1", "@typescript-eslint/visitor-keys@^8.31.0": - version "8.48.1" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-8.48.1.tgz#247d4fe6dcc044f45b7f1c15110bf95e5d73b334" - integrity sha512-BmxxndzEWhE4TIEEMBs8lP3MBWN3jFPs/p6gPm/wkv02o41hI6cq9AuSmGAaTTHPtA1FTi2jBre4A9rm5ZmX+Q== +"@typescript-eslint/visitor-keys@8.32.0", "@typescript-eslint/visitor-keys@8.49.0", "@typescript-eslint/visitor-keys@^8.31.0": + version "8.49.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-8.49.0.tgz#8e450cc502c0d285cad9e84d400cf349a85ced6c" + integrity sha512-LlKaciDe3GmZFphXIc79THF/YYBugZ7FS1pO581E/edlVVNbZKDy93evqmrfQ9/Y4uN0vVhX4iuchq26mK/iiA== dependencies: - "@typescript-eslint/types" "8.48.1" + "@typescript-eslint/types" "8.49.0" eslint-visitor-keys "^4.2.1" "@upwork/node-upwork-oauth2@^2.0.3": @@ -14358,7 +14360,7 @@ aggregate-error@^5.0.0: clean-stack "^5.2.0" indent-string "^5.0.0" -ajv-formats@3.0.1: +ajv-formats@3.0.1, ajv-formats@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/ajv-formats/-/ajv-formats-3.0.1.tgz#3d5dc762bca17679c3c2ea7e90ad6b7532309578" integrity sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ== @@ -14394,7 +14396,7 @@ ajv@8.17.1, ajv@^8.0.0, ajv@^8.0.1, ajv@^8.11.0, ajv@^8.12.0, ajv@^8.17.1, ajv@^ json-schema-traverse "^1.0.0" require-from-string "^2.0.2" -ajv@^6.10.0, ajv@^6.11.0, ajv@^6.12.0, ajv@^6.12.2, ajv@^6.12.3, ajv@^6.12.5, ajv@^6.12.6: +ajv@^6.10.0, ajv@^6.11.0, ajv@^6.12.0, ajv@^6.12.2, ajv@^6.12.3, ajv@^6.12.5: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== @@ -25802,10 +25804,10 @@ jose@^5.0.0: resolved "https://registry.yarnpkg.com/jose/-/jose-5.10.0.tgz#c37346a099d6467c401351a9a0c2161e0f52c4be" integrity sha512-s+3Al/p9g32Iq+oqXxkW//7jk2Vig6FF1CFqzVXoTUXt2qz89YWbL+OwS17NFYEvxC35n0FKeGO2LGYSxeM2Gg== -jose@^6.0.13: - version "6.0.13" - resolved "https://registry.yarnpkg.com/jose/-/jose-6.0.13.tgz#078563b07e9ab82f0ea6922eca589041e8278a22" - integrity sha512-Yms4GpbmdANamS51kKK6w4hRlKx8KTxbWyAAKT/MhUMtqbIqh5mb2HjhTNUbk7TFL8/MBB5zWSDohL7ed4k/UA== +jose@^6.0.13, jose@^6.1.1: + version "6.1.3" + resolved "https://registry.yarnpkg.com/jose/-/jose-6.1.3.tgz#8453d7be88af7bb7d64a0481d6a35a0145ba3ea5" + integrity sha512-0TpaTfihd4QMNwrz/ob2Bp7X04yuxJkjRGi4aKmOqwhov54i6u79oCv7T+C7lo70MKH6BesI3vscD1yb/yzKXQ== joycon@^3.1.1: version "3.1.1" @@ -40132,17 +40134,22 @@ zip-stream@^6.0.1: compress-commons "^6.0.2" readable-stream "^4.0.0" -zod-to-json-schema@^3.24.1: - version "3.24.6" - resolved "https://registry.yarnpkg.com/zod-to-json-schema/-/zod-to-json-schema-3.24.6.tgz#5920f020c4d2647edfbb954fa036082b92c9e12d" - integrity sha512-h/z3PKvcTcTetyjl1fkj79MHNEjm+HpD6NXheWjzOekY7kV+lwDYnHw+ivHkijnCSMz1yJaWBD9vu/Fcmk+vEg== +zod-to-json-schema@^3.25.0: + version "3.25.0" + resolved "https://registry.yarnpkg.com/zod-to-json-schema/-/zod-to-json-schema-3.25.0.tgz#df504c957c4fb0feff467c74d03e6aab0b013e1c" + integrity sha512-HvWtU2UG41LALjajJrML6uQejQhNJx+JBO9IflpSja4R03iNWfKXrj6W2h7ljuLyc1nKS+9yDyL/9tD1U/yBnQ== zod@4.1.11: version "4.1.11" resolved "https://registry.yarnpkg.com/zod/-/zod-4.1.11.tgz#4aab62f76cfd45e6c6166519ba31b2ea019f75f5" integrity sha512-WPsqwxITS2tzx1bzhIKsEs19ABD5vmCVa4xBo2tq/SrV4RNZtfws1EnCWQXM6yh8bD08a1idvkB5MZSBiZsjwg== -zod@^3.23.8, zod@^3.25.67: +"zod@^3.25 || ^4.0": + version "4.1.13" + resolved "https://registry.yarnpkg.com/zod/-/zod-4.1.13.tgz#93699a8afe937ba96badbb0ce8be6033c0a4b6b1" + integrity sha512-AvvthqfqrAhNH9dnfmrfKzX5upOdjUVJYFqNSlkmGf64gRaTzlPwz99IHYnVs28qYAybvAlBV+H7pn0saFY4Ig== + +zod@^3.25.67: version "3.25.76" resolved "https://registry.yarnpkg.com/zod/-/zod-3.25.76.tgz#26841c3f6fd22a6a2760e7ccb719179768471e34" integrity sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==