Skip to content

ci install ffmpeg

ci install ffmpeg #4

Workflow file for this run

name: Deploy Docs
on:
push:
branches: [docs]
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow only one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
# Build job
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Pages
id: pages
uses: actions/configure-pages@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install mkdocs mkdocs-material
- name: Setup mkdocs
run: |
mkdir -p docs/
# Create mkdocs.yml
cat > mkdocs.yml << EOF
site_name: audio2anki
site_description: CLI tool to add language learning cards to Anki
site_author: Oliver Steele
repo_url: https://github.com/osteele/audio2anki
theme:
name: material
palette:
primary: indigo
accent: indigo
features:
- navigation.instant
- navigation.tracking
- navigation.expand
- navigation.indexes
- content.code.copy
markdown_extensions:
- pymdownx.highlight
- pymdownx.superfences
- pymdownx.inlinehilite
- pymdownx.tabbed
- pymdownx.critic
- admonition
nav:
- Home: 'index.md'
- Command Line: 'command-line.md'
- Development: 'development.md'
EOF
# Copy README.md to docs/index.md
cp README.md docs/index.md
# Copy DEVELOPMENT.md to docs/development.md
cp DEVELOPMENT.md docs/development.md
# Fix internal links to work with mkdocs
sed -i 's/\[Command Line Reference\](docs\/command-line.md)/\[Command Line Reference\](command-line.md)/g' docs/index.md
sed -i 's/\[Development Guide\](DEVELOPMENT.md)/\[Development Guide\](development.md)/g' docs/index.md
- name: Build with MkDocs
run: mkdocs build
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./site
# Deployment job
deploy:
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4