diff --git a/.github/workflows/static.yml b/.github/workflows/static.yml new file mode 100644 index 0000000..5131d7c --- /dev/null +++ b/.github/workflows/static.yml @@ -0,0 +1,28 @@ +name: Notes_CI-CD_SCD_A2_Docs_Deploy + +on: + push: + branches: + - main + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Create deployment directory + run: mkdir -p ${{ github.workspace }}/docs/ + + - name: Copy README.md to deployment directory + run: cp README.md ${{ github.workspace }}/docs/ + + - name: Commit and push changes + run: | + cd ${{ github.workspace }}/docs/ + git config --local user.email "action@github.com" + git config --local user.name "GitHub Action" + git add README.md + git commit -m "Deploy README.md to GitHub Pages" + git push origin main