Skip to content

Create main.yml

Create main.yml #2

Workflow file for this run

name: Build Site
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Install dependencies
run: npm install
- name: Build
run: npm run build
- name: Commit changes
run: |
git config --global user.email "[email protected]"
git config --global user.name "98zi"
git pull
git add .
git commit -m "my commit"
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: main