Skip to content

Commit 00ec57a

Browse files
authored
Merge pull request #799 from RooVetGit/cte/package-json-cleanup
Better organize package.json, optimize tasks.json, split extension and webview linting
2 parents b83442e + f913d56 commit 00ec57a

File tree

17 files changed

+6959
-4086
lines changed

17 files changed

+6959
-4086
lines changed

.eslintrc.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@
1717
"@typescript-eslint/semi": "off",
1818
"eqeqeq": "warn",
1919
"no-throw-literal": "warn",
20-
"semi": "off",
21-
"react-hooks/exhaustive-deps": "off"
20+
"semi": "off"
2221
},
2322
"ignorePatterns": ["out", "dist", "**/*.d.ts"]
2423
}

.github/workflows/code-qa.yml

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
branches: [main]
1010

1111
jobs:
12-
compile:
12+
qa:
1313
runs-on: ubuntu-latest
1414
steps:
1515
- name: Checkout code
@@ -21,12 +21,8 @@ jobs:
2121
cache: 'npm'
2222
- name: Install dependencies
2323
run: npm run install:all
24-
- name: Compile
25-
run: npm run compile
26-
- name: Check types
27-
run: npm run check-types
28-
- name: Lint
29-
run: npm run lint
24+
- name: Run lint, check types, and esbuild
25+
run: npm run qa
3026

3127
unit-test:
3228
runs-on: ubuntu-latest
@@ -70,9 +66,9 @@ jobs:
7066
with:
7167
node-version: '18'
7268
cache: 'npm'
73-
- name: Create env.integration file
74-
run: echo "OPENROUTER_API_KEY=${{ secrets.OPENROUTER_API_KEY }}" > .env.integration
69+
- name: Create env.e2e file
70+
run: echo "OPENROUTER_API_KEY=${{ secrets.OPENROUTER_API_KEY }}" > .env.e2e
7571
- name: Install dependencies
7672
run: npm run install:all
77-
- name: Run integration tests
78-
run: xvfb-run -a npm run test:integration
73+
- name: Run end-to-end tests
74+
run: xvfb-run -a npm run e2e

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
dist
22
out
3-
out-integration
3+
out-*
44
node_modules
55
coverage/
66

@@ -21,4 +21,4 @@ roo-cline-*.vsix
2121
docs/_site/
2222

2323
# Dotenv
24-
.env.integration
24+
.env.e2e

.husky/pre-commit

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,3 @@ if [ "$branch" = "main" ]; then
66
fi
77

88
npx lint-staged
9-
10-
npm run compile
11-
npm run lint
12-
npm run check-types

.husky/pre-push

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,14 @@ if [ "$branch" = "main" ]; then
55
exit 1
66
fi
77

8-
npm run compile
8+
npm run qa
99

10-
# Check for new changesets
10+
# Check for new changesets.
1111
NEW_CHANGESETS=$(find .changeset -name "*.md" ! -name "README.md" | wc -l | tr -d ' ')
1212
echo "Changeset files: $NEW_CHANGESETS"
13+
1314
if [ "$NEW_CHANGESETS" == "0" ]; then
1415
echo "-------------------------------------------------------------------------------------"
1516
echo "Changes detected. Please run 'npm run changeset' to create a changeset if applicable."
1617
echo "-------------------------------------------------------------------------------------"
17-
fi
18+
fi

.vscode-test.mjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
import { defineConfig } from '@vscode/test-cli';
66

77
export default defineConfig({
8-
label: 'integrationTest',
9-
files: 'out-integration/test/**/*.test.js',
8+
label: 'e2e',
9+
files: 'out-e2e/test/**/*.test.js',
1010
workspaceFolder: '.',
1111
mocha: {
1212
ui: 'tdd',

.vscode/launch.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"args": ["--extensionDevelopmentPath=${workspaceFolder}"],
1414
"sourceMaps": true,
1515
"outFiles": ["${workspaceFolder}/dist/**/*.js"],
16-
"preLaunchTask": "debug-mode",
16+
"preLaunchTask": "${defaultBuildTask}",
1717
"env": {
1818
"NODE_ENV": "development",
1919
"VSCODE_DEBUG_MODE": "true"

.vscode/tasks.json

Lines changed: 6 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -3,42 +3,15 @@
33
{
44
"version": "2.0.0",
55
"tasks": [
6-
{
7-
"label": "compile",
8-
"type": "npm",
9-
"script": "compile",
10-
"group": {
11-
"kind": "build",
12-
"isDefault": true
13-
},
14-
"presentation": {
15-
"reveal": "silent",
16-
"panel": "shared"
17-
},
18-
"problemMatcher": ["$tsc", "$eslint-stylish"]
19-
},
206
{
217
"label": "watch",
22-
"dependsOn": ["npm: build:webview", "npm: watch:tsc", "npm: watch:esbuild"],
8+
"dependsOn": ["npm: dev", "npm: watch:tsc", "npm: watch:esbuild"],
239
"presentation": {
2410
"reveal": "never"
2511
},
2612
"group": {
2713
"kind": "build",
28-
"isDefault": false
29-
}
30-
},
31-
{
32-
"label": "debug-mode",
33-
"dependsOn": ["compile", "npm: dev"],
34-
"group": {
35-
"kind": "build",
36-
"isDefault": false
37-
},
38-
"dependsOrder": "parallel",
39-
"presentation": {
40-
"reveal": "always",
41-
"panel": "new"
14+
"isDefault": true
4215
}
4316
},
4417
{
@@ -59,20 +32,8 @@
5932
},
6033
"isBackground": true,
6134
"presentation": {
62-
"group": "watch",
63-
"reveal": "never"
64-
}
65-
},
66-
{
67-
"label": "npm: build:webview",
68-
"type": "npm",
69-
"script": "build:webview",
70-
"group": "build",
71-
"problemMatcher": [],
72-
"isBackground": true,
73-
"presentation": {
74-
"group": "watch",
75-
"reveal": "never"
35+
"group": "webview-ui",
36+
"reveal": "always"
7637
}
7738
},
7839
{
@@ -84,7 +45,7 @@
8445
"isBackground": true,
8546
"presentation": {
8647
"group": "watch",
87-
"reveal": "never"
48+
"reveal": "always"
8849
}
8950
},
9051
{
@@ -96,7 +57,7 @@
9657
"isBackground": true,
9758
"presentation": {
9859
"group": "watch",
99-
"reveal": "never"
60+
"reveal": "always"
10061
}
10162
}
10263
]

package-lock.json

Lines changed: 18 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)