📝docs : 경로 변경 #24
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: API Docs Integration | |
on: | |
push: | |
branches: | |
- docs/#44 | |
jobs: | |
document: | |
runs-on: ubuntu-latest | |
steps: | |
# 프로젝트 코드를 가져옵니다. | |
- name: Checkout Code | |
uses: actions/checkout@v3 | |
with: | |
ref: 'docs/#44' | |
# - name: move to docs directory | |
# run: | | |
# cd ./noti-service/docs | |
- name: redoc-cli-github-action | |
uses: seeebiii/redoc-cli-github-action@v9 | |
with: | |
args: 'bundle ./noti-service/docs/noti.json --output ./noti-service/docs/index.html --ext html' | |
# - name: Rename Yaml Title & Desc | |
# run: | | |
# cat ./noti-service/docs/noti.yaml | |
# yq -i '.info.title = "PetStore Backend API Document for FrontEnd"' ./noti-service/docs/noti.yaml | |
# yq -i '.info.description = "Please contact Petstore backend if there are any issues with API"' ./noti-service/docs/noti.yaml | |
# - name: redoc-cli-github-action | |
# uses: seeebiii/redoc-cli-github-action@v9 | |
# with: | |
# args: 'build-docs ./noti-serivce/docs/noti.yaml --output ./noti-serivce/docs/api-docs.html' | |
- name: save build result to tmp dir | |
run: | | |
mkdir -p docs | |
mv ./noti-service/docs/index.html ./docs | |
- name: Install SSH Key | |
uses: webfactory/[email protected] | |
with: | |
ssh-private-key: ${{ secrets.DEPLOY_KEY }} | |
# - name: Commit and push build artifacts | |
# run: | | |
# git config --global user.name "DDonghyeo" | |
# git config --global user.email "[email protected]" | |
# git add . | |
# git commit -m "📝docs : Generate API Docs" | |
# git push https://[email protected]/WaitherTeam/Waither-BE.git HEAD:apiDocs | |
- name: Install SSH Key | |
uses: leigholiver/[email protected] | |
with: | |
source: ./docs/index.html | |
destination_folder: docs | |
destination_repo: WaitherTeam/WaitherTeam.github.io | |
destination_branch: main | |
deploy_key: ${{ secrets.DEPLOY_KEY }} |