Skip to content

Integrating segment-anything-services to ds-annotate #71

Integrating segment-anything-services to ds-annotate

Integrating segment-anything-services to ds-annotate #71

Workflow file for this run

# This workflow performs basic checks:
#
# 1. run a preparation step to install and cache node modules
# 2. once prep succeeds, lint and test run in parallel
#
# The checks only run on non-draft Pull Requests. They don't run on the main
# branch prior to deploy. It's recommended to use branch protection to avoid
# pushes straight to 'main'.
name: Checks
on:
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
env:
NODE: 16
jobs:
prep:
if: github.event.pull_request.draft == false
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v2
- name: Use Node.js ${{ env.NODE }}
uses: actions/setup-node@v1
with:
node-version: ${{ env.NODE }}
- name: Cache node_modules
uses: actions/cache@v2
id: cache-node-modules
with:
path: node_modules
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package.json') }}
- name: Install
run: yarn install
lint:
needs: prep
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Use Node.js ${{ env.NODE }}
uses: actions/setup-node@v1
with:
node-version: ${{ env.NODE }}
- name: Cache node_modules
uses: actions/cache@v2
id: cache-node-modules
with:
path: node_modules
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package.json') }}
- name: Install
run: yarn install
- name: Lint
run: yarn lint
test:
needs: prep
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Use Node.js ${{ env.NODE }}
uses: actions/setup-node@v1
with:
node-version: ${{ env.NODE }}
- name: Cache node_modules
uses: actions/cache@v2
id: cache-node-modules
with:
path: node_modules
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package.json') }}
- name: Install
run: yarn install
- name: Test
run: yarn test