Welcome to mirror list, hosted at ThFree Co, Russian Federation.

deploy.yml « workflows « .github - github.com/le0pard/pgtune.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: f1d699ea69da416d73324db8eb5d030803daa19f (plain)
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
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Build and Deploy

on:
  push:
    branches:
      - master

jobs:
  build-and-deploy:
    name: Build and Deploy
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v2
        with:
          persist-credentials: false

      - name: Install Ruby
        uses: ruby/setup-ruby@v1
        with:
          bundler-cache: true

      - name: Install Node.JS
        uses: actions/setup-node@v2
        with:
          check-latest: true
          cache: 'yarn'

      - name: Install Javascript dependencies
        run: yarn install --immutable

      - name: FE build cache cache
        uses: actions/cache@v2
        with:
          path: |
            tmp/cache
          key: ${{ runner.os }}-builder-cache-${{ hashFiles('**/yarn.lock') }}
          restore-keys: |
            ${{ runner.os }}-builder-cache-

      - name: Check lints
        run: yarn run lint

      - name: Check tests
        run: yarn run test

      - name: Build website
        run: bundle exec middleman build

      - name: Deploy 🚀
        uses: JamesIves/github-pages-deploy-action@v4.2.3
        with:
          token: ${{ secrets.GITHUB_TOKEN }}
          branch: gh-pages # The branch the action should deploy to.
          folder: build # The folder the action should deploy.