name: main
on: [push, pull_request]
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - run: npm install
      - uses: lannonbr/vsce-action@master
        with:
          args: "package -o vscode-R.vsix"
      - uses: actions/upload-artifact@v1
        with:
          name: vscode-R.vsix
          path: vscode-R.vsix
  eslint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: actions/setup-node@v1
        with:
          node-version: "13.x"
      - run: npm ci
      - name: Run eslint
        run: ./node_modules/.bin/eslint -c ./.eslintrc.js src/*.ts
  lintr:
    runs-on: ubuntu-latest
    container:
      image: rocker/tidyverse:latest
    steps:
      - uses: actions/checkout@v2
      - name: Install apt-get dependencies
        run: |
          apt-get update
          apt-get install git ssh curl bzip2 libffi6 libffi-dev -y
      - name: Install lintr
        run: |
          Rscript -e "install.packages('lintr', repos = 'https://cloud.r-project.org')"
        shell: bash
      - name: Running lintr
        run: |
          Rscript -e "lintr::lint_dir('./R')"
        shell: bash

name: main
on: [push, pull_request]
jobs:
  build:
    runs-on: ubuntu-latest
    env:
      VSIX_FILE: vscode-R.vsix
    steps:
      - uses: actions/checkout@v2
      - run: npm install
      - uses: lannonbr/vsce-action@master
        with:
          args: "package -o $VSIX_FILE"
      - uses: actions/upload-artifact@v1
        with:
          name: ${{ env.VSIX_FILE }}
          path: ${{ env.VSIX_FILE }}
  eslint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: actions/setup-node@v1
        with:
          node-version: "13.x"
      - run: npm ci
      - name: Run eslint
        run: ./node_modules/.bin/eslint -c ./.eslintrc.js src/*.ts
  lintr:
    runs-on: ubuntu-latest
    container:
      image: rocker/tidyverse:latest
    steps:
      - uses: actions/checkout@v2
      - name: Install apt-get dependencies
        run: |
          apt-get update
          apt-get install git ssh curl bzip2 libffi6 libffi-dev -y
      - name: Install lintr
        run: |
          Rscript -e "install.packages('lintr', repos = 'https://cloud.r-project.org')"
        shell: bash
      - name: Running lintr
        run: |
          Rscript -e "lintr::lint_dir('./R')"
        shell: bash

Use env to specify vsix file in github actions build
Use env to specify vsix file in github actions build
