Merge pull request #1026 from VaibhavChougule236/bugfix/authenticatio… #218
This file contains hidden or 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
| # Simple workflow for deploying static content to GitHub Pages | |
| name: Deploy to GitHub Pages | |
| on: | |
| push: | |
| # Runs on pushes targeting main and master | |
| branches: | |
| - main | |
| - master | |
| # Allows you to run this workflow manually from the Actions tab | |
| workflow_dispatch: | |
| permissions: | |
| contents: write # Required to allow pushing to gh-pages branch | |
| jobs: | |
| deploy: | |
| # Use the latest Ubuntu runner environment | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout the branch | |
| # Checkout the current branch (main or master) that triggered the workflow | |
| uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 1 # Fetch only the latest commit to speed up the workflow | |
| - name: Deploy to gh-pages branch in subfolder | |
| # Use peaceiris/actions-gh-pages to deploy the content | |
| uses: peaceiris/actions-gh-pages@v3 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} # GitHub automatically provides this token | |
| publish_dir: ./ # Path to the content you want to publish (root directory here) | |
| publish_branch: gh-pages # Target branch to publish to (must be enabled in GitHub Pages settings) | |
| destination_dir: ${{ github.ref_name }} # Store files in a folder named after the branch (e.g., /main/, /master/) |