From fd586e58d97e4ac2d2448426cf6c4937b48c5660 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Wed, 4 Mar 2020 17:58:22 +0100 Subject: cargo xtask dist This builds the typescript extension --- .github/workflows/release.yaml | 43 ++++++++++++------------------------------ 1 file changed, 12 insertions(+), 31 deletions(-) (limited to '.github') diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index aef961671..f5a07c21f 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -41,19 +41,27 @@ jobs: target: x86_64-unknown-linux-musl override: true + - name: Create distribution dir + run: mkdir ./dist + - name: Build if: matrix.os == 'ubuntu-latest' run: cargo build --package rust-analyzer --bin rust-analyzer --release --target x86_64-unknown-linux-musl env: CC: clang + - name: Build VS Code extension + if: matrix.os == 'ubuntu-latest' && github.event_name == 'push' + run: cargo xtask dist + + - name: Build VS Code extension + if: matrix.os == 'ubuntu-latest' && github.event_name != 'push' + run: cargo xtask dist --nightly + - name: Build if: matrix.os != 'ubuntu-latest' run: cargo build --package rust-analyzer --bin rust-analyzer --release - - name: Create distribution dir - run: mkdir ./dist - - name: Copy binary if: matrix.os == 'ubuntu-latest' run: cp ./target/x86_64-unknown-linux-musl/release/rust-analyzer ./dist/rust-analyzer-linux && strip ./dist/rust-analyzer-linux @@ -72,33 +80,6 @@ jobs: name: server-${{ matrix.os }} path: ./dist - build-clients: - name: build-clients - runs-on: ubuntu-latest - steps: - - name: Checkout repository - uses: actions/checkout@v1 - - - name: Install Nodejs - uses: actions/setup-node@v1 - with: - node-version: 12.x - - - run: npm ci - working-directory: ./editors/code - - - run: npm run package --scripts-prepend-node-path - working-directory: ./editors/code - - - name: Copy vscode extension - run: mkdir -p ./dist/code && cp ./editors/code/rust-analyzer.vsix ./dist/ - - - name: Upload artifacts - uses: actions/upload-artifact@v1 - with: - name: editor-plugins - path: ./dist - make-release: name: make-release runs-on: ubuntu-latest @@ -150,4 +131,4 @@ jobs: if: github.event_name == 'push' working-directory: ./editors/code # token from https://dev.azure.com/rust-analyzer/ - run: npx vsce publish 0.1.$(date +%Y%m%d) --pat ${{ secrets.MARKETPLACE_TOKEN }} + run: npx vsce publish 0.1.$(date +%Y%m%d) --pat ${{ secrets.MARKETPLACE_TOKEN }} --packagePath ../../dist/rust-analyzer.vsix -- cgit v1.2.3