Add time functions #115
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
# This is a basic workflow to help you get started with Actions | |
name: build and deploy docs | |
# Controls when the workflow will run | |
on: | |
# Triggers the workflow on push or pull request events but only for the "main" branch | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
release: | |
types: [published] | |
workflow_dispatch: | |
inputs: | |
deploy: | |
description: 'deploy?' | |
required: true | |
default: 'false' | |
type: choice | |
options: | |
- 'true' | |
- 'false' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
SPHINX_GITHUB_CHANGELOG_TOKEN: ${{ github.token }} | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v3 | |
- uses: ammaraskar/sphinx-action@master | |
with: | |
docs-folder: "docs/" | |
- uses: actions/upload-pages-artifact@v1 | |
with: | |
path: docs/build/html | |
deploy: | |
needs: build | |
if: (github.event.action == 'published') || (inputs.deploy == 'true') | |
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment | |
permissions: | |
pages: write # to deploy to Pages | |
id-token: write # to verify the deployment originates from an appropriate source | |
# Deploy to the github-pages environment | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
# Specify runner + deployment step | |
runs-on: ubuntu-latest | |
steps: | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v1 |