🔧 Chore: update repo checkout config in GitHub worlkflows

This commit is contained in:
Cell
2023-03-19 16:20:18 +08:00
parent 0ace5e2aad
commit 40cb2e412a
4 changed files with 22 additions and 16 deletions
+11 -10
View File
@@ -5,35 +5,36 @@ on:
branches: branches:
- master - master
paths: paths:
- 'docs' - "docs"
workflow_dispatch: workflow_dispatch:
jobs: jobs:
algolia-atomic: algolia-atomic:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v3 - name: Check out repository code
uses: actions/checkout@v3
with: with:
submodules: true # Fetch Hugo themes (true OR recursive) submodules: recursive # Fetch Hugo themes (true OR recursive)
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
- name: Setup Hugo - name: Setup Hugo
uses: peaceiris/actions-hugo@v2 uses: peaceiris/actions-hugo@v2
with: with:
hugo-version: 'latest' hugo-version: "latest"
extended: true extended: true
- name: Build - name: Build
run: | run: |
npm install npm install
npm run build npm run build
- name: Update Algolia Index (en) - name: Update Algolia Index (en)
env: env:
ALGOLIA_APP_ID: YKOM6PKLUY ALGOLIA_APP_ID: YKOM6PKLUY
ALGOLIA_ADMIN_KEY: ${{ secrets.ALGOLIA_ADMIN_KEY }} ALGOLIA_ADMIN_KEY: ${{ secrets.ALGOLIA_ADMIN_KEY }}
ALGOLIA_INDEX_NAME: 'index.en' ALGOLIA_INDEX_NAME: "index.en"
ALGOLIA_INDEX_FILE: './docs/public/index.json' ALGOLIA_INDEX_FILE: "./docs/public/index.json"
run: | run: |
npm run algolia npm run algolia
@@ -41,7 +42,7 @@ jobs:
env: env:
ALGOLIA_APP_ID: YKOM6PKLUY ALGOLIA_APP_ID: YKOM6PKLUY
ALGOLIA_ADMIN_KEY: ${{ secrets.ALGOLIA_ADMIN_KEY }} ALGOLIA_ADMIN_KEY: ${{ secrets.ALGOLIA_ADMIN_KEY }}
ALGOLIA_INDEX_NAME: 'index.zh-cn' ALGOLIA_INDEX_NAME: "index.zh-cn"
ALGOLIA_INDEX_FILE: './docs/public/zh-cn/index.json' ALGOLIA_INDEX_FILE: "./docs/public/zh-cn/index.json"
run: | run: |
npm run algolia npm run algolia
+7 -4
View File
@@ -19,7 +19,7 @@ on:
branches: branches:
- master - master
schedule: schedule:
- cron: '30 18 * * 5' - cron: "30 18 * * 5"
jobs: jobs:
analyze: analyze:
@@ -29,14 +29,17 @@ jobs:
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
language: [ 'javascript' ] language: [ "javascript" ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ] # CodeQL supports [ "cpp", "csharp", "go", "java", "javascript", "python" ]
# Learn more: # Learn more:
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed # https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
steps: steps:
- name: Checkout repository - name: Check out repository code
uses: actions/checkout@v3 uses: actions/checkout@v3
with:
submodules: true # Fetch Hugo themes (true OR recursive)
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
# Initializes the CodeQL tools for scanning. # Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL - name: Initialize CodeQL
+3 -1
View File
@@ -181,9 +181,11 @@ pre {
.lntd:first-child { .lntd:first-child {
min-width: 1.6rem; min-width: 1.6rem;
text-align: right; text-align: right;
position: sticky;
left: 0;
pre { pre {
padding-right: 0; // padding-right: 0;
} }
} }
// code content // code content
+1 -1
Submodule docs updated: d59eddda7b...174a8ee1dd