mirror of
https://github.com/gradio-app/gradio.git
synced 2024-12-21 02:19:59 +08:00
61 lines
1.8 KiB
YAML
61 lines
1.8 KiB
YAML
name: 'install all deps'
|
|
description: 'Install all deps'
|
|
|
|
inputs:
|
|
always-install-pnpm:
|
|
description: 'Dictates whether or not we should install pnpm & dependencies, regardless of the cache'
|
|
default: 'false'
|
|
node_auth_token:
|
|
description: 'Node auth token'
|
|
default: ""
|
|
npm_token:
|
|
description: 'npm token'
|
|
default: ""
|
|
skip_build:
|
|
description: 'Skip build'
|
|
default: 'false'
|
|
|
|
runs:
|
|
using: "composite"
|
|
steps:
|
|
- name: Install Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: 3.8
|
|
cache: pip
|
|
cache-dependency-path: |
|
|
client/python/requirements.txt
|
|
requirements.txt
|
|
test/requirements.txt
|
|
- name: Create env
|
|
shell: bash
|
|
run: |
|
|
python -m pip install --upgrade virtualenv
|
|
python -m virtualenv venv
|
|
- uses: actions/cache@v3
|
|
id: cache
|
|
with:
|
|
path: |
|
|
venv/*
|
|
key: gradio-lib-ubuntu-latest-pip-${{ hashFiles('client/python/requirements.txt') }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('test/requirements.txt') }}
|
|
- name: Install Gradio and Client Libraries Locally (Linux)
|
|
shell: bash
|
|
run: |
|
|
. venv/bin/activate
|
|
python -m pip install -e client/python
|
|
python -m pip install -e .
|
|
- name: Install ffmpeg
|
|
uses: FedericoCarboni/setup-ffmpeg@v2
|
|
- name: install-frontend
|
|
uses: "./.github/actions/install-frontend-deps"
|
|
with:
|
|
always-install-pnpm: ${{ inputs.always-install-pnpm }}
|
|
node_auth_token: ${{ inputs.node_auth_token }}
|
|
npm_token: ${{ inputs.npm_token }}
|
|
skip_build: ${{ inputs.skip_build }}
|
|
- name: generate json
|
|
shell: bash
|
|
run: |
|
|
. venv/bin/activate
|
|
python js/_website/generate_jsons/generate.py
|