Skip to content

Commit 619d653

Browse files
committed
Initial commit
0 parents  commit 619d653

43 files changed

Lines changed: 8134 additions & 0 deletions

Some content is hidden

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

.devcontainer/Dockerfile

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
FROM mcr.microsoft.com/vscode/devcontainers/typescript-node:18
2+
3+
# Install additional global packages
4+
RUN npm install -g yo generator-code vsce
5+
6+
# [Optional] Install additional OS packages if needed
7+
RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
8+
&& apt-get -y install --no-install-recommends \
9+
libnss3 \
10+
libdbus-1-3 \
11+
libatk1.0-0 \
12+
libatk-bridge2.0-0 \
13+
libcups2 \
14+
libdrm2 \
15+
libgtk-3-0 \
16+
libgbm1 \
17+
libasound2 \
18+
xvfb \
19+
xauth \
20+
x11-utils \
21+
dbus-x11
22+
23+
# [Optional] Set the default user
24+
USER node
25+
26+
# [Optional] Set the default directory
27+
WORKDIR /workspace

.devcontainer/devcontainer.json

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"name": "VSCode Extension Development",
3+
"build": {
4+
"dockerfile": "Dockerfile"
5+
},
6+
"customizations": {
7+
"vscode": {
8+
"extensions": [
9+
"dbaeumer.vscode-eslint",
10+
"esbenp.prettier-vscode",
11+
"ms-vscode.vscode-typescript-tslint-plugin",
12+
"ms-vscode.extension-test-runner"
13+
],
14+
"settings": {
15+
"terminal.integrated.defaultProfile.linux": "bash"
16+
}
17+
}
18+
},
19+
"postCreateCommand": "npm install",
20+
"remoteUser": "node",
21+
"workspaceFolder": "/workspaces/vscode-virtual-include"
22+
}

.github/workflows/publish.yml

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: Publish VS Code Extension
2+
3+
permissions:
4+
contents: write
5+
6+
on:
7+
push:
8+
branches:
9+
- main
10+
tags:
11+
- "v*"
12+
pull_request:
13+
branches:
14+
- main
15+
16+
jobs:
17+
build:
18+
name: Build and Test
19+
runs-on: ubuntu-latest
20+
steps:
21+
- name: Checkout code
22+
uses: actions/checkout@v3
23+
24+
- name: Setup Node.js
25+
uses: actions/setup-node@v3
26+
with:
27+
node-version: "18"
28+
cache: "npm"
29+
30+
- name: Install dependencies
31+
run: npm ci
32+
33+
- name: Lint code
34+
run: npm run lint || echo "No lint script found"
35+
36+
- name: Run tests
37+
run: npm test || echo "No test script found"
38+
39+
publish:
40+
needs: build
41+
if: startsWith(github.ref, 'refs/tags/v')
42+
runs-on: ubuntu-latest
43+
steps:
44+
- name: Checkout code
45+
uses: actions/checkout@v3
46+
with:
47+
ref: ${{ github.ref }}
48+
49+
- name: Setup Node.js
50+
uses: actions/setup-node@v3
51+
with:
52+
node-version: "18"
53+
cache: "npm"
54+
55+
- name: Install dependencies
56+
run: npm ci
57+
58+
- name: Install specific vsce version
59+
run: npm install -g @vscode/vsce@3.3.2
60+
61+
- name: Publish with explicit version
62+
run: |
63+
# Get version from package.json
64+
CURRENT_VERSION=$(node -p "require('./package.json').version")
65+
66+
# Publish with explicit version
67+
vsce publish $CURRENT_VERSION -p ${{ secrets.VSCODE_MARKETPLACE_TOKEN }}

.gitignore

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
.DS_Store
2+
npm-debug.log
3+
Thumbs.db
4+
**/node_modules/
5+
**/dist/
6+
**/.vs/
7+
tsconfig.lsif.json
8+
*.lsif
9+
*.db
10+
*.tsbuildinfo
11+
**/test-workspace/
12+
**/.vscode-test/

.vscode-test.mjs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
import { defineConfig } from "@vscode/test-cli";
2+
3+
export default defineConfig({
4+
files: "dist/test/**/*.test.js",
5+
workspaceFolder: ".",
6+
extensionDevelopmentPath: ".",
7+
extensionTestsPath: "./dist/test/suite/index.js",
8+
launchArgs: ["--disable-gpu", "--disable-workspace-trust", "--no-sandbox"],
9+
});

.vscode/extensions.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"recommendations": [
3+
"dbaeumer.vscode-eslint",
4+
"esbenp.prettier-vscode",
5+
"amodio.tsl-problem-matcher",
6+
"ms-vscode.extension-test-runner"
7+
]
8+
}

.vscode/launch.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"version": "0.2.0",
3+
"configurations": [
4+
{
5+
"name": "Run Extension",
6+
"type": "extensionHost",
7+
"request": "launch",
8+
"args": ["--extensionDevelopmentPath=${workspaceFolder}"],
9+
"outFiles": ["${workspaceFolder}/dist/**/*.js"],
10+
"preLaunchTask": "${defaultBuildTask}"
11+
}
12+
]
13+
}

.vscode/settings.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"files.exclude": {
3+
"dist": false
4+
},
5+
"search.exclude": {
6+
"dist": true
7+
},
8+
"typescript.tsc.autoDetect": "off"
9+
}

.vscode/tasks.json

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
{
2+
"version": "2.0.0",
3+
"tasks": [
4+
{
5+
"type": "npm",
6+
"script": "build",
7+
"problemMatcher": ["$tsc"],
8+
"group": {
9+
"kind": "build",
10+
"isDefault": true
11+
},
12+
"label": "npm: build - compile to dist",
13+
"detail": "Compiles the project to the dist folder"
14+
},
15+
{
16+
"type": "npm",
17+
"script": "watch",
18+
"problemMatcher": "$ts-webpack-watch",
19+
"isBackground": true,
20+
"presentation": {
21+
"reveal": "never",
22+
"group": "watchers"
23+
},
24+
"group": "build"
25+
},
26+
{
27+
"type": "npm",
28+
"script": "watch-tests",
29+
"problemMatcher": "$tsc-watch",
30+
"isBackground": true,
31+
"presentation": {
32+
"reveal": "never",
33+
"group": "watchers"
34+
},
35+
"group": "build"
36+
},
37+
{
38+
"label": "tasks: watch-all",
39+
"dependsOn": ["npm: watch", "npm: watch-tests"],
40+
"problemMatcher": []
41+
}
42+
]
43+
}

.vscodeignore

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
.vscode/**
2+
.vscode-test/**
3+
node_modules/**
4+
test-workspace/**
5+
./devcontainer/**
6+
src/**
7+
.gitignore
8+
.yarnrc
9+
webpack.config.js
10+
vsc-extension-quickstart.md
11+
**/tsconfig.json
12+
**/eslint.config.mjs
13+
**/*.map
14+
**/*.ts
15+
**/.vscode-test.*

0 commit comments

Comments
 (0)