Skip to content

Commit

Permalink
ci: Move type-checking out of the build process (no-changelog) (n8n-i…
Browse files Browse the repository at this point in the history
  • Loading branch information
netroy authored Jun 13, 2024
1 parent ab29ba9 commit c8f0029
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 161 deletions.
4 changes: 1 addition & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"build": "turbo run build",
"build:backend": "pnpm --filter=!@n8n/chat --filter=!@n8n/codemirror-lang --filter=!n8n-design-system --filter=!n8n-editor-ui build",
"build:frontend": "pnpm --filter=@n8n/chat --filter=@n8n/codemirror-lang --filter=n8n-design-system --filter=n8n-editor-ui build",
"typecheck": "pnpm --filter=!@n8n/chat --filter=!@n8n/storybook --filter=!n8n-core --filter=!n8n-editor-ui --filter=!n8n-workflow --filter=!n8n typecheck",
"typecheck": "pnpm --filter=!@n8n/storybook --filter=!n8n-core --filter=!n8n-workflow --filter=!n8n typecheck",
"dev": "turbo run dev --parallel --filter=!n8n-design-system --filter=!@n8n/chat",
"dev:ai": "turbo run dev --parallel --filter=@n8n/nodes-langchain --filter=n8n --filter=n8n-core",
"clean": "turbo run clean --parallel",
Expand Down Expand Up @@ -58,7 +58,6 @@
"turbo": "1.13.3",
"typescript": "*",
"vite": "^5.2.12",
"vite-plugin-checker": "^0.6.4",
"vitest": "^1.6.0",
"vue-tsc": "^2.0.19"
},
Expand Down Expand Up @@ -86,7 +85,6 @@
"[email protected]": "patches/[email protected]",
"@types/[email protected]": "patches/@[email protected]",
"@types/[email protected]": "patches/@[email protected]",
"[email protected]": "patches/[email protected]",
"@types/[email protected]": "patches/@[email protected]"
}
}
Expand Down
24 changes: 9 additions & 15 deletions packages/@n8n/chat/vite.config.mts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { defineConfig } from 'vite';
import checker from 'vite-plugin-checker';
import { resolve } from 'path';
import vue from '@vitejs/plugin-vue';
import icons from 'unplugin-icons/vite';
Expand All @@ -8,21 +7,16 @@ import dts from 'vite-plugin-dts';
const includeVue = process.env.INCLUDE_VUE === 'true';
const srcPath = resolve(__dirname, 'src');

const plugins = [
vue(),
icons({
compiler: 'vue3',
autoInstall: true,
}),
dts(),
];
if (!process.env.VITEST) {
plugins.push(checker({ vueTsc: true }));
}

// https://vitejs.dev/config/
export default defineConfig({
plugins,
plugins: [
vue(),
icons({
compiler: 'vue3',
autoInstall: true,
}),
dts(),
],
resolve: {
alias: {
'@': srcPath,
Expand Down Expand Up @@ -52,7 +46,7 @@ export default defineConfig({
? {}
: {
vue: 'Vue',
},
},
},
},
},
Expand Down
10 changes: 2 additions & 8 deletions packages/design-system/vite.config.mts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import vue from '@vitejs/plugin-vue';
import { resolve } from 'path';
import { defineConfig, mergeConfig } from 'vite';
import checker from 'vite-plugin-checker';
import { type UserConfig } from 'vitest';
import { defineConfig as defineVitestConfig } from 'vitest/config';

Expand All @@ -19,7 +18,7 @@ export const vitestConfig = defineVitestConfig({
reporter: process.env.CI === 'true' ? 'cobertura' : 'text-summary',
all: true,
},
}
}
: {}),
css: {
modules: {
Expand All @@ -29,14 +28,9 @@ export const vitestConfig = defineVitestConfig({
},
}) as UserConfig;

const plugins = [vue()];
if (!process.env.VITEST) {
plugins.push(checker({ vueTsc: true }));
}

export default mergeConfig(
defineConfig({
plugins,
plugins: [vue()],
resolve: {
alias: {
'@': resolve(__dirname, 'src'),
Expand Down
8 changes: 0 additions & 8 deletions packages/editor-ui/vite.config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import vue from '@vitejs/plugin-vue';
import { resolve } from 'path';
import { defineConfig, mergeConfig } from 'vite';
import { sentryVitePlugin } from '@sentry/vite-plugin';
import checker from 'vite-plugin-checker';

import packageJSON from './package.json';
import { vitestConfig } from '../design-system/vite.config.mts';
Expand Down Expand Up @@ -78,13 +77,6 @@ const plugins = [
vue(),
];

if (!process.env.VITEST) {
plugins.push({
...checker({ vueTsc: true }),
apply: 'build'
});
}

const { SENTRY_AUTH_TOKEN: authToken, RELEASE: release } = process.env;
if (release && authToken) {
plugins.push(
Expand Down
13 changes: 0 additions & 13 deletions patches/[email protected]

This file was deleted.

114 changes: 0 additions & 114 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit c8f0029

Please sign in to comment.