mirror of
https://github.com/nonebot/nonebot2.git
synced 2024-11-28 16:16:21 +08:00
32 lines
739 B
YAML
32 lines
739 B
YAML
name: Setup Python
|
|
description: Setup Python
|
|
|
|
inputs:
|
|
python-version:
|
|
description: Python version
|
|
required: false
|
|
default: "3.10"
|
|
|
|
runs:
|
|
using: "composite"
|
|
steps:
|
|
- id: python
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: ${{ inputs.python-version }}
|
|
architecture: "x64"
|
|
|
|
- uses: Gr1N/setup-poetry@v7
|
|
|
|
- id: poetry-cache
|
|
run: echo "::set-output name=dir::$(poetry config virtualenvs.path)"
|
|
shell: bash
|
|
|
|
- uses: actions/cache@v2
|
|
with:
|
|
path: ${{ steps.poetry-cache.outputs.dir }}
|
|
key: ${{ runner.os }}-poetry-${{ steps.python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
|
|
|
|
- run: poetry install -E all
|
|
shell: bash
|