Add SQL Support #22
Workflow file for this run
This file contains hidden or 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
| name: CI | |
| on: | |
| push: | |
| branches: [ master, main, develop ] | |
| pull_request: | |
| branches: [ master, main ] | |
| jobs: | |
| test: | |
| name: Test Extension | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Install xvfb and setup display | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y xvfb | |
| export DISPLAY=:99 | |
| Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 & | |
| sleep 5 | |
| echo "Display setup complete" | |
| - name: Verify display is working | |
| run: | | |
| export DISPLAY=:99 | |
| xdpyinfo > /dev/null 2>&1 && echo "Display is working" || echo "Display not working" | |
| - name: Run tests | |
| run: npm test | |
| env: | |
| DISPLAY: ':99' | |
| - name: Check for linting errors | |
| run: npm run lint || echo "No lint script found, skipping lint check" | |
| build: | |
| name: Build Extension | |
| runs-on: ubuntu-latest | |
| needs: test | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build extension | |
| run: | | |
| npm install -g @vscode/vsce | |
| vsce package --out pastum-extension.vsix | |
| - name: Upload extension artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: pastum-extension | |
| path: pastum-extension.vsix | |
| retention-days: 30 |