-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (35 loc) · 1 KB
/
deploy.yml
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
31
32
33
34
35
36
37
38
39
40
41
42
name: Deploy to tibrahimm.github.io
on:
push:
branches:
- master
jobs:
deploy:
runs-on: ubuntu-latest
steps:
# Check out source code
- name: Checkout
uses: actions/checkout@v3
# Set up Node.js
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: "18"
# Install dependencies
- name: Install dependencies
run: yarn install
# Build project
- name: Build
run: yarn build
# Test project
- name: Test
run: yarn test
# Deploy to target repo
- name: Deploy
env:
# You'll need to add this secret in your repo settings
GITHUB_TOKEN: ${{ secrets.DEPLOY_TOKEN }}
run: |
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
npx gh-pages -d dist -r https://${GITHUB_TOKEN}@github.com/t-ibrahimm/t-ibrahimm.github.io.git