dms #1
@@ -8,28 +8,25 @@ jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: squidfunk/mkdocs-material:latest # includes Python, pip, MkDocs Material
|
||||
# Bigger container: Ubuntu with Python preinstalled
|
||||
image: ubuntu:22.04
|
||||
steps:
|
||||
# 1️⃣ Checkout the repository
|
||||
- name: Checkout repository
|
||||
run: git clone $GITEA_REPOSITORY /github/workspace
|
||||
uses: actions/checkout@v4
|
||||
|
||||
# 2️⃣ Optional: Install Node (only if you add JS plugins later)
|
||||
# - name: Install Node.js
|
||||
# run: |
|
||||
# curl -fsSL https://deb.nodesource.com/setup_18.x | bash -
|
||||
# apt-get install -y nodejs
|
||||
|
||||
# 3️⃣ Install any Python dependencies (optional if you have extra plugins)
|
||||
- name: Install Python dependencies
|
||||
# 2️⃣ Install Python, pip, and MkDocs
|
||||
- name: Setup Python and MkDocs
|
||||
run: |
|
||||
pip install -r requirements.txt || echo "No requirements.txt found, skipping"
|
||||
apt-get update
|
||||
apt-get install -y python3 python3-pip git curl
|
||||
pip3 install --upgrade pip
|
||||
pip3 install mkdocs mkdocs-material pymdown-extensions
|
||||
|
||||
# 4️⃣ Build the MkDocs site
|
||||
- name: Build MkDocs site
|
||||
run: |
|
||||
mkdocs build --site-dir /public
|
||||
# 3️⃣ Build MkDocs site to /public (mapped to Docker volume)
|
||||
- name: Build MkDocs
|
||||
run: mkdocs build --site-dir /public
|
||||
|
||||
# 5️⃣ List files to verify build
|
||||
# 4️⃣ Verify output
|
||||
- name: Verify output
|
||||
run: ls -l /public
|
||||
|
||||
Reference in New Issue
Block a user