Skip to content

feat(logging): Add proper VSCode Logging Output #25

feat(logging): Add proper VSCode Logging Output

feat(logging): Add proper VSCode Logging Output #25

Workflow file for this run

name: Build VS Code extension
on:
push:
branches: [master]
pull_request:
permissions:
# Write permissions needed for publishing the release
contents: write
pull-requests: write
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
build_vscode_ext:
name: Build VS Code extension
runs-on: ubuntu-latest
if: ${{ github.repository == 'bazel-contrib/vscode-bazel' }} # Allow CI-runs only for events from/to this repository
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install Node.js
uses: actions/setup-node@v6
with:
cache: "npm"
- name: Install buildifier
uses: ./.github/actions/install-buildifier
with:
version: "8.2.1"
- name: Install Javascript dependencies
run: npm ci
- name: Check formatting
run: npm run format-check
# Has to happen before `lint-check`, because we need the generated protobuf types
- name: Compile the extension
run: npm run compile
- name: Lint
run: npm run lint-check
- uses: bazel-contrib/setup-bazel@0.18.0
with:
bazelisk-cache: true
disk-cache: false
repository-cache: false
module-root: ${{ github.workspace }}/test/bazel_workspace
- name: Build Bazel workspace to assure it is working & warm up cache
run: bazel build //...
working-directory: ${{ github.workspace }}/test/bazel_workspace/
# Required for the test cases
- name: Install system dependencies
run: sudo apt install -y binutils rustfilt
- run: xvfb-run -a npm test
if: runner.os == 'Linux'
- name: Package VS Code extension
run: npm run package
- name: Upload Workflow Artifact
uses: actions/upload-artifact@v6
with:
name: vscode-bazel-prerelease.vsix
path: vscode-bazel-*.vsix
if-no-files-found: error
- uses: googleapis/release-please-action@v4
id: release
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
with:
release-type: node
- name: Upload Release Artifact
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' && steps.release.outputs.release_created }}
shell: bash
run: |
filename=`echo vscode-bazel-*.vsix`;
gh release upload ${{ steps.release.outputs.tag_name }} "$filename"
env:
GH_TOKEN: ${{ github.token }}