Add fluid-photo-1.md #262
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: Deploy | |
on: [push] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download Branch | |
uses: actions/checkout@v2 | |
- name: Update Submodule | |
run: | | |
git submodule init | |
git submodule update --remote | |
- name: Setup Node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: "14.x" | |
- name: Install NodeModules | |
run: | | |
rm -f .yarnclean yarn.lock | |
yarn --non-interactive --silent | |
yarn list --depth=0 | |
- name: Install Pandoc | |
run: sudo apt-get install -y pandoc | |
- name: Hexo Generate | |
run: | | |
rm -rf ./public | |
yarn run hexo clean | |
yarn run hexo generate | |
- name: Turnstyle | |
uses: softprops/turnstyle@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Setup qshell | |
uses: foxundermoon/setup-qshell@v5 | |
with: | |
version: '2.12.0' | |
- name: Upload to OSS | |
env: | |
QINIU_ACCESSKEY: ${{ secrets.QINIU_ACCESSKEY }} | |
QINIU_SECRETKEY: ${{ secrets.QINIU_SECRETKEY }} | |
QINIU_BUCKET: 'fluid-dev' | |
run: | | |
qshell account $QINIU_ACCESSKEY $QINIU_SECRETKEY action | |
qshell listbucket $QINIU_BUCKET -o bucket.txt | |
awk -F '\t' '!/docs\// && !/Key/ {print $1}' bucket.txt > to_delete.txt | |
qshell batchdelete -F'\t' --force $QINIU_BUCKET -i to_delete.txt | |
qshell qupload2 --src-dir=./public --bucket=$QINIU_BUCKET --overwrite | |
echo 'https://hexo.fluid-dev.com/' >> cdnrefresh.txt | |
qshell cdnrefresh --dirs -i cdnrefresh.txt |