-
-
Notifications
You must be signed in to change notification settings - Fork 41
45 lines (39 loc) · 1.1 KB
/
docs.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
43
44
45
name: update docs
on:
push:
branches:
- master
jobs:
update-docs:
name: update docs
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.1
- name: Install dependencies
run: |
gem uninstall bundler
gem install bundler -v 2.3.4
bundle install
- name: Deploy Configuration
run: |
mkdir ~/.ssh
ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts
echo "${{ secrets.DOCS_DEPLOY_SSH_RSA }}" | base64 -d > ~/.ssh/id_rsa
chmod 400 ~/.ssh/id_rsa
- name: Build and Push
run: |
git clone git@github.com:YusukeIwaki/puppeteer-ruby-docs.git docs
rm -rf docs/*
bundle exec yardoc -o docs
cp puppeteer-ruby.png docs/
cd docs/
git add -A
git config user.name github
git config user.email github@example.com
git commit -m ${{ github.sha }}
git push origin master