# Workflow for publishing to GitHub Pages. name: Deploy to GitHub Pages on: workflow_call: inputs: settings: required: true description: "The path to your Pelican settings file (`pelican`'s `--settings` option), for example: 'publishconf.py'" type: string requirements: required: false default: "pelican" description: "The Python requirements to install, for example to enable markdown and typogrify use: 'pelican[markdown] typogrify' or if you have a requirements file use: '-r requirements.txt'" type: string output-path: required: false default: "output/" description: "Where to output the generated files (`pelican`'s `--output` option)" type: string theme: required: false default: "" description: "The GitHub repo URL of a custom theme to use, for example: 'https://github.com/seanh/sidecar.git'" type: string python: required: false default: "3.12" description: "The version of Python to use, for example: '3.12' (to use the most recent version of Python 3.12, this is faster) or '3.12.1' (to use an exact version, slower)" type: string siteurl: required: false default: "" description: "The base URL of your web site (Pelican's SITEURL setting). If not passed this will default to the URL of your GitHub Pages site, which is correct in most cases." type: string feed_domain: required: false default: "" description: "The domain to be prepended to feed URLs (Pelican's FEED_DOMAIN setting). If not passed this will default to the URL of your GitHub Pages site, which is correct in most cases." type: string permissions: contents: read pages: write id-token: write concurrency: group: "pages" cancel-in-progress: false jobs: build: uses: "getpelican/pelican/.github/workflows/build.yml@main" with: settings: ${{ inputs.settings }} requirements: ${{ inputs.requirements }} output-path: ${{ inputs.output-path }} theme: ${{ inputs.theme }} python: ${{ inputs.python }} siteurl: ${{ inputs.siteurl }} feed_domain: ${{ inputs.feed_domain }} deploy: environment: name: github-pages url: ${{ steps.deployment.outputs.page_url }} runs-on: ubuntu-latest needs: build steps: - name: Deploy to GitHub Pages id: deployment uses: actions/deploy-pages@v4