|
1 | | -# GitHub Pages ke liye Static Content Deployment Workflow |
2 | | -name: Deploy Static Content to GitHub Pages |
| 1 | +# Simple workflow for deploying static content to GitHub Pages |
| 2 | +name: Deploy static content to Pages |
3 | 3 |
|
4 | 4 | on: |
| 5 | + # Runs on pushes targeting the default branch |
5 | 6 | push: |
6 | | - branches: ["main"] # Sirf 'main' branch pe push hone pe chalega |
7 | | - workflow_dispatch: # Manually Actions tab se bhi run kar sakte ho |
| 7 | + branches: ["main"] |
8 | 8 |
|
| 9 | + # Allows you to run this workflow manually from the Actions tab |
| 10 | + workflow_dispatch: |
| 11 | + |
| 12 | +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages |
9 | 13 | permissions: |
10 | 14 | contents: read |
11 | 15 | pages: write |
12 | 16 | id-token: write |
13 | 17 |
|
| 18 | +# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. |
| 19 | +# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. |
14 | 20 | concurrency: |
15 | 21 | group: "pages" |
16 | | - cancel-in-progress: false # Running deployment ko cancel nahi karega |
| 22 | + cancel-in-progress: false |
17 | 23 |
|
18 | 24 | jobs: |
| 25 | + # Single deploy job since we're just deploying |
19 | 26 | deploy: |
20 | 27 | environment: |
21 | 28 | name: github-pages |
22 | 29 | url: ${{ steps.deployment.outputs.page_url }} |
23 | 30 | runs-on: ubuntu-latest |
24 | | - |
25 | 31 | steps: |
26 | | - - name: Checkout Repository |
27 | | - uses: actions/checkout@v3 # Repository checkout karega |
28 | | - |
29 | | - - name: Setup GitHub Pages |
30 | | - uses: actions/configure-pages@v3 # GitHub Pages setup karega |
31 | | - |
32 | | - - name: Upload Build Files |
| 32 | + - name: Checkout |
| 33 | + uses: actions/checkout@v3 |
| 34 | + - name: Setup Pages |
| 35 | + uses: actions/configure-pages@v3 |
| 36 | + - name: Upload artifact |
33 | 37 | uses: actions/upload-pages-artifact@v2 |
34 | 38 | with: |
35 | | - path: '.' # Pura repository deploy karega |
36 | | - |
| 39 | + # Upload entire repository |
| 40 | + path: '.' |
37 | 41 | - name: Deploy to GitHub Pages |
38 | 42 | id: deployment |
39 | 43 | uses: actions/deploy-pages@v2 |
0 commit comments