Skip to content
Merged

Stage #9326

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions .github/workflows/agent-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,12 +142,12 @@ jobs:
console.log(script.agent(true))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_AGENT_APP_NAME: 'gauzy-agent'
DESKTOP_AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
DESKTOP_AGENT_APP_REPO_OWNER: 'ever-co'
AGENT_APP_NAME: 'gauzy-agent'
AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
AGENT_APP_REPO_OWNER: 'ever-co'
COMPANY_SITE_LINK: 'https://gauzy.co'
DESKTOP_AGENT_APP_DESCRIPTION: 'Gauzy Agent'
DESKTOP_AGENT_APP_ID: 'com.ever.gauzyagent'
AGENT_APP_DESCRIPTION: 'Gauzy Agent'
AGENT_APP_ID: 'com.ever.gauzyagent'

- name: Build Agent
run: 'yarn build:agent:linux:release:gh:arm64'
Expand Down Expand Up @@ -427,12 +427,12 @@ jobs:
console.log(script.agent(true))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_AGENT_APP_NAME: 'gauzy-agent'
DESKTOP_AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
DESKTOP_AGENT_APP_REPO_OWNER: 'ever-co'
AGENT_APP_NAME: 'gauzy-agent'
AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
AGENT_APP_REPO_OWNER: 'ever-co'
COMPANY_SITE_LINK: 'https://gauzy.co'
DESKTOP_AGENT_APP_DESCRIPTION: 'Gauzy Agent'
DESKTOP_AGENT_APP_ID: 'com.ever.gauzyagent'
AGENT_APP_DESCRIPTION: 'Gauzy Agent'
AGENT_APP_ID: 'com.ever.gauzyagent'

