name: Build documentation

on:
  push:
    branches:
      - main
      - doc-builder*
      - v*-release

env:
  TRL_EXPERIMENTAL_SILENCE: 1

jobs:
   build:
    uses: huggingface/doc-builder/.github/workflows/build_main_documentation.yml@6108e850ae1cf2f71bb0815a600bcd50c39abfa7  # main
    with:
      commit_sha: ${{ github.sha }}
      package: trl
      version_tag_suffix: ""
    secrets:
      hf_token: ${{ secrets.HF_DOC_BUILD_PUSH }}
