mirror of
https://github.com/eunomia-bpf/bpf-developer-tutorial.git
synced 2026-02-03 02:04:30 +08:00
Update trigger-sync.yml
This commit is contained in:
34
.github/workflows/trigger-sync.yml
vendored
34
.github/workflows/trigger-sync.yml
vendored
@@ -18,43 +18,13 @@ jobs:
|
||||
ref: main
|
||||
path: ./.
|
||||
|
||||
- name: Checkout main repository
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
repository: ${{ github.repository_owner }}/eunomia-bpf
|
||||
ref: master
|
||||
path: eunomia-bpf
|
||||
|
||||
- name: Checkout this repository
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
repository: ${{ github.repository_owner }}/bpf-developer-tutorial
|
||||
ref: ${{ github.ref }}
|
||||
path: tutorial
|
||||
|
||||
- name: Change suffix
|
||||
run: |
|
||||
find ./tutorial -type f -name "*.md" ! -name "*_en*" -exec bash -c 'mv "$1" "${1%.md}.zh.md"' bash {} \;
|
||||
find ./tutorial -type f -name "*_en*.md" -exec bash -c 'mv "$1" "${1//_en/}"' bash {} \;
|
||||
|
||||
- name: Merge changes
|
||||
run: |
|
||||
cp -rf eunomia-bpf/documents/src docs
|
||||
mkdir docs/tutorials
|
||||
cp -rf tutorial/src/* docs/tutorials
|
||||
mv tutorial/src/SUMMARY.zh.md docs/tutorials/index.zh.md
|
||||
mv tutorial/src/SUMMARY.md docs/tutorials/index.md
|
||||
|
||||
- uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: 3.x
|
||||
|
||||
- name: Install dependents
|
||||
- name: Install all
|
||||
run: |
|
||||
pip install mkdocs-material=="9.*" mkdocs-static-i18n=="0.53"
|
||||
pip install "mkdocs-material[imaging]"
|
||||
pip install mkdocs-git-revision-date-localized-plugin
|
||||
pip install mkdocs-git-authors-plugin
|
||||
make install
|
||||
|
||||
- name: Test page build
|
||||
run: |
|
||||
|
||||
Reference in New Issue
Block a user