Skip to content

Commit b7900cc

Browse files
feat: Add Open VSX publishing to the release workflow (#18)
* feat: Add Open VSX publishing to the release workflow * chore: updated EditorConfig * chore: updated `cSpell.words` --------- Co-authored-by: Lokesh Garg <lokeshgargadv@gmail.com>
1 parent 58e77bc commit b7900cc

File tree

3 files changed

+34
-14
lines changed

3 files changed

+34
-14
lines changed

.editorconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ trim_trailing_whitespace = true
1212

1313
# TypeScript and JavaScript files
1414
[*.{ts,js,tsx,jsx}]
15-
indent_style = tab
16-
indent_size = 4
15+
indent_style = space
16+
indent_size = 2
1717

1818
# JSON files
1919
[*.json]

.github/workflows/release.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,26 @@ jobs:
223223
224224
echo "Extension published to VS Code Marketplace successfully!"
225225
226+
- name: Publish to Open VSX
227+
id: publish_ovsx
228+
continue-on-error: true
229+
env:
230+
OVSX_PAT: ${{ secrets.OVSX_PAT }}
231+
run: |
232+
if [ -z "$OVSX_PAT" ]; then
233+
echo "WARNING: OVSX_PAT secret not found"
234+
echo "Skipping Open VSX publish. To publish to Open VSX, add your Personal Access Token as a secret named OVSX_PAT"
235+
exit 0
236+
fi
237+
238+
# Install ovsx if not already installed
239+
npm install -g ovsx
240+
241+
# Publish to Open VSX
242+
ovsx publish -p $OVSX_PAT
243+
244+
echo "Extension published to Open VSX successfully!"
245+
226246
- name: Create GitHub Release
227247
id: github_release
228248
uses: actions/create-release@v1

.vscode/settings.json

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
// Place your settings in this file to overwrite default and user settings.
22
{
3-
"files.exclude": {
4-
"out": false // set this to true to hide the "out" folder with the compiled JS files
5-
},
6-
"search.exclude": {
7-
"out": true // set this to false to include "out" folder in search results
8-
},
9-
// Turn off tsc task auto detection since we have the necessary tasks as npm scripts
10-
"typescript.tsc.autoDetect": "off",
11-
"cssModulesIntellisense.aliases": {
12-
"~": "./src"
13-
},
14-
"cSpell.words": ["onig", "pcss", "styl", "vsctm"]
3+
"files.exclude": {
4+
"out": false // set this to true to hide the "out" folder with the compiled JS files
5+
},
6+
"search.exclude": {
7+
"out": true // set this to false to include "out" folder in search results
8+
},
9+
// Turn off tsc task auto detection since we have the necessary tasks as npm scripts
10+
"typescript.tsc.autoDetect": "off",
11+
"cssModulesIntellisense.aliases": {
12+
"~": "./src"
13+
},
14+
"cSpell.words": ["onig", "ovsx", "pcss", "styl", "vsctm"]
1515
}

0 commit comments

Comments
 (0)