-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 84055a9
Showing
58 changed files
with
311,355 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
name: Build VS Code Extension | ||
|
||
on: | ||
push: | ||
branches: | ||
- "*" | ||
|
||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
build: | ||
name: "Build VS Code Extension" | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
platform: | ||
[ | ||
"win32-arm64", | ||
"win32-x64", | ||
"linux-arm64", | ||
"linux-x64", | ||
"linux-armhf", | ||
"alpine-x64", | ||
"darwin-x64", | ||
"darwin-arm64", | ||
"alpine-arm64", | ||
] | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: "20" | ||
|
||
- name: Install dependencies | ||
run: npm install | ||
|
||
- name: Checking Linting | ||
run: npm run lint | ||
|
||
- name: Compile Extension | ||
run: npm run package -- --target ${{ matrix.platform }} | ||
|
||
- name: Package extension | ||
run: npx vsce package --target ${{ matrix.platform }} --out "oopilot-${{ matrix.platform }}.vsix" | ||
|
||
- name: Upload extension vsix as artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: "oopilot-${{ matrix.platform }}.vsix" | ||
path: "oopilot-${{ matrix.platform }}.vsix" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
name: Release VS Code Extension | ||
|
||
permissions: | ||
contents: write | ||
|
||
on: | ||
release: | ||
types: [created] | ||
|
||
jobs: | ||
release-job: | ||
name: "Release VS Code Extension" | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
platform: | ||
[ | ||
"win32-arm64", | ||
"win32-x64", | ||
"linux-arm64", | ||
"linux-x64", | ||
"linux-armhf", | ||
"alpine-x64", | ||
"darwin-x64", | ||
"darwin-arm64", | ||
"alpine-arm64", | ||
] | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: "20" | ||
|
||
- name: Verify version match | ||
run: | | ||
# Get version from package.json | ||
PKG_VERSION=$(node -p "require('./package.json').version") | ||
# Get release version | ||
RELEASE_VERSION=${GITHUB_REF#refs/tags/} | ||
# Validate release tag format | ||
if ! [[ $RELEASE_VERSION =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then | ||
echo "Error: Invalid release tag format!" | ||
echo "Release tag must follow the format: 1.2.3 (MAJOR.MINOR.PATCH)" | ||
echo "Got: $RELEASE_VERSION" | ||
exit 1 | ||
fi | ||
# Validate package.json version format | ||
if ! [[ $PKG_VERSION =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then | ||
echo "Error: Invalid package.json version format!" | ||
echo "Version must follow SemVer format: 1.2.3 (MAJOR.MINOR.PATCH)" | ||
echo "Got: $PKG_VERSION" | ||
exit 1 | ||
fi | ||
echo "Package.json version: $PKG_VERSION" | ||
echo "Release version: $RELEASE_VERSION" | ||
# Check if package.json version matches release version | ||
if [ "$PKG_VERSION" != "$RELEASE_VERSION" ]; then | ||
echo "Error: Version mismatch!" | ||
echo "package.json version ($PKG_VERSION) does not match release version ($RELEASE_VERSION)" | ||
exit 1 | ||
fi | ||
- name: Install dependencies | ||
run: npm install | ||
|
||
- name: Checking Linting | ||
run: npm run lint | ||
|
||
- name: Compile Extension | ||
run: npm run package -- --target ${{ matrix.platform }} | ||
|
||
- name: Package extension | ||
run: npx vsce package --target ${{ matrix.platform }} --out "oopilot-${{ matrix.platform }}.vsix" | ||
|
||
- name: Upload extension vsix as artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: "oopilot-${{ matrix.platform }}.vsix" | ||
path: "oopilot-${{ matrix.platform }}.vsix" | ||
|
||
- name: Upload Release Assets | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
files: "oopilot-${{ matrix.platform }}.vsix" | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
# - name: Release to VS Code Marketplace | ||
# uses: nick-fields/retry@v3 | ||
# with: | ||
# timeout_minutes: 5 | ||
# max_attempts: 6 | ||
# retry_on: error | ||
# retry_wait_seconds: 10 | ||
# command: npx vsce publish --packagePath "oopilot-${{ matrix.platform }}.vsix" -p ${{ secrets.VSCODE_MARKETPLACE_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
out | ||
node_modules | ||
.vscode-test/ | ||
*.vsix | ||
.DS_Store | ||
launch_folder | ||
types/ | ||
extension.vsix | ||
extension.hash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"tabWidth": 2, | ||
"useTabs": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
// See http://go.microsoft.com/fwlink/?LinkId=827846 | ||
// for the documentation about the extensions.json format | ||
"recommendations": ["dbaeumer.vscode-eslint", "amodio.tsl-problem-matcher"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// A launch configuration that compiles the extension and then opens it inside a new window | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "Run Extension", | ||
"type": "extensionHost", | ||
"request": "launch", | ||
"args": [ | ||
"${workspaceFolder}/launch_folder", | ||
"--extensionDevelopmentPath=${workspaceFolder}", | ||
"--disable-extensions", | ||
"--enable-proposed-api=flexpilot.flexpilot-vscode-extension" | ||
], | ||
"outFiles": ["${workspaceFolder}/out/**/*.js"], | ||
"env": { | ||
"FLEXPILOT_DEV_MODE": "true" | ||
}, | ||
"preLaunchTask": "${defaultBuildTask}" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
{ | ||
"search.exclude": { "out": true }, | ||
"files.exclude": { "out": false }, | ||
"typescript.tsc.autoDetect": "off", | ||
"prettier.prettierPath": "./node_modules/prettier", | ||
"editor.formatOnSave": true, | ||
"[typescript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.indentSize": "tabSize", | ||
"editor.insertSpaces": true, | ||
"editor.tabSize": 2, | ||
"editor.codeActionsOnSave": { | ||
"source.organizeImports": "explicit" | ||
} | ||
}, | ||
"[javascript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.indentSize": "tabSize", | ||
"editor.insertSpaces": true, | ||
"editor.tabSize": 2, | ||
"editor.codeActionsOnSave": { | ||
"source.organizeImports": "explicit" | ||
} | ||
}, | ||
"[typescriptreact]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.indentSize": "tabSize", | ||
"editor.insertSpaces": true, | ||
"editor.tabSize": 2, | ||
"editor.codeActionsOnSave": { | ||
"source.organizeImports": "explicit" | ||
} | ||
}, | ||
"cSpell.words": [ | ||
"Codestral", | ||
"davinci", | ||
"flexpilot", | ||
"Groq", | ||
"groqcloud", | ||
"ISCM", | ||
"Kwargs", | ||
"machineid", | ||
"mistralai", | ||
"NOSONAR", | ||
"softprops", | ||
"uuidv" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
// See https://go.microsoft.com/fwlink/?LinkId=733558 | ||
// for the documentation about the tasks.json format | ||
{ | ||
"version": "2.0.0", | ||
"tasks": [ | ||
{ | ||
"type": "npm", | ||
"script": "watch", | ||
"problemMatcher": "$ts-webpack-watch", | ||
"isBackground": true, | ||
"presentation": { | ||
"reveal": "never", | ||
"group": "watchers" | ||
}, | ||
"group": { | ||
"kind": "build", | ||
"isDefault": true | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
.vscode/** | ||
.vscode-test/** | ||
node_modules/** | ||
src/** | ||
.gitignore | ||
.yarnrc | ||
webpack.config.js | ||
vsc-extension-quickstart.md | ||
**/tsconfig.json | ||
**/.eslintrc.json | ||
**/*.map | ||
**/*.ts | ||
**/.vscode-test.* | ||
.github | ||
launch_folder | ||
types | ||
build/** | ||
tokenizers/** | ||
.husky/** | ||
eslint.config.mjs |
Oops, something went wrong.