The "Snorkell DocGen Client" GitHub Action is designed to automate the creation of documentation pull requests for recent merges into the main branch. This action interacts with the Snorkell service to generate and commit documentation changes directly to your repository.
To use this action in your workflow, add the following step to your .github/workflows
YAML file:
- name: Generate Documentation
uses: SingularityX-ai/snorkell-documentation-client@v1.0.0
with:
client_id: ${{ secrets.SNORKELL_CLIENT_ID }}
api_key: ${{ secrets.SNORKELL_API_KEY }}
branch_name: 'main'
client_id
: Your client ID for Snorkell. (Required)api_key
: API Key for Snorkell. (Required)branch_name
: Base Branch for the PR. (Required)
- Set up Python: The action sets up a Python environment.
- Download Script and Install Dependencies: It downloads the necessary script and installs dependencies.
- Prepare Commit Message: Formats the commit message for the pull request.
- Run Script: Executes the script to generate and commit the documentation.
- The script initiates documentation generation with the Snorkell service.
- It checks the status of documentation generation and prints updates.
- Handles exceptions and timeouts gracefully.