Merged PR 1907: fix hugo reference #249
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: SmartIDE Docs | |
on: | |
push: | |
branches: | |
- main # Set a branch to deploy | |
paths: | |
- docs/** | |
- .github/workflows/smartide-docs-publish.yml | |
jobs: | |
deploy: | |
runs-on: ubuntu-20.04 | |
defaults: | |
run: | |
working-directory: ./docs | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive # Fetch Hugo themes (true OR recursive) | |
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod | |
- name: Setup Hugo | |
uses: peaceiris/actions-hugo@v2 | |
with: | |
hugo-version: '0.85.0' | |
extended: true | |
- name: Setup Node | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '14' | |
- name: Build | |
run: | | |
npm install | |
hugo --minify --verbose | |
- name: 📂 Sync files - smartide.cn | |
uses: SamKirkland/[email protected] | |
with: | |
server: ${{ secrets.FTP_CHINA_URL }} | |
username: ${{ secrets.FTP_CHINA_USERNAME }} | |
password: ${{ secrets.FTP_PASSWORD }} | |
local-dir: ./docs/public/ | |
server-dir: site/wwwroot/ | |
dangerous-clean-slate: false | |
- name: 📂 Sync files - smartide.dev | |
uses: SamKirkland/[email protected] | |
with: | |
server: ${{ secrets.FTP_GLOBAL_URL }} | |
username: ${{ secrets.FTP_GLOBAL_USERNAME }} | |
password: ${{ secrets.FTP_PASSWORD }} | |
local-dir: ./docs/public/ | |
server-dir: site/wwwroot/ | |
dangerous-clean-slate: false |