Use marketplace git describe for tag #22
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish docs | ||
on: | ||
push: | ||
tags: # See PEP 440 for valid version format | ||
- "*.*.*" # For docs bump, use workflow_dispatch | ||
branches: | ||
- test_branch | ||
workflow_dispatch: # Manually trigger with 'Run workflow' button | ||
permissions: | ||
contents: write | ||
pull-requests: write | ||
issues: write | ||
repository-projects: write | ||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
env: | ||
REPO_OWNER: ${{ github.repository_owner }} | ||
permissions: | ||
contents: write | ||
issues: write | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
fetch-depth: 0 | ||
- name: Set up Python runtime | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.9 | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Setup - pip & config | ||
run: | | ||
pip install .[docs] | ||
git config user.name 'github-actions[bot]' && git config user.email 'github-actions[bot]@users.noreply.github.com' | ||
- name: Git describe # Get tags | ||
id: ghd | ||
uses: proudust/gh-describe@v2 | ||
- name: Deploy | ||
uses: | ||
Check failure on line 47 in .github/workflows/publish-docs.yml GitHub Actions / Publish docsInvalid workflow file
|
||
run: | # github.ref_name is branch name if dispatch | ||
FULL_VERSION=${{ steps.ghd.outputs.tag }} | ||
export MAJOR_VERSION=${FULL_VERSION:0:3} | ||
echo "OWNER: ${REPO_OWNER}. BUILD: ${MAJOR_VERSION}" | ||
bash ./docs/build-docs.sh push $REPO_OWNER | ||
env: | ||
USERNAME: github-actions[bot] | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |