ci(forgejo): install Node.js before actions/checkout@v4
Some checks failed
Some checks failed
This commit is contained in:
parent
98eebe62bf
commit
f08fc04e66
1 changed files with 47 additions and 4 deletions
|
|
@ -10,12 +10,23 @@ on:
|
|||
pull_request:
|
||||
branches: [main]
|
||||
|
||||
env:
|
||||
UV_BIN: /root/.local/bin/uv
|
||||
|
||||
jobs:
|
||||
lint:
|
||||
runs-on: docker-x64
|
||||
container:
|
||||
image: python:3.11-slim
|
||||
steps:
|
||||
- name: Install Node.js for actions/checkout
|
||||
run: |
|
||||
apt-get update
|
||||
apt-get install -y --no-install-recommends curl ca-certificates
|
||||
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
|
||||
apt-get install -y --no-install-recommends nodejs
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install system deps
|
||||
|
|
@ -27,7 +38,8 @@ jobs:
|
|||
- name: Install uv
|
||||
run: |
|
||||
curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||
ln -sf /root/.local/bin/uv /usr/local/bin/uv
|
||||
ln -sf /root/.local/bin/uvx /usr/local/bin/uvx
|
||||
|
||||
- name: Setup Python
|
||||
run: |
|
||||
|
|
@ -50,12 +62,20 @@ jobs:
|
|||
container:
|
||||
image: python:3.11-slim
|
||||
steps:
|
||||
- name: Install Node.js for actions/checkout
|
||||
run: |
|
||||
apt-get update && apt-get install -y --no-install-recommends curl ca-certificates
|
||||
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
|
||||
apt-get install -y --no-install-recommends nodejs
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install uv + setup
|
||||
run: |
|
||||
apt-get update && apt-get install -y --no-install-recommends curl ca-certificates && rm -rf /var/lib/apt/lists/*
|
||||
curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||
ln -sf /root/.local/bin/uv /usr/local/bin/uv
|
||||
ln -sf /root/.local/bin/uvx /usr/local/bin/uvx
|
||||
uv python install 3.11
|
||||
uv venv --python 3.11 .venv
|
||||
uv pip install --python .venv/bin/python -e ".[dev]"
|
||||
|
|
@ -67,12 +87,20 @@ jobs:
|
|||
container:
|
||||
image: python:3.11-slim
|
||||
steps:
|
||||
- name: Install Node.js for actions/checkout
|
||||
run: |
|
||||
apt-get update && apt-get install -y --no-install-recommends curl ca-certificates
|
||||
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
|
||||
apt-get install -y --no-install-recommends nodejs
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install uv + setup
|
||||
run: |
|
||||
apt-get update && apt-get install -y --no-install-recommends gcc libpq-dev curl ca-certificates && rm -rf /var/lib/apt/lists/*
|
||||
curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||
ln -sf /root/.local/bin/uv /usr/local/bin/uv
|
||||
ln -sf /root/.local/bin/uvx /usr/local/bin/uvx
|
||||
uv python install 3.11
|
||||
uv venv --python 3.11 .venv
|
||||
uv pip install --python .venv/bin/python -e ".[dev]"
|
||||
|
|
@ -85,6 +113,13 @@ jobs:
|
|||
container:
|
||||
image: python:3.11-slim
|
||||
steps:
|
||||
- name: Install Node.js for actions/checkout
|
||||
run: |
|
||||
apt-get update && apt-get install -y --no-install-recommends curl ca-certificates
|
||||
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
|
||||
apt-get install -y --no-install-recommends nodejs
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
|
@ -100,12 +135,20 @@ jobs:
|
|||
container:
|
||||
image: python:3.11-slim
|
||||
steps:
|
||||
- name: Install Node.js for actions/checkout
|
||||
run: |
|
||||
apt-get update && apt-get install -y --no-install-recommends curl ca-certificates
|
||||
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
|
||||
apt-get install -y --no-install-recommends nodejs
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install uv + setup
|
||||
run: |
|
||||
apt-get update && apt-get install -y --no-install-recommends curl ca-certificates && rm -rf /var/lib/apt/lists/*
|
||||
curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||
ln -sf /root/.local/bin/uv /usr/local/bin/uv
|
||||
ln -sf /root/.local/bin/uvx /usr/local/bin/uvx
|
||||
uv python install 3.11
|
||||
uv venv --python 3.11 .venv
|
||||
uv pip install --python .venv/bin/python bandit
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue