-
Notifications
You must be signed in to change notification settings - Fork 0
30 lines (28 loc) · 813 Bytes
/
github-pages.yml
File metadata and controls
30 lines (28 loc) · 813 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
name: CI/CD
on:
push:
branches: [main]
jobs:
deployment:
runs-on: ubuntu-latest
environment: production
steps:
- name: Checkout
uses: actions/checkout@v3
with:
persist-credentials: false
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Install
run: npm ci
- name: Build and Deploy
env:
NODE_ENV: production
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git config --global user.name "Abhinav Chaturvedi"
git config --global user.email "abhinav.c@live.in"
git remote set-url origin "https://git:${GITHUB_TOKEN}@github.com/abhinavchat/abhinavchat-portfolio.git"
npm run deploy