pages:
  image:
    name: pandoc/core
    entrypoint: ["/bin/sh", "-c"]
  script:
    - mkdir .public
    - cp default.css .public/
    - pandoc -f markdown -t html README.md -o ".public/index.html" -s -c default.css --metadata title="Fracatux" --mathjax
    - mv .public public
    - find public -type f -regex '.*\.\(htm\|html\|txt\|text\|js\|css\)$' -exec gzip -f -k {} \;
  artifacts:
    paths:
      - public
  rules:
    - if: '$CI_COMMIT_BRANCH == "main" || $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "main"'
      changes:
        - default.css
        - README.md