- name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH
shell: powershell
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/agent-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,15 +139,15 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.agent(true))
console.log(script.agent(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_AGENT_APP_NAME: 'gauzy-agent'
DESKTOP_AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
DESKTOP_AGENT_APP_REPO_OWNER: 'ever-co'
AGENT_APP_NAME: 'gauzy-agent'
AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
AGENT_APP_REPO_OWNER: 'ever-co'
COMPANY_SITE_LINK: 'https://gauzy.co'
DESKTOP_AGENT_APP_DESCRIPTION: 'Gauzy Agent'
DESKTOP_AGENT_APP_ID: 'com.ever.gauzyagent'
AGENT_APP_DESCRIPTION: 'Gauzy Agent'
AGENT_APP_ID: 'com.ever.gauzyagent'

- name: Build Agent
run: 'yarn build:agent:linux:release:gh:arm64'
Expand Down Expand Up @@ -424,15 +424,15 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.agent(true))
console.log(script.agent(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_AGENT_APP_NAME: 'gauzy-agent'
DESKTOP_AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
DESKTOP_AGENT_APP_REPO_OWNER: 'ever-co'
AGENT_APP_NAME: 'gauzy-agent'
AGENT_APP_REPO_NAME: 'ever-gauzy-agent'
AGENT_APP_REPO_OWNER: 'ever-co'
COMPANY_SITE_LINK: 'https://gauzy.co'
DESKTOP_AGENT_APP_DESCRIPTION: 'Gauzy Agent'
DESKTOP_AGENT_APP_ID: 'com.ever.gauzyagent'
AGENT_APP_DESCRIPTION: 'Gauzy Agent'
AGENT_APP_ID: 'com.ever.gauzyagent'

- name: Add Yarn/Node/npm-global/node_modules to GITHUB_PATH
shell: powershell
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/desktop-app-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.desktop(true))
console.log(script.desktop(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_APP_NAME: 'gauzy-desktop'
Expand Down Expand Up @@ -424,7 +424,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.desktop(true))
console.log(script.desktop(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_APP_NAME: 'gauzy-desktop'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/desktop-timer-app-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.desktopTimer(true))
console.log(script.desktopTimer(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_TIMER_APP_NAME: 'gauzy-desktop-timer'
Expand Down Expand Up @@ -424,7 +424,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.desktopTimer(true))
console.log(script.desktopTimer(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_TIMER_APP_NAME: 'gauzy-desktop-timer'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/server-api-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.serverapi(true))
console.log(script.serverapi(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_API_SERVER_APP_NAME: 'gauzy-api-server'
Expand Down Expand Up @@ -424,7 +424,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.serverapi(true))
console.log(script.serverapi(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_API_SERVER_APP_NAME: 'gauzy-api-server'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/server-mcp-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.servermcp(true))
console.log(script.servermcp(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_MCP_SERVER_APP_NAME: 'gauzy-mcp-server'
Expand Down Expand Up @@ -424,7 +424,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.servermcp(true))
console.log(script.servermcp(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_MCP_SERVER_APP_NAME: 'gauzy-mcp-server'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/server-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.server(true))
console.log(script.server(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_SERVER_APP_NAME: 'gauzy-server'
Expand Down Expand Up @@ -424,7 +424,7 @@ jobs:
with:
script: |
const script = require('./.scripts/bump-version-electron.js')
console.log(script.server(true))
console.log(script.server(false))
env:
PROJECT_REPO: 'https://github.com/ever-co/ever-gauzy.git'
DESKTOP_SERVER_APP_NAME: 'gauzy-server'
Expand Down
26 changes: 21 additions & 5 deletions apps/agent/config/custom-webpack.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
require('webpack');
const webpack = require('webpack');
//Polyfill Node.js core modules in Webpack. This module is only needed for webpack 5+.
const TerserPlugin = require('terser-webpack-plugin');
//Polyfill Node.js core modules in Webpack. This module is only needed for webpack 5+.
Expand All @@ -17,13 +17,20 @@ if (isCircleEnv) {
}

module.exports = {
target: 'electron-renderer',
target: 'web',
resolve: {
mainFields: ['es2016', 'browser', 'module', 'main']
mainFields: ['es2016', 'browser', 'module', 'main'],
conditionNames: ['browser', 'import', 'default'],
fallback: {
crypto: require.resolve('crypto-browserify'),
stream: require.resolve('stream-browserify'),
util: require.resolve('util/'),
buffer: require.resolve('buffer/'),
process: require.resolve('process/browser')
}
Comment on lines +24 to +30
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P0] The fallback polyfills reference packages that don't exist in package.json (crypto-browserify, stream-browserify, util/, buffer/, process/browser). This will cause build failures when webpack tries to resolve these modules. Either add these packages to devDependencies or remove the fallback configuration if the target change to 'web' doesn't actually require polyfills.

Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/agent/config/custom-webpack.config.js
Line: 24:30

Comment:
[P0] The fallback polyfills reference packages that don't exist in package.json (`crypto-browserify`, `stream-browserify`, `util/`, `buffer/`, `process/browser`). This will cause build failures when webpack tries to resolve these modules. Either add these packages to devDependencies or remove the fallback configuration if the target change to 'web' doesn't actually require polyfills.

How can I resolve this? If you propose a fix, please make it concise.

},
optimization: {
concatenateModules: false,
// for now let's disable minimize in CircleCI
minimize: !isCircleCI,
minimizer: [
new TerserPlugin({
Expand All @@ -38,11 +45,20 @@ module.exports = {
]
},
externals: {
'electron-log': 'electron-log'
'electron-log': 'electron-log',
electron: 'commonjs electron'
},
plugins: [
new NodePolyfillPlugin({
excludeAliases: ['console']
}),
new webpack.ProvidePlugin({
process: 'process/browser',
Buffer: ['buffer', 'Buffer']
}),
// Define global as window for browser compatibility
new webpack.DefinePlugin({
global: 'globalThis'
})
],
output: {
Expand Down
8 changes: 5 additions & 3 deletions apps/gauzy/config/custom-webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,17 @@ module.exports = {
mainFields: ['es2016', 'browser', 'module', 'main']
},
optimization: {
concatenateModules: false,
concatenateModules: true, // Enable module concatenation for better performance
// for now let's disable minimize in CircleCI
minimize: !isCircleCI,
minimizer: [
new TerserPlugin({
parallel: isCircleEnv ? 2 : true,
parallel: isCircleEnv ? 2 : true, // Use all available CPUs
terserOptions: {
sourceMap: !isCircleEnv,
compress: true
compress: {
passes: 2 // Multiple passes for better minification
}
},
extractComments: !isCircleEnv
})
Expand Down
2 changes: 0 additions & 2 deletions apps/gauzy/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"executor": "@angular-builders/custom-webpack:browser",
"options": {
"preserveSymlinks": true,
"verbose": true,
"aot": true,
"customWebpackConfig": {
"path": "apps/gauzy/config/custom-webpack.config.js"
Expand Down Expand Up @@ -91,7 +90,6 @@
"namedChunks": false,
"ngswConfigPath": "apps/gauzy/ngsw-config.prod.json",
"aot": true,
"verbose": true,
"extractLicenses": true,
"vendorChunk": true,
"buildOptimizer": true,
Expand Down
14 changes: 12 additions & 2 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
},
"defaultProject": "gauzy",
"$schema": "./node_modules/nx/schemas/nx-schema.json",
"parallel": 1,
"parallel": 3,
"targetDefaults": {
"build": {
"cache": false,
Expand Down Expand Up @@ -159,7 +159,17 @@
]
},
"@angular-devkit/build-angular:application": {
"cache": false,
"cache": true,
"dependsOn": [
"^build"
],
"inputs": [
"production",
"^production"
]
},
"@angular-builders/custom-webpack:browser": {
"cache": true,
"dependsOn": [
"^build"
],
Expand Down
27 changes: 16 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,10 @@
"build:lerna": "yarn lerna run --parallel build",
"build:prod": "yarn build:package:all && concurrently --raw \"yarn build:api:prod\" \"yarn build:gauzy:prod\"",
"build:gauzy": "yarn run postinstall.web && yarn run config:dev && yarn ng build gauzy",
"build:gauzy:prod": "yarn run config:prod && yarn ng:prod build gauzy -c=production --prod --verbose",
"build:gauzy:prod:docker": "yarn run config:prod && yarn ng:docker build gauzy -c=production --prod --verbose",
"build:gauzy:prod:ci": "yarn run config:prod && yarn --frozen-lockfile --cache-folder ~/.cache/yarn ng:ci build gauzy -c=production --prod --verbose",
"build:gauzy:prod": "yarn run config:prod && yarn ng:prod build gauzy -c=production --prod",
"build:gauzy:prod:debug": "yarn run config:prod && yarn ng:prod build gauzy -c=production --prod --verbose",
"build:gauzy:prod:docker": "yarn run config:prod && yarn ng:docker build gauzy -c=production --prod",
"build:gauzy:prod:ci": "yarn run config:prod && yarn --frozen-lockfile --cache-folder ~/.cache/yarn ng:ci build gauzy -c=production --prod",
"build:api": "yarn ng build api --configuration=development",
"build:api:prod": "yarn ng:prod build api --configuration=production",
"build:api:prod:docker": "yarn ng:docker build api --configuration=production",
Expand Down Expand Up @@ -299,9 +300,9 @@
"build:package:api": "yarn run build:package:constants && yarn run build:package:contracts && yarn run build:package:common && yarn run build:package:utils && yarn run build:package:config && yarn run build:package:plugin && yarn run build:package:auth && yarn run build:package:core && yarn run build:package:plugins:post && yarn run build:package:plugin:integration-wakatime",
"build:package:api:prod": "yarn run build:package:constants:prod && yarn run build:package:contracts:prod && yarn run build:package:common:prod && yarn run build:package:utils:prod && yarn run build:package:config:prod && yarn run build:package:plugin:prod && yarn run build:package:auth:prod && yarn run build:package:core:prod && yarn run build:package:plugins:post:prod",
"build:package:api:docker": "yarn run build:package:constants:docker && yarn run build:package:contracts:docker && yarn run build:package:common:docker && yarn run build:package:utils:docker && yarn run build:package:config:docker && yarn run build:package:plugin:docker && yarn run build:package:auth:docker && yarn run build:package:core:docker && yarn run build:package:plugins:post:docker",
"build:package:gauzy": "yarn run build:package:constants && yarn run build:package:contracts && yarn run build:package:common && yarn run build:package:utils && yarn run build:package:config && yarn run build:package:plugin && yarn run build:package:auth && yarn run build:package:plugins:pre && yarn run build:package:core && yarn run build:package:plugins:post",
"build:package:gauzy:prod": "yarn run build:package:constants:prod && yarn run build:package:contracts:prod && yarn run build:package:common:prod && yarn run build:package:utils:prod && yarn run build:package:config:prod && yarn run build:package:plugin:prod && yarn run build:package:auth:prod && yarn run build:package:plugins:pre:prod && yarn run build:package:core:prod && yarn run build:package:plugins:post:prod",
"build:package:gauzy:docker": "yarn run build:package:constants:docker && yarn run build:package:contracts:docker && yarn run build:package:common:docker && yarn run build:package:utils:docker && yarn run build:package:config:docker && yarn run build:package:plugin:docker && yarn run build:package:auth:docker && yarn run build:package:plugins:pre:docker && yarn run build:package:core:docker && yarn run build:package:plugins:post:docker",
"build:package:gauzy": "yarn run build:package:constants && yarn run build:package:contracts && yarn run build:package:ui-config && yarn run build:package:ui-core && yarn run build:package:ui-auth && yarn run build:package:plugins:pre",
"build:package:gauzy:prod": "yarn run build:package:constants:prod && yarn run build:package:contracts:prod && yarn run build:package:ui-config:prod && yarn run build:package:ui-core:prod && yarn run build:package:ui-auth:prod && yarn run build:package:plugins:pre:prod",
"build:package:gauzy:docker": "yarn run build:package:constants:docker && yarn run build:package:contracts:docker && yarn run build:package:ui-config:docker && yarn run build:package:ui-core:docker && yarn run build:package:ui-auth:docker && yarn run build:package:plugins:pre:docker",
"build:package:desktop-activity": "cross-env NODE_ENV=development NODE_OPTIONS=--max-old-space-size=12288 yarn nx build desktop-activity",
"build:package:desktop-activity:prod": "cross-env NODE_ENV=production NODE_OPTIONS=--max-old-space-size=12288 yarn nx build desktop-activity",
"build:package:desktop-activity:docker": "cross-env NODE_ENV=production NODE_OPTIONS=--max-old-space-size=30000 yarn nx build desktop-activity",
Expand Down Expand Up @@ -643,6 +644,7 @@
"lighthouse": "^6.3.0",
"lint-staged": "^10.4.0",
"ng-packagr": "19.2.2",
"node-abi": "^3.78.0",
"node-gyp": "^10.2.0",
"npm-run-all": "^4.1.5",
"nx": "21.1.0",
Expand Down Expand Up @@ -674,8 +676,7 @@
"webpack-bundle-analyzer": "^4.10.2",
"webpack-cli": "^6.0.1",
"webpack-merge": "^6.0.1",
"webpack-node-externals": "^3.0.0",
"node-abi": "^3.78.0"
"webpack-node-externals": "^3.0.0"
},
"overrides": {
"prebuild": {
Expand All @@ -685,9 +686,13 @@
"locutus": "2.0.30"
},
"electron-rebuild": {
"node-abi": "3.78.0",
"@electron/rebuild/node-abi": "3.78.0",
"app-builder-lib/node-abi": "3.78.0"
"node-abi": "3.78.0"
},
"@electron/rebuild": {
"node-abi": "3.78.0"
},
"app-builder-lib": {
"node-abi": "3.78.0"
}
},
"engines": {
Expand Down
1 change: 1 addition & 0 deletions packages/constants/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
}
},
"tags": [],
"implicitDependencies": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
}
},
"tags": [],
"implicitDependencies": ["contracts", "config", "common"],
"implicitDependencies": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ export class AlwaysOnComponent implements OnInit, OnDestroy {
).subscribe();
this.checkAndRunTimer();
this.renderer.setStyle(document.body, 'background-color', 'transparent');
this.renderer.setStyle(document.body, 'overflow', 'hidden');
this.isRounded = true;
}
}
Expand Down
1 change: 1 addition & 0 deletions packages/plugins/camshot/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
}
},
"tags": [],
"implicitDependencies": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
Expand Down
1 change: 1 addition & 0 deletions packages/plugins/integration-activepieces/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
}
},
"tags": [],
"implicitDependencies": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
Expand Down
1 change: 1 addition & 0 deletions packages/plugins/integration-zapier/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
}
},
"tags": [],
"implicitDependencies": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
Expand Down
Loading