Skip to content

Commit f50a032

Browse files
authored
Merge pull request #1593 from QwenLM/feat/support-insight-command
feat: Add insight command for personalized programming insights
2 parents a16b4d8 + 7cbebe9 commit f50a032

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+7706
-206
lines changed

.dockerignore

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Dependencies (npm ci installs fresh inside the container)
2+
node_modules
3+
**/node_modules
4+
5+
# Build artifacts (rebuilt from scratch inside the container)
6+
dist
7+
**/dist
8+
9+
# Version control
10+
.git

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ packages/*/coverage/
4747
# Generated files
4848
packages/cli/src/generated/
4949
packages/core/src/generated/
50+
packages/web-templates/src/generated/
5051
.integration-tests/
5152
packages/vscode-ide-companion/*.vsix
5253

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,4 @@ eslint.config.js
1818
gha-creds-*.json
1919
junit.xml
2020
Thumbs.db
21+
packages/cli/src/services/insight/templates/insightTemplate.ts

Dockerfile

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,12 @@ ENV PATH=$PATH:/usr/local/share/npm-global/bin
1919
COPY . /home/node/app
2020
WORKDIR /home/node/app
2121

22-
# Install dependencies and build packages
23-
# Use scripts/build.js which handles workspace dependencies in correct order
22+
# Install dependencies, build workspaces, bundle into a single distributable, and pack
2423
RUN npm ci \
2524
&& npm run build \
26-
&& npm pack -w @qwen-code/qwen-code --pack-destination ./packages/cli/dist \
27-
&& npm pack -w @qwen-code/qwen-code-core --pack-destination ./packages/core/dist
25+
&& npm run bundle \
26+
&& npm run prepare:package \
27+
&& cd dist && npm pack
2828

2929
# Runtime stage
3030
FROM docker.io/library/node:20-slim
@@ -61,9 +61,8 @@ RUN mkdir -p /usr/local/share/npm-global
6161
ENV NPM_CONFIG_PREFIX=/usr/local/share/npm-global
6262
ENV PATH=$PATH:/usr/local/share/npm-global/bin
6363

64-
# Copy built packages from builder stage
65-
COPY --from=builder /home/node/app/packages/cli/dist/*.tgz /tmp/
66-
COPY --from=builder /home/node/app/packages/core/dist/*.tgz /tmp/
64+
# Copy bundled package from builder stage
65+
COPY --from=builder /home/node/app/dist/*.tgz /tmp/
6766

6867
# Install built packages globally
6968
RUN npm install -g /tmp/*.tgz \

eslint.config.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -254,9 +254,12 @@ export default tseslint.config(
254254
'no-console': 'off',
255255
},
256256
},
257-
// Settings for export-html assets
257+
// Settings for web-templates assets
258258
{
259-
files: ['packages/cli/assets/export-html/**/*.{js,jsx,ts,tsx}'],
259+
files: [
260+
'packages/web-templates/src/**/*.{js,jsx,ts,tsx}',
261+
'packages/web-templates/*.mjs',
262+
],
260263
languageOptions: {
261264
globals: {
262265
...globals.browser,
@@ -271,6 +274,8 @@ export default tseslint.config(
271274
rules: {
272275
'react/react-in-jsx-scope': 'off',
273276
'react/prop-types': 'off',
277+
'no-console': 'off',
278+
'no-undef': 'off',
274279
},
275280
},
276281
// Prettier config must be last

integration-tests/terminal-capture/terminal-capture.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ export class TerminalCapture {
293293
await this.page.addScriptTag({ path: join(xtermDir, 'lib', 'xterm.js') });
294294

295295
// 4. Create xterm Terminal instance inside the page
296-
296+
297297
await this.page.evaluate(
298298
({ cols, rows, theme, fontSize, fontFamily }) => {
299299
const W = window as unknown as Record<string, unknown>;
@@ -312,7 +312,7 @@ export class TerminalCapture {
312312
});
313313

314314
const container = document.getElementById('xterm-container')!;
315-
315+
316316
term.open(container);
317317

318318
// Expose to outer scope

0 commit comments

Comments
 (0)